@kedem/okdb 1.0.1 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (142) hide show
  1. package/bin/okdb.js +1 -1
  2. package/keys/public.pem +3 -0
  3. package/okdb.js +1 -1
  4. package/package.json +2 -2
  5. package/public/admin-app.js +1 -1
  6. package/public/components/admin-route-host.ok.js +1 -1
  7. package/public/components/env-picker.ok.js +1 -1
  8. package/public/components/field-path-input.ok.js +1 -1
  9. package/public/components/field.html +154 -2
  10. package/public/components/geo-map.ok.js +1 -1
  11. package/public/components/ok-cron-input.ok.js +1 -1
  12. package/public/components/ok-dropzone.ok.js +1 -1
  13. package/public/components/ok-js-input.ok.js +1 -1
  14. package/public/components/ok-json-input.ok.js +1 -1
  15. package/public/components/ok-text-monaco-input.ok.js +1 -1
  16. package/public/components/theme-toggle.ok.js +1 -1
  17. package/public/index.html +29 -2
  18. package/public/layouts/_default.ok.html +1 -1
  19. package/public/layouts/okdb-cube.ok.html +1 -1
  20. package/public/login-app.js +1 -1
  21. package/public/login.html +205 -1
  22. package/public/modules/ok.js +1 -1
  23. package/public/sections/api/index.ok.html +1 -1
  24. package/public/sections/api/parts/api-endpoint.ok.js +1 -1
  25. package/public/sections/auth/index.ok.html +1 -1
  26. package/public/sections/auth/modals/create-token-modal.ok.js +1 -1
  27. package/public/sections/auth/modals/edit-token-modal.ok.js +1 -1
  28. package/public/sections/auth/modals/perm-info-popover.ok.js +1 -1
  29. package/public/sections/auth/parts/token-detail.ok.js +1 -1
  30. package/public/sections/auth/parts/token-list.ok.js +1 -1
  31. package/public/sections/db/index.ok.html +1 -1
  32. package/public/sections/db/modals/add-item-modal.ok.js +1 -1
  33. package/public/sections/db/modals/create-env-modal.ok.js +1 -1
  34. package/public/sections/db/modals/create-fts-modal.ok.js +1 -1
  35. package/public/sections/db/modals/create-index-modal.ok.js +1 -1
  36. package/public/sections/db/modals/create-pipeline-modal.ok.js +1 -1
  37. package/public/sections/db/modals/demo-env-modal.ok.js +1 -1
  38. package/public/sections/db/modals/remove-env-modal.ok.js +1 -1
  39. package/public/sections/db/modals/schema-edit-modal.ok.js +1 -1
  40. package/public/sections/db/parts/db-overview.ok.js +1 -1
  41. package/public/sections/db/parts/db-pipelines-panel.ok.js +1 -1
  42. package/public/sections/db/parts/edit-row.ok.js +1 -1
  43. package/public/sections/db/parts/tm-timeline.ok.js +1 -1
  44. package/public/sections/db/parts/type-changelog.ok.js +1 -1
  45. package/public/sections/db/parts/type-list.ok.js +1 -1
  46. package/public/sections/db/parts/type-pipelines-tab.ok.js +1 -1
  47. package/public/sections/db/parts/type-schema-tab.ok.js +1 -1
  48. package/public/sections/db/parts/type-viewer.ok.js +1 -1
  49. package/public/sections/db/parts/type-violations-tab.ok.js +1 -1
  50. package/public/sections/docs/index.ok.html +1 -1
  51. package/public/sections/embeddings/index.ok.html +1 -1
  52. package/public/sections/embeddings/modals/register-model-modal.ok.js +1 -1
  53. package/public/sections/embeddings/parts/embed-create-panel.ok.js +1 -1
  54. package/public/sections/embeddings/parts/embed-embedder-panel.ok.js +1 -1
  55. package/public/sections/embeddings/parts/embed-engine-declaration-editor.ok.js +1 -1
  56. package/public/sections/embeddings/parts/embed-engine-list.ok.js +1 -1
  57. package/public/sections/embeddings/parts/embed-indexer-panel.ok.js +1 -1
  58. package/public/sections/embeddings/parts/embed-lifecycle-bar.ok.js +1 -1
  59. package/public/sections/embeddings/parts/embed-model-catalog.ok.js +1 -1
  60. package/public/sections/embeddings/parts/embed-overview.ok.js +1 -1
  61. package/public/sections/embeddings/parts/embed-search-panel.ok.js +1 -1
  62. package/public/sections/embeddings/parts/embed-worker-panel.ok.js +1 -1
  63. package/public/sections/embeddings/parts/embeddings-engine-panel.ok.js +1 -1
  64. package/public/sections/embeddings/parts/engines-overview.ok.js +1 -1
  65. package/public/sections/embeddings/parts/pipeline-create-panel.ok.js +1 -1
  66. package/public/sections/engines/engine-panel-shared-style.js +1 -1
  67. package/public/sections/engines/engine-ui-utils.js +1 -1
  68. package/public/sections/engines/index.ok.html +1 -1
  69. package/public/sections/engines/modals/engine-modal.ok.js +1 -1
  70. package/public/sections/engines/parts/engine-declaration-editor.ok.js +1 -1
  71. package/public/sections/engines/parts/engine-lifecycle-actions.ok.js +1 -1
  72. package/public/sections/engines/parts/engine-panel-shell.ok.js +1 -1
  73. package/public/sections/engines/parts/engine-resource-card.ok.js +1 -1
  74. package/public/sections/engines/parts/engine-row-item.ok.js +1 -1
  75. package/public/sections/engines/parts/generic-engine-panel.ok.js +1 -1
  76. package/public/sections/files/index.ok.html +1 -1
  77. package/public/sections/files/parts/files-blob-status.ok.js +1 -1
  78. package/public/sections/files/parts/files-collection-list.ok.js +1 -1
  79. package/public/sections/files/parts/files-collection-panel.ok.js +1 -1
  80. package/public/sections/files/parts/files-file-list.ok.js +1 -1
  81. package/public/sections/files/parts/files-overview.ok.js +1 -1
  82. package/public/sections/files/parts/files-path-browser.ok.js +1 -1
  83. package/public/sections/files/parts/files-upload-panel.ok.js +1 -1
  84. package/public/sections/functions/index.ok.html +1 -1
  85. package/public/sections/functions/modals/function-modal.ok.js +1 -1
  86. package/public/sections/functions/parts/function-detail.ok.js +1 -1
  87. package/public/sections/functions/parts/function-logs.ok.js +1 -1
  88. package/public/sections/functions/parts/function-runner.ok.js +1 -1
  89. package/public/sections/functions/parts/functions-list.ok.js +1 -1
  90. package/public/sections/license/index.ok.html +1 -1
  91. package/public/sections/license/parts/license-panel.ok.js +1 -1
  92. package/public/sections/processors/index.ok.html +1 -1
  93. package/public/sections/queue/index.ok.html +1 -1
  94. package/public/sections/queue/modals/create-bucket-modal.ok.js +1 -1
  95. package/public/sections/queue/modals/edit-bucket-modal.ok.js +1 -1
  96. package/public/sections/queue/modals/edit-job-modal.ok.js +1 -1
  97. package/public/sections/queue/modals/enqueue-job-modal.ok.js +1 -1
  98. package/public/sections/queue/modals/job-type-modal.ok.js +1 -1
  99. package/public/sections/queue/parts/ok-job-form.ok.js +1 -1
  100. package/public/sections/queue/parts/queue-buckets.ok.js +1 -1
  101. package/public/sections/queue/parts/queue-job-types.ok.js +1 -1
  102. package/public/sections/queue/parts/queue-jobs.ok.js +1 -1
  103. package/public/sections/queue/parts/queue-types.ok.js +1 -1
  104. package/public/sections/queue/parts/queue-workers.ok.js +1 -1
  105. package/public/sections/sync/index.ok.html +1 -1
  106. package/public/sections/sync/parts/sync-node-detail.ok.js +1 -1
  107. package/public/sections/sync/parts/sync-retention.ok.js +1 -1
  108. package/public/sections/sync/parts/sync-topology.ok.js +1 -1
  109. package/public/sections/system/index.ok.html +1 -1
  110. package/public/sections/system/modals/data-ops-modal.ok.js +1 -1
  111. package/public/sections/system/parts/system-api-panel.ok.js +1 -1
  112. package/public/sections/system/parts/system-auth-panel.ok.js +1 -1
  113. package/public/sections/system/parts/system-log-history.ok.js +1 -1
  114. package/public/sections/system/parts/system-log.ok.js +1 -1
  115. package/public/sections/system/parts/system-status.ok.js +1 -1
  116. package/public/sections/system/parts/system-sync-panel.ok.js +1 -1
  117. package/public/sections/views/index.ok.html +1 -1
  118. package/public/sections/views/modals/create-view-modal.ok.js +1 -1
  119. package/public/sections/views/parts/view-detail.ok.js +1 -1
  120. package/public/sections/views/parts/views-list.ok.js +1 -1
  121. package/public/sections/views/parts/views-overview.ok.js +1 -1
  122. package/public/setup-app.js +1 -1
  123. package/public/setup.html +189 -1
  124. package/public/stores/auth-store.js +1 -1
  125. package/public/stores/events-store.js +1 -1
  126. package/public/stores/functions-store.js +1 -1
  127. package/public/stores/okdb-store.js +1 -1
  128. package/public/stores/theme-store.js +1 -1
  129. package/public/test-cron-input.html +53 -3
  130. package/public/test-json-input.html +182 -3
  131. package/public/util/permissions.js +1 -1
  132. package/public/util/sift-schema.js +1 -1
  133. package/public/vendor/okjs/ok.esm.min.js +1 -2
  134. package/public/view-models/type-query-vm.js +1 -1
  135. package/okdb-data/default/data.mdb +0 -0
  136. package/okdb-data/default/lock.mdb +0 -0
  137. package/okdb-data/~log/data.mdb +0 -0
  138. package/okdb-data/~log/lock.mdb +0 -0
  139. package/okdb-data/~system/data.mdb +0 -0
  140. package/okdb-data/~system/lock.mdb +0 -0
  141. package/public/images/logo.png +0 -0
  142. package/public/images/logo.svg +0 -333
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@kedem/okdb",
3
- "version": "1.0.1",
4
- "description": "A lightweight key-value database",
3
+ "version": "1.0.4",
4
+ "description": "A fast, type-oriented database — strong consistency and rich indexing at the core, with sync, vector embeddings, full-text search, and AI tooling built in. Designed for the AI era.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "engines": {
7
7
  "node": ">=18"
@@ -1 +1 @@
1
- const _0x3d272d=_0x114e;(function(_0x165d81,_0x4e7d8){const _0x36a39d=_0x114e,_0x1b751a=_0x165d81();while(!![]){try{const _0x4aa3b9=parseInt(_0x36a39d(0xd3))/0x1+-parseInt(_0x36a39d(0xe2))/0x2+-parseInt(_0x36a39d(0xed))/0x3+parseInt(_0x36a39d(0xe6))/0x4*(-parseInt(_0x36a39d(0xd9))/0x5)+-parseInt(_0x36a39d(0xcd))/0x6+parseInt(_0x36a39d(0xc8))/0x7+-parseInt(_0x36a39d(0xec))/0x8*(-parseInt(_0x36a39d(0xe8))/0x9);if(_0x4aa3b9===_0x4e7d8)break;else _0x1b751a['push'](_0x1b751a['shift']());}catch(_0x21ab5e){_0x1b751a['push'](_0x1b751a['shift']());}}}(_0x283f,0xb15b5));import _0x2fe28f from'./stores/theme-store.js';import{ok as _0x3ddef9}from'./modules/ok.js';function _0x114e(_0x3dbfe4,_0xb17b84){_0x3dbfe4=_0x3dbfe4-0xc7;const _0x283f63=_0x283f();let _0x114e1a=_0x283f63[_0x3dbfe4];return _0x114e1a;}import _0x3d12e2 from'./stores/okdb-store.js';import _0x58d739 from'./stores/events-store.js';import _0x2b7ec2 from'./stores/functions-store.js';import _0x55a748 from'./stores/auth-store.js';window[_0x3d272d(0xe7)]??={},window['__ENV__'][_0x3d272d(0xd5)]??=_0x3d272d(0xe3),window['__ENV__']['ADMIN_API']??='../admin/api',_0x3ddef9[_0x3d272d(0xcf)]={'okdb':_0x3d12e2,'events':_0x58d739,'functions':_0x2b7ec2,'auth':_0x55a748};const n=await fetch(_0x3d272d(0xdc),{'credentials':_0x3d272d(0xc7)}),a=n['ok']&&(await n[_0x3d272d(0xd6)]())?.[_0x3d272d(0xcc)]||{};if(a['bootstrap'])throw window['location'][_0x3d272d(0xd1)](_0x3d272d(0xe5)),new Error(_0x3d272d(0xd2));if(!a[_0x3d272d(0xea)]&&!(await fetch(_0x3d272d(0xe9),{'credentials':_0x3d272d(0xc7)}))['ok']){const o=encodeURIComponent(_0x3d272d(0xd0));throw window[_0x3d272d(0xe4)][_0x3d272d(0xd1)](_0x3d272d(0xe0)+o),new Error(_0x3d272d(0xce));}function c(_0xe6577f){const _0x185345=_0x3d272d,_0x53afe0=globalThis[_0x185345(0xde)];_0x53afe0?.[_0x185345(0xeb)]?.['setTheme']&&_0x53afe0['editor'][_0x185345(0xca)](_0x185345(0xd8)===_0xe6577f?'vs':_0x185345(0xdf));}_0x55a748[_0x3d272d(0xcb)]=a,await _0x55a748[_0x3d272d(0xd4)]()[_0x3d272d(0xda)](()=>{}),await _0x3ddef9[_0x3d272d(0xcf)][_0x3d272d(0xdd)][_0x3d272d(0xd4)](),_0x3ddef9['stores'][_0x3d272d(0xd7)]['connect'](),_0x3ddef9[_0x3d272d(0xd4)](document[_0x3d272d(0xe1)],{}),_0x2fe28f[_0x3d272d(0xdb)](c);function _0x283f(){const _0x74b59a=['subscribe','./login/config','okdb','monaco','vs-dark','./login?redirect=','body','2006224aTMkZu','../api','location','./setup.html','36316sbxBtw','__ENV__','21107025Iajurt','./session','openAccess','editor','8rWqdMb','3689553fjpMwU','same-origin','7807905WgIMUi','current','setTheme','config','data','472218zyrXib','Redirecting\x20to\x20login','stores','/admin/index.html','replace','Redirecting\x20to\x20setup','403668SeyaCl','init','API','json','events','light','455NAngVD','catch'];_0x283f=function(){return _0x74b59a;};return _0x283f();}const m=setInterval(()=>{const _0x401bf2=_0x3d272d;globalThis[_0x401bf2(0xde)]?.[_0x401bf2(0xeb)]?.['setTheme']&&(clearInterval(m),c(_0x2fe28f[_0x401bf2(0xc9)]));},0xc8);setTimeout(()=>clearInterval(m),0x7530);
1
+ import o from"./stores/theme-store.js";import{ok as t}from"./modules/ok.js";import e from"./stores/okdb-store.js";import s from"./stores/events-store.js";import i from"./stores/functions-store.js";import r from"./stores/auth-store.js";window.__ENV__??={},window.__ENV__.API??="../api",window.__ENV__.ADMIN_API??="../admin/api",t.stores={okdb:e,events:s,functions:i,auth:r};const n=await fetch("./login/config",{credentials:"same-origin"}),a=n.ok&&(await n.json())?.data||{};if(a.bootstrap)throw window.location.replace("./setup.html"),new Error("Redirecting to setup");if(!a.openAccess&&!(await fetch("./session",{credentials:"same-origin"})).ok){const o=encodeURIComponent("/admin/index.html");throw window.location.replace(`./login?redirect=${o}`),new Error("Redirecting to login")}function c(o){const t=globalThis.monaco;t?.editor?.setTheme&&t.editor.setTheme("light"===o?"vs":"vs-dark")}r.config=a,await r.init().catch(()=>{}),await t.stores.okdb.init(),t.stores.events.connect(),t.init(document.body,{}),o.subscribe(c);const m=setInterval(()=>{globalThis.monaco?.editor?.setTheme&&(clearInterval(m),c(o.current))},200);setTimeout(()=>clearInterval(m),3e4);
@@ -1 +1 @@
1
- const _0x1180f1=_0x3740;function _0x3740(_0x16a9f6,_0xf9dd31){_0x16a9f6=_0x16a9f6-0x10f;const _0x2875d7=_0x2875();let _0x3740b=_0x2875d7[_0x16a9f6];return _0x3740b;}(function(_0xfcaa75,_0x381399){const _0x5ee320=_0x3740,_0x59b20a=_0xfcaa75();while(!![]){try{const _0x276e93=parseInt(_0x5ee320(0x116))/0x1+-parseInt(_0x5ee320(0x120))/0x2+parseInt(_0x5ee320(0x119))/0x3*(-parseInt(_0x5ee320(0x11d))/0x4)+-parseInt(_0x5ee320(0x127))/0x5+-parseInt(_0x5ee320(0x118))/0x6+parseInt(_0x5ee320(0x114))/0x7+parseInt(_0x5ee320(0x113))/0x8;if(_0x276e93===_0x381399)break;else _0x59b20a['push'](_0x59b20a['shift']());}catch(_0x42ae0c){_0x59b20a['push'](_0x59b20a['shift']());}}}(_0x2875,0xcb539));function e(_0x1fba93){return new Promise(_0x1d8b36=>setTimeout(_0x1d8b36,_0x1fba93));}export default{'tag':'admin-route-host','attr':{'section':{}},'context':_0x3f1d53=>({'loading':!0x1,'error':null,'importHref':null,'requestToken':0x0,get 'sectionName'(){return _0x3f1d53['$attr']['section']||'db';},get 'targetHref'(){const _0x38d267=_0x3740;return'./sections/'+this[_0x38d267(0x123)]+'/index.ok.html';},async 'load'(){const _0x16d9b6=_0x3740,_0x144ad7=++this[_0x16d9b6(0x121)];this['loading']=!0x0,this['error']=null,this[_0x16d9b6(0x11f)]=null;const _0x191261=[0x0,0xc8,0x1f4,0x3e8];let _0x2807ab=null;for(const _0x3f60f1 of _0x191261){if(_0x3f60f1&&await e(_0x3f60f1),_0x144ad7!==this[_0x16d9b6(0x121)])return;try{const _0x299374=await fetch(this['targetHref'],{'credentials':_0x16d9b6(0x111),'cache':_0x16d9b6(0x110)});if(!_0x299374['ok'])throw new Error('HTTP\x20'+_0x299374[_0x16d9b6(0x11e)]+_0x16d9b6(0x117)+this[_0x16d9b6(0x11a)]);if(_0x144ad7!==this['requestToken'])return;return this[_0x16d9b6(0x11f)]=this[_0x16d9b6(0x11a)],void(this['loading']=!0x1);}catch(_0x2def16){_0x2807ab=_0x2def16;}}_0x144ad7===this['requestToken']&&(this['loading']=!0x1,this[_0x16d9b6(0x115)]=_0x2807ab?.[_0x16d9b6(0x112)]||String(_0x2807ab||_0x16d9b6(0x125)));},'retry'(){const _0x116a2b=_0x3740;this[_0x116a2b(0x11b)]();},'reloadPage'(){const _0x40bb5a=_0x3740;window[_0x40bb5a(0x124)][_0x40bb5a(0x10f)]();}}),'init'(_0x150c05){const _0x491a68=_0x3740;_0x150c05['$watch'](()=>_0x150c05[_0x491a68(0x126)]['section'],()=>this[_0x491a68(0x11b)]()),this[_0x491a68(0x11b)]();},'template':_0x1180f1(0x11c),'style':_0x1180f1(0x122)};function _0x2875(){const _0x481712=['status','importHref','3188600TvxigI','requestToken','[tag]{display:flex;flex-grow:1}','sectionName','location','Failed\x20to\x20load\x20section','$attr','1464600JAVlYu','reload','no-store','same-origin','message','18003432waVmwB','10005254FzIaNE','error','65931BfUXLd','\x20loading\x20','202350pPTmjJ','24LiiHjR','targetHref','load','\x0a\x20\x20<if\x20:=\x22importHref\x22>\x0a\x20\x20\x20\x20<component\x20:import=\x22importHref\x22></component>\x0a\x20\x20</if>\x0a\x20\x20<if\x20:=\x22loading\x20&&\x20!importHref\x22>\x0a\x20\x20\x20\x20<div\x20style=\x22min-height:100vh;display:flex;align-items:center;justify-content:center;padding:32px;color:var(--okdb-app-fg-muted);\x22>\x0a\x20\x20\x20\x20\x20\x20<div\x20style=\x22display:flex;flex-direction:column;gap:10px;align-items:center;max-width:420px;text-align:center;\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20style=\x22font-size:15px;font-weight:600;color:var(--okdb-app-fg-strong);\x22>Loading\x20{{\x20sectionName\x20}}…</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20style=\x22font-size:12px;line-height:1.6;opacity:.8;\x22>Retrying\x20section\x20fetch\x20automatically\x20in\x20case\x20the\x20local\x20admin\x20server\x20is\x20still\x20starting.</div>\x0a\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20</if>\x0a\x20\x20<if\x20:=\x22error\x20&&\x20!loading\x20&&\x20!importHref\x22>\x0a\x20\x20\x20\x20<div\x20style=\x22min-height:100vh;display:flex;align-items:center;justify-content:center;padding:32px;color:var(--okdb-app-fg-muted);\x22>\x0a\x20\x20\x20\x20\x20\x20<div\x20style=\x22display:flex;flex-direction:column;gap:12px;max-width:560px;padding:18px;border:1px\x20solid\x20var(--okdb-app-border);border-radius:14px;background:var(--okdb-app-bg);box-shadow:0\x200\x208px\x20#00000022;\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20style=\x22font-size:16px;font-weight:700;color:var(--okdb-app-fg-strong);\x22>Could\x20not\x20load\x20the\x20{{\x20sectionName\x20}}\x20section</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20style=\x22font-size:12px;line-height:1.7;\x22>The\x20admin\x20UI\x20hit\x20a\x20temporary\x20fetch\x20failure\x20while\x20loading\x20<code>{{\x20targetHref\x20}}</code>.\x20This\x20usually\x20resolves\x20once\x20the\x20local\x20server\x20is\x20ready\x20again.</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20style=\x22padding:10px\x2012px;border:1px\x20solid\x20color-mix(in\x20srgb,\x20var(--okdb-danger)\x2033%,\x20transparent);border-radius:10px;background:var(--okdb-danger-soft-bg);color:var(--okdb-danger);font-size:12px;line-height:1.6;word-break:break-word;\x22>{{\x20error\x20}}</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20style=\x22display:flex;gap:10px;flex-wrap:wrap;\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<button\x20@click=\x22retry()\x22\x20style=\x22font-size:12px;padding:6px\x2014px;color:var(--okdb-accent);border-color:var(--okdb-accent-soft-border);\x22>Retry\x20section\x20load</button>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<button\x20@click=\x22reloadPage()\x22\x20style=\x22font-size:12px;padding:6px\x2014px;opacity:.8;\x22>Reload\x20admin\x20UI</button>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20</if>\x0a','495956hEibDR'];_0x2875=function(){return _0x481712;};return _0x2875();}
1
+ function e(e){return new Promise(t=>setTimeout(t,e))}export default{tag:"admin-route-host",attr:{section:{}},context:t=>({loading:!1,error:null,importHref:null,requestToken:0,get sectionName(){return t.$attr.section||"db"},get targetHref(){return`./sections/${this.sectionName}/index.ok.html`},async load(){const t=++this.requestToken;this.loading=!0,this.error=null,this.importHref=null;const i=[0,200,500,1e3];let o=null;for(const r of i){if(r&&await e(r),t!==this.requestToken)return;try{const e=await fetch(this.targetHref,{credentials:"same-origin",cache:"no-store"});if(!e.ok)throw new Error(`HTTP ${e.status} loading ${this.targetHref}`);if(t!==this.requestToken)return;return this.importHref=this.targetHref,void(this.loading=!1)}catch(e){o=e}}t===this.requestToken&&(this.loading=!1,this.error=o?.message||String(o||"Failed to load section"))},retry(){this.load()},reloadPage(){window.location.reload()}}),init(e){e.$watch(()=>e.$attr.section,()=>this.load()),this.load()},template:'\n <if :="importHref">\n <component :import="importHref"></component>\n </if>\n <if :="loading && !importHref">\n <div style="min-height:100vh;display:flex;align-items:center;justify-content:center;padding:32px;color:var(--okdb-app-fg-muted);">\n <div style="display:flex;flex-direction:column;gap:10px;align-items:center;max-width:420px;text-align:center;">\n <div style="font-size:15px;font-weight:600;color:var(--okdb-app-fg-strong);">Loading {{ sectionName }}…</div>\n <div style="font-size:12px;line-height:1.6;opacity:.8;">Retrying section fetch automatically in case the local admin server is still starting.</div>\n </div>\n </div>\n </if>\n <if :="error && !loading && !importHref">\n <div style="min-height:100vh;display:flex;align-items:center;justify-content:center;padding:32px;color:var(--okdb-app-fg-muted);">\n <div style="display:flex;flex-direction:column;gap:12px;max-width:560px;padding:18px;border:1px solid var(--okdb-app-border);border-radius:14px;background:var(--okdb-app-bg);box-shadow:0 0 8px #00000022;">\n <div style="font-size:16px;font-weight:700;color:var(--okdb-app-fg-strong);">Could not load the {{ sectionName }} section</div>\n <div style="font-size:12px;line-height:1.7;">The admin UI hit a temporary fetch failure while loading <code>{{ targetHref }}</code>. This usually resolves once the local server is ready again.</div>\n <div style="padding:10px 12px;border:1px solid color-mix(in srgb, var(--okdb-danger) 33%, transparent);border-radius:10px;background:var(--okdb-danger-soft-bg);color:var(--okdb-danger);font-size:12px;line-height:1.6;word-break:break-word;">{{ error }}</div>\n <div style="display:flex;gap:10px;flex-wrap:wrap;">\n <button @click="retry()" style="font-size:12px;padding:6px 14px;color:var(--okdb-accent);border-color:var(--okdb-accent-soft-border);">Retry section load</button>\n <button @click="reloadPage()" style="font-size:12px;padding:6px 14px;opacity:.8;">Reload admin UI</button>\n </div>\n </div>\n </div>\n </if>\n',style:"[tag]{display:flex;flex-grow:1}"};
@@ -1 +1 @@
1
- var _0x514470=_0x1ef1;(function(_0x5c1b92,_0x27af78){var _0x24865b=_0x1ef1,_0x4a5a28=_0x5c1b92();while(!![]){try{var _0x319ab0=parseInt(_0x24865b(0x103))/0x1+-parseInt(_0x24865b(0xfd))/0x2+-parseInt(_0x24865b(0xf7))/0x3+parseInt(_0x24865b(0xf0))/0x4*(parseInt(_0x24865b(0x102))/0x5)+parseInt(_0x24865b(0xff))/0x6*(-parseInt(_0x24865b(0x101))/0x7)+-parseInt(_0x24865b(0xf8))/0x8*(-parseInt(_0x24865b(0xf1))/0x9)+-parseInt(_0x24865b(0x105))/0xa*(-parseInt(_0x24865b(0xf9))/0xb);if(_0x319ab0===_0x27af78)break;else _0x4a5a28['push'](_0x4a5a28['shift']());}catch(_0x570938){_0x4a5a28['push'](_0x4a5a28['shift']());}}}(_0x3f5a,0x37611));import _0x527d92 from'@toolkit/elements/ok-dropdown.ok.js';import _0x4c1bad from'@toolkit/elements/ok-icon.ok.js';function _0x3f5a(){var _0x273d25=['539428FGCcTG','387qyrwix','filter','ok-dropdown.ep-dropdown{--ok-dropdown-trigger-display:flex;--ok-dropdown-trigger-padding:6px\x209px;--ok-dropdown-trigger-radius:6px;--ok-dropdown-trigger-border:1px\x20solid\x20var(--okdb-app-border-subtle);--ok-dropdown-trigger-bg:var(--okdb-app-bg);--ok-dropdown-trigger-color:var(--okdb-app-fg-muted);--ok-dropdown-trigger-hover-bg:var(--okdb-app-surface);--ok-dropdown-trigger-active-bg:var(--okdb-app-surface);--ok-dropdown-panel-bg:var(--okdb-app-bg);--ok-dropdown-panel-border:1px\x20solid\x20var(--okdb-app-border-subtle);--ok-dropdown-panel-radius:7px;--ok-dropdown-panel-shadow:0\x2010px\x2028px\x20#00000060;--ok-dropdown-panel-gap:3px;--ok-dropdown-panel-padding:3px\x200;--ok-dropdown-z:200;width:100%;font-size:12px;font-family:monospace}ok-dropdown.ep-dropdown\x20.ok-dropdown__trigger{align-items:center;gap:7px}ok-dropdown.ep-dropdown\x20.ok-dropdown--open\x20.ok-dropdown__trigger,ok-dropdown.ep-dropdown\x20.ok-dropdown__trigger:hover{border-color:var(--okdb-app-border);color:var(--okdb-app-fg-muted)}.ep-dot{width:5px;height:5px;border-radius:50%;background:var(--okdb-success-muted);flex-shrink:0}.ep-dot--none{background:var(--okdb-warning-soft-bg);border:1px\x20solid\x20color-mix(in\x20srgb,var(--okdb-warning)\x2040%,transparent)}.ep-name{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ep-caret{width:9px;height:6px;flex-shrink:0;color:var(--okdb-app-fg-faint);transition:transform\x20.14s}.ok-dropdown--open\x20.ep-caret{transform:rotate(180deg)}.ep-row,.ep-row--active{color:var(--okdb-app-fg-muted)}.ep-row{display:flex;align-items:center;gap:6px;padding:6px\x2010px;font-size:12px;font-family:monospace;cursor:pointer;transition:background\x20.08s,color\x20.08s;white-space:nowrap;overflow:hidden}.ep-row--active{background:var(--okdb-app-bg)}.ep-row-dot{width:5px;height:5px;border-radius:50%;background:var(--okdb-success-muted);flex-shrink:0}.ep-row-name{flex:1;overflow:hidden;text-overflow:ellipsis}.ep-check{font-size:10px;color:var(--okdb-success-muted);flex-shrink:0}.ep-sep{height:1px;background:var(--okdb-app-border-subtle);margin:3px\x204px}.ep-plus,.ep-row--add{color:var(--okdb-app-fg-subtle)}.ep-row--add{font-family:inherit;font-size:11px}.ep-row--add:hover,.ep-row:hover{color:var(--okdb-app-fg-muted);background:var(--okdb-app-surface)}.ep-plus{font-size:13px;line-height:1}.ep-sys-toggle{display:flex;align-items:center;gap:5px;width:100%;padding:4px\x2010px;margin-top:2px;border:0;border-top:1px\x20solid\x20var(--okdb-app-border-subtle);border-radius:0;background:0\x200;color:var(--okdb-app-fg-faint);font-size:10px;font-family:monospace;letter-spacing:.05em;text-transform:uppercase;cursor:pointer;text-align:left;transition:color\x20.12s,background\x20.12s;box-shadow:none}.ep-sys-toggle:hover:not(:disabled){color:var(--okdb-app-fg-muted);background:var(--okdb-app-bg);transform:none;box-shadow:none}.ep-sys-toggle--on{color:var(--okdb-accent)}.ep-sys-toggle--on:hover:not(:disabled){color:var(--okdb-accent)}.ep-sys-caret{width:8px;height:5px;margin-left:auto;flex-shrink:0;transition:transform\x20.14s}.ep-row--empty,.ep-row--sys{color:var(--okdb-app-fg-subtle);font-style:italic}.ep-row--sys:hover{color:var(--okdb-app-fg-muted);background:var(--okdb-app-bg)}.ep-row--empty{font-size:11px;color:var(--okdb-app-fg-faint);cursor:default;padding:4px\x2010px\x204px\x2016px}.ep-row--empty:hover{background:0\x200;color:var(--okdb-app-fg-faint)}','$attr','create','name','6216DrRKhv','3736NCEIiQ','11VjMGJq','startsWith','selected','change','786524ridsgP','$dispatch','602322IcooAj','_dd','21xifDcX','10GWMazy','380869dkrfOY','envs','2526640FtKAWt','env-picker','close'];_0x3f5a=function(){return _0x273d25;};return _0x3f5a();}function _0x1ef1(_0x125259,_0x10ff6f){_0x125259=_0x125259-0xef;var _0x3f5a2e=_0x3f5a();var _0x1ef107=_0x3f5a2e[_0x125259];return _0x1ef107;}export default{'tag':_0x514470(0x106),'dependencies':[_0x527d92,_0x4c1bad],'context':_0x582ccf=>({'_dd':null,'showSystem':!0x1,get 'selected'(){var _0x215186=_0x514470;return _0x582ccf[_0x215186(0xf4)][_0x215186(0xfb)]||null;},get 'hasEnv'(){var _0x5e4a48=_0x514470;return!!this[_0x5e4a48(0xfb)];},get 'envs'(){var _0x3754dd=_0x514470;return(_0x582ccf[_0x3754dd(0xf4)][_0x3754dd(0x104)]||[])['filter'](_0x13b9a7=>!_0x13b9a7[_0x3754dd(0xf6)]['startsWith']('~'));},get 'systemEnvs'(){var _0xba85ce=_0x514470;return(_0x582ccf[_0xba85ce(0xf4)][_0xba85ce(0x104)]||[])[_0xba85ce(0xf2)](_0x344497=>_0x344497[_0xba85ce(0xf6)][_0xba85ce(0xfa)]('~'));},'pick'(_0x1b8c5b){var _0x5f37d2=_0x514470;this[_0x5f37d2(0x100)]?.['close']?.(),_0x1b8c5b!==this[_0x5f37d2(0xfb)]&&_0x582ccf[_0x5f37d2(0xfe)](_0x5f37d2(0xfc),_0x1b8c5b);},'create'(){var _0x18b6f0=_0x514470;this['_dd']?.[_0x18b6f0(0xef)]?.(),_0x582ccf[_0x18b6f0(0xfe)](_0x18b6f0(0xf5));}}),'template':'\x0a<ok-dropdown\x20class=\x22ep-dropdown\x20block\x22\x20no-caret\x20placement=\x22auto\x22\x20@mount=\x22_dd\x20=\x20$el\x22>\x0a\x20\x20\x20\x20<template\x20name=\x22trigger\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22ep-dot\x22\x20:class=\x22hasEnv\x20?\x20\x27\x27\x20:\x20\x27ep-dot--none\x27\x22></span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22ep-name\x22\x20:style=\x22hasEnv\x20?\x20\x27\x27\x20:\x20\x27opacity:.4;\x20font-style:italic;\x27\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{\x20hasEnv\x20?\x20selected\x20:\x20\x27no\x20environment\x27\x20}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<svg\x20class=\x22ep-caret\x22\x20viewBox=\x220\x200\x2010\x206\x22\x20fill=\x22none\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<path\x20d=\x22M1\x201l4\x204\x204-4\x22\x20stroke=\x22currentColor\x22\x20stroke-width=\x221.4\x22\x20stroke-linecap=\x22round\x22\x20stroke-linejoin=\x22round\x22/>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</svg>\x0a\x20\x20\x20\x20</template>\x0a\x0a\x20\x20\x20\x20<if\x20:=\x22envs.length\x20===\x200\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22ep-row\x20ep-row--empty\x22>no\x20environments\x20yet</div>\x0a\x20\x20\x20\x20</if>\x0a\x20\x20\x20\x20<each\x20:of=\x22envs\x22\x20let:item=\x22e\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22ep-row\x22\x20:class=\x22e.name\x20===\x20selected\x20?\x20\x27ep-row--active\x27\x20:\x20\x27\x27\x22\x20@click=\x22pick(e.name)\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22ep-row-dot\x22></span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22ep-row-name\x22>{{\x20e.name\x20}}</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<if\x20:=\x22e.name\x20===\x20selected\x22><span\x20class=\x22ep-check\x22>✓</span></if>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20</each>\x0a\x20\x20\x20\x20\x0a\x20\x20\x20\x20<button\x20class=\x22ep-sys-toggle\x22\x20:class=\x22showSystem\x20?\x20\x27ep-sys-toggle--on\x27\x20:\x20\x27\x27\x22\x20@click=\x22showSystem\x20=\x20!showSystem\x22\x20title=\x22Toggle\x20system\x20environments\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<ok-icon\x20name=\x22settings\x22\x20style=\x22width:10px;height:10px;\x22></ok-icon>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<span>system</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<svg\x20class=\x22ep-sys-caret\x22\x20viewBox=\x220\x200\x2010\x206\x22\x20fill=\x22none\x22\x20:style=\x22showSystem\x20?\x20\x27transform:rotate(180deg)\x27\x20:\x20\x27\x27\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<path\x20d=\x22M1\x201l4\x204\x204-4\x22\x20stroke=\x22currentColor\x22\x20stroke-width=\x221.4\x22\x20stroke-linecap=\x22round\x22\x20stroke-linejoin=\x22round\x22/>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</svg>\x0a\x20\x20\x20\x20</button>\x0a\x20\x20\x20\x20<if\x20:=\x22showSystem\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<each\x20:of=\x22systemEnvs\x22\x20let:item=\x22e\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22ep-row\x20ep-row--sys\x22\x20:class=\x22e.name\x20===\x20selected\x20?\x20\x27ep-row--active\x27\x20:\x20\x27\x27\x22\x20@click=\x22pick(e.name)\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22ep-row-name\x22>{{\x20e.name\x20}}</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<if\x20:=\x22e.name\x20===\x20selected\x22><span\x20class=\x22ep-check\x22>✓</span></if>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</each>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<if\x20:=\x22systemEnvs.length\x20===\x200\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22ep-row\x20ep-row--empty\x22>no\x20system\x20envs</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</if>\x0a\x20\x20\x20\x20</if>\x0a\x0a\x20\x20\x20\x20<div\x20class=\x22ep-sep\x22></div>\x0a\x20\x20\x20\x20<div\x20class=\x22ep-row\x20ep-row--add\x22\x20@click=\x22create()\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22ep-plus\x22>+</span>\x20Create\x20environment\x0a\x20\x20\x20\x20</div>\x0a</ok-dropdown>','style':_0x514470(0xf3)};
1
+ import e from"@toolkit/elements/ok-dropdown.ok.js";import o from"@toolkit/elements/ok-icon.ok.js";export default{tag:"env-picker",dependencies:[e,o],context:e=>({_dd:null,showSystem:!1,get selected(){return e.$attr.selected||null},get hasEnv(){return!!this.selected},get envs(){return(e.$attr.envs||[]).filter(e=>!e.name.startsWith("~"))},get systemEnvs(){return(e.$attr.envs||[]).filter(e=>e.name.startsWith("~"))},pick(o){this._dd?.close?.(),o!==this.selected&&e.$dispatch("change",o)},create(){this._dd?.close?.(),e.$dispatch("create")}}),template:'\n<ok-dropdown class="ep-dropdown block" no-caret placement="auto" @mount="_dd = $el">\n <template name="trigger">\n <span class="ep-dot" :class="hasEnv ? \'\' : \'ep-dot--none\'"></span>\n <span class="ep-name" :style="hasEnv ? \'\' : \'opacity:.4; font-style:italic;\'">\n {{ hasEnv ? selected : \'no environment\' }}\n </span>\n <svg class="ep-caret" viewBox="0 0 10 6" fill="none">\n <path d="M1 1l4 4 4-4" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"/>\n </svg>\n </template>\n\n <if :="envs.length === 0">\n <div class="ep-row ep-row--empty">no environments yet</div>\n </if>\n <each :of="envs" let:item="e">\n <div class="ep-row" :class="e.name === selected ? \'ep-row--active\' : \'\'" @click="pick(e.name)">\n <span class="ep-row-dot"></span>\n <span class="ep-row-name">{{ e.name }}</span>\n <if :="e.name === selected"><span class="ep-check">✓</span></if>\n </div>\n </each>\n \n <button class="ep-sys-toggle" :class="showSystem ? \'ep-sys-toggle--on\' : \'\'" @click="showSystem = !showSystem" title="Toggle system environments">\n <ok-icon name="settings" style="width:10px;height:10px;"></ok-icon>\n <span>system</span>\n <svg class="ep-sys-caret" viewBox="0 0 10 6" fill="none" :style="showSystem ? \'transform:rotate(180deg)\' : \'\'">\n <path d="M1 1l4 4 4-4" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"/>\n </svg>\n </button>\n <if :="showSystem">\n <each :of="systemEnvs" let:item="e">\n <div class="ep-row ep-row--sys" :class="e.name === selected ? \'ep-row--active\' : \'\'" @click="pick(e.name)">\n <span class="ep-row-name">{{ e.name }}</span>\n <if :="e.name === selected"><span class="ep-check">✓</span></if>\n </div>\n </each>\n <if :="systemEnvs.length === 0">\n <div class="ep-row ep-row--empty">no system envs</div>\n </if>\n </if>\n\n <div class="ep-sep"></div>\n <div class="ep-row ep-row--add" @click="create()">\n <span class="ep-plus">+</span> Create environment\n </div>\n</ok-dropdown>',style:"ok-dropdown.ep-dropdown{--ok-dropdown-trigger-display:flex;--ok-dropdown-trigger-padding:6px 9px;--ok-dropdown-trigger-radius:6px;--ok-dropdown-trigger-border:1px solid var(--okdb-app-border-subtle);--ok-dropdown-trigger-bg:var(--okdb-app-bg);--ok-dropdown-trigger-color:var(--okdb-app-fg-muted);--ok-dropdown-trigger-hover-bg:var(--okdb-app-surface);--ok-dropdown-trigger-active-bg:var(--okdb-app-surface);--ok-dropdown-panel-bg:var(--okdb-app-bg);--ok-dropdown-panel-border:1px solid var(--okdb-app-border-subtle);--ok-dropdown-panel-radius:7px;--ok-dropdown-panel-shadow:0 10px 28px #00000060;--ok-dropdown-panel-gap:3px;--ok-dropdown-panel-padding:3px 0;--ok-dropdown-z:200;width:100%;font-size:12px;font-family:monospace}ok-dropdown.ep-dropdown .ok-dropdown__trigger{align-items:center;gap:7px}ok-dropdown.ep-dropdown .ok-dropdown--open .ok-dropdown__trigger,ok-dropdown.ep-dropdown .ok-dropdown__trigger:hover{border-color:var(--okdb-app-border);color:var(--okdb-app-fg-muted)}.ep-dot{width:5px;height:5px;border-radius:50%;background:var(--okdb-success-muted);flex-shrink:0}.ep-dot--none{background:var(--okdb-warning-soft-bg);border:1px solid color-mix(in srgb,var(--okdb-warning) 40%,transparent)}.ep-name{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.ep-caret{width:9px;height:6px;flex-shrink:0;color:var(--okdb-app-fg-faint);transition:transform .14s}.ok-dropdown--open .ep-caret{transform:rotate(180deg)}.ep-row,.ep-row--active{color:var(--okdb-app-fg-muted)}.ep-row{display:flex;align-items:center;gap:6px;padding:6px 10px;font-size:12px;font-family:monospace;cursor:pointer;transition:background .08s,color .08s;white-space:nowrap;overflow:hidden}.ep-row--active{background:var(--okdb-app-bg)}.ep-row-dot{width:5px;height:5px;border-radius:50%;background:var(--okdb-success-muted);flex-shrink:0}.ep-row-name{flex:1;overflow:hidden;text-overflow:ellipsis}.ep-check{font-size:10px;color:var(--okdb-success-muted);flex-shrink:0}.ep-sep{height:1px;background:var(--okdb-app-border-subtle);margin:3px 4px}.ep-plus,.ep-row--add{color:var(--okdb-app-fg-subtle)}.ep-row--add{font-family:inherit;font-size:11px}.ep-row--add:hover,.ep-row:hover{color:var(--okdb-app-fg-muted);background:var(--okdb-app-surface)}.ep-plus{font-size:13px;line-height:1}.ep-sys-toggle{display:flex;align-items:center;gap:5px;width:100%;padding:4px 10px;margin-top:2px;border:0;border-top:1px solid var(--okdb-app-border-subtle);border-radius:0;background:0 0;color:var(--okdb-app-fg-faint);font-size:10px;font-family:monospace;letter-spacing:.05em;text-transform:uppercase;cursor:pointer;text-align:left;transition:color .12s,background .12s;box-shadow:none}.ep-sys-toggle:hover:not(:disabled){color:var(--okdb-app-fg-muted);background:var(--okdb-app-bg);transform:none;box-shadow:none}.ep-sys-toggle--on{color:var(--okdb-accent)}.ep-sys-toggle--on:hover:not(:disabled){color:var(--okdb-accent)}.ep-sys-caret{width:8px;height:5px;margin-left:auto;flex-shrink:0;transition:transform .14s}.ep-row--empty,.ep-row--sys{color:var(--okdb-app-fg-subtle);font-style:italic}.ep-row--sys:hover{color:var(--okdb-app-fg-muted);background:var(--okdb-app-bg)}.ep-row--empty{font-size:11px;color:var(--okdb-app-fg-faint);cursor:default;padding:4px 10px 4px 16px}.ep-row--empty:hover{background:0 0;color:var(--okdb-app-fg-faint)}"};
@@ -1 +1 @@
1
- const _0x56d372=_0x1bd0;function _0x3dd2(){const _0x564db4=['string','$el','startsWith','_ddStyle','query','types','_scoreItem','includes','key','#60a5fa','◎\x20geo','split','#34d399','hiIdx','every','\x0afield-path-input\x20{\x20display:block;\x20width:100%;\x20position:relative;\x20}\x0a\x0a.fpi-inp\x20{\x0a\x20\x20\x20\x20width:100%;\x20box-sizing:border-box;\x0a\x20\x20\x20\x20background:#12171a;\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:6px;\x0a\x20\x20\x20\x20padding:6px\x208px;\x20color:inherit;\x20font-size:13px;\x0a\x20\x20\x20\x20outline:none;\x20transition:border-color\x20.12s;\x20font-family:inherit;\x0a}\x0a.fpi-inp:focus\x20\x20\x20{\x20border-color:color-mix(in\x20srgb,\x20var(--okdb-accent)\x2053%,\x20transparent);\x20}\x0a.fpi-inp--warn\x20\x20\x20{\x20border-color:color-mix(in\x20srgb,\x20var(--okdb-warning)\x2040%,\x20transparent);\x20}\x0a\x0a.fpi-custom-tag\x20{\x0a\x20\x20\x20\x20position:absolute;\x20right:8px;\x20top:50%;\x20transform:translateY(-50%);\x0a\x20\x20\x20\x20font-size:10px;\x20color:var(--okdb-warning);\x20opacity:.7;\x20pointer-events:none;\x20user-select:none;\x0a}\x0a\x0a.fpi-drop\x20{\x0a\x20\x20\x20\x20background:var(--okdb-app-bg);\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:7px;\x0a\x20\x20\x20\x20box-shadow:0\x2012px\x2040px\x20#00000090;\x20max-height:240px;\x20overflow-y:auto;\x20overflow-x:hidden;\x0a}\x0a.fpi-drop--empty\x20{\x20max-height:none;\x20}\x0a\x0a.fpi-row\x20{\x0a\x20\x20\x20\x20display:flex;\x20align-items:center;\x20gap:8px;\x20padding:6px\x2010px;\x0a\x20\x20\x20\x20cursor:pointer;\x20border-bottom:1px\x20solid\x20color-mix(in\x20srgb,\x20var(--okdb-app-border)\x208%,\x20transparent);\x20min-width:0;\x0a\x20\x20\x20\x20transition:background\x20.07s;\x0a}\x0a.fpi-row:last-child\x20\x20\x20{\x20border-bottom:none;\x20}\x0a.fpi-row:hover,\x0a.fpi-row--hi\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x20background:var(--okdb-app-surface);\x20}\x0a\x0a.fpi-path\x20{\x0a\x20\x20\x20\x20flex:1;\x20min-width:0;\x20overflow:hidden;\x20text-overflow:ellipsis;\x20white-space:nowrap;\x0a\x20\x20\x20\x20font-family:ui-monospace,\x27Cascadia\x20Code\x27,\x27Fira\x20Code\x27,monospace;\x0a\x20\x20\x20\x20font-size:12px;\x20color:var(--okdb-app-fg);\x0a}\x0a\x0a.fpi-badge\x20{\x20font-size:10px;\x20opacity:.85;\x20white-space:nowrap;\x20flex-shrink:0;\x20}\x0a.fpi-empty\x20{\x20padding:10px;\x20font-size:12px;\x20opacity:.4;\x20text-align:center;\x20}\x0a','Tab','3ELLzIc','localeCompare','map','filter','scrollIntoView','var(--okdb-indigo)','$watch','object','score','ArrowUp','Escape','_blurT','placeholder','\x20|\x20','.fpi-row--hi','length','geo','var(--okdb-orange)','hint','4122384FJTOTK','_commit','true','path','_reposition','filtered','width','_scrollHi','204062skwSln','3380hqUiva','_openDrop','Enter','undefined','sort','stopPropagation','null','items','array','420219dnIbpx','join','toLowerCase','_focused','.fpi-inp','dispatchEvent','preventDefault','28fwLlnr','3890ackGjP','change','_inp','var(--okdb-app-fg-muted)','95775joRljD','3703854jcmpwe','open','push','nearest','_allowCustom','Field\x20path','1422RkhrDH','value','26664ANPGaA','px;z-index:99999;','some','querySelector','min','ArrowDown','trim','$attr','_items','number'];_0x3dd2=function(){return _0x564db4;};return _0x3dd2();}function _0x1bd0(_0x39466e,_0x14f7b8){_0x39466e=_0x39466e-0x9c;const _0x3dd2b2=_0x3dd2();let _0x1bd0b6=_0x3dd2b2[_0x39466e];return _0x1bd0b6;}(function(_0x12e155,_0x2dace3){const _0x248c52=_0x1bd0,_0x82fd84=_0x12e155();while(!![]){try{const _0x2fbea1=parseInt(_0x248c52(0xd4))/0x1*(-parseInt(_0x248c52(0xef))/0x2)+parseInt(_0x248c52(0xb0))/0x3*(-parseInt(_0x248c52(0xab))/0x4)+parseInt(_0x248c52(0xac))/0x5*(parseInt(_0x248c52(0xb7))/0x6)+parseInt(_0x248c52(0xb1))/0x7+-parseInt(_0x248c52(0xe7))/0x8+-parseInt(_0x248c52(0xa4))/0x9+parseInt(_0x248c52(0xf0))/0xa*(parseInt(_0x248c52(0xb9))/0xb);if(_0x2fbea1===_0x2dace3)break;else _0x82fd84['push'](_0x82fd84['shift']());}catch(_0xfcdbf2){_0x82fd84['push'](_0x82fd84['shift']());}}}(_0x3dd2,0x6bbaf));export default{'tag':'field-path-input','attr':{'value':{},'items':{},'placeholder':{},'allowCustom':{}},'context':_0x49ead1=>({'_inp':null,'query':'','open':!0x1,'hiIdx':-0x1,'_ddStyle':'','_blurT':null,'_focused':!0x1,get 'placeholder'(){const _0x2b3332=_0x1bd0;return _0x49ead1[_0x2b3332(0xc0)][_0x2b3332(0xe0)]||_0x2b3332(0xb6);},get '_items'(){const _0x380f8d=_0x1bd0;return _0x49ead1[_0x380f8d(0xc0)][_0x380f8d(0xa2)]||[];},get '_allowCustom'(){const _0x6c65fc=_0x1bd0,_0x3a5eda=_0x49ead1[_0x6c65fc(0xc0)]['allowCustom'];return!0x0===_0x3a5eda||_0x6c65fc(0xe9)===_0x3a5eda||''===_0x3a5eda;},get '_q'(){const _0x5424ee=_0x1bd0;return(''+(this[_0x5424ee(0xc7)]||''))[_0x5424ee(0xbf)]();},'_scoreItem'(_0x22a594,_0x30b2c8,_0x1747d2){const _0x4fe38d=_0x1bd0,_0x1ccaf1=_0x30b2c8[_0x4fe38d(0xe3)]>0x0&&!_0x30b2c8[_0x4fe38d(0xd1)](function(_0x5b9d4b){const _0x415877=_0x4fe38d;return _0x415877(0xdb)===_0x5b9d4b;});if(!_0x1747d2)return _0x1ccaf1?0x2:0x1;const _0x30857e=_0x22a594[_0x4fe38d(0xa6)](),_0x2a0ffc=_0x1747d2[_0x4fe38d(0xa6)](),_0x2ba395=_0x30857e[_0x4fe38d(0xce)]('.'),_0x3116cd=_0x2ba395[_0x2ba395[_0x4fe38d(0xe3)]-0x1];if(_0x30857e===_0x2a0ffc)return 0x64;if(_0x30857e[_0x4fe38d(0xc5)](_0x2a0ffc))return 0x50;if(_0x3116cd===_0x2a0ffc)return 0x4b;if(_0x3116cd['startsWith'](_0x2a0ffc))return 0x41;if(_0x30857e[_0x4fe38d(0xca)](_0x2a0ffc))return 0x32;if(_0x3116cd['includes'](_0x2a0ffc))return 0x28;const _0x583e14=_0x2a0ffc[_0x4fe38d(0xce)](/\s+/)['filter'](Boolean);return _0x583e14[_0x4fe38d(0xe3)]>0x1&&_0x583e14['every'](function(_0x3d4735){const _0x2322c2=_0x4fe38d;return _0x2ba395[_0x2322c2(0xbb)](function(_0x4b6cc0){return _0x4b6cc0['includes'](_0x3d4735);});})?0x1e:-0x1;},get 'filtered'(){const _0xb14cca=_0x1bd0,_0x126bdd=this['_q'],_0x288140=this['_items'],_0x1fe632=[];for(let _0x36e74b=0x0;_0x36e74b<_0x288140[_0xb14cca(0xe3)];_0x36e74b++){const _0x39acc4=_0x288140[_0x36e74b],_0x2589f1=''+(_0x39acc4[_0xb14cca(0xea)]||''),_0x115a9e=_0x39acc4[_0xb14cca(0xc8)]?Array['from'](_0x39acc4[_0xb14cca(0xc8)])[_0xb14cca(0xd6)](function(_0x49bf1b){return''+_0x49bf1b;}):[],_0x4b4408=_0x39acc4[_0xb14cca(0xe6)]?''+_0x39acc4[_0xb14cca(0xe6)]:null,_0x5d8ab9=this[_0xb14cca(0xc9)](_0x2589f1,_0x115a9e,_0x126bdd);_0x5d8ab9>=0x0&&_0x1fe632[_0xb14cca(0xb3)]({'path':_0x2589f1,'types':_0x115a9e,'hint':_0x4b4408,'score':_0x5d8ab9});}return _0x1fe632[_0xb14cca(0x9f)](function(_0x32539b,_0x5f2620){const _0x3a91df=_0xb14cca;return _0x5f2620[_0x3a91df(0xdc)]-_0x32539b[_0x3a91df(0xdc)]||_0x32539b[_0x3a91df(0xea)][_0x3a91df(0xd5)](_0x5f2620[_0x3a91df(0xea)]);}),_0x1fe632;},get 'isUnknown'(){const _0x18a4dd=_0x1bd0,_0x7a647b=this['_q'];if(!_0x7a647b)return!0x1;const _0x1f32d1=this[_0x18a4dd(0xc1)];for(let _0x413581=0x0;_0x413581<_0x1f32d1[_0x18a4dd(0xe3)];_0x413581++)if(''+(_0x1f32d1[_0x413581][_0x18a4dd(0xea)]||'')===_0x7a647b)return!0x1;return!0x0;},'_reposition'(){const _0xd479ac=_0x1bd0,_0x3affd1=this[_0xd479ac(0xae)]||_0x49ead1[_0xd479ac(0xc4)]&&_0x49ead1['$el'][_0xd479ac(0xbc)](_0xd479ac(0xa8));if(!_0x3affd1)return;const _0x43ccc8=_0x3affd1['getBoundingClientRect']();this[_0xd479ac(0xc6)]='position:fixed;width:'+Math['round'](_0x43ccc8[_0xd479ac(0xed)])+_0xd479ac(0xba);},'_openDrop'(){const _0x112b4f=_0x1bd0;this[_0x112b4f(0xeb)](),this[_0x112b4f(0xb2)]=!0x0;},'_commit'(_0xc3c52c){const _0x44aecc=_0x1bd0;clearTimeout(this[_0x44aecc(0xdf)]);const _0x3afba8=''+(_0xc3c52c||'');this['query']=_0x3afba8,this[_0x44aecc(0xae)]&&(this[_0x44aecc(0xae)]['value']=_0x3afba8),this[_0x44aecc(0xb2)]=!0x1,this[_0x44aecc(0xd0)]=-0x1,_0x49ead1[_0x44aecc(0xc4)]&&_0x49ead1[_0x44aecc(0xc4)][_0x44aecc(0xa9)](new CustomEvent(_0x44aecc(0xad),{'detail':_0x3afba8}));},'mountInput'(_0x8e6bf0){const _0x1cc5c4=_0x1bd0;this[_0x1cc5c4(0xae)]=_0x8e6bf0;const _0x49708e=''+(_0x49ead1[_0x1cc5c4(0xc0)][_0x1cc5c4(0xb8)]||'');_0x8e6bf0[_0x1cc5c4(0xb8)]=_0x49708e,this[_0x1cc5c4(0xc7)]=_0x49708e;},'onFocus'(){const _0x558f80=_0x1bd0;clearTimeout(this[_0x558f80(0xdf)]),this[_0x558f80(0xa7)]=!0x0,this[_0x558f80(0xd0)]=-0x1;const _0xdfb6a4=''+(_0x49ead1[_0x558f80(0xc0)][_0x558f80(0xb8)]||''),_0x1eb71e=this[_0x558f80(0xae)]?this[_0x558f80(0xae)][_0x558f80(0xb8)]:this[_0x558f80(0xc7)];_0x1eb71e===_0xdfb6a4||_0x1eb71e||(this[_0x558f80(0xc7)]=_0xdfb6a4,this['_inp']&&(this['_inp'][_0x558f80(0xb8)]=_0xdfb6a4)),this[_0x558f80(0x9c)]();},'onBlur'(){const _0x5712ff=_0x1bd0;this[_0x5712ff(0xa7)]=!0x1,this[_0x5712ff(0xdf)]=setTimeout(()=>{const _0x1c00b3=_0x5712ff;if(this[_0x1c00b3(0xb2)]=!0x1,!this[_0x1c00b3(0xb5)]){const _0x11190d=''+(_0x49ead1[_0x1c00b3(0xc0)][_0x1c00b3(0xb8)]||'');this['query']=_0x11190d,this[_0x1c00b3(0xae)]&&(this[_0x1c00b3(0xae)]['value']=_0x11190d);}},0x96);},'onInput'(_0x436754){const _0x47d650=_0x1bd0,_0x16eadf=''+(_0x436754||'');this[_0x47d650(0xc7)]=_0x16eadf,this[_0x47d650(0xd0)]=-0x1,this[_0x47d650(0xb2)]||this[_0x47d650(0x9c)](),this[_0x47d650(0xb5)]&&_0x49ead1[_0x47d650(0xc4)]&&_0x49ead1[_0x47d650(0xc4)][_0x47d650(0xa9)](new CustomEvent(_0x47d650(0xad),{'detail':_0x16eadf}));},'selectByPath'(_0x1c2e6a){this['_commit'](_0x1c2e6a);},'_scrollHi'(){setTimeout(()=>{const _0x35b125=_0x1bd0,_0x54304b=_0x49ead1['$el']&&_0x49ead1[_0x35b125(0xc4)][_0x35b125(0xbc)](_0x35b125(0xe2));_0x54304b&&_0x54304b[_0x35b125(0xd8)]({'block':_0x35b125(0xb4)});},0x0);},'onKeydown'(_0x987fd4){const _0x300449=_0x1bd0,_0x1d15f2=this[_0x300449(0xec)];if(_0x300449(0xbe)===_0x987fd4[_0x300449(0xcb)])_0x987fd4[_0x300449(0xaa)](),this[_0x300449(0xb2)]||this[_0x300449(0x9c)](),this[_0x300449(0xd0)]=Math[_0x300449(0xbd)](this[_0x300449(0xd0)]+0x1,_0x1d15f2[_0x300449(0xe3)]-0x1),this[_0x300449(0xee)]();else{if(_0x300449(0xdd)===_0x987fd4['key'])_0x987fd4[_0x300449(0xaa)](),this['hiIdx']=Math['max'](this[_0x300449(0xd0)]-0x1,-0x1),this[_0x300449(0xee)]();else{if(_0x300449(0x9d)===_0x987fd4['key'])_0x987fd4[_0x300449(0xaa)](),this[_0x300449(0xd0)]>=0x0&&this[_0x300449(0xd0)]<_0x1d15f2[_0x300449(0xe3)]?this[_0x300449(0xe8)](_0x1d15f2[this[_0x300449(0xd0)]][_0x300449(0xea)]):_0x1d15f2[_0x300449(0xe3)]>0x0&&this['_q']?this[_0x300449(0xe8)](_0x1d15f2[0x0]['path']):this[_0x300449(0xb5)]&&this['_q']&&this[_0x300449(0xe8)](this['_q']);else{if(_0x300449(0xde)===_0x987fd4['key']){if(this[_0x300449(0xb2)]=!0x1,this['hiIdx']=-0x1,!this['_allowCustom']){const _0x26a8e2=''+(_0x49ead1[_0x300449(0xc0)]['value']||'');this[_0x300449(0xc7)]=_0x26a8e2,this[_0x300449(0xae)]&&(this[_0x300449(0xae)][_0x300449(0xb8)]=_0x26a8e2);}}else{if(_0x300449(0xd3)===_0x987fd4[_0x300449(0xcb)]){const _0x1594bd=_0x1d15f2[this[_0x300449(0xd0)]>=0x0?this[_0x300449(0xd0)]:0x0];_0x1594bd&&this['_q']!==_0x1594bd[_0x300449(0xea)]&&(_0x987fd4[_0x300449(0xaa)](),this['_commit'](_0x1594bd['path'])),this[_0x300449(0xb2)]=!0x1;}}}}}},'_stopNativeChange'(_0x33a95e){const _0x27e474=_0x1bd0;_0x33a95e[_0x27e474(0xa0)]();},'typeColor':_0x13367b=>_0x13367b&&_0x13367b[_0x56d372(0xe3)]?_0x13367b[_0x56d372(0xca)](_0x56d372(0xe4))?_0x56d372(0xcf):_0x13367b[_0x56d372(0xca)](_0x56d372(0xc3))?_0x56d372(0xcc):_0x13367b[_0x56d372(0xca)](_0x56d372(0xc2))?_0x56d372(0xe5):_0x13367b['includes']('boolean')?'#facc15':_0x13367b[_0x56d372(0xca)](_0x56d372(0xa3))?_0x56d372(0xd9):_0x56d372(0xaf):_0x56d372(0xaf),'typeLabel'(_0x4fe4bf,_0x5bca16){const _0x24d817=_0x56d372;if('geo'===_0x5bca16)return _0x24d817(0xcd);if(!_0x4fe4bf||!_0x4fe4bf[_0x24d817(0xe3)])return'';const _0x173306=_0x4fe4bf[_0x24d817(0xd7)](function(_0xe4ef63){const _0x410bd7=_0x24d817;return _0x410bd7(0xa1)!==_0xe4ef63&&_0x410bd7(0x9e)!==_0xe4ef63;});return _0x173306['length']?_0x173306[_0x24d817(0xa5)](_0x24d817(0xe1)):'';}}),'mounted'(_0x54b405){const _0x3c9c08=_0x56d372;_0x54b405[_0x3c9c08(0xda)](()=>_0x54b405[_0x3c9c08(0xc0)]['value'],()=>{const _0x42b262=_0x3c9c08;if(this['_focused'])return;const _0x328d33=''+(_0x54b405['$attr'][_0x42b262(0xb8)]||'');_0x328d33!==(this[_0x42b262(0xae)]?this[_0x42b262(0xae)][_0x42b262(0xb8)]:this[_0x42b262(0xc7)])&&(this[_0x42b262(0xc7)]=_0x328d33,this[_0x42b262(0xae)]&&(this[_0x42b262(0xae)][_0x42b262(0xb8)]=_0x328d33));});},'template':'\x0a<div\x20style=\x22position:relative;\x20width:100%;\x22>\x0a\x0a\x20\x20<input\x0a\x20\x20\x20\x20type=\x22text\x22\x0a\x20\x20\x20\x20class=\x22fpi-inp\x22\x0a\x20\x20\x20\x20:class=\x22(_allowCustom\x20&&\x20isUnknown)\x20?\x20\x27fpi-inp--warn\x27\x20:\x20\x27\x27\x22\x0a\x20\x20\x20\x20:placeholder=\x22placeholder\x22\x0a\x20\x20\x20\x20@mount=\x22mountInput($el)\x22\x0a\x20\x20\x20\x20@input=\x22onInput($el.value)\x22\x0a\x20\x20\x20\x20@focus=\x22onFocus()\x22\x0a\x20\x20\x20\x20@blur=\x22onBlur()\x22\x0a\x20\x20\x20\x20@keydown:allow=\x22onKeydown($event)\x22\x0a\x20\x20\x20\x20@change=\x22_stopNativeChange($event)\x22\x0a\x20\x20\x20\x20autocomplete=\x22off\x22\x0a\x20\x20\x20\x20spellcheck=\x22false\x22\x0a\x20\x20/>\x0a\x0a\x20\x20<if\x20:=\x22_allowCustom\x20&&\x20isUnknown\x22>\x0a\x20\x20\x20\x20<span\x20class=\x22fpi-custom-tag\x22>custom</span>\x0a\x20\x20</if>\x0a\x0a\x20\x20<if\x20:=\x22open\x20&&\x20filtered.length\x20>\x200\x22>\x0a\x20\x20\x20\x20<div\x20class=\x22fpi-drop\x22\x20:style=\x22_ddStyle\x22>\x0a\x20\x20\x20\x20\x20\x20<each\x20:of=\x22filtered\x22\x20let:item=\x22item\x22\x20let:index=\x22i\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20class=\x22fpi-row\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20:class=\x22i\x20===\x20hiIdx\x20?\x20\x27fpi-row--hi\x27\x20:\x20\x27\x27\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20@mousedown=\x22selectByPath(item.path)\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22fpi-path\x22>{{\x20item.path\x20}}</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22fpi-badge\x22\x20:style=\x22\x27color:\x27\x20+\x20typeColor(item.types)\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{\x20typeLabel(item.types,\x20item.hint)\x20}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20\x20\x20</each>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20</if>\x0a\x0a\x20\x20<if\x20:=\x22open\x20&&\x20filtered.length\x20===\x200\x20&&\x20_q\x22>\x0a\x20\x20\x20\x20<div\x20class=\x22fpi-drop\x20fpi-drop--empty\x22\x20:style=\x22_ddStyle\x22>\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22fpi-empty\x22>No\x20matching\x20field\x20paths</div>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20</if>\x0a\x0a</div>\x0a','style':_0x56d372(0xd2)};
1
+ export default{tag:"field-path-input",attr:{value:{},items:{},placeholder:{},allowCustom:{}},context:t=>({_inp:null,query:"",open:!1,hiIdx:-1,_ddStyle:"",_blurT:null,_focused:!1,get placeholder(){return t.$attr.placeholder||"Field path"},get _items(){return t.$attr.items||[]},get _allowCustom(){const e=t.$attr.allowCustom;return!0===e||"true"===e||""===e},get _q(){return(""+(this.query||"")).trim()},_scoreItem(t,e,n){const i=e.length>0&&!e.every(function(t){return"object"===t});if(!n)return i?2:1;const o=t.toLowerCase(),s=n.toLowerCase(),r=o.split("."),a=r[r.length-1];if(o===s)return 100;if(o.startsWith(s))return 80;if(a===s)return 75;if(a.startsWith(s))return 65;if(o.includes(s))return 50;if(a.includes(s))return 40;const p=s.split(/\s+/).filter(Boolean);return p.length>1&&p.every(function(t){return r.some(function(e){return e.includes(t)})})?30:-1},get filtered(){const t=this._q,e=this._items,n=[];for(let i=0;i<e.length;i++){const o=e[i],s=""+(o.path||""),r=o.types?Array.from(o.types).map(function(t){return""+t}):[],a=o.hint?""+o.hint:null,p=this._scoreItem(s,r,t);p>=0&&n.push({path:s,types:r,hint:a,score:p})}return n.sort(function(t,e){return e.score-t.score||t.path.localeCompare(e.path)}),n},get isUnknown(){const t=this._q;if(!t)return!1;const e=this._items;for(let n=0;n<e.length;n++)if(""+(e[n].path||"")===t)return!1;return!0},_reposition(){const e=this._inp||t.$el&&t.$el.querySelector(".fpi-inp");if(!e)return;const n=e.getBoundingClientRect();this._ddStyle="position:fixed;width:"+Math.round(n.width)+"px;z-index:99999;"},_openDrop(){this._reposition(),this.open=!0},_commit(e){clearTimeout(this._blurT);const n=""+(e||"");this.query=n,this._inp&&(this._inp.value=n),this.open=!1,this.hiIdx=-1,t.$el&&t.$el.dispatchEvent(new CustomEvent("change",{detail:n}))},mountInput(e){this._inp=e;const n=""+(t.$attr.value||"");e.value=n,this.query=n},onFocus(){clearTimeout(this._blurT),this._focused=!0,this.hiIdx=-1;const e=""+(t.$attr.value||""),n=this._inp?this._inp.value:this.query;n===e||n||(this.query=e,this._inp&&(this._inp.value=e)),this._openDrop()},onBlur(){this._focused=!1,this._blurT=setTimeout(()=>{if(this.open=!1,!this._allowCustom){const e=""+(t.$attr.value||"");this.query=e,this._inp&&(this._inp.value=e)}},150)},onInput(e){const n=""+(e||"");this.query=n,this.hiIdx=-1,this.open||this._openDrop(),this._allowCustom&&t.$el&&t.$el.dispatchEvent(new CustomEvent("change",{detail:n}))},selectByPath(t){this._commit(t)},_scrollHi(){setTimeout(()=>{const e=t.$el&&t.$el.querySelector(".fpi-row--hi");e&&e.scrollIntoView({block:"nearest"})},0)},onKeydown(e){const n=this.filtered;if("ArrowDown"===e.key)e.preventDefault(),this.open||this._openDrop(),this.hiIdx=Math.min(this.hiIdx+1,n.length-1),this._scrollHi();else if("ArrowUp"===e.key)e.preventDefault(),this.hiIdx=Math.max(this.hiIdx-1,-1),this._scrollHi();else if("Enter"===e.key)e.preventDefault(),this.hiIdx>=0&&this.hiIdx<n.length?this._commit(n[this.hiIdx].path):n.length>0&&this._q?this._commit(n[0].path):this._allowCustom&&this._q&&this._commit(this._q);else if("Escape"===e.key){if(this.open=!1,this.hiIdx=-1,!this._allowCustom){const e=""+(t.$attr.value||"");this.query=e,this._inp&&(this._inp.value=e)}}else if("Tab"===e.key){const t=n[this.hiIdx>=0?this.hiIdx:0];t&&this._q!==t.path&&(e.preventDefault(),this._commit(t.path)),this.open=!1}},_stopNativeChange(t){t.stopPropagation()},typeColor:t=>t&&t.length?t.includes("geo")?"#34d399":t.includes("string")?"#60a5fa":t.includes("number")?"var(--okdb-orange)":t.includes("boolean")?"#facc15":t.includes("array")?"var(--okdb-indigo)":"var(--okdb-app-fg-muted)":"var(--okdb-app-fg-muted)",typeLabel(t,e){if("geo"===e)return"◎ geo";if(!t||!t.length)return"";const n=t.filter(function(t){return"null"!==t&&"undefined"!==t});return n.length?n.join(" | "):""}}),mounted(t){t.$watch(()=>t.$attr.value,()=>{if(this._focused)return;const e=""+(t.$attr.value||"");e!==(this._inp?this._inp.value:this.query)&&(this.query=e,this._inp&&(this._inp.value=e))})},template:'\n<div style="position:relative; width:100%;">\n\n <input\n type="text"\n class="fpi-inp"\n :class="(_allowCustom && isUnknown) ? \'fpi-inp--warn\' : \'\'"\n :placeholder="placeholder"\n @mount="mountInput($el)"\n @input="onInput($el.value)"\n @focus="onFocus()"\n @blur="onBlur()"\n @keydown:allow="onKeydown($event)"\n @change="_stopNativeChange($event)"\n autocomplete="off"\n spellcheck="false"\n />\n\n <if :="_allowCustom && isUnknown">\n <span class="fpi-custom-tag">custom</span>\n </if>\n\n <if :="open && filtered.length > 0">\n <div class="fpi-drop" :style="_ddStyle">\n <each :of="filtered" let:item="item" let:index="i">\n <div\n class="fpi-row"\n :class="i === hiIdx ? \'fpi-row--hi\' : \'\'"\n @mousedown="selectByPath(item.path)"\n >\n <span class="fpi-path">{{ item.path }}</span>\n <span class="fpi-badge" :style="\'color:\' + typeColor(item.types)">\n {{ typeLabel(item.types, item.hint) }}\n </span>\n </div>\n </each>\n </div>\n </if>\n\n <if :="open && filtered.length === 0 && _q">\n <div class="fpi-drop fpi-drop--empty" :style="_ddStyle">\n <div class="fpi-empty">No matching field paths</div>\n </div>\n </if>\n\n</div>\n',style:"\nfield-path-input { display:block; width:100%; position:relative; }\n\n.fpi-inp {\n width:100%; box-sizing:border-box;\n background:#12171a; border:1px solid var(--okdb-app-border); border-radius:6px;\n padding:6px 8px; color:inherit; font-size:13px;\n outline:none; transition:border-color .12s; font-family:inherit;\n}\n.fpi-inp:focus { border-color:color-mix(in srgb, var(--okdb-accent) 53%, transparent); }\n.fpi-inp--warn { border-color:color-mix(in srgb, var(--okdb-warning) 40%, transparent); }\n\n.fpi-custom-tag {\n position:absolute; right:8px; top:50%; transform:translateY(-50%);\n font-size:10px; color:var(--okdb-warning); opacity:.7; pointer-events:none; user-select:none;\n}\n\n.fpi-drop {\n background:var(--okdb-app-bg); border:1px solid var(--okdb-app-border); border-radius:7px;\n box-shadow:0 12px 40px #00000090; max-height:240px; overflow-y:auto; overflow-x:hidden;\n}\n.fpi-drop--empty { max-height:none; }\n\n.fpi-row {\n display:flex; align-items:center; gap:8px; padding:6px 10px;\n cursor:pointer; border-bottom:1px solid color-mix(in srgb, var(--okdb-app-border) 8%, transparent); min-width:0;\n transition:background .07s;\n}\n.fpi-row:last-child { border-bottom:none; }\n.fpi-row:hover,\n.fpi-row--hi { background:var(--okdb-app-surface); }\n\n.fpi-path {\n flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap;\n font-family:ui-monospace,'Cascadia Code','Fira Code',monospace;\n font-size:12px; color:var(--okdb-app-fg);\n}\n\n.fpi-badge { font-size:10px; opacity:.85; white-space:nowrap; flex-shrink:0; }\n.fpi-empty { padding:10px; font-size:12px; opacity:.4; text-align:center; }\n"};
@@ -1,6 +1,158 @@
1
- <!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"><title>field-path-input — test</title><script type="importmap">{
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <title>field-path-input — test</title>
6
+ <script type="importmap">
7
+ {
2
8
  "imports": {
3
9
  "@toolkit/": "../vendor/okjs/toolkit/",
4
10
  "@okjs": "../vendor/okjs/ok.esm.min.js"
5
11
  }
6
- }</script><style>body{background:#0d1117;color:#c9d1d9;font-family:system-ui,sans-serif;padding:32px}h2{font-size:13px;text-transform:uppercase;letter-spacing:.08em;opacity:.45;margin:32px 0 10px}.row{display:flex;align-items:flex-start;gap:16px;margin-bottom:24px}.col{flex:1;display:flex;flex-direction:column;gap:8px}.label{font-size:11px;opacity:.5}.out{font-size:12px;font-family:monospace;padding:6px 8px;background:#1e2326;border-radius:6px;min-height:28px;color:#4fc1ff}.chip{display:inline-flex;align-items:center;gap:4px;background:#2a3035;padding:3px 8px;border-radius:4px;font-size:12px;margin:2px;font-family:monospace}.chip button{background:0 0;border:none;color:#aaa;cursor:pointer;padding:0 2px;font-size:13px}.chips{display:flex;flex-wrap:wrap;min-height:28px;align-items:center;gap:2px}.add-row{display:flex;gap:8px;align-items:center}.add-row button{white-space:nowrap}hr{border:none;border-top:1px solid #2a3035;margin:32px 0}</style></head><body><h2>1 · Basic — no initial value, all field types</h2><div class="row"><div class="col"><div class="label">field-path-input (strict mode)</div><field-path-input :items="fields" placeholder="Type to filter…" @change="pick1 = $event.detail"></field-path-input><div class="label">Selected value</div><div class="out">{{ pick1 || '—' }}</div></div></div><h2>2 · Controlled + allow-custom</h2><div class="row"><div class="col"><div class="label">field-path-input (allow-custom="true")</div><field-path-input :value="pick2" :items="fields" allow-custom="true" placeholder="Known or free-text path" @change="pick2 = $event.detail"></field-path-input><div class="label">Value (round-trips via :value)</div><div class="out">{{ pick2 || '—' }}</div><button @click="pick2 = ''">Clear</button></div></div><h2>3 · Multi-select chips (Index / FTS modal pattern)</h2><div class="col"><div class="add-row"><field-path-input :value="pick3" :items="fields" placeholder="Add a field…" @change="pick3 = $event.detail" style="flex:1"></field-path-input><button @click="addChip()" :disabled="!pick3 || chips.includes(pick3)">+ Add</button></div><div class="chips"><each :of="chips" let:item="c"><span class="chip">{{ c }} <button @click="removeChip(c)">×</button></span></each><span style="font-size:12px;opacity:.3" :style="chips.length ? 'display:none' : ''">no fields added</span></div><div class="label">Chips array</div><div class="out">{{ JSON.stringify(chips) }}</div></div><hr><h2>4 · Scoring proof — type "body" → content.body ranks highest</h2><div class="row"><div class="col"><div class="label">Try typing: body, cre, lat, co bo</div><field-path-input :items="deepFields" placeholder="Test scoring…" @change="pick4 = $event.detail"></field-path-input><div class="out">{{ pick4 || '—' }}</div></div></div><script type="module">import fieldPathInput from"./field-path-input.ok.js";import{ok}from"../modules/ok.js";ok.register(fieldPathInput),ok.init(document.body,{fields:[{path:"name",types:["string"]},{path:"email",types:["string"]},{path:"city",types:["string"]},{path:"country",types:["string"]},{path:"home",types:["geo"],hint:"geo"},{path:"bio",types:["string"]},{path:"interests",types:["array"]},{path:"memberSince",types:["string"]},{path:"checkinsCount",types:["number"]},{path:"active",types:["boolean"]},{path:"meta",types:["object"]}],deepFields:[{path:"content",types:["object"]},{path:"content.title",types:["string"]},{path:"content.body",types:["string"]},{path:"content.summary",types:["string"]},{path:"meta",types:["object"]},{path:"meta.created",types:["number"]},{path:"meta.author",types:["string"]},{path:"location",types:["geo"],hint:"geo"}],pick1:"",pick2:"",pick3:"",pick4:"",chips:[],addChip(){const t=this.pick3.trim();t&&!this.chips.includes(t)&&(this.chips.push(t),this.pick3="")},removeChip(t){const e=this.chips.indexOf(t);e>=0&&this.chips.splice(e,1)}})</script></body></html>
12
+ }
13
+ </script>
14
+ <style>
15
+ body { background:#0d1117; color:#c9d1d9; font-family:system-ui,sans-serif; padding:32px; }
16
+ h2 { font-size:13px; text-transform:uppercase; letter-spacing:.08em; opacity:.45; margin:32px 0 10px; }
17
+ .row { display:flex; align-items:flex-start; gap:16px; margin-bottom:24px; }
18
+ .col { flex:1; display:flex; flex-direction:column; gap:8px; }
19
+ .label { font-size:11px; opacity:.5; }
20
+ .out { font-size:12px; font-family:monospace; padding:6px 8px; background:#1e2326; border-radius:6px; min-height:28px; color:#4FC1FF; }
21
+ .chip { display:inline-flex; align-items:center; gap:4px; background:#2a3035; padding:3px 8px; border-radius:4px; font-size:12px; margin:2px; font-family:monospace; }
22
+ .chip button { background:none; border:none; color:#aaa; cursor:pointer; padding:0 2px; font-size:13px; }
23
+ .chips { display:flex; flex-wrap:wrap; min-height:28px; align-items:center; gap:2px; }
24
+ .add-row { display:flex; gap:8px; align-items:center; }
25
+ .add-row button { white-space:nowrap; }
26
+ hr { border:none; border-top:1px solid #2a3035; margin:32px 0; }
27
+ </style>
28
+ </head>
29
+ <body>
30
+
31
+ <!-- ─── Test 1: basic, no :value, all types ─────────────────────────────── -->
32
+ <h2>1 · Basic — no initial value, all field types</h2>
33
+ <div class="row">
34
+ <div class="col">
35
+ <div class="label">field-path-input (strict mode)</div>
36
+ <field-path-input
37
+ :items="fields"
38
+ placeholder="Type to filter…"
39
+ @change="pick1 = $event.detail"
40
+ ></field-path-input>
41
+ <div class="label">Selected value</div>
42
+ <div class="out">{{ pick1 || '—' }}</div>
43
+ </div>
44
+ </div>
45
+
46
+ <!-- ─── Test 2: controlled :value + allow-custom ────────────────────────── -->
47
+ <h2>2 · Controlled + allow-custom</h2>
48
+ <div class="row">
49
+ <div class="col">
50
+ <div class="label">field-path-input (allow-custom="true")</div>
51
+ <field-path-input
52
+ :value="pick2"
53
+ :items="fields"
54
+ allow-custom="true"
55
+ placeholder="Known or free-text path"
56
+ @change="pick2 = $event.detail"
57
+ ></field-path-input>
58
+ <div class="label">Value (round-trips via :value)</div>
59
+ <div class="out">{{ pick2 || '—' }}</div>
60
+ <button @click="pick2 = ''">Clear</button>
61
+ </div>
62
+ </div>
63
+
64
+ <!-- ─── Test 3: multi-select (the chips pattern used in the real modals) ── -->
65
+ <h2>3 · Multi-select chips (Index / FTS modal pattern)</h2>
66
+ <div class="col">
67
+ <div class="add-row">
68
+ <field-path-input
69
+ :value="pick3"
70
+ :items="fields"
71
+ placeholder="Add a field…"
72
+ @change="pick3 = $event.detail"
73
+ style="flex:1"
74
+ ></field-path-input>
75
+ <button @click="addChip()" :disabled="!pick3 || chips.includes(pick3)">+ Add</button>
76
+ </div>
77
+ <div class="chips">
78
+ <each :of="chips" let:item="c">
79
+ <span class="chip">{{ c }} <button @click="removeChip(c)">×</button></span>
80
+ </each>
81
+ <span style="font-size:12px; opacity:.3;" :style="chips.length ? 'display:none' : ''">no fields added</span>
82
+ </div>
83
+ <div class="label">Chips array</div>
84
+ <div class="out">{{ JSON.stringify(chips) }}</div>
85
+ </div>
86
+
87
+ <hr>
88
+
89
+ <!-- ─── Scoring proof ─────────────────────────────────────────────────────── -->
90
+ <h2>4 · Scoring proof — type "body" → content.body ranks highest</h2>
91
+ <div class="row">
92
+ <div class="col">
93
+ <div class="label">Try typing: body, cre, lat, co bo</div>
94
+ <field-path-input
95
+ :items="deepFields"
96
+ placeholder="Test scoring…"
97
+ @change="pick4 = $event.detail"
98
+ ></field-path-input>
99
+ <div class="out">{{ pick4 || '—' }}</div>
100
+ </div>
101
+ </div>
102
+
103
+ <script type="module">
104
+ import fieldPathInput from './field-path-input.ok.js';
105
+ import { ok } from '../modules/ok.js';
106
+ ok.register(fieldPathInput);
107
+
108
+ ok.init(document.body, {
109
+ // ── shared items ──────────────────────────────────────────────────────
110
+ fields: [
111
+ { path: 'name', types: ['string'] },
112
+ { path: 'email', types: ['string'] },
113
+ { path: 'city', types: ['string'] },
114
+ { path: 'country', types: ['string'] },
115
+ { path: 'home', types: ['geo'], hint: 'geo' },
116
+ { path: 'bio', types: ['string'] },
117
+ { path: 'interests', types: ['array'] },
118
+ { path: 'memberSince', types: ['string'] },
119
+ { path: 'checkinsCount', types: ['number'] },
120
+ { path: 'active', types: ['boolean'] },
121
+ { path: 'meta', types: ['object'] },
122
+ ],
123
+
124
+ // deeper paths for scoring test
125
+ deepFields: [
126
+ { path: 'content', types: ['object'] },
127
+ { path: 'content.title', types: ['string'] },
128
+ { path: 'content.body', types: ['string'] },
129
+ { path: 'content.summary', types: ['string'] },
130
+ { path: 'meta', types: ['object'] },
131
+ { path: 'meta.created', types: ['number'] },
132
+ { path: 'meta.author', types: ['string'] },
133
+ { path: 'location', types: ['geo'], hint: 'geo' },
134
+ ],
135
+
136
+ // ── state ─────────────────────────────────────────────────────────────
137
+ pick1: '',
138
+ pick2: '',
139
+ pick3: '',
140
+ pick4: '',
141
+ chips: [],
142
+
143
+ addChip() {
144
+ const v = this.pick3.trim();
145
+ if (v && !this.chips.includes(v)) {
146
+ this.chips.push(v);
147
+ this.pick3 = '';
148
+ }
149
+ },
150
+ removeChip(c) {
151
+ const i = this.chips.indexOf(c);
152
+ if (i >= 0) this.chips.splice(i, 1);
153
+ },
154
+ });
155
+ </script>
156
+ </body>
157
+ </html>
158
+
@@ -1 +1 @@
1
- const _0x1ddc70=_0x1964;(function(_0x3e6f52,_0x36f65a){const _0x584e33=_0x1964,_0x5c2a93=_0x3e6f52();while(!![]){try{const _0x8a96ac=-parseInt(_0x584e33(0x100))/0x1*(parseInt(_0x584e33(0x119))/0x2)+-parseInt(_0x584e33(0xd6))/0x3+-parseInt(_0x584e33(0xdc))/0x4+-parseInt(_0x584e33(0xe9))/0x5*(parseInt(_0x584e33(0x14b))/0x6)+-parseInt(_0x584e33(0xd8))/0x7*(-parseInt(_0x584e33(0x13a))/0x8)+parseInt(_0x584e33(0xc5))/0x9*(parseInt(_0x584e33(0xf6))/0xa)+parseInt(_0x584e33(0xf3))/0xb;if(_0x8a96ac===_0x36f65a)break;else _0x5c2a93['push'](_0x5c2a93['shift']());}catch(_0x239e83){_0x5c2a93['push'](_0x5c2a93['shift']());}}}(_0x2ab1,0x1b697));let _am5Ready=!0x1,_am5Promise=null;function _loadScript(_0x4e19ec){return new Promise((_0x28bca0,_0x181ee5)=>{const _0x98a3c9=_0x1964;if(document[_0x98a3c9(0xe3)]('script[src=\x22'+_0x4e19ec+'\x22]'))return _0x28bca0();const _0x3a22bd=document['createElement'](_0x98a3c9(0x13f));_0x3a22bd['src']=_0x4e19ec,_0x3a22bd[_0x98a3c9(0x101)]=_0x28bca0,_0x3a22bd[_0x98a3c9(0x13e)]=()=>_0x181ee5(new Error(_0x98a3c9(0x134)+_0x4e19ec)),document[_0x98a3c9(0xca)]['appendChild'](_0x3a22bd);});}function ensureAmcharts(){const _0x586e1d=_0x1964;if(_am5Ready&&window['am5']&&window[_0x586e1d(0xf2)])return Promise[_0x586e1d(0x130)]();if(_am5Promise)return _am5Promise;const _0x329fae='https://cdn.amcharts.com/lib/5';return _am5Promise=_loadScript(_0x329fae+_0x586e1d(0xcd))[_0x586e1d(0x12a)](()=>_loadScript(_0x329fae+'/map.js'))['then'](()=>_loadScript(_0x329fae+_0x586e1d(0xe8)))[_0x586e1d(0x12a)](()=>_loadScript(_0x329fae+_0x586e1d(0xc8)))['then'](()=>{_am5Ready=!0x0;}),_am5Promise;}function geoCircle(_0x571839,_0x32b797,_0x3b0bb3,_0x3abaf5=0x40){const _0x55ac4d=_0x1964,_0x57f40c=0x6136b8,_0x3ea27e=_0x571839*Math['PI']/0xb4,_0x4d1893=[];for(let _0x470171=0x0;_0x470171<=_0x3abaf5;_0x470171++){const _0x516727=_0x470171/_0x3abaf5*0x2*Math['PI'],_0x273f59=_0x3b0bb3/_0x57f40c*Math['cos'](_0x516727)*(0xb4/Math['PI']),_0x4415fd=_0x3b0bb3/_0x57f40c*Math[_0x55ac4d(0x131)](_0x516727)/Math[_0x55ac4d(0xd2)](_0x3ea27e)*(0xb4/Math['PI']);_0x4d1893[_0x55ac4d(0xfe)]([_0x32b797+_0x4415fd,_0x571839+_0x273f59]);}return{'type':'Feature','geometry':{'type':'Polygon','coordinates':[_0x4d1893]}};}function _0x1964(_0x42c15c,_0x224f33){_0x42c15c=_0x42c15c-0xbf;const _0x2ab19a=_0x2ab1();let _0x196408=_0x2ab19a[_0x42c15c];return _0x196408;}function fmtDist(_0x645df0){const _0xad93ae=_0x1964;return null==_0x645df0?'':_0x645df0<0x3e8?Math[_0xad93ae(0xe4)](_0x645df0)+'\x20m':(_0x645df0/0x3e8)[_0xad93ae(0xde)](0x1)+_0xad93ae(0xcf);}export default{'tag':_0x1ddc70(0xfa),'attr':{'points':{},'originLat':{},'originLon':{},'radius':{},'highlightKey':{}},'context':_0x464507=>({'loading':!0x0,'_root':null,'_chart':null,'_ptSeries':null,'_originSeries':null,'_radiusSeries':null,'_originItem':null,'_hasOrigin':!0x1,'_firstZoom':!0x0,'_suppressMove':!0x1,'_downX':0x0,'_downY':0x0,'_inner':()=>_0x464507[_0x1ddc70(0x104)]?.[_0x1ddc70(0xe3)](_0x1ddc70(0xda))??null,'_build'(){const _0x26bae3=_0x1ddc70;if(this[_0x26bae3(0x102)])return;const _0x47c9de=this[_0x26bae3(0xd4)]();if(!_0x47c9de||_0x47c9de[_0x26bae3(0x11b)]<0x1)return;const _0x2069ed=window['am5'],_0x15f6a1=window[_0x26bae3(0xf2)],_0x4ec6eb=_0x2069ed[_0x26bae3(0xee)][_0x26bae3(0x121)](_0x47c9de);_0x4ec6eb[_0x26bae3(0xcc)]([window[_0x26bae3(0x14a)]['new'](_0x4ec6eb)]);const _0x292dd8=_0x4ec6eb[_0x26bae3(0xc9)][_0x26bae3(0x107)][_0x26bae3(0xfe)](_0x15f6a1['MapChart']['new'](_0x4ec6eb,{'panX':'rotateX','panY':_0x26bae3(0x12c),'projection':_0x15f6a1[_0x26bae3(0x128)](),'maxZoomLevel':0x186a0}));_0x292dd8[_0x26bae3(0x112)]['set'](_0x26bae3(0x136),_0x2069ed[_0x26bae3(0xce)]['new'](_0x4ec6eb,{'fill':_0x2069ed[_0x26bae3(0xe1)](0x161c20),'fillOpacity':0x1})),_0x292dd8[_0x26bae3(0x149)](_0x26bae3(0xe0),_0x15f6a1[_0x26bae3(0xf0)]['new'](_0x4ec6eb,{}))[_0x26bae3(0xf5)][_0x26bae3(0x149)]('visible',!0x0);const _0x1234e7=_0x292dd8[_0x26bae3(0xc4)][_0x26bae3(0xfe)](_0x15f6a1['MapPolygonSeries'][_0x26bae3(0x121)](_0x4ec6eb,{'geoJSON':window[_0x26bae3(0xd3)],'exclude':['AQ']}));_0x1234e7[_0x26bae3(0xdf)][_0x26bae3(0xfc)]['setAll']({'fill':_0x2069ed[_0x26bae3(0xe1)](0x2a3035),'stroke':_0x2069ed['color'](0x1e2630),'strokeWidth':0.5}),_0x1234e7['mapPolygons'][_0x26bae3(0xfc)][_0x26bae3(0x132)]['create'](_0x26bae3(0x10e),{'fill':_0x2069ed[_0x26bae3(0xe1)](0x333c42)});const _0x1c7ecb=_0x292dd8[_0x26bae3(0xc4)][_0x26bae3(0xfe)](_0x15f6a1['MapPolygonSeries']['new'](_0x4ec6eb,{}));_0x1c7ecb[_0x26bae3(0xdf)][_0x26bae3(0xfc)][_0x26bae3(0xc6)]({'fill':_0x2069ed[_0x26bae3(0xe1)](0x34d399),'fillOpacity':0.07,'stroke':_0x2069ed[_0x26bae3(0xe1)](0x34d399),'strokeOpacity':0.45,'strokeWidth':1.5,'strokeDasharray':[0x5,0x4],'interactive':!0x1,'tooltipText':''});const _0x1cb5b0=_0x292dd8[_0x26bae3(0xc4)][_0x26bae3(0xfe)](_0x15f6a1[_0x26bae3(0x12b)][_0x26bae3(0x121)](_0x4ec6eb,{'minDistance':0x18}));_0x1cb5b0[_0x26bae3(0x149)]('clusteredBullet',_0x483991=>{const _0x41e7da=_0x26bae3,_0x492865=_0x2069ed[_0x41e7da(0x122)][_0x41e7da(0x121)](_0x483991,{'cursorOverStyle':_0x41e7da(0xe2)});return _0x492865[_0x41e7da(0x107)][_0x41e7da(0xfe)](_0x2069ed[_0x41e7da(0x116)]['new'](_0x483991,{'radius':0x14,'fill':_0x2069ed[_0x41e7da(0xe1)](0x34d399),'fillOpacity':0.1})),_0x492865['children'][_0x41e7da(0xfe)](_0x2069ed[_0x41e7da(0x116)][_0x41e7da(0x121)](_0x483991,{'radius':0xd,'fill':_0x2069ed['color'](0x34d399),'fillOpacity':0.18})),_0x492865[_0x41e7da(0x107)][_0x41e7da(0xfe)](_0x2069ed['Circle'][_0x41e7da(0x121)](_0x483991,{'radius':0x8,'fill':_0x2069ed[_0x41e7da(0xe1)](0x34d399),'fillOpacity':0.9,'stroke':_0x2069ed[_0x41e7da(0xe1)](0x1a2228),'strokeWidth':1.5})),_0x492865[_0x41e7da(0x107)][_0x41e7da(0xfe)](_0x2069ed[_0x41e7da(0x113)][_0x41e7da(0x121)](_0x483991,{'centerX':_0x2069ed[_0x41e7da(0xec)],'centerY':_0x2069ed[_0x41e7da(0xec)],'fill':_0x2069ed[_0x41e7da(0xe1)](0xffffff),'fontSize':0x9,'fontWeight':_0x41e7da(0x11a),'populateText':!0x0,'text':_0x41e7da(0xf8)})),_0x492865[_0x41e7da(0xe5)]['on'](_0x41e7da(0x126),_0xb65f97=>{const _0x545b5a=_0x41e7da;this[_0x545b5a(0x138)]=!0x0;try{_0x1cb5b0[_0x545b5a(0xf4)](_0xb65f97[_0x545b5a(0x123)][_0x545b5a(0xf7)]);}catch(_0x9af0ec){}}),_0x2069ed['Bullet'][_0x41e7da(0x121)](_0x483991,{'sprite':_0x492865});}),_0x1cb5b0[_0x26bae3(0xd5)][_0x26bae3(0xfe)](()=>{const _0x298d01=_0x26bae3,_0x45c8e4=_0x2069ed[_0x298d01(0x118)]['new'](_0x4ec6eb,{'getFillFromSprite':!0x1,'pointerOrientation':_0x298d01(0x103),'keepTargetHover':!0x0});_0x45c8e4['get'](_0x298d01(0x136))[_0x298d01(0xc6)]({'fill':_0x2069ed[_0x298d01(0xe1)](0x1e2630),'fillOpacity':0.96,'stroke':_0x2069ed[_0x298d01(0xe1)](0x34d399),'strokeOpacity':0.3,'cornerRadius':0x6}),_0x45c8e4[_0x298d01(0x111)][_0x298d01(0xc6)]({'fill':_0x2069ed['color'](0xd0d8e0),'fontSize':0xc});const _0x35f257=_0x2069ed['Circle'][_0x298d01(0x121)](_0x4ec6eb,{'radius':0x6,'fill':_0x2069ed['color'](0x34d399),'fillOpacity':0.9,'stroke':_0x2069ed[_0x298d01(0xe1)](0x1a2228),'strokeWidth':1.5,'tooltipText':_0x298d01(0xea),'tooltip':_0x45c8e4,'cursorOverStyle':_0x298d01(0xe2)});return _0x35f257[_0x298d01(0xe5)]['on'](_0x298d01(0x126),_0x3dc2f1=>{const _0x300c3b=_0x298d01;this[_0x300c3b(0x138)]=!0x0;const _0x1175b6=_0x3dc2f1[_0x300c3b(0x123)][_0x300c3b(0xf7)],_0x5019e0=_0x1175b6?.['dataContext']?.[_0x300c3b(0xed)];_0x5019e0&&_0x464507[_0x300c3b(0x104)]?.[_0x300c3b(0x110)](new CustomEvent(_0x300c3b(0xd0),{'detail':{'key':_0x5019e0},'bubbles':!0x0}));}),_0x2069ed['Bullet']['new'](_0x4ec6eb,{'sprite':_0x35f257});});const _0x3c6169=_0x292dd8[_0x26bae3(0xc4)][_0x26bae3(0xfe)](_0x15f6a1['MapPointSeries']['new'](_0x4ec6eb,{}));_0x3c6169[_0x26bae3(0xd5)][_0x26bae3(0xfe)](()=>{const _0xfe439f=_0x26bae3,_0x24cc14=_0x2069ed[_0xfe439f(0x118)][_0xfe439f(0x121)](_0x4ec6eb,{'getFillFromSprite':!0x1});_0x24cc14[_0xfe439f(0x10a)](_0xfe439f(0x136))['setAll']({'fill':_0x2069ed[_0xfe439f(0xe1)](0x1e2630),'fillOpacity':0.96,'stroke':_0x2069ed[_0xfe439f(0xe1)](0x4fc1ff),'strokeOpacity':0.3,'cornerRadius':0x6}),_0x24cc14[_0xfe439f(0x111)][_0xfe439f(0xc6)]({'fill':_0x2069ed['color'](0xd0d8e0),'fontSize':0xb});const _0x1d97ac=_0x2069ed['Container'][_0xfe439f(0x121)](_0x4ec6eb,{});return _0x1d97ac[_0xfe439f(0x107)]['push'](_0x2069ed['Circle'][_0xfe439f(0x121)](_0x4ec6eb,{'radius':0x12,'fill':_0x2069ed[_0xfe439f(0xe1)](0x4fc1ff),'fillOpacity':0.08,'stroke':_0x2069ed[_0xfe439f(0xe1)](0x4fc1ff),'strokeOpacity':0.3,'strokeWidth':1.5})),_0x1d97ac[_0xfe439f(0x107)][_0xfe439f(0xfe)](_0x2069ed[_0xfe439f(0x116)]['new'](_0x4ec6eb,{'radius':0x5,'fill':_0x2069ed[_0xfe439f(0xe1)](0x4fc1ff),'stroke':_0x2069ed['color'](0x1e2630),'strokeWidth':0x2,'tooltipText':'[bold\x20#4FC1FF]Search\x20origin[/]\x0a[fontSize:10px\x20#888]Click\x20map\x20to\x20move[/]','tooltip':_0x24cc14,'cursorOverStyle':_0xfe439f(0x10f)})),_0x2069ed[_0xfe439f(0x140)][_0xfe439f(0x121)](_0x4ec6eb,{'sprite':_0x1d97ac});}),_0x47c9de[_0x26bae3(0x106)]('pointerdown',_0x4b50e1=>{const _0x25c90b=_0x26bae3;this[_0x25c90b(0xc7)]=_0x4b50e1['clientX'],this['_downY']=_0x4b50e1[_0x25c90b(0x12f)],this['_suppressMove']=!0x1;},{'passive':!0x0}),_0x292dd8['chartContainer'][_0x26bae3(0xe5)]['on'](_0x26bae3(0x126),_0x503d55=>{const _0x59a5df=_0x26bae3;if(this[_0x59a5df(0x138)])this[_0x59a5df(0x138)]=!0x1;else try{const _0x3926aa=(_0x503d55[_0x59a5df(0x148)]?.[_0x59a5df(0x10d)]??0x0)-this[_0x59a5df(0xc7)],_0x1f2dd7=(_0x503d55[_0x59a5df(0x148)]?.[_0x59a5df(0x12f)]??0x0)-this[_0x59a5df(0x117)];if(Math[_0x59a5df(0xe7)](_0x3926aa,_0x1f2dd7)>0x8)return;const _0x142ab9=_0x292dd8['invert'](_0x503d55['point']);_0x142ab9&&isFinite(_0x142ab9['latitude'])&&isFinite(_0x142ab9[_0x59a5df(0x142)])&&_0x464507[_0x59a5df(0x104)]?.[_0x59a5df(0x110)](new CustomEvent(_0x59a5df(0xd7),{'detail':{'lat':_0x142ab9[_0x59a5df(0x147)],'lon':_0x142ab9['longitude']},'bubbles':!0x0}));}catch(_0x3eeb62){}}),this[_0x26bae3(0x102)]=_0x4ec6eb,this[_0x26bae3(0x11e)]=_0x292dd8,this[_0x26bae3(0x146)]=_0x1cb5b0,this['_originSeries']=_0x3c6169,this['_radiusSeries']=_0x1c7ecb,_0x292dd8[_0x26bae3(0x11d)](0x320,0x64),this[_0x26bae3(0x109)]=!0x1;},'_syncData'(){const _0x37ad47=_0x1ddc70;if(!this[_0x37ad47(0x11e)])return;const _0x596341=_0x464507['$attr'][_0x37ad47(0x115)]||[],_0x1ea985=parseFloat(_0x464507['$attr']['originLat']),_0x239e78=parseFloat(_0x464507['$attr'][_0x37ad47(0xff)]),_0x498d9a=parseFloat(_0x464507[_0x37ad47(0xef)][_0x37ad47(0xbf)]),_0x4062da=!isNaN(_0x1ea985)&&!isNaN(_0x239e78),_0x1c5dd1=_0x4062da&&_0x498d9a>0x0&&!isNaN(_0x498d9a)&&_0x498d9a<0x1312d00;try{this[_0x37ad47(0x146)][_0x37ad47(0xeb)][_0x37ad47(0xc6)](_0x596341[_0x37ad47(0x114)](_0xe16cc5=>({'geometry':{'type':_0x37ad47(0x124),'coordinates':[_0xe16cc5[_0x37ad47(0x10c)],_0xe16cc5[_0x37ad47(0xf9)]]},'title':_0xe16cc5['title']||_0xe16cc5[_0x37ad47(0xed)]||'','dist':fmtDist(_0xe16cc5[_0x37ad47(0xe6)]),'key':_0xe16cc5[_0x37ad47(0xed)]})));}catch(_0x57eeb5){}_0x464507[_0x37ad47(0xef)][_0x37ad47(0x11f)]&&requestAnimationFrame(()=>{const _0x243633=_0x37ad47;try{this[_0x243633(0xc3)]();}catch(_0x41c029){}});try{_0x4062da?this['_hasOrigin']?this[_0x37ad47(0x129)]&&(this['_originItem'][_0x37ad47(0x149)](_0x37ad47(0x142),_0x239e78),this[_0x37ad47(0x129)][_0x37ad47(0x149)](_0x37ad47(0x147),_0x1ea985)):(this[_0x37ad47(0x120)][_0x37ad47(0xeb)]['setAll']([{'geometry':{'type':_0x37ad47(0x124),'coordinates':[_0x239e78,_0x1ea985]}}]),this[_0x37ad47(0x129)]=this[_0x37ad47(0x120)][_0x37ad47(0x139)][0x0]??null,this[_0x37ad47(0x13c)]=!0x0):this['_hasOrigin']&&(this['_originSeries']['data'][_0x37ad47(0xc6)]([]),this[_0x37ad47(0x129)]=null,this[_0x37ad47(0x13c)]=!0x1);}catch(_0x352348){}try{this[_0x37ad47(0x141)][_0x37ad47(0xeb)][_0x37ad47(0xc6)](_0x1c5dd1?[geoCircle(_0x1ea985,_0x239e78,_0x498d9a)]:[]);}catch(_0x432e2f){}if(_0x4062da&&this[_0x37ad47(0x105)]){this[_0x37ad47(0x105)]=!0x1;const _0x423fe0=_0x1c5dd1?Math[_0x37ad47(0xdd)](0x3e8,Math[_0x37ad47(0x14c)](0x2,Math[_0x37ad47(0xe4)](Math[_0x37ad47(0xc0)](0x2625a00/_0x498d9a)))):0x3;try{this['_chart']['zoomToGeoPoint']({'latitude':_0x1ea985,'longitude':_0x239e78},_0x423fe0,!0x0);}catch(_0xf4eef7){}}},'_syncHighlight'(){const _0x562d31=_0x1ddc70;if(!this[_0x562d31(0x11e)])return;const _0x109427=_0x464507[_0x562d31(0xef)][_0x562d31(0x11f)]??null,_0x266d32=_0x464507[_0x562d31(0xef)][_0x562d31(0x115)]||[],_0x10d02e=window['am5'],_0x151279=_0x109427?_0x266d32[_0x562d31(0x143)](_0x13ea66=>_0x13ea66[_0x562d31(0xed)]===_0x109427):null;try{this[_0x562d31(0x146)][_0x562d31(0x139)][_0x562d31(0x145)](_0x37e812=>{const _0x57fdcc=_0x562d31,_0x4bc29e=_0x37e812[_0x57fdcc(0xd5)]?.[0x0]?.[_0x57fdcc(0x10a)]?.(_0x57fdcc(0x10b));if(!_0x4bc29e)return;const _0x5e7777=_0x109427&&_0x37e812[_0x57fdcc(0xc1)]?.[_0x57fdcc(0xed)]===_0x109427;if(_0x4bc29e[_0x57fdcc(0x149)](_0x57fdcc(0x135),_0x10d02e[_0x57fdcc(0xe1)](_0x5e7777?0xfbbf24:0x34d399)),_0x4bc29e[_0x57fdcc(0x149)](_0x57fdcc(0xfb),_0x5e7777?0x1:0.9),_0x4bc29e[_0x57fdcc(0x149)](_0x57fdcc(0xbf),_0x5e7777?0xc:0x6),_0x4bc29e['set'](_0x57fdcc(0x108),_0x5e7777?0x3:1.5),_0x4bc29e[_0x57fdcc(0x149)](_0x57fdcc(0xdb),_0x10d02e[_0x57fdcc(0xe1)](_0x5e7777?0xffffff:0x1a2228)),_0x5e7777)try{_0x4bc29e[_0x57fdcc(0xf1)]();}catch(_0x3371f8){}else try{_0x4bc29e[_0x57fdcc(0x133)]();}catch(_0x5c511b){}});}catch(_0x5e7741){}if(_0x151279&&isFinite(_0x151279['lat'])&&isFinite(_0x151279['lon'])){const _0x13fb46=Math[_0x562d31(0x14c)](this[_0x562d31(0x11e)][_0x562d31(0x10a)](_0x562d31(0x11c))||0xa,0xa);try{this['_chart'][_0x562d31(0xd1)]({'latitude':_0x151279[_0x562d31(0xf9)],'longitude':_0x151279[_0x562d31(0x10c)]},_0x13fb46,!0x0);}catch(_0x396d56){}}},'_destroy'(){const _0x6f5115=_0x1ddc70;try{this[_0x6f5115(0x102)]?.[_0x6f5115(0xfd)]();}catch(_0x38b0bd){}this['_root']=null,this[_0x6f5115(0x11e)]=null,this[_0x6f5115(0x146)]=null,this[_0x6f5115(0x120)]=null,this[_0x6f5115(0x141)]=null,this[_0x6f5115(0x129)]=null,this[_0x6f5115(0x13c)]=!0x1,this[_0x6f5115(0x105)]=!0x0,this['_suppressMove']=!0x1;}}),async 'init'(_0x5cd71a){const _0x438941=_0x1ddc70;this[_0x438941(0x109)]=!0x0;const _0x32df4f=async()=>{const _0x455dd3=_0x438941,_0x3f8f77=this[_0x455dd3(0xd4)]();if(!_0x3f8f77)return!0x1;if(_0x3f8f77[_0x455dd3(0x11b)]<0x1)return!0x1;try{await ensureAmcharts(),await new Promise(_0x51c9d6=>requestAnimationFrame(_0x51c9d6)),this[_0x455dd3(0x13b)](),this[_0x455dd3(0x137)](),this[_0x455dd3(0xc3)]();}catch(_0x19cc01){console[_0x455dd3(0x12d)](_0x455dd3(0x127),_0x19cc01),this['loading']=!0x1;}return!0x0;};if(!await _0x32df4f()){const _0x3ef40f=_0x5cd71a[_0x438941(0x104)]??this[_0x438941(0xd4)]();if(!_0x3ef40f)return void(this[_0x438941(0x109)]=!0x1);const _0x20985f=new ResizeObserver(async _0x5a396c=>{const _0x418b38=_0x438941;_0x5a396c[0x0]?.['contentRect']?.[_0x418b38(0xc2)]>0x0&&(_0x20985f[_0x418b38(0xcb)](),await _0x32df4f());});_0x20985f['observe'](_0x3ef40f);}_0x5cd71a[_0x438941(0x125)](()=>[_0x5cd71a['$attr'][_0x438941(0x115)],_0x5cd71a[_0x438941(0xef)][_0x438941(0xd9)],_0x5cd71a['$attr']['originLon'],_0x5cd71a[_0x438941(0xef)][_0x438941(0xbf)]],()=>{const _0x57023b=_0x438941;try{this[_0x57023b(0x137)]();}catch(_0x37d9fc){}}),_0x5cd71a[_0x438941(0x125)](()=>_0x5cd71a[_0x438941(0xef)][_0x438941(0x11f)],()=>{try{this['_syncHighlight']();}catch(_0x1a4da3){}});},'unmount'(){const _0x119912=_0x1ddc70;this[_0x119912(0x12e)]();},'template':_0x1ddc70(0x13d),'style':_0x1ddc70(0x144)};function _0x2ab1(){const _0x1daeec=['45fdoHCg','[bold]{title}[/]\x0a[fontSize:11px\x20#a0c8b0]{dist}[/]','data','p50','key','Root','$attr','ZoomControl','showTooltip','am5map','3905979YkrraP','zoomToCluster','homeButton','80ZxjZRU','dataItem','{value}','lat','geo-map','fillOpacity','template','dispose','push','originLon','2tDuouh','onload','_root','vertical','$el','_firstZoom','addEventListener','children','strokeWidth','loading','get','sprite','lon','clientX','hover','crosshair','dispatchEvent','label','chartContainer','Label','map','points','Circle','_downY','Tooltip','15398hdegAD','600','offsetHeight','zoomLevel','appear','_chart','highlightKey','_originSeries','new','Container','target','Point','$watch','click','geo-map\x20init:','geoMercator','_originItem','then','ClusteredPointSeries','translateY','error','_destroy','clientY','resolve','sin','states','hideTooltip','geo-map:\x20failed\x20to\x20load\x20','fill','background','_syncData','_suppressMove','dataItems','693832iXEdWF','_build','_hasOrigin','\x0a<div\x20style=\x22position:relative;\x20width:100%;\x20height:100%;\x22>\x0a\x20\x20<if\x20:=\x22loading\x22>\x0a\x20\x20\x20\x20<div\x20style=\x22position:absolute;inset:0;display:flex;align-items:center;justify-content:center;pointer-events:none;gap:6px;z-index:1;\x22>\x0a\x20\x20\x20\x20\x20\x20<ok-icon\x20name=\x22loader\x22\x20class=\x22spin\x22\x20style=\x22width:14px;height:14px;opacity:.3;\x22></ok-icon>\x0a\x20\x20\x20\x20\x20\x20<span\x20style=\x22font-size:11px;opacity:.3;\x22>Loading\x20map…</span>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20</if>\x0a\x20\x20<div\x20class=\x22geo-map-inner\x22\x20style=\x22width:100%;height:100%;\x22></div>\x0a</div>','onerror','script','Bullet','_radiusSeries','longitude','find','[tag]{display:block;background:var(--okdb-app-bg);overflow:hidden}','forEach','_ptSeries','latitude','originalEvent','set','am5themes_Animated','55206CfjPZG','max','radius','log2','dataContext','height','_syncHighlight','series','17829mdKwXI','setAll','_downX','/themes/Animated.js','container','head','disconnect','setThemes','/index.js','Rectangle','\x20km','select','zoomToGeoPoint','cos','am5geodata_worldLow','_inner','bullets','484446AlDyqy','move','14BneuhL','originLat','.geo-map-inner','stroke','689708jAYbse','min','toFixed','mapPolygons','zoomControl','color','pointer','querySelector','round','events','distance','hypot','/geodata/worldLow.js'];_0x2ab1=function(){return _0x1daeec;};return _0x2ab1();}
1
+ let _am5Ready=!1,_am5Promise=null;function _loadScript(t){return new Promise((e,i)=>{if(document.querySelector(`script[src="${t}"]`))return e();const o=document.createElement("script");o.src=t,o.onload=e,o.onerror=()=>i(new Error("geo-map: failed to load "+t)),document.head.appendChild(o)})}function ensureAmcharts(){if(_am5Ready&&window.am5&&window.am5map)return Promise.resolve();if(_am5Promise)return _am5Promise;const t="https://cdn.amcharts.com/lib/5";return _am5Promise=_loadScript(`${t}/index.js`).then(()=>_loadScript(`${t}/map.js`)).then(()=>_loadScript(`${t}/geodata/worldLow.js`)).then(()=>_loadScript(`${t}/themes/Animated.js`)).then(()=>{_am5Ready=!0}),_am5Promise}function geoCircle(t,e,i,o=64){const r=6371e3,s=t*Math.PI/180,n=[];for(let l=0;l<=o;l++){const a=l/o*2*Math.PI,c=i/r*Math.cos(a)*(180/Math.PI),h=i/r*Math.sin(a)/Math.cos(s)*(180/Math.PI);n.push([e+h,t+c])}return{type:"Feature",geometry:{type:"Polygon",coordinates:[n]}}}function fmtDist(t){return null==t?"":t<1e3?`${Math.round(t)} m`:`${(t/1e3).toFixed(1)} km`}export default{tag:"geo-map",attr:{points:{},originLat:{},originLon:{},radius:{},highlightKey:{}},context:t=>({loading:!0,_root:null,_chart:null,_ptSeries:null,_originSeries:null,_radiusSeries:null,_originItem:null,_hasOrigin:!1,_firstZoom:!0,_suppressMove:!1,_downX:0,_downY:0,_inner:()=>t.$el?.querySelector(".geo-map-inner")??null,_build(){if(this._root)return;const e=this._inner();if(!e||e.offsetHeight<1)return;const i=window.am5,o=window.am5map,r=i.Root.new(e);r.setThemes([window.am5themes_Animated.new(r)]);const s=r.container.children.push(o.MapChart.new(r,{panX:"rotateX",panY:"translateY",projection:o.geoMercator(),maxZoomLevel:1e5}));s.chartContainer.set("background",i.Rectangle.new(r,{fill:i.color(1448992),fillOpacity:1})),s.set("zoomControl",o.ZoomControl.new(r,{})).homeButton.set("visible",!0);const n=s.series.push(o.MapPolygonSeries.new(r,{geoJSON:window.am5geodata_worldLow,exclude:["AQ"]}));n.mapPolygons.template.setAll({fill:i.color(2764853),stroke:i.color(1975856),strokeWidth:.5}),n.mapPolygons.template.states.create("hover",{fill:i.color(3357762)});const l=s.series.push(o.MapPolygonSeries.new(r,{}));l.mapPolygons.template.setAll({fill:i.color(3462041),fillOpacity:.07,stroke:i.color(3462041),strokeOpacity:.45,strokeWidth:1.5,strokeDasharray:[5,4],interactive:!1,tooltipText:""});const a=s.series.push(o.ClusteredPointSeries.new(r,{minDistance:24}));a.set("clusteredBullet",t=>{const e=i.Container.new(t,{cursorOverStyle:"pointer"});return e.children.push(i.Circle.new(t,{radius:20,fill:i.color(3462041),fillOpacity:.1})),e.children.push(i.Circle.new(t,{radius:13,fill:i.color(3462041),fillOpacity:.18})),e.children.push(i.Circle.new(t,{radius:8,fill:i.color(3462041),fillOpacity:.9,stroke:i.color(1712680),strokeWidth:1.5})),e.children.push(i.Label.new(t,{centerX:i.p50,centerY:i.p50,fill:i.color(16777215),fontSize:9,fontWeight:"600",populateText:!0,text:"{value}"})),e.events.on("click",t=>{this._suppressMove=!0;try{a.zoomToCluster(t.target.dataItem)}catch(t){}}),i.Bullet.new(t,{sprite:e})}),a.bullets.push(()=>{const e=i.Tooltip.new(r,{getFillFromSprite:!1,pointerOrientation:"vertical",keepTargetHover:!0});e.get("background").setAll({fill:i.color(1975856),fillOpacity:.96,stroke:i.color(3462041),strokeOpacity:.3,cornerRadius:6}),e.label.setAll({fill:i.color(13687008),fontSize:12});const o=i.Circle.new(r,{radius:6,fill:i.color(3462041),fillOpacity:.9,stroke:i.color(1712680),strokeWidth:1.5,tooltipText:"[bold]{title}[/]\n[fontSize:11px #a0c8b0]{dist}[/]",tooltip:e,cursorOverStyle:"pointer"});return o.events.on("click",e=>{this._suppressMove=!0;const i=e.target.dataItem,o=i?.dataContext?.key;o&&t.$el?.dispatchEvent(new CustomEvent("select",{detail:{key:o},bubbles:!0}))}),i.Bullet.new(r,{sprite:o})});const c=s.series.push(o.MapPointSeries.new(r,{}));c.bullets.push(()=>{const t=i.Tooltip.new(r,{getFillFromSprite:!1});t.get("background").setAll({fill:i.color(1975856),fillOpacity:.96,stroke:i.color(5227007),strokeOpacity:.3,cornerRadius:6}),t.label.setAll({fill:i.color(13687008),fontSize:11});const e=i.Container.new(r,{});return e.children.push(i.Circle.new(r,{radius:18,fill:i.color(5227007),fillOpacity:.08,stroke:i.color(5227007),strokeOpacity:.3,strokeWidth:1.5})),e.children.push(i.Circle.new(r,{radius:5,fill:i.color(5227007),stroke:i.color(1975856),strokeWidth:2,tooltipText:"[bold #4FC1FF]Search origin[/]\n[fontSize:10px #888]Click map to move[/]",tooltip:t,cursorOverStyle:"crosshair"})),i.Bullet.new(r,{sprite:e})}),e.addEventListener("pointerdown",t=>{this._downX=t.clientX,this._downY=t.clientY,this._suppressMove=!1},{passive:!0}),s.chartContainer.events.on("click",e=>{if(this._suppressMove)this._suppressMove=!1;else try{const i=(e.originalEvent?.clientX??0)-this._downX,o=(e.originalEvent?.clientY??0)-this._downY;if(Math.hypot(i,o)>8)return;const r=s.invert(e.point);r&&isFinite(r.latitude)&&isFinite(r.longitude)&&t.$el?.dispatchEvent(new CustomEvent("move",{detail:{lat:r.latitude,lon:r.longitude},bubbles:!0}))}catch(t){}}),this._root=r,this._chart=s,this._ptSeries=a,this._originSeries=c,this._radiusSeries=l,s.appear(800,100),this.loading=!1},_syncData(){if(!this._chart)return;const e=t.$attr.points||[],i=parseFloat(t.$attr.originLat),o=parseFloat(t.$attr.originLon),r=parseFloat(t.$attr.radius),s=!isNaN(i)&&!isNaN(o),n=s&&r>0&&!isNaN(r)&&r<2e7;try{this._ptSeries.data.setAll(e.map(t=>({geometry:{type:"Point",coordinates:[t.lon,t.lat]},title:t.title||t.key||"",dist:fmtDist(t.distance),key:t.key})))}catch(t){}t.$attr.highlightKey&&requestAnimationFrame(()=>{try{this._syncHighlight()}catch(t){}});try{s?this._hasOrigin?this._originItem&&(this._originItem.set("longitude",o),this._originItem.set("latitude",i)):(this._originSeries.data.setAll([{geometry:{type:"Point",coordinates:[o,i]}}]),this._originItem=this._originSeries.dataItems[0]??null,this._hasOrigin=!0):this._hasOrigin&&(this._originSeries.data.setAll([]),this._originItem=null,this._hasOrigin=!1)}catch(t){}try{this._radiusSeries.data.setAll(n?[geoCircle(i,o,r)]:[])}catch(t){}if(s&&this._firstZoom){this._firstZoom=!1;const t=n?Math.min(1e3,Math.max(2,Math.round(Math.log2(4e7/r)))):3;try{this._chart.zoomToGeoPoint({latitude:i,longitude:o},t,!0)}catch(t){}}},_syncHighlight(){if(!this._chart)return;const e=t.$attr.highlightKey??null,i=t.$attr.points||[],o=window.am5,r=e?i.find(t=>t.key===e):null;try{this._ptSeries.dataItems.forEach(t=>{const i=t.bullets?.[0]?.get?.("sprite");if(!i)return;const r=e&&t.dataContext?.key===e;if(i.set("fill",o.color(r?16498468:3462041)),i.set("fillOpacity",r?1:.9),i.set("radius",r?12:6),i.set("strokeWidth",r?3:1.5),i.set("stroke",o.color(r?16777215:1712680)),r)try{i.showTooltip()}catch(t){}else try{i.hideTooltip()}catch(t){}})}catch(t){}if(r&&isFinite(r.lat)&&isFinite(r.lon)){const t=Math.max(this._chart.get("zoomLevel")||10,10);try{this._chart.zoomToGeoPoint({latitude:r.lat,longitude:r.lon},t,!0)}catch(t){}}},_destroy(){try{this._root?.dispose()}catch(t){}this._root=null,this._chart=null,this._ptSeries=null,this._originSeries=null,this._radiusSeries=null,this._originItem=null,this._hasOrigin=!1,this._firstZoom=!0,this._suppressMove=!1}}),async init(t){this.loading=!0;const e=async()=>{const t=this._inner();if(!t)return!1;if(t.offsetHeight<1)return!1;try{await ensureAmcharts(),await new Promise(t=>requestAnimationFrame(t)),this._build(),this._syncData(),this._syncHighlight()}catch(t){console.error("geo-map init:",t),this.loading=!1}return!0};if(!await e()){const i=t.$el??this._inner();if(!i)return void(this.loading=!1);const o=new ResizeObserver(async t=>{t[0]?.contentRect?.height>0&&(o.disconnect(),await e())});o.observe(i)}t.$watch(()=>[t.$attr.points,t.$attr.originLat,t.$attr.originLon,t.$attr.radius],()=>{try{this._syncData()}catch(t){}}),t.$watch(()=>t.$attr.highlightKey,()=>{try{this._syncHighlight()}catch(t){}})},unmount(){this._destroy()},template:'\n<div style="position:relative; width:100%; height:100%;">\n <if :="loading">\n <div style="position:absolute;inset:0;display:flex;align-items:center;justify-content:center;pointer-events:none;gap:6px;z-index:1;">\n <ok-icon name="loader" class="spin" style="width:14px;height:14px;opacity:.3;"></ok-icon>\n <span style="font-size:11px;opacity:.3;">Loading map…</span>\n </div>\n </if>\n <div class="geo-map-inner" style="width:100%;height:100%;"></div>\n</div>',style:"[tag]{display:block;background:var(--okdb-app-bg);overflow:hidden}"};
@@ -1 +1 @@
1
- function _0x5687(){const _0x1cd4af=['*/15\x20*\x20*\x20*\x20*','Mar','Every\x20month\x20(1st\x20midnight)','placeholder','1–31\x20\x20or\x20\x20*/5\x20\x20or\x20\x201,15','Once\x20at\x20startup\x20/\x20reboot','true','invalid\x20step\x20\x22','384usSizE','hour','*/30\x20*\x20*\x20*\x20*','mousedown','Sat','64230whLgNU','0\x209\x20*\x20*\x201-5','Minute','*\x20*\x20*\x20*\x20*','weekdays','Dec','.oci-panel','day-of-week','Oct','Day\x20of\x20month','@midnight','Every\x20day\x20(midnight)','114340PYYWqI','Every\x205\x20minutes','@weekly','_hour','Expected\x205\x20fields,\x20got\x20','dom','_minute','0–59\x20\x20or\x20\x20*/5\x20\x20or\x20\x200,30','Once\x20an\x20hour,\x20at\x20the\x20start\x20of\x20the\x20hour','open','trim','error','Hour','@monthly','0–23\x20\x20or\x20\x20*/2\x20\x20or\x20\x208,17','month','2472iXeMxv','\x0aok-cron-input\x20{\x20display:block;\x20position:relative;\x20}\x0a\x0a/*\x20──\x20Trigger\x20───────────────────────────────\x20*/\x0a.oci-wrap\x20{\x20display:inline-flex;\x20align-items:center;\x20width:100%;\x20}\x0a\x0a.oci-field\x20{\x0a\x20\x20\x20\x20display:flex;\x20align-items:center;\x20gap:0;\x0a\x20\x20\x20\x20background:var(--okdb-app-surface-2);\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:7px;\x0a\x20\x20\x20\x20padding:6px\x200\x206px\x2010px;\x20width:100%;\x20box-sizing:border-box;\x0a\x20\x20\x20\x20transition:border-color\x20.15s,\x20background\x20.12s;\x0a\x20\x20\x20\x20height:31px;\x0a}\x0a.oci-field:focus-within\x20{\x20border-color:color-mix(in\x20srgb,\x20var(--okdb-accent)\x2053%,\x20transparent);\x20background:var(--okdb-app-surface-2);\x20}\x0a.oci-field:hover\x20{\x20background:var(--okdb-app-surface-2);\x20border-color:var(--okdb-app-border-strong);\x20}\x0a.oci-field--disabled\x20{\x20opacity:.45;\x20pointer-events:none;\x20}\x0a\x0a.oci-value\x20{\x0a\x20\x20\x20\x20flex:1;\x20min-width:0;\x20overflow:hidden;\x20text-overflow:ellipsis;\x20white-space:nowrap;\x0a\x20\x20\x20\x20font-family:inherit;\x0a\x20\x20\x20\x20font-size:13px;\x20color:#c8d4de;\x20padding:0\x204px\x200\x200;\x0a\x20\x20\x20\x20user-select:none;\x0a}\x0a.oci-value:empty::before\x20{\x20content:\x20attr(data-ph);\x20opacity:.4;\x20}\x0a\x0a.oci-btn\x20{\x0a\x20\x20\x20\x20flex-shrink:0;\x20background:none;\x20border:none;\x20border-left:1px\x20solid\x20var(--okdb-app-border);\x0a\x20\x20\x20\x20color:var(--okdb-app-fg-muted);\x20cursor:pointer;\x20padding:0\x2010px;\x20display:flex;\x20align-items:center;\x20justify-content:center;\x0a\x20\x20\x20\x20height:19px;\x20transition:background\x20.1s,\x20color\x20.1s;\x0a}\x0a.oci-btn:hover\x20{\x20color:var(--okdb-accent);\x20}\x0a.oci-btn:disabled\x20{\x20opacity:.4;\x20cursor:not-allowed;\x20}\x0a\x0a/*\x20──\x20Panel\x20─────────────────────────────────\x20*/\x0a.oci-panel\x20{\x0a\x20\x20\x20\x20background:var(--okdb-app-bg);\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:10px;\x0a\x20\x20\x20\x20box-shadow:0\x2016px\x2048px\x20#00000099;\x20overflow:hidden;\x0a\x20\x20\x20\x20display:flex;\x20flex-direction:column;\x0a\x20\x20\x20\x20animation:oci-fadein\x20.12s\x20ease;\x0a}\x0a@keyframes\x20oci-fadein\x20{\x20from\x20{\x20opacity:0;\x20transform:translateY(-4px);\x20}\x20to\x20{\x20opacity:1;\x20transform:translateY(0);\x20}\x20}\x0a\x0a.oci-panel-head\x20{\x0a\x20\x20\x20\x20display:flex;\x20align-items:center;\x20padding:10px\x2014px\x208px;\x0a\x20\x20\x20\x20border-bottom:1px\x20solid\x20var(--okdb-app-border);\x0a}\x0a.oci-panel-title\x20{\x20font-size:13px;\x20font-weight:600;\x20color:var(--okdb-app-fg);\x20flex:1;\x20}\x0a.oci-close\x20{\x0a\x20\x20\x20\x20background:none;\x20border:none;\x20color:var(--okdb-app-fg-muted);\x20cursor:pointer;\x0a\x20\x20\x20\x20font-size:14px;\x20padding:2px\x204px;\x20border-radius:4px;\x20line-height:1;\x0a\x20\x20\x20\x20transition:color\x20.1s,\x20background\x20.1s;\x0a}\x0a.oci-close:hover\x20{\x20color:var(--okdb-app-fg-strong);\x20background:var(--okdb-app-surface);\x20}\x0a\x0a/*\x20──\x20Raw\x20input\x20─────────────────────────────\x20*/\x0a.oci-raw-row\x20{\x0a\x20\x20\x20\x20padding:10px\x2014px\x204px;\x20display:flex;\x20flex-direction:column;\x20gap:3px;\x0a}\x0a.oci-raw-inp\x20{\x0a\x20\x20\x20\x20background:var(--okdb-app-bg-deep);\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:6px;\x0a\x20\x20\x20\x20padding:7px\x2010px;\x20color:var(--okdb-app-fg-strong);\x20font-family:ui-monospace,\x27Cascadia\x20Code\x27,\x27Fira\x20Code\x27,monospace;\x0a\x20\x20\x20\x20font-size:14px;\x20letter-spacing:.05em;\x20outline:none;\x20width:100%;\x20box-sizing:border-box;\x0a\x20\x20\x20\x20transition:border-color\x20.12s;\x0a}\x0a.oci-raw-inp:focus\x20{\x20border-color:color-mix(in\x20srgb,\x20var(--okdb-accent)\x2053%,\x20transparent);\x20}\x0a.oci-raw-hint\x20{\x0a\x20\x20\x20\x20font-size:10px;\x20color:var(--okdb-app-fg-muted);\x20text-align:center;\x0a\x20\x20\x20\x20font-family:ui-monospace,\x27Cascadia\x20Code\x27,monospace;\x20letter-spacing:.18em;\x0a\x20\x20\x20\x20user-select:none;\x20padding:0\x2010px;\x0a}\x0a\x0a/*\x20──\x20Description\x20bar\x20───────────────────────\x20*/\x0a.oci-desc\x20{\x0a\x20\x20\x20\x20display:flex;\x20align-items:flex-start;\x20gap:6px;\x0a\x20\x20\x20\x20margin:6px\x2014px\x208px;\x20padding:7px\x2010px;\x20border-radius:6px;\x0a\x20\x20\x20\x20font-size:12px;\x20line-height:1.4;\x0a}\x0a.oci-desc--ok\x20\x20{\x20background:#0e2a1a;\x20color:var(--okdb-success);\x20border:1px\x20solid\x20#166534;\x20}\x0a.oci-desc--err\x20{\x20background:var(--okdb-danger-deep-bg);\x20color:var(--okdb-danger);\x20border:1px\x20solid\x20var(--okdb-danger-deep-border);\x20}\x0a.oci-desc-icon\x20{\x20flex-shrink:0;\x20}\x0a\x0a/*\x20──\x20Divider\x20───────────────────────────────\x20*/\x0a.oci-divider\x20{\x20border-top:1px\x20solid\x20var(--okdb-app-border);\x20margin:4px\x200;\x20}\x0a\x0a/*\x20──\x20Field\x20rows\x20────────────────────────────\x20*/\x0a.oci-fields\x20{\x0a\x20\x20\x20\x20padding:6px\x2014px\x204px;\x20display:flex;\x20flex-direction:column;\x20gap:5px;\x0a}\x0a.oci-field-row\x20{\x0a\x20\x20\x20\x20display:grid;\x20grid-template-columns:100px\x201fr\x20auto;\x0a\x20\x20\x20\x20align-items:center;\x20gap:8px;\x0a}\x0a.oci-flabel\x20{\x0a\x20\x20\x20\x20font-size:11px;\x20color:var(--okdb-app-fg-muted);\x20font-weight:500;\x20text-align:right;\x0a\x20\x20\x20\x20padding-right:4px;\x20user-select:none;\x0a}\x0a.oci-finp\x20{\x0a\x20\x20\x20\x20background:var(--okdb-app-bg-deep);\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:5px;\x0a\x20\x20\x20\x20padding:4px\x208px;\x20color:var(--okdb-app-fg);\x0a\x20\x20\x20\x20font-family:ui-monospace,\x27Cascadia\x20Code\x27,\x27Fira\x20Code\x27,monospace;\x0a\x20\x20\x20\x20font-size:12px;\x20outline:none;\x20width:100%;\x20box-sizing:border-box;\x0a\x20\x20\x20\x20transition:border-color\x20.12s;\x0a}\x0a.oci-finp:focus\x20{\x20border-color:color-mix(in\x20srgb,\x20var(--okdb-accent)\x2053%,\x20transparent);\x20}\x0a.oci-field-row--err\x20.oci-finp\x20{\x20border-color:color-mix(in\x20srgb,\x20var(--okdb-danger)\x2053%,\x20transparent);\x20}\x0a.oci-frange\x20{\x0a\x20\x20\x20\x20font-size:10px;\x20color:var(--okdb-app-fg-muted);\x20white-space:nowrap;\x0a\x20\x20\x20\x20font-family:ui-monospace,monospace;\x0a}\x0a.oci-ferr\x20{\x0a\x20\x20\x20\x20font-size:10px;\x20color:var(--okdb-danger);\x20white-space:nowrap;\x20overflow:hidden;\x0a\x20\x20\x20\x20text-overflow:ellipsis;\x20max-width:100px;\x0a}\x0a\x0a/*\x20──\x20Presets\x20───────────────────────────────\x20*/\x0a.oci-presets-label\x20{\x0a\x20\x20\x20\x20font-size:10px;\x20color:var(--okdb-app-fg-muted);\x20text-transform:uppercase;\x20letter-spacing:.08em;\x0a\x20\x20\x20\x20padding:4px\x2014px\x202px;\x20user-select:none;\x20font-weight:600;\x0a}\x0a.oci-presets\x20{\x0a\x20\x20\x20\x20display:flex;\x20flex-wrap:wrap;\x20gap:5px;\x0a\x20\x20\x20\x20padding:4px\x2014px\x2010px;\x0a}\x0a.oci-preset\x20{\x0a\x20\x20\x20\x20background:var(--okdb-app-surface-2);\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:5px;\x0a\x20\x20\x20\x20color:#8bb4cc;\x20font-size:11px;\x20cursor:pointer;\x20padding:4px\x209px;\x0a\x20\x20\x20\x20transition:background\x20.1s,\x20border-color\x20.1s,\x20color\x20.1s;\x20white-space:nowrap;\x0a}\x0a.oci-preset:hover\x20\x20\x20\x20{\x20background:var(--okdb-app-surface-2);\x20border-color:color-mix(in\x20srgb,\x20var(--okdb-accent)\x2033%,\x20transparent);\x20color:var(--okdb-app-fg);\x20}\x0a.oci-preset--active\x20\x20{\x20background:#0e2233;\x20border-color:var(--okdb-accent);\x20color:var(--okdb-accent);\x20}\x0a\x0a/*\x20──\x20Footer\x20────────────────────────────────\x20*/\x0a.oci-footer\x20{\x0a\x20\x20\x20\x20display:flex;\x20align-items:center;\x20gap:8px;\x0a\x20\x20\x20\x20padding:8px\x2014px\x2010px;\x20border-top:1px\x20solid\x20var(--okdb-app-border);\x0a}\x0a.oci-btn-clear\x20{\x0a\x20\x20\x20\x20background:none;\x20border:none;\x20color:var(--okdb-app-fg-muted);\x20cursor:pointer;\x0a\x20\x20\x20\x20font-size:12px;\x20padding:5px\x208px;\x20border-radius:5px;\x0a\x20\x20\x20\x20transition:color\x20.1s,\x20background\x20.1s;\x0a}\x0a.oci-btn-clear:hover\x20{\x20color:var(--okdb-danger);\x20background:var(--okdb-danger-deep-bg);\x20}\x0a.oci-btn-cancel\x20{\x0a\x20\x20\x20\x20background:none;\x20border:1px\x20solid\x20var(--okdb-app-border);\x20border-radius:5px;\x0a\x20\x20\x20\x20color:var(--okdb-app-fg-muted);\x20cursor:pointer;\x20font-size:12px;\x20padding:5px\x2012px;\x0a\x20\x20\x20\x20transition:background\x20.1s,\x20color\x20.1s;\x0a}\x0a.oci-btn-cancel:hover\x20{\x20background:var(--okdb-app-surface);\x20color:var(--okdb-app-fg);\x20}\x0a.oci-btn-apply\x20{\x0a\x20\x20\x20\x20background:#1a4a6a;\x20border:1px\x20solid\x20color-mix(in\x20srgb,\x20var(--okdb-accent)\x2033%,\x20transparent);\x20border-radius:5px;\x0a\x20\x20\x20\x20color:var(--okdb-accent);\x20cursor:pointer;\x20font-size:12px;\x20font-weight:600;\x20padding:5px\x2016px;\x0a\x20\x20\x20\x20transition:background\x20.1s,\x20border-color\x20.1s;\x0a}\x0a.oci-btn-apply:hover:not(:disabled)\x20{\x20background:#1e5a80;\x20border-color:var(--okdb-accent);\x20}\x0a.oci-btn-apply:disabled\x20{\x20opacity:.4;\x20cursor:not-allowed;\x20}\x0a','Apr','Fri','filter','value\x20\x22','4624DugWvc','Once\x20a\x20week,\x20at\x20midnight\x20on\x20Sunday','type','split','\x22\x20out\x20of\x20bounds\x20','map','target','disabled','Every\x20day\x20at\x20noon','$attr','7564270ChbcOZ','charAt','Empty\x20expression','sort','padStart','max','969993fpTVjH','length','_dow','_dom','months','value','$el','addEventListener','1–12\x20\x20or\x20\x20Jan–Dec\x20\x20or\x20\x20*/3','0\x200\x20*\x20*\x200','6lVagQu','455VEZWSS','days','0–6\x20\x20(0=Sun)\x20\x20or\x20\x20Mon–Fri','May','@daily','match','Thu','@annually','Every\x2015\x20minutes','Feb','contains','dow','*/5\x20*\x20*\x20*\x20*','@yearly','querySelector','startsWith','min','Every\x20Sunday','toUpperCase','ok-cron-input','at\x20','msg','0\x2012\x20*\x20*\x20*','.oci-btn','Sun',':xx','_month','toLowerCase','minutes','join','Wed','_raw','slice','list','push','change','name','_compiled','weekday','Every\x20week\x20(Sunday\x20midnight)','Once\x20a\x20month,\x20at\x20midnight\x20on\x20the\x201st','Month','_parse','\x0a<div\x20class=\x22oci-wrap\x22>\x0a\x0a\x20\x20<!--\x20──\x20Trigger\x20───────────────────────────────────────────────────────\x20-->\x0a\x20\x20<div\x20class=\x22oci-field\x22\x20:class=\x22disabled\x20?\x20\x27oci-field--disabled\x27\x20:\x20\x27\x27\x22>\x0a\x20\x20\x20\x20<span\x20class=\x22oci-value\x22>{{\x20_currentValue\x20||\x20placeholder\x20}}</span>\x0a\x20\x20\x20\x20<button\x20class=\x22oci-btn\x22\x20@click=\x22openPanel()\x22\x20:disabled=\x22disabled\x22\x20title=\x22Configure\x20cron\x20expression\x22>\x0a\x20\x20\x20\x20\x20\x20<svg\x20width=\x2214\x22\x20height=\x2214\x22\x20viewBox=\x220\x200\x2016\x2016\x22\x20fill=\x22none\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<path\x20d=\x22M11.013\x201.427a1.75\x201.75\x200\x200\x201\x202.474\x200l1.086\x201.086a1.75\x201.75\x200\x200\x201\x200\x202.474l-8.61\x208.61c-.21.21-.47.364-.756.445l-3.251.93a.75.75\x200\x200\x201-.927-.928l.929-3.25c.081-.286.235-.547.445-.758l8.61-8.61zm1.414\x201.06a.25.25\x200\x200\x200-.354\x200L10.811\x203.75l1.439\x201.44\x201.263-1.263a.25.25\x200\x200\x200\x200-.354l-1.086-1.086zM11.189\x206.25\x209.75\x204.81\x203.23\x2011.33a.25.25\x200\x200\x200-.064.108l-.618\x202.16\x202.16-.617a.25.25\x200\x200\x200\x20.108-.065L11.19\x206.25z\x22\x20fill=\x22currentColor\x22/>\x0a\x20\x20\x20\x20\x20\x20</svg>\x0a\x20\x20\x20\x20</button>\x0a\x20\x20</div>\x0a\x0a\x20\x20<!--\x20──\x20Panel\x20──────────────────────────────────────────────────────────\x20-->\x0a\x20\x20<ok-flyover\x20:open=\x22open\x22\x20:anchor=\x22_fieldElement\x22\x20placement=\x22bottom-start\x22\x20:gap=\x224\x22\x0a\x20\x20\x20\x20style=\x22--ok-flyover-bg:var(--okdb-app-bg);\x20--ok-flyover-border:1px\x20solid\x20var(--okdb-app-border);\x20--ok-flyover-radius:10px;\x20--ok-flyover-shadow:0\x208px\x2032px\x20rgba(0,0,0,.6);\x22>\x0a\x20\x20\x20\x20<div\x20class=\x22oci-panel\x22>\x0a\x0a\x20\x20\x20\x20\x20\x20<!--\x20Header\x20-->\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-panel-head\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22oci-panel-title\x22>Cron\x20expression</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<button\x20class=\x22oci-close\x22\x20@click=\x22closePanel()\x22>✕</button>\x0a\x20\x20\x20\x20\x20\x20</div>\x0a\x0a\x20\x20\x20\x20\x20\x20<!--\x20Raw\x20input\x20+\x20description\x20-->\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-raw-row\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<input\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20class=\x22oci-raw-inp\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20type=\x22text\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20spellcheck=\x22false\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20autocomplete=\x22off\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20:value=\x22_raw\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20@input=\x22onRawInput($el.value)\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20placeholder=\x22*\x20*\x20*\x20*\x20*\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20/>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22oci-raw-hint\x22>min\x20\x20hr\x20\x20dom\x20\x20mon\x20\x20dow</span>\x0a\x20\x20\x20\x20\x20\x20</div>\x0a\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-desc\x22\x20:class=\x22_description.ok\x20?\x20\x27oci-desc--ok\x27\x20:\x20\x27oci-desc--err\x27\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<if\x20:=\x22_description.ok\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22oci-desc-icon\x22>🕒</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span>{{\x20_description.text\x20}}</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</if>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<if\x20:=\x22!_description.ok\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22oci-desc-icon\x22>⚠</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span>{{\x20_description.error\x20||\x20\x27Invalid\x20expression\x27\x20}}</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</if>\x0a\x20\x20\x20\x20\x20\x20</div>\x0a\x0a\x20\x20\x20\x20\x20\x20<!--\x20Divider\x20-->\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-divider\x22></div>\x0a\x0a\x20\x20\x20\x20\x20\x20<!--\x20Field\x20builders\x20(only\x20for\x20standard\x205-part\x20expressions)\x20-->\x0a\x20\x20\x20\x20\x20\x20<if\x20:=\x22!_isSpecial\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-fields\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<each\x20:of=\x22fields\x22\x20let:f=\x22f\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-field-row\x22\x20:class=\x22fieldError(f.key)\x20?\x20\x27oci-field-row--err\x27\x20:\x20\x27\x27\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<label\x20class=\x22oci-flabel\x22>{{\x20f.label\x20}}</label>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<input\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20class=\x22oci-finp\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20type=\x22text\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20spellcheck=\x22false\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20autocomplete=\x22off\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20:value=\x22fieldVal(f.key)\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20:placeholder=\x22f.placeholder\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20@input=\x22setField(f.key,\x20$el.value)\x22\x0a\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<if\x20:=\x22fieldError(f.key)\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22oci-ferr\x22>{{\x20fieldError(f.key)\x20}}</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</if>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<if\x20:=\x22!fieldError(f.key)\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<span\x20class=\x22oci-frange\x22>{{\x20f.min\x20}}–{{\x20f.max\x20}}</span>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</if>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</each>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-divider\x22></div>\x0a\x20\x20\x20\x20\x20\x20</if>\x0a\x0a\x20\x20\x20\x20\x20\x20<!--\x20Presets\x20-->\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-presets-label\x22>Quick\x20presets</div>\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-presets\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<each\x20:of=\x22presets\x22\x20let:p=\x22p\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<button\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20class=\x22oci-preset\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20:class=\x22isPresetActive(p.value)\x20?\x20\x27oci-preset--active\x27\x20:\x20\x27\x27\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20@click=\x22applyPreset(p.value)\x22\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20>{{\x20p.label\x20}}</button>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</each>\x0a\x20\x20\x20\x20\x20\x20</div>\x0a\x0a\x20\x20\x20\x20\x20\x20<!--\x20Footer\x20-->\x0a\x20\x20\x20\x20\x20\x20<div\x20class=\x22oci-footer\x22>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<button\x20class=\x22oci-btn-clear\x22\x20@click=\x22clear()\x22>Clear</button>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<div\x20style=\x22flex:1\x22></div>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<button\x20class=\x22oci-btn-cancel\x22\x20@click=\x22closePanel()\x22>Cancel</button>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<button\x20class=\x22oci-btn-apply\x22\x20:disabled=\x22_error\x20?\x20true\x20:\x20false\x22\x20@click=\x22apply()\x22>Apply</button>\x0a\x20\x20\x20\x20\x20\x20</div>\x0a\x0a\x20\x20\x20\x20</div>\x0a\x20\x20</ok-flyover>\x0a\x0a</div>\x0a','values','start','every\x20','Once\x20a\x20day,\x20at\x20midnight','step','every\x20minute','Every\x20Monday–Friday','includes','Every\x20year\x20(Jan\x201st)','Every\x20hour','Every\x2030\x20minutes','minute','range\x20\x22','any','Every\x20minute','Sep','_isSpecial','949488KwmsLA'];_0x5687=function(){return _0x1cd4af;};return _0x5687();}const _0x36b198=_0x2648;(function(_0x47423f,_0x57b0f1){const _0x27c718=_0x2648,_0x4bd6ae=_0x47423f();while(!![]){try{const _0x8055ee=parseInt(_0x27c718(0x134))/0x1*(-parseInt(_0x27c718(0x164))/0x2)+parseInt(_0x27c718(0x1ab))/0x3*(-parseInt(_0x27c718(0x14a))/0x4)+parseInt(_0x27c718(0x1b0))/0x5+-parseInt(_0x27c718(0x144))/0x6*(parseInt(_0x27c718(0x165))/0x7)+-parseInt(_0x27c718(0x1a2))/0x8+parseInt(_0x27c718(0x15a))/0x9+parseInt(_0x27c718(0x154))/0xa;if(_0x8055ee===_0x57b0f1)break;else _0x4bd6ae['push'](_0x4bd6ae['shift']());}catch(_0x30762d){_0x4bd6ae['push'](_0x4bd6ae['shift']());}}}(_0x5687,0x3abd4));function _0x2648(_0x59d904,_0x5053ee){_0x59d904=_0x59d904-0x131;const _0x5687ed=_0x5687();let _0x26486a=_0x5687ed[_0x59d904];return _0x26486a;}import _0x1f410f from'@toolkit/interaction/ok-flyover.ok.js';const n=['Jan',_0x36b198(0x16e),_0x36b198(0x1a4),_0x36b198(0x146),_0x36b198(0x168),'Jun','Jul','Aug',_0x36b198(0x1a0),_0x36b198(0x1b8),'Nov',_0x36b198(0x1b5)],o=[_0x36b198(0x17d),'Mon','Tue',_0x36b198(0x183),_0x36b198(0x16b),_0x36b198(0x147),_0x36b198(0x1af)];function r(_0xe6bf28,_0x491398,_0x55d573,_0xcefed0){const _0x404a5c=_0x36b198,_0x4d437c=(_0xe6bf28||'')[_0x404a5c(0x13e)]();if(!_0x4d437c||'*'===_0x4d437c)return{'type':_0x404a5c(0x19e)};const _0x6fcb24=_0x4d437c[_0x404a5c(0x16a)](/^(\*|\d+)\/(\d+)$/);if(_0x6fcb24){const _0x2d52f5=parseInt(_0x6fcb24[0x2],0xa),_0x5ab9ee='*'===_0x6fcb24[0x1]?_0x491398:parseInt(_0x6fcb24[0x1],0xa);return isNaN(_0x2d52f5)||_0x2d52f5<0x1||isNaN(_0x5ab9ee)||_0x5ab9ee<_0x491398||_0x5ab9ee>_0x55d573?{'type':_0x404a5c(0x13f),'msg':_0x404a5c(0x1aa)+_0x4d437c+'\x22'}:{'type':'step','start':_0x5ab9ee,'step':_0x2d52f5};}const _0x13dbb0=_0x4d437c['split'](','),_0x32855a=[];for(const _0x156c12 of _0x13dbb0){const _0x39dab1=_0x156c12[_0x404a5c(0x16a)](/^(\d+)-(\d+)$/);if(_0x39dab1){const _0x2f6542=parseInt(_0x39dab1[0x1],0xa),_0x45b428=parseInt(_0x39dab1[0x2],0xa);if(_0x2f6542<_0x491398||_0x45b428>_0x55d573||_0x2f6542>_0x45b428)return{'type':_0x404a5c(0x13f),'msg':_0x404a5c(0x19d)+_0x156c12+'\x22\x20out\x20of\x20bounds\x20'+_0x491398+'-'+_0x55d573};for(let _0x985bf4=_0x2f6542;_0x985bf4<=_0x45b428;_0x985bf4++)_0x32855a[_0x404a5c(0x187)](_0x985bf4);}else{const _0x29863a=parseInt(_0x156c12,0xa);if(isNaN(_0x29863a)||_0x29863a<_0x491398||_0x29863a>_0x55d573)return{'type':_0x404a5c(0x13f),'msg':_0x404a5c(0x149)+_0x156c12+_0x404a5c(0x14e)+_0x491398+'-'+_0x55d573};_0x32855a['push'](_0x29863a);}}return{'type':_0x404a5c(0x186),'values':[...new Set(_0x32855a)][_0x404a5c(0x157)]((_0x1a7d30,_0x377692)=>_0x1a7d30-_0x377692)};}function t(_0x4584e5,_0x18aa82){return _0x18aa82&&_0x18aa82[_0x4584e5]||String(_0x4584e5);}function a(_0x309923,_0x5089ce,_0x347c70,_0x3cc2bc){const _0x447994=_0x36b198;if(_0x447994(0x19e)===_0x309923[_0x447994(0x14c)])return null;if(_0x447994(0x13f)===_0x309923[_0x447994(0x14c)])return null;if(_0x447994(0x195)===_0x309923[_0x447994(0x14c)]){const _0x9d10f3=_0x309923[_0x447994(0x192)]>0x0?'\x20starting\x20at\x20'+t(_0x309923['start'],_0x3cc2bc):'';return _0x447994(0x193)+_0x309923[_0x447994(0x195)]+'\x20'+_0x347c70+_0x9d10f3;}const _0x37ca2d=_0x309923[_0x447994(0x191)];if(0x1===_0x37ca2d[_0x447994(0x15b)])return _0x447994(0x179)+_0x5089ce+'\x20'+t(_0x37ca2d[0x0],_0x3cc2bc);const _0x527158=t(_0x37ca2d[_0x37ca2d[_0x447994(0x15b)]-0x1],_0x3cc2bc);return _0x447994(0x179)+_0x347c70+'\x20'+_0x37ca2d[_0x447994(0x185)](0x0,-0x1)[_0x447994(0x14f)](_0x2a1027=>t(_0x2a1027,_0x3cc2bc))[_0x447994(0x182)](',\x20')+'\x20and\x20'+_0x527158;}function i(_0x9199a0){const _0x3ac05c=_0x36b198;if(!_0x9199a0||!_0x9199a0['trim']())return _0x3ac05c(0x156);const _0x1dddca=_0x9199a0[_0x3ac05c(0x13e)]()[_0x3ac05c(0x180)]();if([_0x3ac05c(0x172),_0x3ac05c(0x16c),'@monthly','@weekly',_0x3ac05c(0x169),_0x3ac05c(0x132),'@hourly','@reboot'][_0x3ac05c(0x198)](_0x1dddca))return null;const _0x166f1e=_0x9199a0[_0x3ac05c(0x13e)]()[_0x3ac05c(0x14d)](/\s+/);if(0x5!==_0x166f1e['length'])return _0x3ac05c(0x138)+_0x166f1e[_0x3ac05c(0x15b)];const _0x3d1e64=[{'raw':_0x166f1e[0x0],'min':0x0,'max':0x3b,'name':'minute'},{'raw':_0x166f1e[0x1],'min':0x0,'max':0x17,'name':_0x3ac05c(0x1ac)},{'raw':_0x166f1e[0x2],'min':0x1,'max':0x1f,'name':'day-of-month'},{'raw':_0x166f1e[0x3],'min':0x1,'max':0xc,'name':_0x3ac05c(0x143)},{'raw':_0x166f1e[0x4],'min':0x0,'max':0x6,'name':_0x3ac05c(0x1b7)}];for(const _0x2d7917 of _0x3d1e64){const _0x32fd93=r(_0x2d7917['raw'],_0x2d7917[_0x3ac05c(0x175)],_0x2d7917[_0x3ac05c(0x159)]);if(_0x3ac05c(0x13f)===_0x32fd93['type'])return _0x2d7917[_0x3ac05c(0x189)]+':\x20'+_0x32fd93[_0x3ac05c(0x17a)];}return null;}const s=[{'label':'Every\x20minute','value':'*\x20*\x20*\x20*\x20*'},{'label':_0x36b198(0x135),'value':_0x36b198(0x171)},{'label':_0x36b198(0x16d),'value':_0x36b198(0x1a3)},{'label':_0x36b198(0x19b),'value':_0x36b198(0x1ad)},{'label':_0x36b198(0x19a),'value':'@hourly'},{'label':_0x36b198(0x133),'value':_0x36b198(0x169)},{'label':_0x36b198(0x152),'value':_0x36b198(0x17b)},{'label':_0x36b198(0x176),'value':_0x36b198(0x163)},{'label':_0x36b198(0x197),'value':_0x36b198(0x1b1)},{'label':_0x36b198(0x18c),'value':_0x36b198(0x136)},{'label':_0x36b198(0x1a5),'value':_0x36b198(0x141)},{'label':_0x36b198(0x199),'value':_0x36b198(0x172)}],l=[{'key':'minute','label':_0x36b198(0x1b2),'min':0x0,'max':0x3b,'placeholder':_0x36b198(0x13b)},{'key':'hour','label':_0x36b198(0x140),'min':0x0,'max':0x17,'placeholder':_0x36b198(0x142)},{'key':'dom','label':_0x36b198(0x131),'min':0x1,'max':0x1f,'placeholder':_0x36b198(0x1a7)},{'key':_0x36b198(0x143),'label':_0x36b198(0x18e),'min':0x1,'max':0xc,'placeholder':_0x36b198(0x162)},{'key':_0x36b198(0x170),'label':'Day\x20of\x20week','min':0x0,'max':0x6,'placeholder':_0x36b198(0x167)}];export default{'tag':_0x36b198(0x178),'dependencies':[_0x1f410f],'attr':{'value':{},'placeholder':{},'disabled':{}},'context':_0x58a93b=>({'open':!0x1,'_raw':'','_minute':'*','_hour':'*','_dom':'*','_month':'*','_dow':'*',get '_isSpecial'(){const _0x501e2c=_0x36b198;return(this[_0x501e2c(0x184)]||'')[_0x501e2c(0x13e)]()['toLowerCase']()[_0x501e2c(0x174)]('@');},get '_compiled'(){const _0x7039fd=_0x36b198;return this[_0x7039fd(0x1a1)]?this['_raw'][_0x7039fd(0x13e)]():[this[_0x7039fd(0x13a)],this[_0x7039fd(0x137)],this['_dom'],this[_0x7039fd(0x17f)],this[_0x7039fd(0x15c)]][_0x7039fd(0x182)]('\x20');},get '_description'(){const _0x56d730=_0x36b198;return function(_0x3bb3b0){const _0x22aa1c=_0x2648;if(!_0x3bb3b0||!_0x3bb3b0['trim']())return{'ok':!0x1,'text':'','error':_0x22aa1c(0x156)};const _0x2c66fa={'@yearly':'Once\x20a\x20year,\x20at\x20midnight\x20on\x20January\x201st','@annually':'Once\x20a\x20year,\x20at\x20midnight\x20on\x20January\x201st','@monthly':_0x22aa1c(0x18d),'@weekly':_0x22aa1c(0x14b),'@daily':_0x22aa1c(0x194),'@midnight':'Once\x20a\x20day,\x20at\x20midnight','@hourly':_0x22aa1c(0x13c),'@reboot':_0x22aa1c(0x1a8)},_0x5950f7=_0x3bb3b0['trim']()['toLowerCase']();if(_0x2c66fa[_0x5950f7])return{'ok':!0x0,'text':_0x2c66fa[_0x5950f7]};const _0x2d4324=_0x3bb3b0[_0x22aa1c(0x13e)]()[_0x22aa1c(0x14d)](/\s+/);if(0x5!==_0x2d4324[_0x22aa1c(0x15b)])return{'ok':!0x1,'text':'','error':'Expected\x205\x20fields,\x20got\x20'+_0x2d4324['length']};const [_0x2d6e55,_0x544b6c,_0x2c5ae8,_0x24510d,_0xd74ab0]=_0x2d4324,_0x4240c0=r(_0x2d6e55,0x0,0x3b),_0xfe2dcb=r(_0x544b6c,0x0,0x17),_0x3d0c9a=r(_0x2c5ae8,0x1,0x1f),_0x26e4ae=r(_0x24510d,0x1,0xc),_0x5a2cfa=r(_0xd74ab0,0x0,0x6),_0x36dc20=[_0x4240c0,_0xfe2dcb,_0x3d0c9a,_0x26e4ae,_0x5a2cfa][_0x22aa1c(0x148)](_0x859687=>_0x22aa1c(0x13f)===_0x859687[_0x22aa1c(0x14c)])[_0x22aa1c(0x14f)](_0x3b53be=>_0x3b53be[_0x22aa1c(0x17a)]);if(_0x36dc20[_0x22aa1c(0x15b)])return{'ok':!0x1,'text':'','error':_0x36dc20[_0x22aa1c(0x182)](';\x20')};const _0x5006d1=[],_0x23f31a=a(_0x4240c0,_0x22aa1c(0x19c),_0x22aa1c(0x181));_0x23f31a?_0x5006d1['push'](_0x23f31a):_0x22aa1c(0x19e)===_0xfe2dcb['type']&&_0x22aa1c(0x19e)===_0x3d0c9a[_0x22aa1c(0x14c)]&&_0x22aa1c(0x19e)===_0x26e4ae[_0x22aa1c(0x14c)]&&_0x22aa1c(0x19e)===_0x5a2cfa['type']&&_0x5006d1['push'](_0x22aa1c(0x196));const _0x83e380=a(_0xfe2dcb,_0x22aa1c(0x1ac),'hours');_0x83e380&&(_0x4240c0[_0x22aa1c(0x14c)],_0x5006d1[_0x22aa1c(0x187)](_0x83e380));let _0x8977ce=null;_0x22aa1c(0x186)===_0xfe2dcb[_0x22aa1c(0x14c)]&&0x1===_0xfe2dcb[_0x22aa1c(0x191)][_0x22aa1c(0x15b)]&&_0x22aa1c(0x186)===_0x4240c0[_0x22aa1c(0x14c)]&&0x1===_0x4240c0['values'][_0x22aa1c(0x15b)]?_0x8977ce=String(_0xfe2dcb[_0x22aa1c(0x191)][0x0])[_0x22aa1c(0x158)](0x2,'0')+':'+String(_0x4240c0[_0x22aa1c(0x191)][0x0])[_0x22aa1c(0x158)](0x2,'0'):_0x22aa1c(0x186)===_0xfe2dcb[_0x22aa1c(0x14c)]&&0x1===_0xfe2dcb[_0x22aa1c(0x191)][_0x22aa1c(0x15b)]&&'any'===_0x4240c0[_0x22aa1c(0x14c)]?_0x8977ce=String(_0xfe2dcb[_0x22aa1c(0x191)][0x0])[_0x22aa1c(0x158)](0x2,'0')+_0x22aa1c(0x17e):_0x22aa1c(0x186)===_0x4240c0[_0x22aa1c(0x14c)]&&0x1===_0x4240c0['values'][_0x22aa1c(0x15b)]&&_0x22aa1c(0x19e)===_0xfe2dcb[_0x22aa1c(0x14c)]&&(_0x8977ce='xx:'+String(_0x4240c0[_0x22aa1c(0x191)][0x0])[_0x22aa1c(0x158)](0x2,'0'));const _0x29fc9f=a(_0x3d0c9a,'day',_0x22aa1c(0x166)),_0x25b473=a(_0x26e4ae,_0x22aa1c(0x143),_0x22aa1c(0x15e),n),_0x4fce91=a(_0x5a2cfa,_0x22aa1c(0x18b),_0x22aa1c(0x1b4),o);let _0x4df594='';const _0x283477=_0x22aa1c(0x195)===_0x4240c0[_0x22aa1c(0x14c)]||_0x22aa1c(0x195)===_0xfe2dcb[_0x22aa1c(0x14c)];if('any'===_0x4240c0['type']&&'any'===_0xfe2dcb['type']&&_0x22aa1c(0x19e)===_0x3d0c9a[_0x22aa1c(0x14c)]&&_0x22aa1c(0x19e)===_0x26e4ae[_0x22aa1c(0x14c)]&&_0x22aa1c(0x19e)===_0x5a2cfa['type'])_0x4df594=_0x22aa1c(0x19f);else{if(_0x283477)_0x4df594=[_0x23f31a,_0x83e380][_0x22aa1c(0x148)](Boolean)['join'](',\x20');else{if(!_0x8977ce||_0x83e380||_0x23f31a){const _0xfb5922=[];_0x23f31a&&_0xfb5922[_0x22aa1c(0x187)](_0x23f31a),_0x83e380&&_0xfb5922[_0x22aa1c(0x187)](_0x83e380),_0x23f31a||_0x83e380||!_0x8977ce||_0xfb5922[_0x22aa1c(0x187)](_0x22aa1c(0x179)+_0x8977ce),_0x4df594=_0xfb5922['join'](',\x20')||'At\x20a\x20scheduled\x20time';}else _0x4df594='At\x20'+_0x8977ce;}}const _0x3e03ac=[];return _0x29fc9f&&_0x4fce91?_0x3e03ac[_0x22aa1c(0x187)](_0x29fc9f+'\x20or\x20'+_0x4fce91):_0x29fc9f?_0x3e03ac['push'](_0x29fc9f):_0x4fce91&&_0x3e03ac[_0x22aa1c(0x187)](_0x4fce91),_0x25b473&&_0x3e03ac[_0x22aa1c(0x187)](_0x25b473),_0x3e03ac[_0x22aa1c(0x15b)]&&(_0x4df594+=',\x20'+_0x3e03ac['join'](',\x20')),{'ok':!0x0,'text':_0x4df594[_0x22aa1c(0x155)](0x0)[_0x22aa1c(0x177)]()+_0x4df594[_0x22aa1c(0x185)](0x1)};}(this[_0x56d730(0x18a)]);},get '_error'(){const _0x1546a2=_0x36b198;return i(this[_0x1546a2(0x18a)]);},get '_currentValue'(){const _0x3c18df=_0x36b198;return''+(_0x58a93b[_0x3c18df(0x153)][_0x3c18df(0x15f)]||'');},get 'disabled'(){const _0x50d7d7=_0x36b198,_0x460048=_0x58a93b[_0x50d7d7(0x153)][_0x50d7d7(0x151)];return!0x0===_0x460048||_0x50d7d7(0x1a9)===_0x460048||''===_0x460048;},get 'placeholder'(){const _0x3438c2=_0x36b198;return _0x58a93b[_0x3438c2(0x153)][_0x3438c2(0x1a6)]||_0x3438c2(0x1b3);},get '_fieldElement'(){const _0x14e2cf=_0x36b198;return _0x58a93b[_0x14e2cf(0x160)]&&_0x58a93b[_0x14e2cf(0x160)][_0x14e2cf(0x173)]('.oci-field');},'presets':s,'fields':l,'_parse'(_0x28169f){const _0x4eced8=_0x36b198,_0x463511=(_0x28169f||'')[_0x4eced8(0x13e)]();if(this[_0x4eced8(0x184)]=_0x463511,!_0x463511||_0x463511[_0x4eced8(0x174)]('@'))return;const _0x1d43b3=_0x463511[_0x4eced8(0x14d)](/\s+/);this[_0x4eced8(0x13a)]=_0x1d43b3[0x0]||'*',this['_hour']=_0x1d43b3[0x1]||'*',this[_0x4eced8(0x15d)]=_0x1d43b3[0x2]||'*',this[_0x4eced8(0x17f)]=_0x1d43b3[0x3]||'*',this[_0x4eced8(0x15c)]=_0x1d43b3[0x4]||'*';},'_syncRaw'(){const _0x492cc9=_0x36b198;this[_0x492cc9(0x1a1)]||(this['_raw']=this[_0x492cc9(0x18a)]);},'setField'(_0x2c6e99,_0x56a0fd){const _0x412547=_0x36b198,_0x211abb=(_0x56a0fd||'')[_0x412547(0x13e)]()||'*';_0x412547(0x19c)===_0x2c6e99&&(this[_0x412547(0x13a)]=_0x211abb),_0x412547(0x1ac)===_0x2c6e99&&(this['_hour']=_0x211abb),_0x412547(0x139)===_0x2c6e99&&(this['_dom']=_0x211abb),_0x412547(0x143)===_0x2c6e99&&(this[_0x412547(0x17f)]=_0x211abb),_0x412547(0x170)===_0x2c6e99&&(this[_0x412547(0x15c)]=_0x211abb),this[_0x412547(0x184)]=this['_compiled'];},'fieldVal'(_0x2f8a4b){const _0x274e04=_0x36b198;return _0x274e04(0x19c)===_0x2f8a4b?this[_0x274e04(0x13a)]:_0x274e04(0x1ac)===_0x2f8a4b?this[_0x274e04(0x137)]:_0x274e04(0x139)===_0x2f8a4b?this[_0x274e04(0x15d)]:_0x274e04(0x143)===_0x2f8a4b?this[_0x274e04(0x17f)]:_0x274e04(0x170)===_0x2f8a4b?this[_0x274e04(0x15c)]:'*';},'fieldError'(_0x1f8295){const _0x280e6f=_0x36b198;let _0x4242d4,_0x57f35f,_0x193116;if(_0x280e6f(0x19c)===_0x1f8295&&(_0x4242d4=this[_0x280e6f(0x13a)],_0x57f35f=0x0,_0x193116=0x3b),_0x280e6f(0x1ac)===_0x1f8295&&(_0x4242d4=this[_0x280e6f(0x137)],_0x57f35f=0x0,_0x193116=0x17),_0x280e6f(0x139)===_0x1f8295&&(_0x4242d4=this[_0x280e6f(0x15d)],_0x57f35f=0x1,_0x193116=0x1f),_0x280e6f(0x143)===_0x1f8295&&(_0x4242d4=this[_0x280e6f(0x17f)],_0x57f35f=0x1,_0x193116=0xc),_0x280e6f(0x170)===_0x1f8295&&(_0x4242d4=this[_0x280e6f(0x15c)],_0x57f35f=0x0,_0x193116=0x6),!_0x4242d4||'*'===_0x4242d4)return null;const _0x23b994=r(_0x4242d4,_0x57f35f,_0x193116);return _0x280e6f(0x13f)===_0x23b994[_0x280e6f(0x14c)]?_0x23b994[_0x280e6f(0x17a)]:null;},'onRawInput'(_0x447260){const _0x519527=_0x36b198;if(this[_0x519527(0x184)]=_0x447260,!_0x447260[_0x519527(0x174)]('@')){const _0x589f12=_0x447260['trim']()[_0x519527(0x14d)](/\s+/);_0x589f12[_0x519527(0x15b)]>=0x1&&(this['_minute']=_0x589f12[0x0]||'*'),_0x589f12[_0x519527(0x15b)]>=0x2&&(this[_0x519527(0x137)]=_0x589f12[0x1]||'*'),_0x589f12['length']>=0x3&&(this[_0x519527(0x15d)]=_0x589f12[0x2]||'*'),_0x589f12[_0x519527(0x15b)]>=0x4&&(this['_month']=_0x589f12[0x3]||'*'),_0x589f12[_0x519527(0x15b)]>=0x5&&(this[_0x519527(0x15c)]=_0x589f12[0x4]||'*');}},'applyPreset'(_0x12af81){const _0x119746=_0x36b198;this[_0x119746(0x18f)](_0x12af81),this[_0x119746(0x184)]=_0x12af81;},'isPresetActive'(_0x50053d){const _0x491636=_0x36b198;return this[_0x491636(0x18a)]===_0x50053d||this[_0x491636(0x184)][_0x491636(0x13e)]()===_0x50053d;},'openPanel'(){const _0x2ed3df=_0x36b198;if(this[_0x2ed3df(0x151)])return;const _0x582380=this['_currentValue'];this[_0x2ed3df(0x18f)](_0x582380||_0x2ed3df(0x1b3)),_0x582380||(this[_0x2ed3df(0x184)]=''),this['open']=!0x0,setTimeout(()=>{const _0xc5e64f=_0x2ed3df,_0x30577d=_0x319b6e=>{const _0x47f172=_0x2648,_0x161273=_0x58a93b[_0x47f172(0x160)]&&_0x58a93b[_0x47f172(0x160)][_0x47f172(0x173)](_0x47f172(0x1b6)),_0x11948a=_0x58a93b[_0x47f172(0x160)]&&_0x58a93b[_0x47f172(0x160)][_0x47f172(0x173)](_0x47f172(0x17c));_0x161273&&(_0x161273['contains'](_0x319b6e[_0x47f172(0x150)])||_0x319b6e[_0x47f172(0x150)]===_0x11948a||_0x11948a[_0x47f172(0x16f)](_0x319b6e[_0x47f172(0x150)])||(this[_0x47f172(0x13d)]=!0x1,document['removeEventListener']('mousedown',_0x30577d)));};document[_0xc5e64f(0x161)](_0xc5e64f(0x1ae),_0x30577d);},0x0);},'closePanel'(){this['open']=!0x1;},'apply'(){const _0xf0245d=_0x36b198,_0x5ef865=this[_0xf0245d(0x18a)];i(_0x5ef865)||(_0x58a93b[_0xf0245d(0x160)]&&_0x58a93b[_0xf0245d(0x160)]['dispatchEvent'](new CustomEvent(_0xf0245d(0x188),{'detail':_0x5ef865,'bubbles':!0x0})),this[_0xf0245d(0x13d)]=!0x1);},'clear'(){const _0x54d40e=_0x36b198;_0x58a93b['$el']&&_0x58a93b[_0x54d40e(0x160)]['dispatchEvent'](new CustomEvent('change',{'detail':'','bubbles':!0x0})),this[_0x54d40e(0x13d)]=!0x1;}}),'template':_0x36b198(0x190),'style':_0x36b198(0x145)};
1
+ import e from"@toolkit/interaction/ok-flyover.ok.js";const n=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],o=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"];function r(e,n,o,r){const t=(e||"").trim();if(!t||"*"===t)return{type:"any"};const a=t.match(/^(\*|\d+)\/(\d+)$/);if(a){const e=parseInt(a[2],10),r="*"===a[1]?n:parseInt(a[1],10);return isNaN(e)||e<1||isNaN(r)||r<n||r>o?{type:"error",msg:`invalid step "${t}"`}:{type:"step",start:r,step:e}}const i=t.split(","),s=[];for(const e of i){const r=e.match(/^(\d+)-(\d+)$/);if(r){const t=parseInt(r[1],10),a=parseInt(r[2],10);if(t<n||a>o||t>a)return{type:"error",msg:`range "${e}" out of bounds ${n}-${o}`};for(let e=t;e<=a;e++)s.push(e)}else{const r=parseInt(e,10);if(isNaN(r)||r<n||r>o)return{type:"error",msg:`value "${e}" out of bounds ${n}-${o}`};s.push(r)}}return{type:"list",values:[...new Set(s)].sort((e,n)=>e-n)}}function t(e,n){return n&&n[e]||String(e)}function a(e,n,o,r){if("any"===e.type)return null;if("error"===e.type)return null;if("step"===e.type){const n=e.start>0?` starting at ${t(e.start,r)}`:"";return`every ${e.step} ${o}${n}`}const a=e.values;if(1===a.length)return`at ${n} ${t(a[0],r)}`;const i=t(a[a.length-1],r);return`at ${o} ${a.slice(0,-1).map(e=>t(e,r)).join(", ")} and ${i}`}function i(e){if(!e||!e.trim())return"Empty expression";const n=e.trim().toLowerCase();if(["@yearly","@annually","@monthly","@weekly","@daily","@midnight","@hourly","@reboot"].includes(n))return null;const o=e.trim().split(/\s+/);if(5!==o.length)return`Expected 5 fields, got ${o.length}`;const t=[{raw:o[0],min:0,max:59,name:"minute"},{raw:o[1],min:0,max:23,name:"hour"},{raw:o[2],min:1,max:31,name:"day-of-month"},{raw:o[3],min:1,max:12,name:"month"},{raw:o[4],min:0,max:6,name:"day-of-week"}];for(const e of t){const n=r(e.raw,e.min,e.max);if("error"===n.type)return`${e.name}: ${n.msg}`}return null}const s=[{label:"Every minute",value:"* * * * *"},{label:"Every 5 minutes",value:"*/5 * * * *"},{label:"Every 15 minutes",value:"*/15 * * * *"},{label:"Every 30 minutes",value:"*/30 * * * *"},{label:"Every hour",value:"@hourly"},{label:"Every day (midnight)",value:"@daily"},{label:"Every day at noon",value:"0 12 * * *"},{label:"Every Sunday",value:"0 0 * * 0"},{label:"Every Monday–Friday",value:"0 9 * * 1-5"},{label:"Every week (Sunday midnight)",value:"@weekly"},{label:"Every month (1st midnight)",value:"@monthly"},{label:"Every year (Jan 1st)",value:"@yearly"}],l=[{key:"minute",label:"Minute",min:0,max:59,placeholder:"0–59 or */5 or 0,30"},{key:"hour",label:"Hour",min:0,max:23,placeholder:"0–23 or */2 or 8,17"},{key:"dom",label:"Day of month",min:1,max:31,placeholder:"1–31 or */5 or 1,15"},{key:"month",label:"Month",min:1,max:12,placeholder:"1–12 or Jan–Dec or */3"},{key:"dow",label:"Day of week",min:0,max:6,placeholder:"0–6 (0=Sun) or Mon–Fri"}];export default{tag:"ok-cron-input",dependencies:[e],attr:{value:{},placeholder:{},disabled:{}},context:e=>({open:!1,_raw:"",_minute:"*",_hour:"*",_dom:"*",_month:"*",_dow:"*",get _isSpecial(){return(this._raw||"").trim().toLowerCase().startsWith("@")},get _compiled(){return this._isSpecial?this._raw.trim():[this._minute,this._hour,this._dom,this._month,this._dow].join(" ")},get _description(){return function(e){if(!e||!e.trim())return{ok:!1,text:"",error:"Empty expression"};const t={"@yearly":"Once a year, at midnight on January 1st","@annually":"Once a year, at midnight on January 1st","@monthly":"Once a month, at midnight on the 1st","@weekly":"Once a week, at midnight on Sunday","@daily":"Once a day, at midnight","@midnight":"Once a day, at midnight","@hourly":"Once an hour, at the start of the hour","@reboot":"Once at startup / reboot"},i=e.trim().toLowerCase();if(t[i])return{ok:!0,text:t[i]};const s=e.trim().split(/\s+/);if(5!==s.length)return{ok:!1,text:"",error:`Expected 5 fields, got ${s.length}`};const[l,d,p,c,u]=s,b=r(l,0,59),h=r(d,0,23),f=r(p,1,31),m=r(c,1,12),g=r(u,0,6),x=[b,h,f,m,g].filter(e=>"error"===e.type).map(e=>e.msg);if(x.length)return{ok:!1,text:"",error:x.join("; ")};const v=[],y=a(b,"minute","minutes");y?v.push(y):"any"===h.type&&"any"===f.type&&"any"===m.type&&"any"===g.type&&v.push("every minute");const k=a(h,"hour","hours");k&&(b.type,v.push(k));let w=null;"list"===h.type&&1===h.values.length&&"list"===b.type&&1===b.values.length?w=`${String(h.values[0]).padStart(2,"0")}:${String(b.values[0]).padStart(2,"0")}`:"list"===h.type&&1===h.values.length&&"any"===b.type?w=`${String(h.values[0]).padStart(2,"0")}:xx`:"list"===b.type&&1===b.values.length&&"any"===h.type&&(w=`xx:${String(b.values[0]).padStart(2,"0")}`);const _=a(f,"day","days"),$=a(m,"month","months",n),E=a(g,"weekday","weekdays",o);let S="";const z="step"===b.type||"step"===h.type;if("any"===b.type&&"any"===h.type&&"any"===f.type&&"any"===m.type&&"any"===g.type)S="Every minute";else if(z)S=[y,k].filter(Boolean).join(", ");else if(!w||k||y){const e=[];y&&e.push(y),k&&e.push(k),y||k||!w||e.push(`at ${w}`),S=e.join(", ")||"At a scheduled time"}else S=`At ${w}`;const C=[];return _&&E?C.push(_+" or "+E):_?C.push(_):E&&C.push(E),$&&C.push($),C.length&&(S+=", "+C.join(", ")),{ok:!0,text:S.charAt(0).toUpperCase()+S.slice(1)}}(this._compiled)},get _error(){return i(this._compiled)},get _currentValue(){return""+(e.$attr.value||"")},get disabled(){const n=e.$attr.disabled;return!0===n||"true"===n||""===n},get placeholder(){return e.$attr.placeholder||"* * * * *"},get _fieldElement(){return e.$el&&e.$el.querySelector(".oci-field")},presets:s,fields:l,_parse(e){const n=(e||"").trim();if(this._raw=n,!n||n.startsWith("@"))return;const o=n.split(/\s+/);this._minute=o[0]||"*",this._hour=o[1]||"*",this._dom=o[2]||"*",this._month=o[3]||"*",this._dow=o[4]||"*"},_syncRaw(){this._isSpecial||(this._raw=this._compiled)},setField(e,n){const o=(n||"").trim()||"*";"minute"===e&&(this._minute=o),"hour"===e&&(this._hour=o),"dom"===e&&(this._dom=o),"month"===e&&(this._month=o),"dow"===e&&(this._dow=o),this._raw=this._compiled},fieldVal(e){return"minute"===e?this._minute:"hour"===e?this._hour:"dom"===e?this._dom:"month"===e?this._month:"dow"===e?this._dow:"*"},fieldError(e){let n,o,t;if("minute"===e&&(n=this._minute,o=0,t=59),"hour"===e&&(n=this._hour,o=0,t=23),"dom"===e&&(n=this._dom,o=1,t=31),"month"===e&&(n=this._month,o=1,t=12),"dow"===e&&(n=this._dow,o=0,t=6),!n||"*"===n)return null;const a=r(n,o,t);return"error"===a.type?a.msg:null},onRawInput(e){if(this._raw=e,!e.startsWith("@")){const n=e.trim().split(/\s+/);n.length>=1&&(this._minute=n[0]||"*"),n.length>=2&&(this._hour=n[1]||"*"),n.length>=3&&(this._dom=n[2]||"*"),n.length>=4&&(this._month=n[3]||"*"),n.length>=5&&(this._dow=n[4]||"*")}},applyPreset(e){this._parse(e),this._raw=e},isPresetActive(e){return this._compiled===e||this._raw.trim()===e},openPanel(){if(this.disabled)return;const n=this._currentValue;this._parse(n||"* * * * *"),n||(this._raw=""),this.open=!0,setTimeout(()=>{const n=o=>{const r=e.$el&&e.$el.querySelector(".oci-panel"),t=e.$el&&e.$el.querySelector(".oci-btn");r&&(r.contains(o.target)||o.target===t||t.contains(o.target)||(this.open=!1,document.removeEventListener("mousedown",n)))};document.addEventListener("mousedown",n)},0)},closePanel(){this.open=!1},apply(){const n=this._compiled;i(n)||(e.$el&&e.$el.dispatchEvent(new CustomEvent("change",{detail:n,bubbles:!0})),this.open=!1)},clear(){e.$el&&e.$el.dispatchEvent(new CustomEvent("change",{detail:"",bubbles:!0})),this.open=!1}}),template:'\n<div class="oci-wrap">\n\n \x3c!-- ── Trigger ─────────────────────────────────────────────────────── --\x3e\n <div class="oci-field" :class="disabled ? \'oci-field--disabled\' : \'\'">\n <span class="oci-value">{{ _currentValue || placeholder }}</span>\n <button class="oci-btn" @click="openPanel()" :disabled="disabled" title="Configure cron expression">\n <svg width="14" height="14" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">\n <path d="M11.013 1.427a1.75 1.75 0 0 1 2.474 0l1.086 1.086a1.75 1.75 0 0 1 0 2.474l-8.61 8.61c-.21.21-.47.364-.756.445l-3.251.93a.75.75 0 0 1-.927-.928l.929-3.25c.081-.286.235-.547.445-.758l8.61-8.61zm1.414 1.06a.25.25 0 0 0-.354 0L10.811 3.75l1.439 1.44 1.263-1.263a.25.25 0 0 0 0-.354l-1.086-1.086zM11.189 6.25 9.75 4.81 3.23 11.33a.25.25 0 0 0-.064.108l-.618 2.16 2.16-.617a.25.25 0 0 0 .108-.065L11.19 6.25z" fill="currentColor"/>\n </svg>\n </button>\n </div>\n\n \x3c!-- ── Panel ────────────────────────────────────────────────────────── --\x3e\n <ok-flyover :open="open" :anchor="_fieldElement" placement="bottom-start" :gap="4"\n style="--ok-flyover-bg:var(--okdb-app-bg); --ok-flyover-border:1px solid var(--okdb-app-border); --ok-flyover-radius:10px; --ok-flyover-shadow:0 8px 32px rgba(0,0,0,.6);">\n <div class="oci-panel">\n\n \x3c!-- Header --\x3e\n <div class="oci-panel-head">\n <span class="oci-panel-title">Cron expression</span>\n <button class="oci-close" @click="closePanel()">✕</button>\n </div>\n\n \x3c!-- Raw input + description --\x3e\n <div class="oci-raw-row">\n <input\n class="oci-raw-inp"\n type="text"\n spellcheck="false"\n autocomplete="off"\n :value="_raw"\n @input="onRawInput($el.value)"\n placeholder="* * * * *"\n />\n <span class="oci-raw-hint">min hr dom mon dow</span>\n </div>\n\n <div class="oci-desc" :class="_description.ok ? \'oci-desc--ok\' : \'oci-desc--err\'">\n <if :="_description.ok">\n <span class="oci-desc-icon">🕒</span>\n <span>{{ _description.text }}</span>\n </if>\n <if :="!_description.ok">\n <span class="oci-desc-icon">⚠</span>\n <span>{{ _description.error || \'Invalid expression\' }}</span>\n </if>\n </div>\n\n \x3c!-- Divider --\x3e\n <div class="oci-divider"></div>\n\n \x3c!-- Field builders (only for standard 5-part expressions) --\x3e\n <if :="!_isSpecial">\n <div class="oci-fields">\n <each :of="fields" let:f="f">\n <div class="oci-field-row" :class="fieldError(f.key) ? \'oci-field-row--err\' : \'\'">\n <label class="oci-flabel">{{ f.label }}</label>\n <input\n class="oci-finp"\n type="text"\n spellcheck="false"\n autocomplete="off"\n :value="fieldVal(f.key)"\n :placeholder="f.placeholder"\n @input="setField(f.key, $el.value)"\n />\n <if :="fieldError(f.key)">\n <span class="oci-ferr">{{ fieldError(f.key) }}</span>\n </if>\n <if :="!fieldError(f.key)">\n <span class="oci-frange">{{ f.min }}–{{ f.max }}</span>\n </if>\n </div>\n </each>\n </div>\n <div class="oci-divider"></div>\n </if>\n\n \x3c!-- Presets --\x3e\n <div class="oci-presets-label">Quick presets</div>\n <div class="oci-presets">\n <each :of="presets" let:p="p">\n <button\n class="oci-preset"\n :class="isPresetActive(p.value) ? \'oci-preset--active\' : \'\'"\n @click="applyPreset(p.value)"\n >{{ p.label }}</button>\n </each>\n </div>\n\n \x3c!-- Footer --\x3e\n <div class="oci-footer">\n <button class="oci-btn-clear" @click="clear()">Clear</button>\n <div style="flex:1"></div>\n <button class="oci-btn-cancel" @click="closePanel()">Cancel</button>\n <button class="oci-btn-apply" :disabled="_error ? true : false" @click="apply()">Apply</button>\n </div>\n\n </div>\n </ok-flyover>\n\n</div>\n',style:"\nok-cron-input { display:block; position:relative; }\n\n/* ── Trigger ─────────────────────────────── */\n.oci-wrap { display:inline-flex; align-items:center; width:100%; }\n\n.oci-field {\n display:flex; align-items:center; gap:0;\n background:var(--okdb-app-surface-2); border:1px solid var(--okdb-app-border); border-radius:7px;\n padding:6px 0 6px 10px; width:100%; box-sizing:border-box;\n transition:border-color .15s, background .12s;\n height:31px;\n}\n.oci-field:focus-within { border-color:color-mix(in srgb, var(--okdb-accent) 53%, transparent); background:var(--okdb-app-surface-2); }\n.oci-field:hover { background:var(--okdb-app-surface-2); border-color:var(--okdb-app-border-strong); }\n.oci-field--disabled { opacity:.45; pointer-events:none; }\n\n.oci-value {\n flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap;\n font-family:inherit;\n font-size:13px; color:#c8d4de; padding:0 4px 0 0;\n user-select:none;\n}\n.oci-value:empty::before { content: attr(data-ph); opacity:.4; }\n\n.oci-btn {\n flex-shrink:0; background:none; border:none; border-left:1px solid var(--okdb-app-border);\n color:var(--okdb-app-fg-muted); cursor:pointer; padding:0 10px; display:flex; align-items:center; justify-content:center;\n height:19px; transition:background .1s, color .1s;\n}\n.oci-btn:hover { color:var(--okdb-accent); }\n.oci-btn:disabled { opacity:.4; cursor:not-allowed; }\n\n/* ── Panel ───────────────────────────────── */\n.oci-panel {\n background:var(--okdb-app-bg); border:1px solid var(--okdb-app-border); border-radius:10px;\n box-shadow:0 16px 48px #00000099; overflow:hidden;\n display:flex; flex-direction:column;\n animation:oci-fadein .12s ease;\n}\n@keyframes oci-fadein { from { opacity:0; transform:translateY(-4px); } to { opacity:1; transform:translateY(0); } }\n\n.oci-panel-head {\n display:flex; align-items:center; padding:10px 14px 8px;\n border-bottom:1px solid var(--okdb-app-border);\n}\n.oci-panel-title { font-size:13px; font-weight:600; color:var(--okdb-app-fg); flex:1; }\n.oci-close {\n background:none; border:none; color:var(--okdb-app-fg-muted); cursor:pointer;\n font-size:14px; padding:2px 4px; border-radius:4px; line-height:1;\n transition:color .1s, background .1s;\n}\n.oci-close:hover { color:var(--okdb-app-fg-strong); background:var(--okdb-app-surface); }\n\n/* ── Raw input ───────────────────────────── */\n.oci-raw-row {\n padding:10px 14px 4px; display:flex; flex-direction:column; gap:3px;\n}\n.oci-raw-inp {\n background:var(--okdb-app-bg-deep); border:1px solid var(--okdb-app-border); border-radius:6px;\n padding:7px 10px; color:var(--okdb-app-fg-strong); font-family:ui-monospace,'Cascadia Code','Fira Code',monospace;\n font-size:14px; letter-spacing:.05em; outline:none; width:100%; box-sizing:border-box;\n transition:border-color .12s;\n}\n.oci-raw-inp:focus { border-color:color-mix(in srgb, var(--okdb-accent) 53%, transparent); }\n.oci-raw-hint {\n font-size:10px; color:var(--okdb-app-fg-muted); text-align:center;\n font-family:ui-monospace,'Cascadia Code',monospace; letter-spacing:.18em;\n user-select:none; padding:0 10px;\n}\n\n/* ── Description bar ─────────────────────── */\n.oci-desc {\n display:flex; align-items:flex-start; gap:6px;\n margin:6px 14px 8px; padding:7px 10px; border-radius:6px;\n font-size:12px; line-height:1.4;\n}\n.oci-desc--ok { background:#0e2a1a; color:var(--okdb-success); border:1px solid #166534; }\n.oci-desc--err { background:var(--okdb-danger-deep-bg); color:var(--okdb-danger); border:1px solid var(--okdb-danger-deep-border); }\n.oci-desc-icon { flex-shrink:0; }\n\n/* ── Divider ─────────────────────────────── */\n.oci-divider { border-top:1px solid var(--okdb-app-border); margin:4px 0; }\n\n/* ── Field rows ──────────────────────────── */\n.oci-fields {\n padding:6px 14px 4px; display:flex; flex-direction:column; gap:5px;\n}\n.oci-field-row {\n display:grid; grid-template-columns:100px 1fr auto;\n align-items:center; gap:8px;\n}\n.oci-flabel {\n font-size:11px; color:var(--okdb-app-fg-muted); font-weight:500; text-align:right;\n padding-right:4px; user-select:none;\n}\n.oci-finp {\n background:var(--okdb-app-bg-deep); border:1px solid var(--okdb-app-border); border-radius:5px;\n padding:4px 8px; color:var(--okdb-app-fg);\n font-family:ui-monospace,'Cascadia Code','Fira Code',monospace;\n font-size:12px; outline:none; width:100%; box-sizing:border-box;\n transition:border-color .12s;\n}\n.oci-finp:focus { border-color:color-mix(in srgb, var(--okdb-accent) 53%, transparent); }\n.oci-field-row--err .oci-finp { border-color:color-mix(in srgb, var(--okdb-danger) 53%, transparent); }\n.oci-frange {\n font-size:10px; color:var(--okdb-app-fg-muted); white-space:nowrap;\n font-family:ui-monospace,monospace;\n}\n.oci-ferr {\n font-size:10px; color:var(--okdb-danger); white-space:nowrap; overflow:hidden;\n text-overflow:ellipsis; max-width:100px;\n}\n\n/* ── Presets ─────────────────────────────── */\n.oci-presets-label {\n font-size:10px; color:var(--okdb-app-fg-muted); text-transform:uppercase; letter-spacing:.08em;\n padding:4px 14px 2px; user-select:none; font-weight:600;\n}\n.oci-presets {\n display:flex; flex-wrap:wrap; gap:5px;\n padding:4px 14px 10px;\n}\n.oci-preset {\n background:var(--okdb-app-surface-2); border:1px solid var(--okdb-app-border); border-radius:5px;\n color:#8bb4cc; font-size:11px; cursor:pointer; padding:4px 9px;\n transition:background .1s, border-color .1s, color .1s; white-space:nowrap;\n}\n.oci-preset:hover { background:var(--okdb-app-surface-2); border-color:color-mix(in srgb, var(--okdb-accent) 33%, transparent); color:var(--okdb-app-fg); }\n.oci-preset--active { background:#0e2233; border-color:var(--okdb-accent); color:var(--okdb-accent); }\n\n/* ── Footer ──────────────────────────────── */\n.oci-footer {\n display:flex; align-items:center; gap:8px;\n padding:8px 14px 10px; border-top:1px solid var(--okdb-app-border);\n}\n.oci-btn-clear {\n background:none; border:none; color:var(--okdb-app-fg-muted); cursor:pointer;\n font-size:12px; padding:5px 8px; border-radius:5px;\n transition:color .1s, background .1s;\n}\n.oci-btn-clear:hover { color:var(--okdb-danger); background:var(--okdb-danger-deep-bg); }\n.oci-btn-cancel {\n background:none; border:1px solid var(--okdb-app-border); border-radius:5px;\n color:var(--okdb-app-fg-muted); cursor:pointer; font-size:12px; padding:5px 12px;\n transition:background .1s, color .1s;\n}\n.oci-btn-cancel:hover { background:var(--okdb-app-surface); color:var(--okdb-app-fg); }\n.oci-btn-apply {\n background:#1a4a6a; border:1px solid color-mix(in srgb, var(--okdb-accent) 33%, transparent); border-radius:5px;\n color:var(--okdb-accent); cursor:pointer; font-size:12px; font-weight:600; padding:5px 16px;\n transition:background .1s, border-color .1s;\n}\n.oci-btn-apply:hover:not(:disabled) { background:#1e5a80; border-color:var(--okdb-accent); }\n.oci-btn-apply:disabled { opacity:.4; cursor:not-allowed; }\n"};
@@ -1 +1 @@
1
- function _0x1b35(){const _0x41c640=['dispatchEvent','11oVzQon','relativePath','20zfATUL','ok-dropzone','4377648egHCaj','name','files-drop','7LSYuxC','10PlFDON','contains','357165MqRInT','classList','isDirectory','preventDefault','relatedTarget','items','over','\x0a<div\x20@dragover=\x22dragover($event)\x22\x20@dragleave=\x22dragleave($event)\x22\x20@drop=\x22drop($event)\x22>\x0a\x20\x20<slot\x20/>\x0a</div>','$el','length','webkitGetAsEntry','defineProperty','createReader','push','862317KTpjzW','1111380zTdnkO','file','2yQbOrO','8150337TcSeaS','dataTransfer','1606760VObXUe','2946600DDGSFt','\x0a[tag]\x20{\x0a\x20\x20\x20\x20display:\x20block;\x0a\x20\x20\x20\x20position:\x20relative;\x0a}\x0a[tag].over::after\x20{\x0a\x20\x20\x20\x20content:\x20\x22📁\x20Drop\x20to\x20upload\x22;\x0a\x20\x20\x20\x20position:\x20absolute;\x0a\x20\x20\x20\x20inset:\x200;\x0a\x20\x20\x20\x20background:\x20rgba(0,\x20170,\x20255,\x200.08);\x0a\x20\x20\x20\x20border:\x202px\x20dashed\x20#0af;\x0a\x20\x20\x20\x20color:\x20#0af;\x0a\x20\x20\x20\x20font-size:\x201.1em;\x0a\x20\x20\x20\x20font-family:\x20sans-serif;\x0a\x20\x20\x20\x20display:\x20flex;\x0a\x20\x20\x20\x20align-items:\x20center;\x0a\x20\x20\x20\x20justify-content:\x20center;\x0a\x20\x20\x20\x20pointer-events:\x20none;\x0a\x20\x20\x20\x20z-index:\x2010;\x0a\x20\x20\x20\x20border-radius:\x208px;\x0a}\x0a','remove'];_0x1b35=function(){return _0x41c640;};return _0x1b35();}const _0x997603=_0xb982;(function(_0xbcf033,_0x154c4c){const _0x42df8e=_0xb982,_0x415c7d=_0xbcf033();while(!![]){try{const _0x5950cb=parseInt(_0x42df8e(0x18a))/0x1*(parseInt(_0x42df8e(0x16a))/0x2)+parseInt(_0x42df8e(0x17c))/0x3*(-parseInt(_0x42df8e(0x174))/0x4)+parseInt(_0x42df8e(0x16d))/0x5+parseInt(_0x42df8e(0x168))/0x6*(-parseInt(_0x42df8e(0x179))/0x7)+-parseInt(_0x42df8e(0x176))/0x8+-parseInt(_0x42df8e(0x16b))/0x9*(-parseInt(_0x42df8e(0x17a))/0xa)+parseInt(_0x42df8e(0x172))/0xb*(-parseInt(_0x42df8e(0x16e))/0xc);if(_0x5950cb===_0x154c4c)break;else _0x415c7d['push'](_0x415c7d['shift']());}catch(_0xa1119){_0x415c7d['push'](_0x415c7d['shift']());}}}(_0x1b35,0x7dfa1));function _0xb982(_0x18a37a,_0x38934a){_0x18a37a=_0x18a37a-0x168;const _0x1b357a=_0x1b35();let _0xb98292=_0x1b357a[_0x18a37a];return _0xb98292;}export default{'tag':_0x997603(0x175),'context':_0x509ae6=>({'over':!0x1,'dragover'(_0x2cce1a){const _0x201b35=_0x997603;_0x2cce1a[_0x201b35(0x17f)](),_0x509ae6[_0x201b35(0x182)]=!0x0,_0x509ae6[_0x201b35(0x184)][_0x201b35(0x17d)]['add'](_0x201b35(0x182));},'dragleave'(_0x18f777){const _0x3af65a=_0x997603;_0x509ae6[_0x3af65a(0x184)][_0x3af65a(0x17b)](_0x18f777[_0x3af65a(0x180)])||(_0x509ae6[_0x3af65a(0x182)]=!0x1,_0x509ae6['$el'][_0x3af65a(0x17d)]['remove'](_0x3af65a(0x182)));},async 'drop'(_0x49688f){const _0x455bc6=_0x997603;_0x49688f[_0x455bc6(0x17f)](),_0x509ae6['over']=!0x1,_0x509ae6['$el'][_0x455bc6(0x17d)][_0x455bc6(0x170)]('over');const _0x5e0cef=_0x49688f[_0x455bc6(0x16c)][_0x455bc6(0x181)],_0x54181d=[],_0xebccba=[];async function _0x401514(_0x452cc2,_0x11a835=''){const _0x43f5ca=_0x455bc6;if(_0x452cc2['isFile'])await new Promise(_0x16f45c=>{const _0x1ef365=_0xb982;_0x452cc2[_0x1ef365(0x169)](_0x405bda=>{const _0x566e29=_0x1ef365;Object[_0x566e29(0x187)](_0x405bda,_0x566e29(0x173),{'value':_0x11a835+_0x405bda[_0x566e29(0x177)],'writable':!0x0,'configurable':!0x0}),_0x54181d[_0x566e29(0x189)](_0x405bda),_0x16f45c();});});else{if(_0x452cc2[_0x43f5ca(0x17e)]){const _0x282471=_0x11a835+_0x452cc2[_0x43f5ca(0x177)]+'/';_0xebccba[_0x43f5ca(0x189)](_0x282471);const _0x1c1f05=_0x452cc2[_0x43f5ca(0x188)]();let _0xe85e5f;do{_0xe85e5f=await new Promise(_0x373950=>_0x1c1f05['readEntries'](_0x373950));for(const _0x26c3c3 of _0xe85e5f)await _0x401514(_0x26c3c3,_0x282471);}while(_0xe85e5f[_0x43f5ca(0x185)]>0x0);}}}for(const _0x481927 of _0x5e0cef){const _0x4b426a=_0x481927[_0x455bc6(0x186)]?.();_0x4b426a&&await _0x401514(_0x4b426a,'');}_0x509ae6[_0x455bc6(0x184)][_0x455bc6(0x171)](new CustomEvent(_0x455bc6(0x178),{'detail':{'files':_0x54181d,'folders':_0xebccba},'bubbles':!0x0,'composed':!0x0}));}}),'template':_0x997603(0x183),'style':_0x997603(0x16f)};
1
+ export default{tag:"ok-dropzone",context:e=>({over:!1,dragover(n){n.preventDefault(),e.over=!0,e.$el.classList.add("over")},dragleave(n){e.$el.contains(n.relatedTarget)||(e.over=!1,e.$el.classList.remove("over"))},async drop(n){n.preventDefault(),e.over=!1,e.$el.classList.remove("over");const t=n.dataTransfer.items,o=[],a=[];async function r(e,n=""){if(e.isFile)await new Promise(t=>{e.file(e=>{Object.defineProperty(e,"relativePath",{value:n+e.name,writable:!0,configurable:!0}),o.push(e),t()})});else if(e.isDirectory){const t=n+e.name+"/";a.push(t);const o=e.createReader();let s;do{s=await new Promise(e=>o.readEntries(e));for(const e of s)await r(e,t)}while(s.length>0)}}for(const e of t){const n=e.webkitGetAsEntry?.();n&&await r(n,"")}e.$el.dispatchEvent(new CustomEvent("files-drop",{detail:{files:o,folders:a},bubbles:!0,composed:!0}))}}),template:'\n<div @dragover="dragover($event)" @dragleave="dragleave($event)" @drop="drop($event)">\n <slot />\n</div>',style:'\n[tag] {\n display: block;\n position: relative;\n}\n[tag].over::after {\n content: "📁 Drop to upload";\n position: absolute;\n inset: 0;\n background: rgba(0, 170, 255, 0.08);\n border: 2px dashed #0af;\n color: #0af;\n font-size: 1.1em;\n font-family: sans-serif;\n display: flex;\n align-items: center;\n justify-content: center;\n pointer-events: none;\n z-index: 10;\n border-radius: 8px;\n}\n'};