mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
edits to suggest
This commit is contained in:
committed by
openshift-cherrypick-robot
parent
f244561356
commit
c73e90bf0e
@@ -103,17 +103,16 @@ function selectVersion(currentVersion) {
|
||||
// edit in the branch
|
||||
h1.innerHTML += " <a href='https://github.com/openshift/openshift-docs/edit/" + (is4? "master" : ("enterprise-" + currentVersion)) + "/" + fn + "?" + message;
|
||||
|
||||
// add mouseover and out to the h1 tag to show or hide the link
|
||||
// unlike the links added to h2, here it is at [0], the only 'a' tag
|
||||
// added
|
||||
h1.addEventListener("mouseover", function() {
|
||||
this.getElementsByTagName('a')[0].style.visibility = "visible";
|
||||
});
|
||||
|
||||
h1.addEventListener("mouseout", function() {
|
||||
this.getElementsByTagName('a')[0].style.visibility = "hidden";
|
||||
});
|
||||
// add mouseover and out to the h1 tag to show or hide the link
|
||||
// unlike the links added to h2, here it is at [0], the only 'a' tag
|
||||
// added
|
||||
h1.addEventListener("mouseover", function() {
|
||||
this.getElementsByTagName('a')[0].style.visibility = "visible";
|
||||
});
|
||||
|
||||
h1.addEventListener("mouseout", function() {
|
||||
this.getElementsByTagName('a')[0].style.visibility = "hidden";
|
||||
});
|
||||
|
||||
if(is4) { // in version 4 also allow to edit subsections which are modules
|
||||
|
||||
@@ -145,24 +144,4 @@ function selectVersion(currentVersion) {
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
// Object.entries(element).map(( object ) => {
|
||||
// object[1].innerHTML += " <font size='-2'><a href=''>Edit this section</a></font>";
|
||||
// var fn = this.id.split("_", 1)[0] + ".adoc";
|
||||
// alert(fn);
|
||||
// object[1].addEventListener("dblclick", function() {
|
||||
// // alert(this.id);
|
||||
// // alert(this.id.split("_", 1)[0] + ".adoc");
|
||||
// var fn = this.id.split("_", 1)[0] + ".adoc";
|
||||
// // window.open("https://github.com/openshift/openshift-docs/edit/enterprise-" +
|
||||
// // currentVersion + "/modules/" + fn, "_new");
|
||||
// window.open("https://github.com/openshift/openshift-docs/edit/master/modules/" + fn, "_new");
|
||||
// });
|
||||
// });
|
||||
// }
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user