From 33f03da6a14ecb3000778e71b2df7d7128b91e8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E8=83=A1?= <3203164629@qq.com> Date: Thu, 17 Oct 2024 10:53:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=BC=96=E8=BE=91=E5=99=A8?= =?UTF-8?q?=E8=87=AA=E5=8A=A8=E4=BF=9D=E5=AD=98=E6=97=B6=E6=B2=A1=E6=9C=89?= =?UTF-8?q?=E5=B0=86=E5=86=85=E5=AE=B9=E4=BF=9D=E5=AD=98=E5=88=B0=E8=8D=89?= =?UTF-8?q?=E7=A8=BF=E7=AE=B1=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ueditor/themes/default/css/ueditor.css | 3 + .../ueditor/themes/default/images/drafts.png | Bin 0 -> 2055 bytes dzz/system/ueditor/ueditor.all.js | 169 +++++++++--------- dzz/system/ueditor/ueditor.config.js | 1 + 4 files changed, 86 insertions(+), 87 deletions(-) create mode 100644 dzz/system/ueditor/themes/default/images/drafts.png diff --git a/dzz/system/ueditor/themes/default/css/ueditor.css b/dzz/system/ueditor/themes/default/css/ueditor.css index bc9dcde..2c4fa29 100644 --- a/dzz/system/ueditor/themes/default/css/ueditor.css +++ b/dzz/system/ueditor/themes/default/css/ueditor.css @@ -739,6 +739,9 @@ div.edui-box { .edui-default .edui-for-kityminder .edui-icon { background-image: url(../images/kityminder.png); } +.edui-default .edui-for-drafts .edui-icon { + background-image: url(../images/drafts.png); +} .edui-default .edui-for-print .edui-icon:before { content: "\e67a"; } diff --git a/dzz/system/ueditor/themes/default/images/drafts.png b/dzz/system/ueditor/themes/default/images/drafts.png new file mode 100644 index 0000000000000000000000000000000000000000..c7627b2575e90a96d35b561f5e0395ddecb7c235 GIT binary patch literal 2055 zcmcIleQeZZ9PY+M*?u%$=ZftG`3p>IVHPCC{-8$~t(ssMs zB40|JB2h4i2x5>Z;84To5T^JQ5`*%g2@)e36O<(+2!aV}5PW-Ipy6ZxcuB8s+vk0r z=Y4*^zJ0!V#`H0T6ALj68`DrP%|hp~=qSD`AN@bxtxZCwQD%LcjbTNl?vaPBdwl|i zjhwB8TbVB6*u6~=cnado4-i3D5N{1N z<28l_alu2A3IH_jLnF@1_yyq+oB<3=0WZbyBm+c1i#(5Kegu-U)OK-}RF@G$R{^5K zaZHh-5{ZN-!FmiUO3{KKP=KKrhC~R`?$I4NN$U2bEQ17X#nMbiGj!Z#lp{u$6CjY) z^cv!3j#jrbIibX;q-;{O2e@m>0z;u&L*wxr+IDKYkxItz4TsfyiS<2sMH#JM!?r zhN`vq3qyT|Tc{EKGAq29Q_HrbnLYagdr;q{^7!pQ&K0nK&A?r{1 zLh~g<>2i~B=coHtH59~=OH-s3l~I|9m*j!!BUyz5WP}v}Df>7@0le1>IhbXeX=&)y zkz?1hx~^2$mBItg>l4sKZ-k^(P9XhWnI{#7Q~Z7(V7c~o0>7qPW5f(AWT+@zmcUg- zY&Wd9jQU55%TY*~derS^#Ew=`ui2<{J(>5T1un>pVj7-mI#E{KUJnq8TV$vbncLcp z(i@h~G;N{-BGOwFKMk{ub|)cQFc?Ki-?q7^o0+%e?%P-&R^k6g>zP=U4q1;vv~yB~ zyBNydV$wyS{#&nW_0IN85OuR#O*<1qwH(a_QkiWgpX8SqhGQfjT}{)qUO&sQLEg)A z3=3GmNomcPmQ_!aP`6e~`Mhpx%uYu8tvk%^^ynh@t$;dOriH!)U;jFF5X16X8>C>k zeAU8ljyC28$KQGW+@aGe_B8atOY@TBf`#PEp6pcV8+r7kKS>mG`PL7 z 0 ) { + + me._saveFlag = window.setTimeout( function () { + + save( me ); + + }, me.options.saveInterval ); + + } else { + save(me); - }, 1000); + + } + + } }, - commands: { - clear_auto_save_content: { - execCommand: function (cmd, name) { - if (saveKey && me.getPreferences(saveKey)) { - me.removePreferences(saveKey); + commands:{ + 'clearlocaldata':{ + execCommand:function (cmd, name) { + if ( saveKey && me.getPreferences( saveKey ) ) { + me.removePreferences( saveKey ) } }, notNeedUndo: true, - ignoreContentChange: true + ignoreContentChange:true }, - set_auto_save_content: { - execCommand: function (cmd, name) { - save(me); + 'getlocaldata':{ + execCommand:function (cmd, name) { + return saveKey ? me.getPreferences( saveKey ) || '' : ''; }, notNeedUndo: true, - ignoreContentChange: true + ignoreContentChange:true }, - get_auto_save_content: { - execCommand: function (cmd, name) { - return me.getPreferences(saveKey) || ""; - }, - notNeedUndo: true, - ignoreContentChange: true - }, - - auto_save_restore: { - execCommand: function (cmd, name) { - if (saveKey) { - me.body.innerHTML = - me.getPreferences(saveKey) || "

" + domUtils.fillHtml + "

"; + 'drafts':{ + execCommand:function (cmd, name) { + if ( saveKey ) { + me.body.innerHTML = me.getPreferences( saveKey ) || '

'+domUtils.fillHtml+'

'; me.focus(true); } }, queryCommandState: function () { - return saveKey ? (me.getPreferences(saveKey) === null ? -1 : 0) : -1; + return saveKey ? ( me.getPreferences( saveKey ) === null ? -1 : 0 ) : -1; }, notNeedUndo: true, - ignoreContentChange: true + ignoreContentChange:true } } - }; -}); + } +}); // plugins/formula.js UE.plugin.register("formula", function () { @@ -34691,6 +34685,7 @@ UE.ui = baidu.editor.ui = {}; "splittocells", "mergecells", "deletetable", + "drafts" ]; for (var i = 0, ci; (ci = btnCmds[i++]);) { diff --git a/dzz/system/ueditor/ueditor.config.js b/dzz/system/ueditor/ueditor.config.js index 80c50c5..0a125c9 100644 --- a/dzz/system/ueditor/ueditor.config.js +++ b/dzz/system/ueditor/ueditor.config.js @@ -145,6 +145,7 @@ "|", "contentimport", "help", // 帮助 + "drafts", ] ]