git.shiar.nl
/
minimedit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
43a352b
)
edit: avoid js warning if link not found
author
Mischa POSLAWSKY
<perl@shiar.org>
Sun, 8 Jul 2018 02:25:15 +0000
(
04:25
+0200)
committer
Mischa POSLAWSKY
<perl@shiar.org>
Mon, 9 Jul 2018 23:52:57 +0000
(
01:52
+0200)
Expect optional results.
edit.js
patch
|
blob
|
history
diff --git
a/edit.js
b/edit.js
index 1485394ab029618a9fcddc0736d02e6b3b2e65ca..1b71547f359950ab25950160e6de4195129ac495 100644
(file)
--- a/
edit.js
+++ b/
edit.js
@@
-119,6
+119,7
@@
CKEDITOR.on('instanceCreated', function (event) {
var pagebody = document.getElementsByClassName('static')[0];
if (pagebody) {
var editlink = document.querySelector('a[href="#edit"]');
+ if (editlink)
editlink.onclick = function (e) {
editlink.style.fontWeight = 'bold';
editlink.href = '';