From 198e066d001fd3b37cc1b86b49713d7817f88e8e Mon Sep 17 00:00:00 2001
From: Wx-2025 <351320169@qq.com>
Date: Sun, 24 Aug 2025 11:54:15 +0800
Subject: [PATCH] Update table-bindings.js
---
ui/table-bindings.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ui/table-bindings.js b/ui/table-bindings.js
index 39a3cb9..4efab4f 100644
--- a/ui/table-bindings.js
+++ b/ui/table-bindings.js
@@ -1 +1 @@
-const _0x33c8f3=_0x5e44;(function(_0x4f6809,_0x40a2ee){const _0x3165ae=_0x5e44,_0x37c398=_0x4f6809();while(!![]){try{const _0x1dfb32=-parseInt(_0x3165ae(0xba))/0x1*(parseInt(_0x3165ae(0x121))/0x2)+parseInt(_0x3165ae(0x90))/0x3+-parseInt(_0x3165ae(0x7d))/0x4*(parseInt(_0x3165ae(0xe7))/0x5)+-parseInt(_0x3165ae(0x12a))/0x6+-parseInt(_0x3165ae(0x99))/0x7+parseInt(_0x3165ae(0x12b))/0x8+parseInt(_0x3165ae(0xea))/0x9*(parseInt(_0x3165ae(0xdc))/0xa);if(_0x1dfb32===_0x40a2ee)break;else _0x37c398['push'](_0x37c398['shift']());}catch(_0x298703){_0x37c398['push'](_0x37c398['shift']());}}}(_0x2535,0xeb606));import*as _0x1225e6 from'../core/table-system/manager.js';import{log}from'../core/table-system/logger.js';import{extension_settings}from'/scripts/extensions.js';function _0x2535(){const _0x4c956f=['auto','focus','danger','opacity','input','flex','floor-end-input','.amily2-context-menu','trim','100%','#rule-delete','alignItems','close','请输入新表格的名称:','stopPropagation','target','keydown','amily2-table-','rows','\x0a\x20\x20\x20\x20\x20\x20\x20\x20
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
\x0a\x20\x20\x20\x20\x20\x20\x20\x20',_0x5208bf=$(_0x461be4)[_0x3a8440(0xd3)](_0x3a8440(0x104)),_0xde74a3=()=>{const _0x52f189=_0x3a8440;_0x5208bf[0x0][_0x52f189(0xb2)](),_0x5208bf[_0x52f189(0xee)]();};_0x5208bf[_0x3a8440(0xc8)](_0x3a8440(0x146))['on'](_0x3a8440(0x12f),()=>{const _0x1ba56e=_0x3a8440,_0x5e6acd={'note':_0x5208bf[_0x1ba56e(0xc8)]('#rule-note')['val'](),'rule_add':_0x5208bf[_0x1ba56e(0xc8)](_0x1ba56e(0x163))[_0x1ba56e(0x118)](),'rule_delete':_0x5208bf[_0x1ba56e(0xc8)](_0x1ba56e(0xb0))[_0x1ba56e(0x118)](),'rule_update':_0x5208bf[_0x1ba56e(0xc8)](_0x1ba56e(0xc9))[_0x1ba56e(0x118)]()};_0x1225e6[_0x1ba56e(0x13b)](_0x27b6a0,_0x5e6acd),_0xde74a3();}),_0x5208bf[_0x3a8440(0xc8)](_0x3a8440(0x16d))['on'](_0x3a8440(0x12f),_0xde74a3),_0x5208bf[0x0]['showModal']();}function bindInjectionSettings(){const _0x3f8101=_0x33c8f3,_0x5c5d6d=extension_settings[extensionName],_0x5b1abb=document[_0x3f8101(0x174)](_0x3f8101(0xda)),_0x391bd4=document['getElementById'](_0x3f8101(0x83)),_0x38b3dd=document[_0x3f8101(0x174)](_0x3f8101(0xbb)),_0x2f33eb=document[_0x3f8101(0x174)](_0x3f8101(0xd4)),_0xd25e55=document['querySelectorAll'](_0x3f8101(0xc4));if(!_0x5b1abb||!_0x391bd4||!_0x38b3dd||!_0x2f33eb||!_0xd25e55[_0x3f8101(0x17a)])return;const _0x4f6f37=()=>{const _0x162899=_0x3f8101,_0x403ce4=_0x38b3dd['value'],_0x1ea4bb=_0x5b1abb[_0x162899(0x92)],_0x41bff3=_0x403ce4==='1';_0x391bd4['disabled']=!_0x1ea4bb,_0x38b3dd[_0x162899(0xe2)]=!_0x1ea4bb,_0x2f33eb[_0x162899(0xe2)]=!_0x1ea4bb||!_0x41bff3,_0xd25e55[_0x162899(0x117)](_0x5972f6=>_0x5972f6[_0x162899(0xe2)]=!_0x1ea4bb||!_0x41bff3);const _0x3947e0=_0x1ea4bb?'1':_0x162899(0x143);_0x391bd4['style'][_0x162899(0xa9)]=_0x3947e0;_0x391bd4[_0x162899(0x170)]('.control-block-with-switch')&&(_0x391bd4[_0x162899(0x170)](_0x162899(0xc0))[_0x162899(0x16c)][_0x162899(0xa9)]=_0x3947e0);_0x38b3dd['style'][_0x162899(0xa9)]=_0x3947e0;_0x38b3dd['previousElementSibling']&&(_0x38b3dd['previousElementSibling']['style'][_0x162899(0xa9)]=_0x3947e0);const _0x27f5d4=_0x1ea4bb&&_0x41bff3?'1':'0.5';_0x2f33eb[_0x162899(0x16c)][_0x162899(0xa9)]=_0x27f5d4;_0x2f33eb['previousElementSibling']&&(_0x2f33eb[_0x162899(0x164)][_0x162899(0x16c)]['opacity']=_0x27f5d4);const _0x126c1a=_0x1ea4bb&&_0x41bff3?'1':_0x162899(0x143),_0x545601=document['getElementById'](_0x162899(0x8f))?.['closest'](_0x162899(0xe3));_0x545601&&(_0x545601[_0x162899(0x16c)][_0x162899(0xa9)]=_0x126c1a,_0x545601[_0x162899(0x164)]&&(_0x545601['previousElementSibling'][_0x162899(0x16c)][_0x162899(0xa9)]=_0x126c1a));const _0xcfabfb=document['querySelectorAll']('input[name=\x22filling-mode\x22]');_0xcfabfb[_0x162899(0x117)](_0x199000=>{const _0x236aec=_0x162899;_0x199000[_0x236aec(0xe2)]=!_0x1ea4bb;const _0x55fbf5=_0x199000[_0x236aec(0x170)](_0x236aec(0x154));_0x55fbf5&&(_0x55fbf5[_0x236aec(0x16c)]['opacity']=_0x1ea4bb?'1':_0x236aec(0x143));});const _0x532b85=document[_0x162899(0x174)]('fill-table-now-btn');_0x532b85&&(_0x532b85['disabled']=!_0x1ea4bb,_0x532b85[_0x162899(0x16c)][_0x162899(0xa9)]=_0x1ea4bb?'1':'0.5');};_0x5b1abb[_0x3f8101(0x92)]=_0x5c5d6d[_0x3f8101(0x160)]!==![],_0x391bd4[_0x3f8101(0x92)]=_0x5c5d6d[_0x3f8101(0x17b)],_0x38b3dd[_0x3f8101(0x182)]=_0x5c5d6d[_0x3f8101(0xf4)][_0x3f8101(0xbc)],_0x2f33eb[_0x3f8101(0x182)]=_0x5c5d6d[_0x3f8101(0xf4)][_0x3f8101(0x16f)],_0xd25e55[_0x3f8101(0x117)](_0x3a96d3=>{const _0x5eb769=_0x3f8101;parseInt(_0x3a96d3[_0x5eb769(0x182)],0xa)===_0x5c5d6d[_0x5eb769(0xf4)][_0x5eb769(0x151)]&&(_0x3a96d3[_0x5eb769(0x92)]=!![]);}),_0x4f6f37(),_0x5b1abb[_0x3f8101(0x142)]('change',()=>{const _0x2c9569=_0x3f8101;_0x5c5d6d[_0x2c9569(0x160)]=_0x5b1abb[_0x2c9569(0x92)],saveSettingsDebounced(),_0x4f6f37();const _0x29ffa8=_0x5b1abb[_0x2c9569(0x92)]?_0x2c9569(0x179):_0x2c9569(0x178);toastr[_0x2c9569(0xa1)](_0x2c9569(0x183)+_0x29ffa8+'。'),log(_0x2c9569(0x183)+_0x29ffa8+'。',_0x2c9569(0xa1));}),_0x391bd4[_0x3f8101(0x142)](_0x3f8101(0x133),()=>{_0x5c5d6d['table_injection_enabled']=_0x391bd4['checked'],saveSettingsDebounced();}),_0x38b3dd[_0x3f8101(0x142)]('change',()=>{const _0x2ad122=_0x3f8101;_0x5c5d6d['injection'][_0x2ad122(0xbc)]=parseInt(_0x38b3dd[_0x2ad122(0x182)],0xa),saveSettingsDebounced(),_0x4f6f37();}),_0x2f33eb[_0x3f8101(0x142)](_0x3f8101(0xaa),()=>{const _0x2446ba=_0x3f8101;_0x5c5d6d[_0x2446ba(0xf4)][_0x2446ba(0x16f)]=parseInt(_0x2f33eb[_0x2446ba(0x182)],0xa),saveSettingsDebounced();}),_0xd25e55[_0x3f8101(0x117)](_0x230d84=>{const _0x201377=_0x3f8101;_0x230d84[_0x201377(0x142)](_0x201377(0x133),()=>{const _0x48bee9=_0x201377;_0x230d84[_0x48bee9(0x92)]&&(_0x5c5d6d['injection'][_0x48bee9(0x151)]=parseInt(_0x230d84[_0x48bee9(0x182)],0xa),saveSettingsDebounced());});}),log(_0x3f8101(0x175),_0x3f8101(0xbd));}function updateAndSaveTableSetting(_0x1c7b93,_0x5c8de2){!extension_settings[extensionName]&&(extension_settings[extensionName]={}),extension_settings[extensionName][_0x1c7b93]=_0x5c8de2,saveSettingsDebounced();}export function bindTableEvents(){const _0x30ea5f=_0x33c8f3,_0x5a8ad6=document[_0x30ea5f(0x174)](_0x30ea5f(0x10f));if(!_0x5a8ad6||_0x5a8ad6['dataset'][_0x30ea5f(0xc3)])return;log(_0x30ea5f(0x112),_0x30ea5f(0xa1));const _0x210e3c=_0x5a8ad6[_0x30ea5f(0x110)]('input[name=\x22filling-mode\x22]'),_0x2fb50e=()=>{const _0x32fc0d=_0x30ea5f,_0x3e719a=extension_settings[extensionName]?.[_0x32fc0d(0x14a)]||_0x32fc0d(0x10c);_0x210e3c[_0x32fc0d(0x117)](_0x153b7b=>{const _0x2e7cf9=_0x32fc0d;_0x153b7b['checked']=_0x153b7b[_0x2e7cf9(0x182)]===_0x3e719a;});};_0x210e3c[_0x30ea5f(0x117)](_0x3a9961=>{const _0x4560e7=_0x30ea5f;_0x3a9961[_0x4560e7(0x142)](_0x4560e7(0x133),function(){const _0x1be240=_0x4560e7,_0x47e1f9=this[_0x1be240(0x182)];updateAndSaveTableSetting(_0x1be240(0x14a),_0x47e1f9);let _0x52432f='原始填表';if(_0x47e1f9===_0x1be240(0x8d))_0x52432f=_0x1be240(0x17f);if(_0x47e1f9===_0x1be240(0xfb))_0x52432f=_0x1be240(0x16a);toastr['info']('填表模式已切换为\x20'+_0x52432f+'。'),_0x2fb50e();});}),_0x2fb50e();const _0x3af2d2=()=>{renderTables(),bindInjectionSettings();};_0x3af2d2(),bindBatchFillButton(),bindFloorFillButtons(),bindTemplateEditors();const _0x5741b6=document['querySelector'](_0x30ea5f(0x107));_0x5741b6&&_0x5741b6['addEventListener'](_0x30ea5f(0x12f),_0x57dd7d=>{const _0x20f95f=_0x30ea5f,_0x4b27f6=_0x57dd7d[_0x20f95f(0xb5)][_0x20f95f(0x170)](_0x20f95f(0x15c));if(!_0x4b27f6)return;const _0x2dc25a=_0x4b27f6[_0x20f95f(0x148)][_0x20f95f(0x7e)];if(!_0x2dc25a)return;const _0x2766d8=_0x4b27f6['closest'](_0x20f95f(0x11e));if(!_0x2766d8)return;_0x2766d8[_0x20f95f(0x110)](_0x20f95f(0x15c))[_0x20f95f(0x117)](_0x299d4c=>_0x299d4c[_0x20f95f(0x15d)][_0x20f95f(0xee)](_0x20f95f(0x94))),_0x4b27f6['classList'][_0x20f95f(0x96)](_0x20f95f(0x94)),_0x2766d8['querySelectorAll'](_0x20f95f(0x137))[_0x20f95f(0x117)](_0x24de47=>_0x24de47[_0x20f95f(0x15d)][_0x20f95f(0xee)]('active'));const _0x429ed0=_0x2766d8[_0x20f95f(0xf9)](_0x20f95f(0xd9)+_0x2dc25a+_0x20f95f(0x162));_0x429ed0&&_0x429ed0[_0x20f95f(0x15d)][_0x20f95f(0x96)](_0x20f95f(0x94));});const _0x167d47=document['getElementById'](_0x30ea5f(0x165)),_0x6ce665=document[_0x30ea5f(0x174)]('amily2-export-preset-full-btn'),_0x3361d3=document[_0x30ea5f(0x174)](_0x30ea5f(0xed));_0x167d47&&_0x167d47[_0x30ea5f(0x142)]('click',()=>_0x1225e6['exportPreset']());_0x6ce665&&_0x6ce665[_0x30ea5f(0x142)](_0x30ea5f(0x12f),()=>_0x1225e6[_0x30ea5f(0x113)]());_0x3361d3&&_0x3361d3[_0x30ea5f(0x142)]('click',()=>_0x1225e6[_0x30ea5f(0x102)](_0x3af2d2));const _0x301101=document[_0x30ea5f(0x174)]('amily2-clear-all-tables-btn');_0x301101&&_0x301101[_0x30ea5f(0x142)](_0x30ea5f(0x12f),()=>{const _0x160db6=_0x30ea5f;confirm(_0x160db6(0x8c))&&(_0x1225e6[_0x160db6(0x108)](),_0x3af2d2());});const _0x1b77df=document[_0x30ea5f(0x174)](_0x30ea5f(0xbf));_0x1b77df&&_0x1b77df[_0x30ea5f(0x142)](_0x30ea5f(0x12f),()=>{const _0x538f46=_0x30ea5f,_0x538767=prompt(_0x538f46(0xb3),_0x538f46(0x166));_0x538767&&_0x538767[_0x538f46(0xae)]()&&(_0x1225e6['addTable'](_0x538767[_0x538f46(0xae)]()),_0x3af2d2());});const _0x3e43f9=getAllTablesContainer();if(_0x3e43f9){_0x3e43f9[_0x30ea5f(0x142)](_0x30ea5f(0x12f),_0x5b6d05=>{const _0x5107f6=_0x30ea5f,_0x44de75=_0x5b6d05['target'][_0x5107f6(0x170)]('th');if(_0x44de75&&!_0x44de75[_0x5107f6(0x15d)][_0x5107f6(0x9a)](_0x5107f6(0x14f))){toggleColumnContextMenu(_0x5b6d05);return;}const _0x7c8db0=_0x5b6d05[_0x5107f6(0xb5)][_0x5107f6(0x170)](_0x5107f6(0x155));if(_0x7c8db0){toggleRowContextMenu(_0x5b6d05);return;}const _0x131d2d=_0x5b6d05[_0x5107f6(0xb5)]['closest'](_0x5107f6(0xf3));if(!_0x131d2d)return;const _0x5c6539=parseInt(_0x131d2d[_0x5107f6(0x148)][_0x5107f6(0x168)],0xa);if(_0x131d2d[_0x5107f6(0x105)]('.add-row-btn'))_0x1225e6[_0x5107f6(0x169)](_0x5c6539),_0x3af2d2();else{if(_0x131d2d[_0x5107f6(0x105)](_0x5107f6(0x130)))_0x1225e6['addColumn'](_0x5c6539),_0x3af2d2();else{if(_0x131d2d[_0x5107f6(0x105)](_0x5107f6(0x13d))||_0x131d2d[_0x5107f6(0x105)](_0x5107f6(0x9f))){const _0x4dc0bf=_0x131d2d[_0x5107f6(0x15d)][_0x5107f6(0x9a)](_0x5107f6(0xd6))?'up':'down';_0x1225e6[_0x5107f6(0x10d)](_0x5c6539,_0x4dc0bf),_0x3af2d2();}else{if(_0x131d2d[_0x5107f6(0x105)](_0x5107f6(0x135)))openRuleEditor(_0x5c6539);else{if(_0x131d2d[_0x5107f6(0x105)](_0x5107f6(0x115))){const _0x387b8b=_0x1225e6['getMemoryState'](),_0x20bc1b=_0x387b8b[_0x5c6539]?.['name']||_0x5107f6(0x139);confirm('【最终警告】您确定要永久废黜表格\x20“['+_0x20bc1b+']”\x20吗?此操作不可逆!')&&(_0x1225e6[_0x5107f6(0xd1)](_0x5c6539),_0x3af2d2());}}}}}});const _0x1357cf=()=>'ontouchstart'in window||navigator[_0x30ea5f(0xd8)]>0x0;if(_0x1357cf()){let _0x5e85e2=0x0,_0xc6beee=null;_0x3e43f9[_0x30ea5f(0x142)](_0x30ea5f(0x9e),_0x1bc578=>{const _0x2419d5=_0x30ea5f,_0x10d7fd=_0x1bc578[_0x2419d5(0xb5)][_0x2419d5(0x170)]('td');if(!_0x10d7fd||_0x10d7fd[_0x2419d5(0x148)]['colIndex']===undefined)return;const _0x37a037=new Date()[_0x2419d5(0x172)](),_0x35fc20=_0x37a037-_0x5e85e2;_0x35fc20<0x12c&&_0x35fc20>0x0&&_0xc6beee===_0x10d7fd&&(_0x1bc578[_0x2419d5(0x126)](),_0x10d7fd['getAttribute'](_0x2419d5(0xf1))!==_0x2419d5(0x176)&&(_0x10d7fd[_0x2419d5(0x122)](_0x2419d5(0xf1),_0x2419d5(0x176)),setTimeout(()=>_0x10d7fd['focus'](),0x0))),_0x5e85e2=_0x37a037,_0xc6beee=_0x10d7fd;});}_0x3e43f9[_0x30ea5f(0x142)](_0x30ea5f(0x153),_0x5555fa=>{const _0x22aff3=_0x30ea5f,_0x2646ab=_0x5555fa[_0x22aff3(0xb5)];if(_0x2646ab[_0x22aff3(0xcd)]!=='TD'||_0x2646ab[_0x22aff3(0x144)](_0x22aff3(0xf1))!==_0x22aff3(0x176))return;const _0x4e5389=()=>'ontouchstart'in window||navigator['maxTouchPoints']>0x0;_0x4e5389()&&_0x2646ab[_0x22aff3(0x122)](_0x22aff3(0xf1),_0x22aff3(0x10b));const _0x37bad3=_0x2646ab[_0x22aff3(0x170)]('table');if(!_0x37bad3)return;const _0x15e524=parseInt(_0x37bad3[_0x22aff3(0x148)]['tableIndex'],0xa),_0x3ad6d7=parseInt(_0x2646ab[_0x22aff3(0x170)]('tr')[_0x22aff3(0x148)][_0x22aff3(0x15e)],0xa),_0x1ce406=parseInt(_0x2646ab[_0x22aff3(0x148)][_0x22aff3(0x187)],0xa),_0x2f8ff0=_0x2646ab[_0x22aff3(0xe8)];_0x1225e6[_0x22aff3(0x159)](_0x15e524,_0x3ad6d7,_0x1ce406);const _0x19460f={[_0x1ce406]:_0x2f8ff0};_0x1225e6[_0x22aff3(0x116)](_0x15e524,_0x3ad6d7,_0x19460f),_0x3af2d2();},!![]);}_0x5a8ad6[_0x30ea5f(0x148)]['eventsBound']=_0x30ea5f(0x176),log(_0x30ea5f(0xc1),_0x30ea5f(0xbd));}function bindBatchFillButton(){const _0xba786a=_0x33c8f3,_0x5cf245=document[_0xba786a(0x174)](_0xba786a(0xd2));if(_0x5cf245){if(_0x5cf245[_0xba786a(0x148)][_0xba786a(0x8b)])return;_0x5cf245[_0xba786a(0x142)](_0xba786a(0x12f),_0x57432a=>{const _0x21e002=_0xba786a,_0x557c1b=extension_settings[extensionName],_0x572d4d=_0x557c1b['table_system_enabled']!==![];if(!_0x572d4d){_0x57432a[_0x21e002(0x126)](),toastr[_0x21e002(0x123)](_0x21e002(0x11b));return;}startBatchFilling();}),_0x5cf245[_0xba786a(0x148)][_0xba786a(0x8b)]=_0xba786a(0x176),log(_0xba786a(0x11d),_0xba786a(0xbd));}}function bindFloorFillButtons(){const _0x49b5ff=_0x33c8f3,_0x5f5272=document[_0x49b5ff(0x174)](_0x49b5ff(0x127)),_0x39cf67=document[_0x49b5ff(0x174)](_0x49b5ff(0xf5));if(_0x5f5272){if(_0x5f5272['dataset']['floorEventBound'])return;_0x5f5272['addEventListener'](_0x49b5ff(0x12f),_0x3e5275=>{const _0x1b095b=_0x49b5ff,_0x5c2acd=extension_settings[extensionName],_0x5b22fa=_0x5c2acd['table_system_enabled']!==![];if(!_0x5b22fa){_0x3e5275['preventDefault'](),toastr[_0x1b095b(0x123)](_0x1b095b(0x11b));return;}const _0x2b9f10=document['getElementById']('floor-start-input'),_0x2358fc=document[_0x1b095b(0x174)](_0x1b095b(0xac)),_0x5b5bac=parseInt(_0x2b9f10[_0x1b095b(0x182)],0xa),_0x31e85f=parseInt(_0x2358fc[_0x1b095b(0x182)],0xa);if(!_0x5b5bac||!_0x31e85f){toastr['warning'](_0x1b095b(0x171));return;}if(_0x5b5bac>_0x31e85f){toastr[_0x1b095b(0x123)](_0x1b095b(0xeb));return;}if(_0x5b5bac<0x1){toastr['warning'](_0x1b095b(0xe5));return;}import(_0x1b095b(0xcc))['then'](_0x1ca3c9=>{const _0x532c05=_0x1b095b;_0x1ca3c9[_0x532c05(0x150)](_0x5b5bac,_0x31e85f);});}),_0x5f5272[_0x49b5ff(0x148)][_0x49b5ff(0x14c)]=_0x49b5ff(0x176),log('\x22选定楼层填表\x22按钮已成功绑定。',_0x49b5ff(0xbd));}if(_0x39cf67){if(_0x39cf67['dataset'][_0x49b5ff(0x157)])return;_0x39cf67[_0x49b5ff(0x142)]('click',_0x3f65cb=>{const _0x540625=_0x49b5ff,_0x1b9fc6=extension_settings[extensionName],_0x534308=_0x1b9fc6[_0x540625(0x160)]!==![];if(!_0x534308){_0x3f65cb['preventDefault'](),toastr[_0x540625(0x123)]('表格系统总开关已关闭,请先启用总开关。');return;}import(_0x540625(0xcc))[_0x540625(0x167)](_0x4262e2=>{_0x4262e2['startCurrentFloorFilling']();});}),_0x39cf67[_0x49b5ff(0x148)]['currentEventBound']='true',log(_0x49b5ff(0x9b),_0x49b5ff(0xbd));}}function bindTemplateEditors(){const _0x2609ee=_0x33c8f3,_0x3be6cb=document[_0x2609ee(0x174)]('ai-rule-template-editor'),_0x3d67cb=document[_0x2609ee(0x174)](_0x2609ee(0x103)),_0x375b9c=document[_0x2609ee(0x174)](_0x2609ee(0x9c)),_0x3d6f76=document['getElementById'](_0x2609ee(0x17d)),_0x2a58bd=document[_0x2609ee(0x174)]('ai-flow-template-save-btn'),_0x13d067=document[_0x2609ee(0x174)]('ai-flow-template-restore-btn');if(!_0x3be6cb||!_0x3d6f76){log(_0x2609ee(0x7c),'warn');return;}_0x3be6cb[_0x2609ee(0x182)]=_0x1225e6[_0x2609ee(0x98)](),_0x3d6f76['value']=_0x1225e6['getBatchFillerFlowTemplate'](),_0x3d67cb[_0x2609ee(0x142)](_0x2609ee(0x12f),()=>{const _0x3c9334=_0x2609ee;_0x1225e6[_0x3c9334(0xa5)](_0x3be6cb[_0x3c9334(0x182)]),toastr[_0x3c9334(0xbd)](_0x3c9334(0x12d)),log(_0x3c9334(0x152),'success');}),_0x2a58bd['addEventListener']('click',()=>{const _0x1bc0a4=_0x2609ee;_0x1225e6[_0x1bc0a4(0xcf)](_0x3d6f76['value']),toastr[_0x1bc0a4(0xbd)](_0x1bc0a4(0x10e)),log(_0x1bc0a4(0x184),'success');}),_0x375b9c[_0x2609ee(0x142)]('click',()=>{const _0x45febf=_0x2609ee;confirm(_0x45febf(0xde))&&(_0x3be6cb[_0x45febf(0x182)]=DEFAULT_AI_RULE_TEMPLATE,_0x1225e6['saveBatchFillerRuleTemplate'](_0x3be6cb[_0x45febf(0x182)]),toastr[_0x45febf(0xa1)](_0x45febf(0x100)),log('批量填表-规则提示词已恢复默认。',_0x45febf(0xa1)));}),_0x13d067[_0x2609ee(0x142)]('click',()=>{const _0x30cb5a=_0x2609ee;confirm('您确定要将流程提示词恢复为默认设置吗?')&&(_0x3d6f76[_0x30cb5a(0x182)]=DEFAULT_AI_FLOW_TEMPLATE,_0x1225e6[_0x30cb5a(0xcf)](_0x3d6f76[_0x30cb5a(0x182)]),toastr[_0x30cb5a(0xa1)](_0x30cb5a(0x145)),log(_0x30cb5a(0x15f),_0x30cb5a(0xa1)));}),log('指令模板编辑器已成功绑定。','success');}
+const _0x3fb332=_0x5ea8;(function(_0x3f2db3,_0x25a51c){const _0x1d4385=_0x5ea8,_0x587e72=_0x3f2db3();while(!![]){try{const _0x1bc200=-parseInt(_0x1d4385(0x114))/0x1*(-parseInt(_0x1d4385(0xf1))/0x2)+-parseInt(_0x1d4385(0x1e3))/0x3*(-parseInt(_0x1d4385(0xfd))/0x4)+-parseInt(_0x1d4385(0x197))/0x5*(parseInt(_0x1d4385(0x1bf))/0x6)+-parseInt(_0x1d4385(0x1bc))/0x7+parseInt(_0x1d4385(0x13c))/0x8*(-parseInt(_0x1d4385(0x169))/0x9)+-parseInt(_0x1d4385(0xe7))/0xa+parseInt(_0x1d4385(0x19d))/0xb;if(_0x1bc200===_0x25a51c)break;else _0x587e72['push'](_0x587e72['shift']());}catch(_0xf64f6f){_0x587e72['push'](_0x587e72['shift']());}}}(_0xd81b,0x3d055));import*as _0x5cc481 from'../core/table-system/manager.js';import{log}from'../core/table-system/logger.js';import{extension_settings}from'/scripts/extensions.js';import{extensionName}from'../utils/settings.js';import{saveSettingsDebounced}from'/script.js';import{startBatchFilling}from'../core/table-system/batch-filler.js';import{DEFAULT_AI_RULE_TEMPLATE,DEFAULT_AI_FLOW_TEMPLATE}from'../core/table-system/settings.js';function _0x5ea8(_0x35c3ee,_0x8caac3){const _0xd81bbc=_0xd81b();return _0x5ea8=function(_0x5ea840,_0x3dbb41){_0x5ea840=_0x5ea840-0xe3;let _0x27615a=_0xd81bbc[_0x5ea840];return _0x27615a;},_0x5ea8(_0x35c3ee,_0x8caac3);}const getAllTablesContainer=()=>document[_0x3fb332(0x143)](_0x3fb332(0x175));function toggleRowContextMenu(_0x597439){const _0x1110de=_0x3fb332;_0x597439[_0x1110de(0x1bb)](),_0x597439[_0x1110de(0x1d3)]();const _0x279a00=_0x597439[_0x1110de(0x1d7)][_0x1110de(0xed)]('td.index-col');if(!_0x279a00)return;const _0xa74312=_0x279a00['querySelector'](_0x1110de(0x11c));if(!_0xa74312)return;const _0x4322bc=_0xa74312['classList'][_0x1110de(0x171)](_0x1110de(0x18e));document[_0x1110de(0x15a)]('.amily2-context-menu.amily2-menu-active')[_0x1110de(0xf0)](_0x2cf5ba=>{const _0x7e1aad=_0x1110de;_0x2cf5ba[_0x7e1aad(0x110)][_0x7e1aad(0x1ba)](_0x7e1aad(0x18e));});!_0x4322bc&&_0xa74312[_0x1110de(0x110)]['add']('amily2-menu-active');const _0x3574af=_0x267ae4=>{const _0x24f290=_0x1110de;!_0xa74312[_0x24f290(0x171)](_0x267ae4[_0x24f290(0x1d7)])&&(_0xa74312[_0x24f290(0x110)][_0x24f290(0x1ba)](_0x24f290(0x18e)),document[_0x24f290(0xe4)](_0x24f290(0x1ed),_0x3574af,!![]));};setTimeout(()=>{const _0x149625=_0x1110de;_0xa74312[_0x149625(0x110)]['contains'](_0x149625(0x18e))&&document[_0x149625(0x131)](_0x149625(0x1ed),_0x3574af,!![]);},0x0);}function toggleColumnContextMenu(_0x5163e8){const _0x2c8f63=_0x3fb332;_0x5163e8[_0x2c8f63(0x1bb)](),_0x5163e8[_0x2c8f63(0x1d3)]();const _0x5e46f0=_0x5163e8['target'][_0x2c8f63(0xed)]('th');if(!_0x5e46f0)return;const _0x5c7bc6=_0x5e46f0[_0x2c8f63(0x110)][_0x2c8f63(0x171)]('amily2-menu-open');document[_0x2c8f63(0x15a)]('th.amily2-menu-open')[_0x2c8f63(0xf0)](_0x4d382f=>{const _0x446fef=_0x2c8f63;_0x4d382f[_0x446fef(0x110)][_0x446fef(0x1ba)](_0x446fef(0x1c2));});!_0x5c7bc6&&_0x5e46f0['classList'][_0x2c8f63(0x160)](_0x2c8f63(0x1c2));const _0x55d9b5=_0x5249e2=>{const _0x3d2c23=_0x2c8f63;!_0x5e46f0[_0x3d2c23(0x171)](_0x5249e2['target'])&&(_0x5e46f0['classList'][_0x3d2c23(0x1ba)](_0x3d2c23(0x1c2)),document[_0x3d2c23(0xe4)](_0x3d2c23(0x1ed),_0x55d9b5,!![]));};setTimeout(()=>{const _0x321508=_0x2c8f63;_0x5e46f0[_0x321508(0x110)]['contains']('amily2-menu-open')&&document['addEventListener'](_0x321508(0x1ed),_0x55d9b5,!![]);},0x0);}function showColumnNameEditor(_0x57a436,_0x541a71,_0x101de7){const _0xa51574=_0x3fb332,_0x2d4cfb=_0xa51574(0x1ce)+_0x101de7+_0xa51574(0x14a),_0x14ee5e=$(_0x2d4cfb)['appendTo'](_0xa51574(0x19e)),_0x14de1f=_0x14ee5e[_0xa51574(0x1b0)]('#column-name-input'),_0x178fce=()=>{const _0x3b5545=_0xa51574;_0x14ee5e[0x0][_0x3b5545(0xf9)](),_0x14ee5e[_0x3b5545(0x1ba)]();};_0x14ee5e[_0xa51574(0x1b0)](_0xa51574(0x134))['on']('click',()=>{const _0x482c86=_0xa51574,_0x3c3488=_0x14de1f[_0x482c86(0x16b)]()[_0x482c86(0x198)]();if(_0x3c3488&&_0x3c3488!==_0x101de7)_0x5cc481[_0x482c86(0x100)](_0x57a436,_0x541a71,_0x3c3488),renderTables(),toastr[_0x482c86(0x193)](_0x482c86(0x1a7)+_0x3c3488+'\x22');else{if(!_0x3c3488){toastr[_0x482c86(0xe3)](_0x482c86(0x156)),_0x14de1f[_0x482c86(0x1eb)]();return;}}_0x178fce();}),_0x14ee5e[_0xa51574(0x1b0)]('.popup-button-cancel')['on']('click',_0x178fce),_0x14de1f['on'](_0xa51574(0x155),_0x84e050=>{const _0x45b6d6=_0xa51574;_0x84e050[_0x45b6d6(0x1e0)]===0xd&&_0x14ee5e['find'](_0x45b6d6(0x134))[_0x45b6d6(0x1ed)]();}),_0x14de1f['on']('keydown',_0x41555b=>{const _0x4ce23a=_0xa51574;_0x41555b[_0x4ce23a(0x1e0)]===0x1b&&_0x178fce();}),_0x14ee5e[0x0][_0xa51574(0x1a0)](),_0x14de1f[_0xa51574(0x1eb)]()[_0xa51574(0x1e1)]();}function positionContextMenu(_0x2df2b7,_0x4d16cd){const _0x533c60=_0x3fb332;_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x14f)]=_0x533c60(0x127),_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x1a2)]=_0x533c60(0x1ab),_0x2df2b7['style'][_0x533c60(0x16f)]='0',_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0xe9)]=_0x533c60(0x1d2),_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x1cf)]='',_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x13a)]='',_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x15d)]='',_0x2df2b7['style']['overflowY']='';const _0xf12810=window[_0x533c60(0x12c)],_0x224021=_0x4d16cd['getBoundingClientRect'](),_0x5731a8=0xc8,_0x48ab77=_0x4d16cd[_0x533c60(0xed)]('.hly-scroll'),_0x1866d4=_0x48ab77?_0x48ab77[_0x533c60(0x11f)]():{'top':0x0,'bottom':_0xf12810},_0x936bdf=Math[_0x533c60(0x128)](_0xf12810,_0x1866d4['bottom'])-_0x224021[_0x533c60(0x182)],_0x817e9d=_0x224021[_0x533c60(0xe5)]-Math['max'](0x0,_0x1866d4[_0x533c60(0xe5)]);_0x936bdf<_0x5731a8&&_0x817e9d>_0x936bdf?(_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0xe5)]=_0x533c60(0x1d2),_0x2df2b7['style'][_0x533c60(0x182)]=_0x533c60(0x142),_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x13a)]=_0x533c60(0x13f)):(_0x2df2b7['style'][_0x533c60(0xe5)]=_0x533c60(0x142),_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x182)]='auto',_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x1cf)]='2px');const _0xf99fc4=0xa0,_0x5aa737=_0x4d16cd['closest'](_0x533c60(0x1d9)),_0x36a2e5=_0x5aa737?_0x5aa737['closest']('div[style*=\x22overflowX\x22]'):null;if(_0x36a2e5){const _0x261c8c=_0x36a2e5[_0x533c60(0x11f)](),_0x4e1372=_0x224021['left']-_0x261c8c[_0x533c60(0x16f)];_0x4e1372+_0xf99fc4>_0x261c8c[_0x533c60(0x1b5)]-0x14&&(_0x2df2b7[_0x533c60(0x12e)][_0x533c60(0x16f)]=_0x533c60(0x1d2),_0x2df2b7['style']['right']='0');}}function _0xd81b(){const _0x20501f=['dataset','input[name=\x22filling-mode\x22]','button','startFloorRangeFilling','表格系统总开关已关闭,请先启用总开关。','.move-table-up-btn','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','add-left','colIndex','【最终警告】您确定要永久废黜表格\x20“[','error','classList','#rule-note','table-controls','您确定要将规则提示词恢复为默认设置吗?','393QAoIHs','向左移动','note','currentEventBound','在上加行','depth','amily2-context-menu','loadTables','.amily2-context-menu','delete','add-below','getBoundingClientRect','down','fa-plus-circle','流程提示词已保存。','createElement','table-injection-depth','appendTo','在左加列','absolute','min','0.5','contenteditable','addTable','innerHeight','filling_mode','style','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
保存
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
取消
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20','saveBatchFillerFlowTemplate','addEventListener','批量填表-规则提示词已恢复默认。','danger','.popup-button-ok','checked','move-left','optimized','deleteColumn','injection','marginBottom','role','2504KRBvxC','\x20行吗?','menu_button\x20small_button','2px','add-above','在右加列','100%','getElementById','amily2-import-global-preset-btn','maxTouchPoints','ai-rule-template-save-btn','move-up','table_injection_enabled','\x22\x20title=\x22编辑规则\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20