进行了一些小修复
This commit is contained in:
1 parent
2e7cc56043
commit
d37c34f71c
114 files changed
+86
-181
No files matched your search
@@ -1,5 +1,5 @@
|
||||
/**
|
||||
* Comment expand tools — legacy-style shortcode inserts ([g=] [code] [img=] quick).
|
||||
* Comment expand tools — legacy-style shortcode inserts ([code] [img=] quick).
|
||||
*/
|
||||
(function () {
|
||||
'use strict';
|
||||
@@ -39,21 +39,6 @@
|
||||
}
|
||||
|
||||
document.addEventListener('click', function (e) {
|
||||
var sm = e.target && e.target.closest ? e.target.closest('[data-smilie], a.smilie-icon') : null;
|
||||
if (sm) {
|
||||
e.preventDefault();
|
||||
var key = sm.getAttribute('data-smilie');
|
||||
if (!key && sm.querySelector) {
|
||||
var img = sm.querySelector('[data-smilie]');
|
||||
if (img) key = img.getAttribute('data-smilie');
|
||||
}
|
||||
if (!key) return;
|
||||
insertAtCursor(findTextarea(sm), '[g=' + key + ']');
|
||||
var wrap = sm.closest('span.dropup');
|
||||
if (wrap) wrap.classList.remove('open');
|
||||
return;
|
||||
}
|
||||
|
||||
var codeBtn = e.target && e.target.closest ? e.target.closest('.input-code-submit') : null;
|
||||
if (codeBtn) {
|
||||
e.preventDefault();
|
||||
|
||||
Reference in new issue
Block a user