x-block-lib 0.8.59 → 0.8.60

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.
package/dist/index.js CHANGED
@@ -1,9 +1,9 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var l=document.createElement("style");l.id="x-block-lib",l.appendChild(document.createTextNode("pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}.hljs{background:#f3f3f3;color:#444}.hljs-comment{color:#697070}.hljs-punctuation,.hljs-tag{color:#444a}.hljs-tag .hljs-attr,.hljs-tag .hljs-name{color:#444}.hljs-attribute,.hljs-doctag,.hljs-keyword,.hljs-meta .hljs-keyword,.hljs-name,.hljs-selector-tag{font-weight:700}.hljs-deletion,.hljs-number,.hljs-quote,.hljs-selector-class,.hljs-selector-id,.hljs-string,.hljs-template-tag,.hljs-type{color:#800}.hljs-section,.hljs-title{color:#800;font-weight:700}.hljs-link,.hljs-operator,.hljs-regexp,.hljs-selector-attr,.hljs-selector-pseudo,.hljs-symbol,.hljs-template-variable,.hljs-variable{color:#ab5656}.hljs-literal{color:#695}.hljs-addition,.hljs-built_in,.hljs-bullet,.hljs-code{color:#397300}.hljs-meta{color:#1f7199}.hljs-meta .hljs-string{color:#38a}.hljs-emphasis{font-style:italic}.hljs-strong{font-weight:700}.ghost[data-v-a77ed323]{opacity:.4;pointer-events:none}.blocklyToolbox{overflow-x:hidden;width:56px}.blocklyMainBackground{stroke-width:0}.blocklyToolboxCategory{margin-bottom:12px!important}.blocklyToolboxCategoryIcon{display:none!important}.blocklyTreeRowContentContainer{height:28px;display:flex;align-items:center;justify-items:center;overflow:hidden}.blocklyFlyout{z-index:21}")),document.head.appendChild(l)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
2
- import { E as O, r as On, M as Do, s as Mo, a as Uo, X as Kn, u as L, B as A, j as i, O as _, F as v, b as je, i as N, c as It, d as Vo, e as w, f as g, g as xo, h as J, k as Et, p as wt, l as ct, m as vn, n as M, C as $n, N as rt, o as Yo, P as Xe, q as Ye, V as bt, t as Hn, W as Fo, v as wo, w as Ko, S as $o, x as Ho, y as Go, z as Xt, T as ye, A as Gn, D as Wo, G as jo, H as Wn, I as Xo, J as Jo, K as qo, L as Qo, Q as zo, R as Zo, U as ts, Y as es } from "./vendor.je7mkgas.js";
2
+ import { E as O, r as On, M as Ro, s as Do, a as Mo, X as Kn, u as N, B as A, j as i, O as _, F as v, b as je, i as S, c as It, d as Uo, e as w, f as g, g as Vo, h as J, k as Et, p as wt, l as ct, m as vn, n as M, C as $n, N as rt, o as xo, P as Xe, q as Ye, V as bt, t as Hn, W as Yo, v as Fo, w as wo, S as Ko, x as $o, y as Ho, z as Xt, T as ye, A as Gn, D as Go, G as Wo, H as Wn, I as jo, J as Xo, K as Jo, L as qo, Q as Qo, R as zo, U as Zo, Y as ts } from "./vendor.je7mkgas.js";
3
3
  import { globalState as I } from "x-state-lib";
4
- import { globalObjects as St, openConfirmDlg as ns, openPromptDlg as os, messageWarning as jn, useColor as Jt, useSystem as Xn, useViewStack as rn, eventBus as Bt } from "x-essential-lib";
5
- import { pkgs as ie, parsePixelStr as ss, parsePercentStr as is, getPropertyTag as Vt, unwrapEventId as un, elements as V, unwrapEventKeyOfCustomSlot as Cn, unwrapEventKeyOfElementSlot as as, unwrapPropertyKeyOfCustomSlot as Je, unwrapPropertyKeyOfElementSlot as Jn, makeEventId as K, makeEventKeyOfCustomSlot as kn, unwrapSlotId as ae, makeEventKeyOfElementSlot as cs, makePropertyKeyOfCustomSlot as qe, makePropertyKeyOfElementSlot as qn, toEventName as Oe, unwrapMethodId as qt, unwrapMethodKeyOfCustomSlot as Qe, unwrapMethodKeyOfElementSlot as rs, makeMethodId as _t, makeMethodKeyOfCustomSlot as Nn, makeMethodKeyOfElementSlot as us, toMethodName as ve, unwrapPropertyId as ls, makePropertyId as Ct, toPropertyName as Qn, isLocaleOfMethodKind as zn, makeTriggerId as kt } from "x-runtime-lib";
6
- import { provide as _s, inject as ps, defineComponent as pt, computed as $, resolveComponent as F, createBlock as ut, openBlock as D, unref as Y, withCtx as lt, createVNode as R, mergeProps as ln, useModel as Ht, ref as Pt, resolveDirective as ds, withDirectives as hs, createElementBlock as it, normalizeStyle as z, createElementVNode as X, createCommentVNode as dt, toDisplayString as Gt, withModifiers as Kt, mergeModels as ze, Fragment as Zn, renderList as fs, useId as Ze, onUnmounted as ms, useTemplateRef as $t, withKeys as to, isRef as oe, onMounted as Sn, nextTick as Ts, onBeforeUnmount as Ln, watch as Yt, renderSlot as Es } from "vue";
4
+ import { globalObjects as Nt, openConfirmDlg as es, openPromptDlg as ns, messageWarning as jn, useColor as Jt, useSystem as Xn, useViewStack as rn, eventBus as Bt } from "x-essential-lib";
5
+ import { pkgs as ie, parsePixelStr as os, parsePercentStr as ss, getPropertyTag as Vt, unwrapEventId as un, elements as V, unwrapEventKeyOfCustomSlot as Cn, unwrapEventKeyOfElementSlot as is, unwrapPropertyKeyOfCustomSlot as Je, unwrapPropertyKeyOfElementSlot as Jn, makeEventId as K, makeEventKeyOfCustomSlot as kn, unwrapSlotId as ae, makeEventKeyOfElementSlot as as, makePropertyKeyOfCustomSlot as qe, makePropertyKeyOfElementSlot as qn, toEventName as Oe, unwrapMethodId as qt, unwrapMethodKeyOfCustomSlot as Qe, unwrapMethodKeyOfElementSlot as cs, makeMethodId as _t, makeMethodKeyOfCustomSlot as Sn, makeMethodKeyOfElementSlot as rs, toMethodName as ve, unwrapPropertyId as us, makePropertyId as Ct, toPropertyName as Qn, isLocaleOfMethodKind as zn, makeTriggerId as kt } from "x-runtime-lib";
6
+ import { provide as ls, inject as _s, defineComponent as pt, computed as $, resolveComponent as F, createBlock as ut, openBlock as D, unref as Y, withCtx as lt, createVNode as R, mergeProps as ln, useModel as Ht, ref as Pt, resolveDirective as ps, withDirectives as ds, createElementBlock as it, normalizeStyle as z, createElementVNode as X, createCommentVNode as dt, toDisplayString as Gt, withModifiers as Kt, mergeModels as ze, Fragment as Zn, renderList as hs, useId as Ze, onUnmounted as fs, useTemplateRef as $t, withKeys as to, isRef as oe, onMounted as Nn, nextTick as ms, onBeforeUnmount as Ln, watch as Yt, renderSlot as Ts } from "vue";
7
7
  import { useDisplay as _n } from "vuetify";
8
8
  import { useI18n as Qt } from "vue-i18n";
9
9
  var U = /* @__PURE__ */ ((t) => (t.STATE_CHANGE = "state_change", t))(U || {});
@@ -22,18 +22,18 @@ const no = (t, e, n) => {
22
22
  });
23
23
  };
24
24
  async function Bn(t) {
25
- const e = await no(/* @__PURE__ */ Object.assign({ "./msg/en.ts": () => import("./msg-en.jch03670.js"), "./msg/zhHans.ts": () => import("./msg-zhHans.dkvb4o7c.js") }), `./msg/${t}.ts`, 3);
26
- Mo(e.default);
25
+ const e = await no(/* @__PURE__ */ Object.assign({ "./msg/en.ts": () => import("./msg-en.lazlimvt.js"), "./msg/zhHans.ts": () => import("./msg-zhHans.b1gbdbmm.js") }), `./msg/${t}.ts`, 3);
26
+ Do(e.default);
27
27
  }
28
28
  function m(t) {
29
- return Do[t] ?? t;
29
+ return Ro[t] ?? t;
30
30
  }
31
31
  const Rt = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZlcnNpb249IjEuMSIgd2lkdGg9IjI0IiBoZWlnaHQ9IjI0Ij48cGF0aCBkPSJNMTggMTBoLTR2LTRjMC0xLjEwNC0uODk2LTItMi0ycy0yIC44OTYtMiAybC4wNzEgNGgtNC4wNzFjLTEuMTA0IDAtMiAuODk2LTIgMnMuODk2IDIgMiAybDQuMDcxLS4wNzEtLjA3MSA0LjA3MWMwIDEuMTA0Ljg5NiAyIDIgMnMyLS44OTYgMi0ydi00LjA3MWw0IC4wNzFjMS4xMDQgMCAyLS44OTYgMi0ycy0uODk2LTItMi0yeiIgZmlsbD0id2hpdGUiIC8+PC9zdmc+Cg==", ce = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZlcnNpb249IjEuMSIgd2lkdGg9IjI0IiBoZWlnaHQ9IjI0Ij48cGF0aCBkPSJNMTggMTFoLTEyYy0xLjEwNCAwLTIgLjg5Ni0yIDJzLjg5NiAyIDIgMmgxMmMxLjEwNCAwIDItLjg5NiAyLTJzLS44OTYtMi0yLTJ6IiBmaWxsPSJ3aGl0ZSIgLz48L3N2Zz4K";
32
32
  function Ce(t) {
33
33
  const e = t.lastIndexOf("V");
34
34
  if (e <= 0 || e >= t.length - 1)
35
35
  return console.assert(!1, `invalid key=${t}`), "";
36
- const n = Uo(t.substring(0, e - 1)), o = "v" + t.substring(e + 1);
36
+ const n = Mo(t.substring(0, e - 1)), o = "v" + t.substring(e + 1);
37
37
  return `${n}_${o}`;
38
38
  }
39
39
  function re(t) {
@@ -46,7 +46,7 @@ function re(t) {
46
46
  function B(t) {
47
47
  return t.length <= 0 && t.push([m("NO_OPTION"), ""]), t;
48
48
  }
49
- function gs(t) {
49
+ function Es(t) {
50
50
  let e = 0;
51
51
  for (; t; )
52
52
  e++, t = t.getParent();
@@ -58,7 +58,7 @@ function oo(t) {
58
58
  function ke(t, e) {
59
59
  return !!(t.startsWith("basic.") || !e.ui || e.readonly);
60
60
  }
61
- function S(t) {
61
+ function L(t) {
62
62
  return t.startsWith("globality_v");
63
63
  }
64
64
  function et(t) {
@@ -72,24 +72,24 @@ function so(t) {
72
72
  }
73
73
  function Fe(t) {
74
74
  const e = `<block type="text_v1"><field name="TEXT">${t}</field></block>`;
75
- return L.xml.textToDom(e);
75
+ return N.xml.textToDom(e);
76
76
  }
77
77
  function bn(t) {
78
78
  const e = `<block type="math_number_v1"><field name="NUM">${t}</field></block>`;
79
- return L.xml.textToDom(e);
79
+ return N.xml.textToDom(e);
80
80
  }
81
- function As(t) {
82
- return L.xml.textToDom('<block type="logic_boolean_v1"><field name="BOOL">FALSE</field></block>');
81
+ function gs(t) {
82
+ return N.xml.textToDom('<block type="logic_boolean_v1"><field name="BOOL">FALSE</field></block>');
83
83
  }
84
84
  function tn(t, e) {
85
85
  let n = null;
86
- return e === "string" ? n = Fe("") : e === "integer" || e === "decimal" ? n = bn(0) : e === "boolean" ? n = As() : e === "enum" || e === "dateTime" ? n = Fe("") : console.assert(!1), n ? Kn.domToBlock(n, t) : null;
86
+ return e === "string" ? n = Fe("") : e === "integer" || e === "decimal" ? n = bn(0) : e === "boolean" ? n = gs() : e === "enum" || e === "dateTime" ? n = Fe("") : console.assert(!1), n ? Kn.domToBlock(n, t) : null;
87
87
  }
88
88
  function yt(t) {
89
89
  return t === "string" ? "String" : t === "number" ? "Number" : t === "boolean" ? "Boolean" : t === "array" ? "Array" : t === "object" ? "Object" : (console.assert(!1), null);
90
90
  }
91
- function Is(t) {
92
- return t.ui === "dummy" ? null : t.ui === "strInput" ? "String" : t.ui === "numInput" ? "Number" : t.ui === "switch" ? "Boolean" : t.ui === "select" ? re(t.items) : t.ui === "multiTypes" ? re(t.types) : t.ui === "compSelect" ? "Comp" : t.ui === "colorPicker" ? "Color" : (console.assert(!1), null);
91
+ function As(t) {
92
+ return t.ui === "dummy" ? null : t.ui === "strInput" ? "String" : t.ui === "numInput" ? "Number" : t.ui === "switch" ? "Boolean" : t.ui === "select" ? re(t.items) : t.ui === "multiTypes" ? re(t.types) : t.ui === "selectComp" ? "Comp" : t.ui === "selectSlot" ? "Slot" : t.ui === "selectAdaptSlot" ? "AdaptSlot" : t.ui === "colorPicker" ? "Color" : (console.assert(!1), null);
93
93
  }
94
94
  function io(t) {
95
95
  return t === "string" ? "String" : t === "integer" || t === "decimal" ? "Number" : t === "boolean" ? "Boolean" : t === "enum" || t === "dateTime" ? "String" : (console.assert(!1), null);
@@ -99,7 +99,7 @@ function pn(t, e, n, o) {
99
99
  <block type="parameter_v1">
100
100
  <mutation key="${e}" name="${n}" locale="${o ? "TRUE" : "FALSE"}"/>
101
101
  </block>
102
- `, a = L.xml.textToDom(s);
102
+ `, a = N.xml.textToDom(s);
103
103
  return Kn.domToBlock(a, t);
104
104
  }
105
105
  function j(t, e) {
@@ -128,44 +128,47 @@ function j(t, e) {
128
128
  }
129
129
  function Tt(t) {
130
130
  const e = `<shadow type="text_v1"><field name="TEXT">${t}</field></shadow>`;
131
- return L.xml.textToDom(e);
131
+ return N.xml.textToDom(e);
132
132
  }
133
133
  function ue(t) {
134
134
  const e = `<shadow type="math_number_v1"><field name="NUM">${t}</field></shadow>`;
135
- return L.xml.textToDom(e);
135
+ return N.xml.textToDom(e);
136
136
  }
137
137
  function le(t) {
138
138
  const e = `<shadow type="logic_boolean_v1"><field name="BOOL">${t ? "TRUE" : "FALSE"}</field></shadow>`;
139
- return L.xml.textToDom(e);
139
+ return N.xml.textToDom(e);
140
+ }
141
+ function Is() {
142
+ return N.xml.textToDom('<shadow type="list_create_v1"></shadow>');
140
143
  }
141
144
  function ys() {
142
- return L.xml.textToDom('<shadow type="list_create_v1"></shadow>');
145
+ return N.xml.textToDom('<shadow type="object_create_v1"></shadow>');
143
146
  }
144
- function Os() {
145
- return L.xml.textToDom('<shadow type="object_create_v1"></shadow>');
147
+ function Os(t) {
148
+ const e = `<shadow type="${Ce(t)}"></shadow>`;
149
+ return N.xml.textToDom(e);
146
150
  }
147
151
  function vs(t) {
148
152
  const e = `<shadow type="${Ce(t)}"></shadow>`;
149
- return L.xml.textToDom(e);
153
+ return N.xml.textToDom(e);
150
154
  }
151
- function Cs(t) {
152
- const e = `<shadow type="${Ce(t)}"></shadow>`;
153
- return L.xml.textToDom(e);
155
+ function Cs() {
156
+ return N.xml.textToDom('<shadow type="select_comp_v1"></shadow>');
154
157
  }
155
- function ks(t) {
156
- const e = `<shadow type="color_picker_v1"><field name="COLOR">${t}</field></shadow>`;
157
- return L.xml.textToDom(e);
158
+ function ks() {
159
+ return N.xml.textToDom('<shadow type="select_slot_v1"></shadow>');
158
160
  }
159
- function Ns() {
160
- return L.xml.textToDom('<shadow type="select_comp_v1"></shadow>');
161
+ function Ss(t) {
162
+ const e = `<shadow type="color_picker_v1"><field name="COLOR">${t}</field></shadow>`;
163
+ return N.xml.textToDom(e);
161
164
  }
162
165
  function Ot(t) {
163
166
  let e = null;
164
- return t === "string" ? e = Tt("") : t === "number" ? e = ue(0) : t === "boolean" ? e = le(!1) : t === "array" ? e = ys() : t === "object" ? e = Os() : console.assert(!1), e;
167
+ return t === "string" ? e = Tt("") : t === "number" ? e = ue(0) : t === "boolean" ? e = le(!1) : t === "array" ? e = Is() : t === "object" ? e = ys() : console.assert(!1), e;
165
168
  }
166
- function Ss(t) {
169
+ function Ns(t) {
167
170
  let e = null;
168
- return t.ui === "dummy" ? console.assert(!0) : t.ui === "strInput" ? e = Tt(t.default) : t.ui === "numInput" ? e = ue(t.default) : t.ui === "switch" ? e = le(t.default) : t.ui === "select" ? e = vs(t.items) : t.ui === "multiTypes" ? e = Cs(t.types) : t.ui === "compSelect" ? e = Ns() : t.ui === "colorPicker" ? e = ks(t.default ?? "#ff0000") : console.assert(!1), e;
171
+ return t.ui === "dummy" ? console.assert(!0) : t.ui === "strInput" ? e = Tt(t.default) : t.ui === "numInput" ? e = ue(t.default) : t.ui === "switch" ? e = le(t.default) : t.ui === "select" ? e = Os(t.items) : t.ui === "multiTypes" ? e = vs(t.types) : t.ui === "selectComp" ? e = Cs() : t.ui === "selectSlot" ? e = ks() : t.ui === "colorPicker" ? e = Ss(t.default ?? "#ff0000") : console.assert(!1), e;
169
172
  }
170
173
  function Ls() {
171
174
  const { activeObject: t, activePage: e } = I.app, n = [];
@@ -265,7 +268,7 @@ const Ps = (t, e) => {
265
268
  ), this.setOutput(!0, o), this.setStyle("property_blocks"), this.setTooltip(""), this.setHelpUrl("");
266
269
  },
267
270
  genOpts_: function() {
268
- const { i18n: s } = St, a = [];
271
+ const { i18n: s } = Nt, a = [];
269
272
  for (const { title: r, value: c } of e)
270
273
  a.push([s.global.t(r), c]);
271
274
  return B(a);
@@ -298,7 +301,7 @@ const Rs = (t, e) => {
298
301
  }, 0);
299
302
  },
300
303
  genOpts_: function() {
301
- const { i18n: s } = St, a = [];
304
+ const { i18n: s } = Nt, a = [];
302
305
  for (const { title: r, value: c } of e)
303
306
  a.push([s.global.t(r), c]);
304
307
  return B(a);
@@ -333,7 +336,7 @@ const Rs = (t, e) => {
333
336
  s.removeField("VALUE", !0), s.removeField("SUFFIX", !0);
334
337
  let c, l;
335
338
  if (r.ui === "pixelInput") {
336
- const d = ss(this.value) ?? 0;
339
+ const d = os(this.value) ?? 0;
337
340
  c = new je(
338
341
  d,
339
342
  r.min,
@@ -344,7 +347,7 @@ const Rs = (t, e) => {
344
347
  }
345
348
  ), l = "px";
346
349
  } else if (r.ui === "percentInput") {
347
- const d = is(this.value) ?? 0;
350
+ const d = ss(this.value) ?? 0;
348
351
  c = new je(
349
352
  d,
350
353
  r.min,
@@ -375,7 +378,7 @@ for (const t in ie) {
375
378
  for (const n in e.types)
376
379
  Rs(n, e.types[n]);
377
380
  }
378
- const Ds = L.xml, Ms = {
381
+ const Ds = N.xml, Ms = {
379
382
  init: function() {
380
383
  this.appendDummyInput().appendField(
381
384
  "%{BKY_APP_V1_APP_BIND_CONTAINER_TITLE}"
@@ -396,7 +399,7 @@ const Vs = {
396
399
  ["app_bind_item_v1"],
397
400
  this
398
401
  )
399
- ), this.debounce_ = Vo(() => {
402
+ ), this.debounce_ = Uo(() => {
400
403
  this.checkWarning_();
401
404
  }, 250), this.setStyle("event_blocks"), this.setTooltip("%{BKY_APP_V1_APP_BIND_TOOLTIP}"), this.setHelpUrl("%{BKY_APP_V1_APP_BIND_HELPURL}"), this.updateShape_();
402
405
  },
@@ -477,7 +480,7 @@ const Vs = {
477
480
  "Boolean",
478
481
  "Array",
479
482
  "Object"
480
- ]), t === 0 && this.getInput("ADD" + t).setAlign(N.Align.RIGHT).appendField("%{BKY_APP_V1_APP_BIND_TITLE}"));
483
+ ]), t === 0 && this.getInput("ADD" + t).setAlign(S.Align.RIGHT).appendField("%{BKY_APP_V1_APP_BIND_TITLE}"));
481
484
  for (let t = this.itemCount_; this.getInput("ADD" + t); t++)
482
485
  this.removeInput("ADD" + t);
483
486
  },
@@ -512,10 +515,18 @@ i.forBlock.app_bind_v1 = function() {
512
515
  return "";
513
516
  };
514
517
  function ao() {
515
- return I.app.appList;
518
+ const t = [], { appList: e } = I.app;
519
+ for (const { id: n, name: o } of e)
520
+ t.push({ id: n, name: o });
521
+ return t;
516
522
  }
517
523
  function Rn(t) {
518
- return I.app.appList.find((e) => e.id === t);
524
+ const { appList: e } = I.app, n = e.find((o) => o.id === t);
525
+ if (n)
526
+ return {
527
+ id: n.id,
528
+ name: n.name
529
+ };
519
530
  }
520
531
  function xs() {
521
532
  const t = [];
@@ -524,13 +535,23 @@ function xs() {
524
535
  }), B(t);
525
536
  }
526
537
  function en(t) {
527
- const e = I.app.appList.find((n) => n.id === t);
528
- return e ? e.pages : [];
538
+ const { appList: e } = I.app, n = [], o = e.find((s) => s.id === t);
539
+ if (!o)
540
+ return n;
541
+ for (const { id: s, name: a } of o.pages)
542
+ n.push({ id: s, name: a });
543
+ return n;
529
544
  }
530
545
  function we(t, e) {
531
- const n = I.app.appList.find((o) => o.id === t);
532
- if (n)
533
- return n.pages.find((o) => o.id === e);
546
+ const { appList: n } = I.app, o = n.find((a) => a.id === t);
547
+ if (!o)
548
+ return;
549
+ const s = o.pages.find((a) => a.id === e);
550
+ if (s)
551
+ return {
552
+ id: s.id,
553
+ name: s.name
554
+ };
534
555
  }
535
556
  function Ys(t) {
536
557
  const e = [];
@@ -538,22 +559,26 @@ function Ys(t) {
538
559
  e.push([s, o]);
539
560
  }), B(e);
540
561
  }
541
- const co = {
542
- id: "",
543
- groupId: "",
544
- name: "",
545
- position: 0
546
- };
547
- function ro() {
548
- const { comps: t } = I.app.activeApp;
549
- return [co, ...t];
562
+ function co() {
563
+ const { activeApp: t } = I.app, e = [{ id: "", name: "" }];
564
+ for (const { id: n, name: o } of t.comps)
565
+ e.push({ id: n, name: o });
566
+ return e;
550
567
  }
551
568
  function Dn(t) {
552
- return t === "" ? co : I.app.activeApp.comps.find((e) => e.id === t);
569
+ const { activeApp: e } = I.app;
570
+ if (!t)
571
+ return;
572
+ const n = e.comps.find((o) => o.id === t);
573
+ if (n)
574
+ return {
575
+ id: n.id,
576
+ name: n.name
577
+ };
553
578
  }
554
579
  function Fs() {
555
- const { i18n: t } = St, e = [];
556
- return ro().forEach(({ id: o, name: s }) => {
580
+ const { i18n: t } = Nt, e = [];
581
+ return co().forEach(({ id: o, name: s }) => {
557
582
  let a = s;
558
583
  o === "" && (a = t.global.t("x-runtime-lib.notSet")), e.push([a, o]);
559
584
  }), B(e);
@@ -612,7 +637,7 @@ function nn(t) {
612
637
  params: ot(f)
613
638
  });
614
639
  }
615
- if (S(d.key) && n.type === "comp" && s.meta.events)
640
+ if (L(d.key) && n.type === "comp" && s.meta.events)
616
641
  for (const { id: u, name: h, params: p } of s.meta.events)
617
642
  r.push({
618
643
  id: K("customEvent", t, u),
@@ -620,7 +645,7 @@ function nn(t) {
620
645
  names: [h],
621
646
  params: ot(p)
622
647
  });
623
- if (S(d.key) && n.type === "comp" && s.meta.slots) {
648
+ if (L(d.key) && n.type === "comp" && s.meta.slots) {
624
649
  for (const u of s.meta.slots)
625
650
  if (u.events)
626
651
  for (const h of u.events)
@@ -635,7 +660,7 @@ function nn(t) {
635
660
  params: ot(h.params)
636
661
  });
637
662
  }
638
- if (S(d.key) && n.type === "comp" && l.settings && l.settings.adaptSlot) {
663
+ if (L(d.key) && n.type === "comp" && l.settings && l.settings.adaptSlot) {
639
664
  const u = ae(l.settings.adaptSlot);
640
665
  if (u) {
641
666
  if (u.kind === "elementSlot") {
@@ -650,7 +675,7 @@ function nn(t) {
650
675
  id: K(
651
676
  "adaptSlotElementEvent",
652
677
  t,
653
- cs(
678
+ as(
654
679
  u.mainKey,
655
680
  u.slotKey,
656
681
  f.key
@@ -713,7 +738,7 @@ function nn(t) {
713
738
  params: x(f)
714
739
  });
715
740
  }
716
- if (S(d.key) && n.type === "comp" && s.meta.properties)
741
+ if (L(d.key) && n.type === "comp" && s.meta.properties)
717
742
  for (const { id: u, name: h, type: p } of s.meta.properties)
718
743
  r.push({
719
744
  id: K("customPropertyChangeEvent", t, u),
@@ -721,7 +746,7 @@ function nn(t) {
721
746
  names: [h],
722
747
  params: x(p)
723
748
  });
724
- if (S(d.key) && n.type === "comp" && s.meta.slots) {
749
+ if (L(d.key) && n.type === "comp" && s.meta.slots) {
725
750
  for (const u of s.meta.slots)
726
751
  if (u.properties)
727
752
  for (const h of u.properties)
@@ -736,7 +761,7 @@ function nn(t) {
736
761
  params: x(h.type)
737
762
  });
738
763
  }
739
- if (S(d.key) && n.type === "comp" && l.settings && l.settings.adaptSlot) {
764
+ if (L(d.key) && n.type === "comp" && l.settings && l.settings.adaptSlot) {
740
765
  const u = ae(l.settings.adaptSlot);
741
766
  if (u) {
742
767
  if (u.kind === "elementSlot") {
@@ -788,7 +813,7 @@ function nn(t) {
788
813
  }
789
814
  }
790
815
  }
791
- if (S(d.key)) {
816
+ if (L(d.key)) {
792
817
  if (n.type === "page") {
793
818
  if (o.meta.states)
794
819
  for (const { id: u, name: h, type: p } of o.meta.states)
@@ -861,7 +886,7 @@ function Ke(t) {
861
886
  }
862
887
  }
863
888
  } else if (c === "customEvent") {
864
- if (S(h.key) && n.type === "comp") {
889
+ if (L(h.key) && n.type === "comp") {
865
890
  const p = s.meta.events?.find((f) => f.id === d);
866
891
  if (p)
867
892
  return {
@@ -872,7 +897,7 @@ function Ke(t) {
872
897
  };
873
898
  }
874
899
  } else if (c === "customSlotEvent") {
875
- if (S(h.key) && n.type === "comp" && s.meta.slots) {
900
+ if (L(h.key) && n.type === "comp" && s.meta.slots) {
876
901
  const { slotId: p, eventId: f } = Cn(d), T = s.meta.slots.find((E) => E.id === p);
877
902
  if (T && T.events) {
878
903
  const E = T.events.find((y) => y.id === f);
@@ -886,12 +911,12 @@ function Ke(t) {
886
911
  }
887
912
  }
888
913
  } else if (c === "adaptSlotElementEvent") {
889
- if (S(h.key) && n.type === "comp") {
914
+ if (L(h.key) && n.type === "comp") {
890
915
  const {
891
916
  elementKey: p,
892
917
  slotKey: f,
893
918
  eventKey: T
894
- } = as(d), E = V[p];
919
+ } = is(d), E = V[p];
895
920
  if (E && E.slots) {
896
921
  const y = E.slots.find((k) => k.key === f);
897
922
  if (y && y.events) {
@@ -907,7 +932,7 @@ function Ke(t) {
907
932
  }
908
933
  }
909
934
  } else if (c === "adaptSlotCustomEvent") {
910
- if (S(h.key) && n.type === "comp") {
935
+ if (L(h.key) && n.type === "comp") {
911
936
  const { compId: p, slotId: f, eventId: T } = Cn(d), E = a[p];
912
937
  if (E && E.meta.slots) {
913
938
  const y = E.meta.slots.find((k) => k.id === f);
@@ -969,7 +994,7 @@ function Ke(t) {
969
994
  }
970
995
  }
971
996
  } else if (c === "customPropertyChangeEvent") {
972
- if (S(h.key) && n.type === "comp") {
997
+ if (L(h.key) && n.type === "comp") {
973
998
  const p = s.meta.properties?.find(
974
999
  (f) => f.id === d
975
1000
  );
@@ -982,7 +1007,7 @@ function Ke(t) {
982
1007
  };
983
1008
  }
984
1009
  } else if (c === "customSlotPropertyChangeEvent") {
985
- if (S(h.key) && n.type === "comp" && s.meta.slots) {
1010
+ if (L(h.key) && n.type === "comp" && s.meta.slots) {
986
1011
  const { slotId: p, propertyId: f } = Je(d), T = s.meta.slots.find((E) => E.id === p);
987
1012
  if (T && T.properties) {
988
1013
  const E = T.properties.find((y) => y.id === f);
@@ -996,7 +1021,7 @@ function Ke(t) {
996
1021
  }
997
1022
  }
998
1023
  } else if (c === "adaptSlotElementPropertyChangeEvent") {
999
- if (S(h.key) && n.type === "comp") {
1024
+ if (L(h.key) && n.type === "comp") {
1000
1025
  const { elementKey: p, slotKey: f, propertyKey: T } = Jn(d), E = V[p];
1001
1026
  if (E && E.slots) {
1002
1027
  const y = E.slots.find((k) => k.key === f);
@@ -1029,7 +1054,7 @@ function Ke(t) {
1029
1054
  };
1030
1055
  }
1031
1056
  }
1032
- } else if (c === "stateChangeEvent" && S(h.key)) {
1057
+ } else if (c === "stateChangeEvent" && L(h.key)) {
1033
1058
  if (n.type === "page") {
1034
1059
  const p = o.meta.states?.find(
1035
1060
  (f) => f.id === d
@@ -1061,7 +1086,7 @@ function ws(t) {
1061
1086
  e.push([Oe(s, a), o]);
1062
1087
  return B(e);
1063
1088
  }
1064
- function uo() {
1089
+ function ro() {
1065
1090
  const { activeObject: t, activeComp: e } = I.app, n = [];
1066
1091
  if (t.type === "comp" && e.meta.events)
1067
1092
  for (const { id: o, name: s, params: a } of e.meta.events)
@@ -1091,7 +1116,7 @@ function Mn(t) {
1091
1116
  }
1092
1117
  }
1093
1118
  function Ks() {
1094
- const t = [], e = uo();
1119
+ const t = [], e = ro();
1095
1120
  for (const { id: n, kind: o, names: s } of e)
1096
1121
  t.push([Oe(o, s), n]);
1097
1122
  return B(t);
@@ -1152,7 +1177,7 @@ function on(t) {
1152
1177
  outputs: tt(h)
1153
1178
  });
1154
1179
  }
1155
- if (S(r.key) && e.type === "comp" && n.meta.methods)
1180
+ if (L(r.key) && e.type === "comp" && n.meta.methods)
1156
1181
  for (const { id: c, name: l, inputs: d, outputs: u } of n.meta.methods)
1157
1182
  s.push({
1158
1183
  id: _t("customMethod", t, c),
@@ -1161,7 +1186,7 @@ function on(t) {
1161
1186
  inputs: H(d),
1162
1187
  outputs: tt(u)
1163
1188
  });
1164
- if (S(r.key) && e.type === "comp" && n.meta.slots) {
1189
+ if (L(r.key) && e.type === "comp" && n.meta.slots) {
1165
1190
  for (const c of n.meta.slots)
1166
1191
  if (c.methods)
1167
1192
  for (const l of c.methods)
@@ -1169,7 +1194,7 @@ function on(t) {
1169
1194
  id: _t(
1170
1195
  "customSlotMethod",
1171
1196
  t,
1172
- Nn("", c.id, l.id)
1197
+ Sn("", c.id, l.id)
1173
1198
  ),
1174
1199
  kind: "customSlotMethod",
1175
1200
  names: [c.name, l.name],
@@ -1177,7 +1202,7 @@ function on(t) {
1177
1202
  outputs: tt(l.outputs)
1178
1203
  });
1179
1204
  }
1180
- if (S(r.key) && e.type === "comp" && a.settings && a.settings.adaptSlot) {
1205
+ if (L(r.key) && e.type === "comp" && a.settings && a.settings.adaptSlot) {
1181
1206
  const c = ae(a.settings.adaptSlot);
1182
1207
  if (c) {
1183
1208
  if (c.kind === "elementSlot") {
@@ -1192,7 +1217,7 @@ function on(t) {
1192
1217
  id: _t(
1193
1218
  "adaptSlotElementMethod",
1194
1219
  t,
1195
- us(l.key, d.key, u.key)
1220
+ rs(l.key, d.key, u.key)
1196
1221
  ),
1197
1222
  kind: "adaptSlotElementMethod",
1198
1223
  names: [l.name, d.name, u.name],
@@ -1212,7 +1237,7 @@ function on(t) {
1212
1237
  id: _t(
1213
1238
  "adaptSlotCustomMethod",
1214
1239
  t,
1215
- Nn(
1240
+ Sn(
1216
1241
  c.mainKey,
1217
1242
  d.id,
1218
1243
  u.id
@@ -1285,7 +1310,7 @@ function $e(t) {
1285
1310
  }
1286
1311
  }
1287
1312
  } else if (s === "customMethod") {
1288
- if (S(l.key) && e.type === "comp") {
1313
+ if (L(l.key) && e.type === "comp") {
1289
1314
  const d = n.meta.methods?.find(
1290
1315
  (u) => u.id === r
1291
1316
  );
@@ -1299,7 +1324,7 @@ function $e(t) {
1299
1324
  };
1300
1325
  }
1301
1326
  } else if (s === "customSlotMethod") {
1302
- if (S(l.key) && e.type === "comp" && n.meta.slots) {
1327
+ if (L(l.key) && e.type === "comp" && n.meta.slots) {
1303
1328
  const { slotId: d, methodId: u } = Qe(r), h = n.meta.slots.find((p) => p.id === d);
1304
1329
  if (h && h.methods) {
1305
1330
  const p = h.methods.find((f) => f.id === u);
@@ -1314,12 +1339,12 @@ function $e(t) {
1314
1339
  }
1315
1340
  }
1316
1341
  } else if (s === "adaptSlotElementMethod") {
1317
- if (S(l.key) && e.type === "comp") {
1342
+ if (L(l.key) && e.type === "comp") {
1318
1343
  const {
1319
1344
  elementKey: d,
1320
1345
  slotKey: u,
1321
1346
  methodKey: h
1322
- } = rs(r), p = V[d];
1347
+ } = cs(r), p = V[d];
1323
1348
  if (p && p.slots) {
1324
1349
  const f = p.slots.find((T) => T.key === u);
1325
1350
  if (f && f.methods) {
@@ -1335,7 +1360,7 @@ function $e(t) {
1335
1360
  }
1336
1361
  }
1337
1362
  }
1338
- } else if (s === "adaptSlotCustomMethod" && S(l.key) && e.type === "comp") {
1363
+ } else if (s === "adaptSlotCustomMethod" && L(l.key) && e.type === "comp") {
1339
1364
  const { compId: d, slotId: u, methodId: h } = Qe(r), p = o[d];
1340
1365
  if (p && p.meta.slots) {
1341
1366
  const f = p.meta.slots.find((T) => T.id === u);
@@ -1417,7 +1442,7 @@ function Ut(t) {
1417
1442
  }
1418
1443
  }
1419
1444
  }
1420
- function lo() {
1445
+ function uo() {
1421
1446
  const t = [], e = dn();
1422
1447
  for (const { id: n, kind: o, names: s } of e)
1423
1448
  t.push([ve(o, s), n]);
@@ -1453,7 +1478,7 @@ function Gs(t, e, n) {
1453
1478
  if (l && l.meta.events && l.meta.events.length > 0)
1454
1479
  return !1;
1455
1480
  }
1456
- if (S(t.key) && s.type === "comp" && r.meta.events && r.meta.events.length > 0)
1481
+ if (L(t.key) && s.type === "comp" && r.meta.events && r.meta.events.length > 0)
1457
1482
  return !1;
1458
1483
  if (o[t.key] && o[t.key][e]) {
1459
1484
  for (const { keys: l, raw: d } of o[t.key][e])
@@ -1470,9 +1495,9 @@ function Gs(t, e, n) {
1470
1495
  if (l && l.meta.properties && l.meta.properties.length > 0)
1471
1496
  return !1;
1472
1497
  }
1473
- if (S(t.key) && s.type === "comp" && r.meta.properties && r.meta.properties.length > 0)
1498
+ if (L(t.key) && s.type === "comp" && r.meta.properties && r.meta.properties.length > 0)
1474
1499
  return !1;
1475
- if (S(t.key)) {
1500
+ if (L(t.key)) {
1476
1501
  if (s.type === "page") {
1477
1502
  if (a.meta.states && a.meta.states.length > 0)
1478
1503
  return !1;
@@ -1495,7 +1520,7 @@ function Ws(t, e) {
1495
1520
  if (a && a.meta.methods && a.meta.methods.length > 0)
1496
1521
  return !1;
1497
1522
  }
1498
- return S(t.key) && n.type === "comp" && o.meta.methods && o.meta.methods.length > 0 ? !1 : (S(t.key) && n.type, !0);
1523
+ return L(t.key) && n.type === "comp" && o.meta.methods && o.meta.methods.length > 0 ? !1 : (L(t.key) && n.type, !0);
1499
1524
  }
1500
1525
  function js(t, e, n) {
1501
1526
  const { properties: o } = I.runtime, { activeObject: s, activeComp: a, depends: r } = I.app;
@@ -1511,7 +1536,7 @@ function js(t, e, n) {
1511
1536
  if (c && c.meta.properties && c.meta.properties.length > 0)
1512
1537
  return !1;
1513
1538
  }
1514
- return !(S(t.key) && s.type === "comp" && a.meta.properties && a.meta.properties.length > 0);
1539
+ return !(L(t.key) && s.type === "comp" && a.meta.properties && a.meta.properties.length > 0);
1515
1540
  }
1516
1541
  function Xs(t, e, n) {
1517
1542
  const { properties: o } = I.runtime, { activeObject: s, activeComp: a, depends: r } = I.app;
@@ -1530,9 +1555,9 @@ function Xs(t, e, n) {
1530
1555
  if (c && c.meta.properties && c.meta.properties.length > 0)
1531
1556
  return !1;
1532
1557
  }
1533
- return !(S(t.key) && s.type === "comp" && a.meta.properties && a.meta.properties.length > 0);
1558
+ return !(L(t.key) && s.type === "comp" && a.meta.properties && a.meta.properties.length > 0);
1534
1559
  }
1535
- function _o(t, e, n, o) {
1560
+ function lo(t, e, n, o) {
1536
1561
  return t ? t === "onEvent" ? Gs(e, n, o) : t === "callMethod" ? Ws(e, o) : t === "getProperty" ? js(e, n, o) : t === "setProperty" ? Xs(e, n, o) : !1 : !1;
1537
1562
  }
1538
1563
  function Z(t) {
@@ -1545,7 +1570,7 @@ function Z(t) {
1545
1570
  console.assert(!1, "invalid element", o.key);
1546
1571
  continue;
1547
1572
  }
1548
- if (!_o(t, s, n, o.settings?.comp))
1573
+ if (!lo(t, s, n, o.settings?.comp))
1549
1574
  return !0;
1550
1575
  }
1551
1576
  return !1;
@@ -1560,7 +1585,7 @@ function zt(t) {
1560
1585
  console.assert(!1, "invalid element", s.key);
1561
1586
  continue;
1562
1587
  }
1563
- _o(t, a, o, s.settings?.comp) || n.push({
1588
+ lo(t, a, o, s.settings?.comp) || n.push({
1564
1589
  id: s.id,
1565
1590
  key: s.key,
1566
1591
  name: a.name,
@@ -1585,8 +1610,8 @@ function gt(t) {
1585
1610
  alias: n.alias
1586
1611
  };
1587
1612
  }
1588
- function Ne(t) {
1589
- const { i18n: e } = St, n = [], o = zt(t);
1613
+ function Se(t) {
1614
+ const { i18n: e } = Nt, n = [], o = zt(t);
1590
1615
  for (const { id: s, name: a, alias: r } of o) {
1591
1616
  let c = e.global.t(a);
1592
1617
  r && (c += " / " + r), n.push([c, s]);
@@ -1640,7 +1665,7 @@ function Wt(t, e) {
1640
1665
  }
1641
1666
  });
1642
1667
  }
1643
- if (S(d.key) && o.type === "comp" && s.meta.properties)
1668
+ if (L(d.key) && o.type === "comp" && s.meta.properties)
1644
1669
  for (const { id: u, name: h, type: p } of s.meta.properties)
1645
1670
  r.push({
1646
1671
  id: Ct("customProperty", t, u),
@@ -1665,7 +1690,7 @@ function Wt(t, e) {
1665
1690
  }
1666
1691
  });
1667
1692
  }
1668
- if (S(d.key) && o.type === "comp" && l.settings && l.settings.adaptSlot) {
1693
+ if (L(d.key) && o.type === "comp" && l.settings && l.settings.adaptSlot) {
1669
1694
  const u = ae(l.settings.adaptSlot);
1670
1695
  if (u) {
1671
1696
  if (u.kind === "elementSlot") {
@@ -1723,13 +1748,13 @@ function Wt(t, e) {
1723
1748
  }
1724
1749
  return r;
1725
1750
  }
1726
- function Nt(t) {
1751
+ function St(t) {
1727
1752
  if (!t)
1728
1753
  return;
1729
1754
  const { properties: e } = I.runtime, { activeObject: n, activeComp: o, depends: s } = I.app, a = Vt(n.type, n.subtype);
1730
1755
  if (!a)
1731
1756
  return;
1732
- const { kind: r, nodeId: c, propertyKey: l } = ls(t), d = n.nodes.find((h) => h.id === c);
1757
+ const { kind: r, nodeId: c, propertyKey: l } = us(t), d = n.nodes.find((h) => h.id === c);
1733
1758
  if (!d)
1734
1759
  return;
1735
1760
  const u = V[d.key];
@@ -1790,7 +1815,7 @@ function Nt(t) {
1790
1815
  }
1791
1816
  }
1792
1817
  } else if (r === "customProperty") {
1793
- if (S(u.key) && n.type === "comp") {
1818
+ if (L(u.key) && n.type === "comp") {
1794
1819
  const h = o.meta.properties?.find(
1795
1820
  (p) => p.id === l
1796
1821
  );
@@ -1823,7 +1848,7 @@ function Nt(t) {
1823
1848
  }
1824
1849
  }
1825
1850
  } else if (r === "adaptSlotElementProperty") {
1826
- if (S(u.key) && n.type === "comp") {
1851
+ if (L(u.key) && n.type === "comp") {
1827
1852
  const {
1828
1853
  elementKey: h,
1829
1854
  slotKey: p,
@@ -1847,7 +1872,7 @@ function Nt(t) {
1847
1872
  }
1848
1873
  }
1849
1874
  }
1850
- } else if (r === "adaptSlotCustomProperty" && S(u.key) && n.type === "comp") {
1875
+ } else if (r === "adaptSlotCustomProperty" && L(u.key) && n.type === "comp") {
1851
1876
  const { compId: h, slotId: p, propertyId: f } = Je(l), T = s[h];
1852
1877
  if (T && T.meta.slots) {
1853
1878
  const E = T.meta.slots.find((y) => y.id === p);
@@ -1868,7 +1893,7 @@ function Nt(t) {
1868
1893
  }
1869
1894
  }
1870
1895
  }
1871
- function po(t, e) {
1896
+ function _o(t, e) {
1872
1897
  const n = [], o = Wt(t, e);
1873
1898
  for (const { id: s, kind: a, names: r } of o)
1874
1899
  n.push([Qn(a, r), s]);
@@ -1885,7 +1910,7 @@ function _e(t) {
1885
1910
  if (e.type === "comp")
1886
1911
  return o.meta.states?.find((s) => s.id === t);
1887
1912
  }
1888
- function ho() {
1913
+ function po() {
1889
1914
  const t = [], e = hn();
1890
1915
  for (const { id: n, name: o } of e)
1891
1916
  t.push([o, n]);
@@ -1934,7 +1959,7 @@ const Js = {
1934
1959
  }, 0);
1935
1960
  },
1936
1961
  genNodeOpts_: function() {
1937
- return Ne("onEvent");
1962
+ return Se("onEvent");
1938
1963
  },
1939
1964
  genEventOpts_: function() {
1940
1965
  return ws(this.node.id);
@@ -2052,7 +2077,7 @@ const qs = {
2052
2077
  initData_: function() {
2053
2078
  if (this.event.id)
2054
2079
  return;
2055
- const t = uo()?.[0];
2080
+ const t = ro()?.[0];
2056
2081
  if (!t)
2057
2082
  return;
2058
2083
  this.event.id = t.id, this.event.kind = t.kind, this.event.names = t.names, this.event.params = t.params;
@@ -2161,7 +2186,7 @@ g([
2161
2186
  }
2162
2187
  ]);
2163
2188
  i.forBlock.watch_effect_v1 = function(t) {
2164
- const e = xo(t.id), n = i.statementToCode(t, "HANDLE");
2189
+ const e = Vo(t.id), n = i.statementToCode(t, "HANDLE");
2165
2190
  return `function __watchEffect$${e}__() {
2166
2191
  ${n}};
2167
2192
  `;
@@ -2200,7 +2225,7 @@ const Qs = {
2200
2225
  }, 0);
2201
2226
  },
2202
2227
  updateShape_: function() {
2203
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_APP_DO}"), this.getInput("RESULT") || (this.appendValueInput("RESULT").appendField("%{BKY_APP_RETURN}"), this.moveInputBefore("RESULT", "HANDLE")), this.getInput("TEXT") || (this.appendValueInput("TEXT").setCheck("String").setAlign(N.Align.RIGHT).appendField("%{BKY_APP_TEXT}"), this.moveInputBefore("TEXT", "RESULT")), this.getInput("TITLE") || (this.appendValueInput("TITLE").setCheck("String").setAlign(N.Align.RIGHT).appendField("%{BKY_APP_TITLE}"), this.moveInputBefore("TITLE", "TEXT"));
2228
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_APP_DO}"), this.getInput("RESULT") || (this.appendValueInput("RESULT").appendField("%{BKY_APP_RETURN}"), this.moveInputBefore("RESULT", "HANDLE")), this.getInput("TEXT") || (this.appendValueInput("TEXT").setCheck("String").setAlign(S.Align.RIGHT).appendField("%{BKY_APP_TEXT}"), this.moveInputBefore("TEXT", "RESULT")), this.getInput("TITLE") || (this.appendValueInput("TITLE").setCheck("String").setAlign(S.Align.RIGHT).appendField("%{BKY_APP_TITLE}"), this.moveInputBefore("TITLE", "TEXT"));
2204
2229
  },
2205
2230
  updateShadow_: function() {
2206
2231
  if (this.isInsertionMarker())
@@ -2237,7 +2262,7 @@ const zs = {
2237
2262
  }, 0);
2238
2263
  },
2239
2264
  updateShape_: function() {
2240
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_APP_DO}"), this.getInput("RESULT") || (this.appendValueInput("RESULT").appendField("%{BKY_APP_RETURN}"), this.moveInputBefore("RESULT", "HANDLE")), this.getInput("VALUE") || (this.appendValueInput("VALUE").setCheck("String").setAlign(N.Align.RIGHT).appendField("%{BKY_APP_VALUE}"), this.moveInputBefore("VALUE", "RESULT")), this.getInput("LABEL") || (this.appendValueInput("LABEL").setCheck("String").setAlign(N.Align.RIGHT).appendField("%{BKY_APP_LABEL}"), this.moveInputBefore("LABEL", "VALUE")), this.getInput("TITLE") || (this.appendValueInput("TITLE").setCheck("String").setAlign(N.Align.RIGHT).appendField("%{BKY_APP_TITLE}"), this.moveInputBefore("TITLE", "LABEL"));
2265
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_APP_DO}"), this.getInput("RESULT") || (this.appendValueInput("RESULT").appendField("%{BKY_APP_RETURN}"), this.moveInputBefore("RESULT", "HANDLE")), this.getInput("VALUE") || (this.appendValueInput("VALUE").setCheck("String").setAlign(S.Align.RIGHT).appendField("%{BKY_APP_VALUE}"), this.moveInputBefore("VALUE", "RESULT")), this.getInput("LABEL") || (this.appendValueInput("LABEL").setCheck("String").setAlign(S.Align.RIGHT).appendField("%{BKY_APP_LABEL}"), this.moveInputBefore("LABEL", "VALUE")), this.getInput("TITLE") || (this.appendValueInput("TITLE").setCheck("String").setAlign(S.Align.RIGHT).appendField("%{BKY_APP_TITLE}"), this.moveInputBefore("TITLE", "LABEL"));
2241
2266
  },
2242
2267
  updateShadow_: function() {
2243
2268
  if (this.isInsertionMarker())
@@ -2338,7 +2363,7 @@ const Zs = {
2338
2363
  }, 0);
2339
2364
  },
2340
2365
  genNodeOpts_: function() {
2341
- return Ne("callMethod");
2366
+ return Se("callMethod");
2342
2367
  },
2343
2368
  genMethodOpts_: function() {
2344
2369
  return $s(this.node.id);
@@ -2392,10 +2417,10 @@ const Zs = {
2392
2417
  if (this.method.inputs)
2393
2418
  for (let t = 0; t < this.method.inputs.length; t++) {
2394
2419
  const e = this.method.inputs[t];
2395
- this.getInput("INPUT" + t) || (this.appendValueInput("INPUT" + t).setAlign(N.Align.RIGHT).appendField(m(e.name)), this.method.outputs && this.method.outputs.length > 0 && this.moveInputBefore("INPUT" + t, "OUTPUT0"));
2420
+ this.getInput("INPUT" + t) || (this.appendValueInput("INPUT" + t).setAlign(S.Align.RIGHT).appendField(m(e.name)), this.method.outputs && this.method.outputs.length > 0 && this.moveInputBefore("INPUT" + t, "OUTPUT0"));
2396
2421
  }
2397
2422
  if (this.method.kind === "multipleRefMethod")
2398
- this.getInput("REF_KEY") || this.appendValueInput("REF_KEY").setAlign(N.Align.RIGHT).appendField(m("BKY_APP_REF_KEY")), this.method.inputs && this.method.inputs.length > 0 ? this.moveInputBefore("REF_KEY", "INPUT0") : this.method.outputs && this.method.outputs.length > 0 && this.moveInputBefore("REF_KEY", "OUTPUT0");
2423
+ this.getInput("REF_KEY") || this.appendValueInput("REF_KEY").setAlign(S.Align.RIGHT).appendField(m("BKY_APP_REF_KEY")), this.method.inputs && this.method.inputs.length > 0 ? this.moveInputBefore("REF_KEY", "INPUT0") : this.method.outputs && this.method.outputs.length > 0 && this.moveInputBefore("REF_KEY", "OUTPUT0");
2399
2424
  else if (this.getInput("REF_KEY")) {
2400
2425
  const t = this.getInput("REF_KEY").connection.targetBlock();
2401
2426
  t && t.dispose(), this.removeInput("REF_KEY");
@@ -2546,7 +2571,7 @@ const ti = {
2546
2571
  }, 0);
2547
2572
  },
2548
2573
  genMethodOpts_: function() {
2549
- return lo();
2574
+ return uo();
2550
2575
  },
2551
2576
  onchange: function(t) {
2552
2577
  if (t.type === U.STATE_CHANGE)
@@ -2662,7 +2687,7 @@ const ei = {
2662
2687
  }, 0);
2663
2688
  },
2664
2689
  genMethodOpts_: function() {
2665
- return lo();
2690
+ return uo();
2666
2691
  },
2667
2692
  genOutputOpts_: function() {
2668
2693
  return Hs(this.method.id);
@@ -2881,14 +2906,14 @@ i.forBlock.navigate_to_v1 = function(t) {
2881
2906
  const oi = {
2882
2907
  init: function() {
2883
2908
  this.comp = {
2884
- id: void 0,
2909
+ id: "",
2885
2910
  name: ""
2886
2911
  }, this.appendDummyInput().appendField("%{BKY_APP_V1_SELECT_COMP_TITLE}").appendField(new v(() => this.genCompOpts_()), "COMP"), this.setOutput(!0, "Comp"), this.setStyle("property_blocks"), this.setTooltip("%{BKY_APP_V1_SELECT_COMP_TOOLTIP}"), this.setHelpUrl("%{BKY_APP_V1_SELECT_COMP_HELPURL}"), this.initData_();
2887
2912
  },
2888
2913
  initData_: function() {
2889
- if (this.comp.id !== void 0)
2914
+ if (this.comp.id)
2890
2915
  return;
2891
- const t = ro()?.[0];
2916
+ const t = co()?.[0];
2892
2917
  if (!t)
2893
2918
  return;
2894
2919
  this.comp.id = t.id, this.comp.name = t.name;
@@ -2920,22 +2945,15 @@ const oi = {
2920
2945
  },
2921
2946
  onCompChange_: function(t) {
2922
2947
  const e = Dn(t);
2923
- if (!e) {
2924
- console.assert(!1);
2925
- return;
2926
- }
2927
- this.comp.id = e.id, this.comp.name = e.name;
2948
+ e ? (this.comp.id = e.id, this.comp.name = e.name) : (this.comp.id = "", this.comp.name = "");
2928
2949
  },
2929
2950
  checkWarning_: function() {
2930
- if (this.comp.id === void 0) {
2931
- this.setWarningText(m("WARN_COMP_NOT_FOUND"));
2932
- return;
2933
- }
2934
- if (!Dn(this.comp.id)) {
2951
+ const t = Dn(this.comp.id);
2952
+ if (!t) {
2935
2953
  this.setWarningText(m("WARN_COMP_NOT_FOUND"));
2936
2954
  return;
2937
2955
  }
2938
- this.setWarningText(null);
2956
+ t.name !== this.comp.name && (this.comp.name = t.name), this.setWarningText(null);
2939
2957
  }
2940
2958
  };
2941
2959
  A.select_comp_v1 = oi;
@@ -2986,10 +3004,10 @@ const si = {
2986
3004
  }, 0);
2987
3005
  },
2988
3006
  genNodeOpts_: function() {
2989
- return Ne("getProperty");
3007
+ return Se("getProperty");
2990
3008
  },
2991
3009
  genPropertyOpts_: function() {
2992
- return po(this.node.id, "read");
3010
+ return _o(this.node.id, "read");
2993
3011
  },
2994
3012
  onchange: function(t) {
2995
3013
  if (t.type === U.STATE_CHANGE)
@@ -3010,14 +3028,14 @@ const si = {
3010
3028
  const n = this.node.key !== e.key;
3011
3029
  this.node.id = e.id, this.node.key = e.key, this.node.alias = e.alias;
3012
3030
  const o = this.getField("PROPERTY");
3013
- if (o.getOptions(!1), n || !Nt(this.property.id)) {
3031
+ if (o.getOptions(!1), n || !St(this.property.id)) {
3014
3032
  const s = Wt(this.node.id, "read")?.[0];
3015
3033
  o.setValue(s?.id ?? "");
3016
3034
  }
3017
3035
  this.onPropChange_(o.getValue());
3018
3036
  },
3019
3037
  onPropChange_: function(t) {
3020
- const e = Nt(t);
3038
+ const e = St(t);
3021
3039
  e ? (this.property.id = e.id, this.property.kind = e.kind, this.property.names = e.names) : (this.property.id = "", this.property.kind = "", this.property.names = []);
3022
3040
  },
3023
3041
  checkWarning_: function() {
@@ -3031,7 +3049,7 @@ const si = {
3031
3049
  return;
3032
3050
  }
3033
3051
  t.alias !== this.node.alias && (this.node.alias = t.alias);
3034
- const e = Nt(this.property.id);
3052
+ const e = St(this.property.id);
3035
3053
  if (!e) {
3036
3054
  this.setWarningText(m("WARN_PROPERTY_NOT_FOUND"));
3037
3055
  return;
@@ -3091,10 +3109,10 @@ const ii = {
3091
3109
  }, 0);
3092
3110
  },
3093
3111
  genNodeOpts_: function() {
3094
- return Ne("setProperty");
3112
+ return Se("setProperty");
3095
3113
  },
3096
3114
  genPropertyOpts_: function() {
3097
- return po(this.node.id, "write");
3115
+ return _o(this.node.id, "write");
3098
3116
  },
3099
3117
  onchange: function(t) {
3100
3118
  if (t.type === U.STATE_CHANGE)
@@ -3115,26 +3133,26 @@ const ii = {
3115
3133
  const n = this.node.key !== e.key;
3116
3134
  this.node.id = e.id, this.node.key = e.key, this.node.alias = e.alias;
3117
3135
  const o = this.getField("PROPERTY");
3118
- if (o.getOptions(!1), n || !Nt(this.property.id)) {
3136
+ if (o.getOptions(!1), n || !St(this.property.id)) {
3119
3137
  const s = Wt(this.node.id, "write")?.[0];
3120
3138
  o.setValue(s?.id ?? "");
3121
3139
  }
3122
3140
  this.onPropChange_(o.getValue());
3123
3141
  },
3124
3142
  onPropChange_: function(t) {
3125
- const e = Nt(t);
3143
+ const e = St(t);
3126
3144
  e ? (this.property.id = e.id, this.property.kind = e.kind, this.property.names = e.names) : (this.property.id = "", this.property.kind = "", this.property.names = []), this.updateShadow_();
3127
3145
  },
3128
3146
  updateShadow_: function() {
3129
3147
  if (this.isInsertionMarker())
3130
3148
  return;
3131
- const t = Nt(this.property.id);
3149
+ const t = St(this.property.id);
3132
3150
  if (!t)
3133
3151
  return;
3134
3152
  this.getInput("VALUE").setShadowDom(null);
3135
3153
  const e = this.getInput("VALUE").connection.targetBlock();
3136
3154
  if (e && e.dispose(), t.meta.element) {
3137
- const n = Is(t.meta.raw), o = Ss(t.meta.raw);
3155
+ const n = As(t.meta.raw), o = Ns(t.meta.raw);
3138
3156
  this.getInput("VALUE").setCheck(n).setShadowDom(o);
3139
3157
  } else {
3140
3158
  const n = yt(t.meta.raw.type), o = Ot(t.meta.raw.type);
@@ -3152,7 +3170,7 @@ const ii = {
3152
3170
  return;
3153
3171
  }
3154
3172
  t.alias !== this.node.alias && (this.node.alias = t.alias);
3155
- const e = Nt(this.property.id);
3173
+ const e = St(this.property.id);
3156
3174
  if (!e) {
3157
3175
  this.setWarningText(m("WARN_PROPERTY_NOT_FOUND"));
3158
3176
  return;
@@ -3202,7 +3220,7 @@ const ai = {
3202
3220
  }, 0);
3203
3221
  },
3204
3222
  genStateOpts_: function() {
3205
- return ho();
3223
+ return po();
3206
3224
  },
3207
3225
  onchange: function(t) {
3208
3226
  if (t.type === U.STATE_CHANGE)
@@ -3264,7 +3282,7 @@ const ci = {
3264
3282
  this.state.id = t.state?.id ?? "", this.state.name = t.state?.name ?? "", this.state.type = t.state?.type ?? "string";
3265
3283
  },
3266
3284
  genStateOpts_: function() {
3267
- return ho();
3285
+ return po();
3268
3286
  },
3269
3287
  onchange: function(t) {
3270
3288
  if (t.type === O.BLOCK_CHANGE) {
@@ -4007,7 +4025,7 @@ function ${i.FUNCTION_NAME_PLACEHOLDER_}(r, g, b) {
4007
4025
  `
4008
4026
  )}(${e}, ${n}, ${o})`, _.FUNCTION_CALL];
4009
4027
  };
4010
- const ri = L.xml, ui = [
4028
+ const ri = N.xml, ui = [
4011
4029
  {
4012
4030
  type: "add_data_v1",
4013
4031
  inputs: ["SUCCESS", "MESSAGE", "DATA"]
@@ -4126,7 +4144,7 @@ const _i = {
4126
4144
  },
4127
4145
  updateShape_: function() {
4128
4146
  if (this.locale) {
4129
- const { i18n: t } = St;
4147
+ const { i18n: t } = Nt;
4130
4148
  this.setFieldValue(t.global.t(this.name), "LABEL");
4131
4149
  } else
4132
4150
  this.setFieldValue(this.name, "LABEL");
@@ -4154,7 +4172,7 @@ function Dt(t, e) {
4154
4172
  if (n)
4155
4173
  return n.funcs.find((o) => o.id === e);
4156
4174
  }
4157
- function fo(t) {
4175
+ function ho(t) {
4158
4176
  const e = [];
4159
4177
  return jt(t).forEach(({ id: o, name: s }) => {
4160
4178
  e.push([s, o]);
@@ -4182,7 +4200,7 @@ function Zt(t) {
4182
4200
  function pe(t) {
4183
4201
  return I.compute.spaces.find((e) => e.id === t);
4184
4202
  }
4185
- function mo(t) {
4203
+ function fo(t) {
4186
4204
  const e = [];
4187
4205
  return Zt(t).forEach(({ id: o, name: s }) => {
4188
4206
  e.push([s, o]);
@@ -4231,10 +4249,10 @@ const hi = {
4231
4249
  }, 0);
4232
4250
  },
4233
4251
  genSpaceOpts_: function() {
4234
- return mo("func");
4252
+ return fo("func");
4235
4253
  },
4236
4254
  genFuncOpts_: function() {
4237
- return fo(this.space.id);
4255
+ return ho(this.space.id);
4238
4256
  },
4239
4257
  onchange: function(t) {
4240
4258
  if (t.type === U.STATE_CHANGE)
@@ -4286,7 +4304,7 @@ const hi = {
4286
4304
  }
4287
4305
  for (let t = 0; t < this.func.inputs.length; t++) {
4288
4306
  const { name: e } = this.func.inputs[t], n = this.getInput("INPUT" + t);
4289
- n ? (this.setFieldValue(e, "NAME" + t), n.setCheck(null)) : (this.appendValueInput("INPUT" + t).setAlign(N.Align.RIGHT).appendField(e, "NAME" + t).setCheck(null), this.getInput("OUTPUT0") ? this.moveInputBefore("INPUT" + t, "OUTPUT0") : this.moveInputBefore("INPUT" + t, "CALLBACK"));
4307
+ n ? (this.setFieldValue(e, "NAME" + t), n.setCheck(null)) : (this.appendValueInput("INPUT" + t).setAlign(S.Align.RIGHT).appendField(e, "NAME" + t).setCheck(null), this.getInput("OUTPUT0") ? this.moveInputBefore("INPUT" + t, "OUTPUT0") : this.moveInputBefore("INPUT" + t, "CALLBACK"));
4290
4308
  }
4291
4309
  },
4292
4310
  updateCheck_: function() {
@@ -4405,10 +4423,10 @@ const fi = {
4405
4423
  }, 0);
4406
4424
  },
4407
4425
  genSpaceOpts_: function() {
4408
- return mo("func");
4426
+ return fo("func");
4409
4427
  },
4410
4428
  genFuncOpts_: function() {
4411
- return fo(this.space.id);
4429
+ return ho(this.space.id);
4412
4430
  },
4413
4431
  onchange: function(t) {
4414
4432
  if (t.type === U.STATE_CHANGE)
@@ -4460,7 +4478,7 @@ const fi = {
4460
4478
  }
4461
4479
  for (let t = 0; t < this.func.inputs.length; t++) {
4462
4480
  const { name: e } = this.func.inputs[t], n = this.getInput("INPUT" + t);
4463
- n ? (this.setFieldValue(e, "NAME" + t), n.setCheck(null)) : (this.appendValueInput("INPUT" + t).setAlign(N.Align.RIGHT).appendField(e, "NAME" + t).setCheck(null), this.getInput("OUTPUT0") ? this.moveInputBefore("INPUT" + t, "OUTPUT0") : this.moveInputBefore("INPUT" + t, "CALLBACK"));
4481
+ n ? (this.setFieldValue(e, "NAME" + t), n.setCheck(null)) : (this.appendValueInput("INPUT" + t).setAlign(S.Align.RIGHT).appendField(e, "NAME" + t).setCheck(null), this.getInput("OUTPUT0") ? this.moveInputBefore("INPUT" + t, "OUTPUT0") : this.moveInputBefore("INPUT" + t, "CALLBACK"));
4464
4482
  }
4465
4483
  },
4466
4484
  updateCheck_: function() {
@@ -4763,7 +4781,7 @@ function At(t) {
4763
4781
  const { spaces: e } = I.data;
4764
4782
  return e.find((n) => n.id === t);
4765
4783
  }
4766
- function Se() {
4784
+ function Ne() {
4767
4785
  const t = [];
4768
4786
  return at().forEach(({ id: n, name: o }) => {
4769
4787
  t.push([o, n]);
@@ -4876,7 +4894,7 @@ const Ii = {
4876
4894
  }, 0);
4877
4895
  },
4878
4896
  updateShape_: function() {
4879
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("DATA") || (this.appendValueInput("DATA"), this.moveInputBefore("DATA", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_DATA_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck("UpdateColumn").setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "SUCCESS"));
4897
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("DATA") || (this.appendValueInput("DATA"), this.moveInputBefore("DATA", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_DATA_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck("UpdateColumn").setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "SUCCESS"));
4880
4898
  },
4881
4899
  ensureBlocks_: function() {
4882
4900
  this.isInsertionMarker() || (gi(this), j(this, [
@@ -4965,7 +4983,7 @@ const yi = {
4965
4983
  }, 0);
4966
4984
  },
4967
4985
  genSpaceOpts_: function() {
4968
- return Se();
4986
+ return Ne();
4969
4987
  },
4970
4988
  genTableOpts_: function() {
4971
4989
  return Le(this.space.id);
@@ -5190,7 +5208,7 @@ function ki(t) {
5190
5208
  }, a = J.blocks.append(s, t.workspace);
5191
5209
  e.connect(a.outputConnection);
5192
5210
  }
5193
- function Ni(t) {
5211
+ function Si(t) {
5194
5212
  const e = t.getInput("CONDITION").connection;
5195
5213
  if (e.targetBlock())
5196
5214
  return;
@@ -5215,7 +5233,7 @@ function Ni(t) {
5215
5233
  }, r = J.blocks.append(a, t.workspace);
5216
5234
  e.connect(r.outputConnection);
5217
5235
  }
5218
- function Si(t) {
5236
+ function Ni(t) {
5219
5237
  const e = t.getInput("HANDLE").connection;
5220
5238
  if (e.targetBlock())
5221
5239
  return;
@@ -5252,13 +5270,13 @@ const Li = {
5252
5270
  }, 0);
5253
5271
  },
5254
5272
  updateShape_: function() {
5255
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "HANDLE")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("CONDITION") || (this.appendValueInput("CONDITION").setCheck("Condition").setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_CONDITION}"), this.moveInputBefore("CONDITION", "SUCCESS")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck("SelectTable").setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "CONDITION"));
5273
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "HANDLE")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("CONDITION") || (this.appendValueInput("CONDITION").setCheck("Condition").setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_CONDITION}"), this.moveInputBefore("CONDITION", "SUCCESS")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck("SelectTable").setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "CONDITION"));
5256
5274
  },
5257
5275
  ensureBlocks_: function() {
5258
- this.isInsertionMarker() || (ki(this), Ni(this), j(this, [
5276
+ this.isInsertionMarker() || (ki(this), Si(this), j(this, [
5259
5277
  ["SUCCESS", "__success__", "x-runtime-lib.success", !0],
5260
5278
  ["MESSAGE", "__message__", "x-runtime-lib.message", !0]
5261
- ]), Si(this));
5279
+ ]), Ni(this));
5262
5280
  }
5263
5281
  };
5264
5282
  A.delete_data_v1 = Li;
@@ -5430,7 +5448,7 @@ const Di = {
5430
5448
  }, 0);
5431
5449
  },
5432
5450
  updateShape_: function() {
5433
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("EXTRA_DATA") || (this.appendValueInput("EXTRA_DATA"), this.moveInputBefore("EXTRA_DATA", "HANDLE")), this.getInput("MAIN_DATA") || (this.appendValueInput("MAIN_DATA"), this.moveInputBefore("MAIN_DATA", "EXTRA_DATA")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "MAIN_DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_DATA_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("EXTRA") || (this.appendValueInput("EXTRA").setCheck(["QueryExtra", "Array"]).setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_EXTRA}"), this.moveInputBefore("EXTRA", "SUCCESS")), this.getInput("CONDITION") || (this.appendValueInput("CONDITION").setCheck("Condition").setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_CONDITION}"), this.moveInputBefore("CONDITION", "EXTRA")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck(["SelectColumn", "Array"]).setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "CONDITION"));
5451
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("EXTRA_DATA") || (this.appendValueInput("EXTRA_DATA"), this.moveInputBefore("EXTRA_DATA", "HANDLE")), this.getInput("MAIN_DATA") || (this.appendValueInput("MAIN_DATA"), this.moveInputBefore("MAIN_DATA", "EXTRA_DATA")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "MAIN_DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_DATA_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("EXTRA") || (this.appendValueInput("EXTRA").setCheck(["QueryExtra", "Array"]).setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_EXTRA}"), this.moveInputBefore("EXTRA", "SUCCESS")), this.getInput("CONDITION") || (this.appendValueInput("CONDITION").setCheck("Condition").setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_CONDITION}"), this.moveInputBefore("CONDITION", "EXTRA")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck(["SelectColumn", "Array"]).setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "CONDITION"));
5434
5452
  },
5435
5453
  ensureBlocks_: function() {
5436
5454
  this.isInsertionMarker() || (Bi(this), bi(this), Pi(this), j(this, [
@@ -5577,7 +5595,7 @@ const Vi = {
5577
5595
  }, 0);
5578
5596
  },
5579
5597
  genSpaceOpts_: function() {
5580
- return Se();
5598
+ return Ne();
5581
5599
  },
5582
5600
  genTableOpts_: function() {
5583
5601
  return Le(this.space.id);
@@ -5699,7 +5717,7 @@ const Vi = {
5699
5717
  const e = this.table.columns[t], n = new v(
5700
5718
  () => this.genColumnOpts_()
5701
5719
  ), o = new Et("");
5702
- this.appendDummyInput("ADD" + t).setAlign(N.Align.RIGHT).appendField(n, "COLUMN" + t).appendField("%{BKY_DATA_AS}").appendField(o, "ALIAS" + t), n.setValue(e.id, !1), o.setValue(e.name, !1);
5720
+ this.appendDummyInput("ADD" + t).setAlign(S.Align.RIGHT).appendField(n, "COLUMN" + t).appendField("%{BKY_DATA_AS}").appendField(o, "ALIAS" + t), n.setValue(e.id, !1), o.setValue(e.name, !1);
5703
5721
  }
5704
5722
  },
5705
5723
  updateShape_: function() {
@@ -5711,7 +5729,7 @@ const Vi = {
5711
5729
  const e = new v(
5712
5730
  () => this.genColumnOpts_()
5713
5731
  ), n = new Et("");
5714
- this.appendDummyInput("ADD" + t).setAlign(N.Align.RIGHT).appendField(e, "COLUMN" + t).appendField("%{BKY_DATA_AS}").appendField(n, "ALIAS" + t);
5732
+ this.appendDummyInput("ADD" + t).setAlign(S.Align.RIGHT).appendField(e, "COLUMN" + t).appendField("%{BKY_DATA_AS}").appendField(n, "ALIAS" + t);
5715
5733
  const o = this.table.columns[0];
5716
5734
  e.setValue(o.id ?? "", !1), n.setValue(o.name ?? "", !1);
5717
5735
  }
@@ -5789,7 +5807,7 @@ const xi = {
5789
5807
  this.space.id = t.space?.id ?? "", this.space.name = t.space?.name ?? "", this.table.id = t.table?.id ?? "", this.table.name = t.table?.name ?? "", this.checkWarning_();
5790
5808
  },
5791
5809
  genSpaceOpts_: function() {
5792
- return Se();
5810
+ return Ne();
5793
5811
  },
5794
5812
  genTableOpts_: function() {
5795
5813
  return Le(this.space.id);
@@ -5868,7 +5886,7 @@ const Yi = {
5868
5886
  };
5869
5887
  A.transaction_v1 = Yi;
5870
5888
  i.forBlock.transaction_v1 = function(t) {
5871
- const e = i.INDENT, n = t, o = gs(n), s = i.statementToCode(n, "HANDLE"), a = i.statementToCode(n, "FINALLY");
5889
+ const e = i.INDENT, n = t, o = Es(n), s = i.statementToCode(n, "HANDLE"), a = i.statementToCode(n, "FINALLY");
5872
5890
  return `{
5873
5891
  ${e}var __error${o}__ = '';
5874
5892
  ${e}var __txExist${o}__ = typeof(__tx__) !== 'undefined';
@@ -5973,7 +5991,7 @@ const Ki = {
5973
5991
  }, 0);
5974
5992
  },
5975
5993
  genSpaceOpts_: function() {
5976
- return Se();
5994
+ return Ne();
5977
5995
  },
5978
5996
  genTableOpts_: function() {
5979
5997
  return Le(this.space.id);
@@ -6105,7 +6123,7 @@ const Ki = {
6105
6123
  const e = this.table.columns[t], n = new v(
6106
6124
  () => this.genColumnOpts_()
6107
6125
  );
6108
- this.appendValueInput("ADD" + t).setAlign(N.Align.RIGHT).appendField(n, "COLUMN" + t), n.setValue(e.id, !1);
6126
+ this.appendValueInput("ADD" + t).setAlign(S.Align.RIGHT).appendField(n, "COLUMN" + t), n.setValue(e.id, !1);
6109
6127
  }
6110
6128
  },
6111
6129
  updateShape_: function() {
@@ -6119,7 +6137,7 @@ const Ki = {
6119
6137
  const e = new v(
6120
6138
  () => this.genColumnOpts_()
6121
6139
  );
6122
- this.appendValueInput("ADD" + t).setAlign(N.Align.RIGHT).appendField(e, "COLUMN" + t);
6140
+ this.appendValueInput("ADD" + t).setAlign(S.Align.RIGHT).appendField(e, "COLUMN" + t);
6123
6141
  }
6124
6142
  },
6125
6143
  updateBlocks_: function(t) {
@@ -6258,7 +6276,7 @@ const Wi = {
6258
6276
  }, 0);
6259
6277
  },
6260
6278
  updateShape_: function() {
6261
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("DATA") || (this.appendValueInput("DATA"), this.moveInputBefore("DATA", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_DATA_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("CONDITION") || (this.appendValueInput("CONDITION").setCheck("Condition").setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_CONDITION}"), this.moveInputBefore("CONDITION", "SUCCESS")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck("UpdateColumn").setAlign(N.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "CONDITION"));
6279
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_DATA_DO}"), this.getInput("DATA") || (this.appendValueInput("DATA"), this.moveInputBefore("DATA", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_DATA_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("CONDITION") || (this.appendValueInput("CONDITION").setCheck("Condition").setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_CONDITION}"), this.moveInputBefore("CONDITION", "SUCCESS")), this.getInput("TABLE") || (this.appendValueInput("TABLE").setCheck("UpdateColumn").setAlign(S.Align.RIGHT).appendField("%{BKY_DATA_TABLE}"), this.moveInputBefore("TABLE", "CONDITION"));
6262
6280
  },
6263
6281
  ensureBlocks: function() {
6264
6282
  this.isInsertionMarker() || ($i(this), Hi(this), j(this, [
@@ -6285,9 +6303,9 @@ ${e}}
6285
6303
  ${s}}
6286
6304
  `;
6287
6305
  };
6288
- const ji = L.xml, Xi = {
6306
+ const ji = N.xml, Xi = {
6289
6307
  init: function() {
6290
- this.length = 0, this.appendDummyInput("OPEN_BRACKET").appendField(" [ "), this.appendDummyInput("ADD").setAlign(N.Align.CENTRE).appendField(
6308
+ this.length = 0, this.appendDummyInput("OPEN_BRACKET").appendField(" [ "), this.appendDummyInput("ADD").setAlign(S.Align.CENTRE).appendField(
6291
6309
  new ct(Rt, 20, 20, void 0, () => {
6292
6310
  this.isInFlyout || this.addEntry_();
6293
6311
  })
@@ -6359,9 +6377,9 @@ const Ji = {
6359
6377
  }
6360
6378
  };
6361
6379
  A.json_boolean_v1 = Ji;
6362
- const Vn = L.xml, qi = {
6380
+ const Vn = N.xml, qi = {
6363
6381
  init: function() {
6364
- this.length = 0, this.appendDummyInput("OPEN_BRACKET").appendField(" { "), this.appendDummyInput("ADD").setAlign(N.Align.CENTRE).appendField(
6382
+ this.length = 0, this.appendDummyInput("OPEN_BRACKET").appendField(" { "), this.appendDummyInput("ADD").setAlign(S.Align.CENTRE).appendField(
6365
6383
  new ct(Rt, 20, 20, void 0, () => {
6366
6384
  this.isInFlyout || this.addEntry_();
6367
6385
  })
@@ -6434,7 +6452,7 @@ const Qi = {
6434
6452
  A.json_number_v1 = Qi;
6435
6453
  const zi = {
6436
6454
  init: function() {
6437
- this.appendDummyInput().setAlign(N.Align.CENTRE).appendField("JSON"), this.appendValueInput("JSON").setCheck(["JsonMap", "JsonArray"]), this.setDeletable(!1), this.setColour(250), this.setTooltip(""), this.setHelpUrl("");
6455
+ this.appendDummyInput().setAlign(S.Align.CENTRE).appendField("JSON"), this.appendValueInput("JSON").setCheck(["JsonMap", "JsonArray"]), this.setDeletable(!1), this.setColour(250), this.setTooltip(""), this.setHelpUrl("");
6438
6456
  }
6439
6457
  };
6440
6458
  A.json_root_v1 = zi;
@@ -6444,7 +6462,7 @@ const Zi = {
6444
6462
  }
6445
6463
  };
6446
6464
  A.json_string_v1 = Zi;
6447
- const ta = L.xml, ea = {
6465
+ const ta = N.xml, ea = {
6448
6466
  init: function() {
6449
6467
  this.appendDummyInput().appendField("%{BKY_LIST_V1_CREATE_CONTAINER_TITLE}"), this.appendStatementInput("STACK"), this.setStyle("list_blocks"), this.contextMenu = !1;
6450
6468
  }
@@ -6533,7 +6551,7 @@ const oa = {
6533
6551
  "Boolean",
6534
6552
  "Array",
6535
6553
  "Object"
6536
- ]), t === 0 && this.getInput("ADD" + t).setAlign(N.Align.RIGHT).appendField("%{BKY_LIST_V1_CREATE_TITLE}"));
6554
+ ]), t === 0 && this.getInput("ADD" + t).setAlign(S.Align.RIGHT).appendField("%{BKY_LIST_V1_CREATE_TITLE}"));
6537
6555
  for (let t = this.itemCount_; this.getInput("ADD" + t); t++)
6538
6556
  this.removeInput("ADD" + t);
6539
6557
  }
@@ -6869,7 +6887,7 @@ const aa = {
6869
6887
  mutationToDom: function() {
6870
6888
  if (this.elseIfCount_ <= 0 && !this.hasElse_)
6871
6889
  return null;
6872
- const t = L.xml.createElement("mutation");
6890
+ const t = N.xml.createElement("mutation");
6873
6891
  return this.elseIfCount_ > 0 && t.setAttribute("elseIf", String(this.elseIfCount_)), this.hasElse_ && t.setAttribute("else", "TRUE"), t;
6874
6892
  },
6875
6893
  domToMutation: function(t) {
@@ -7356,7 +7374,7 @@ i.forBlock.for_v1 = function(t) {
7356
7374
  i.statementToCode(t, "DO"),
7357
7375
  t
7358
7376
  );
7359
- if (L.string.isNumber(o) && L.string.isNumber(s) && L.string.isNumber(a)) {
7377
+ if (N.string.isNumber(o) && N.string.isNumber(s) && N.string.isNumber(a)) {
7360
7378
  const c = Math.abs(Number(a));
7361
7379
  return Number(o) <= Number(s) ? `for (${n} = ${o}; ${n} <= ${s}; ${n} += ${c}) {
7362
7380
  ${r}}
@@ -7365,13 +7383,13 @@ ${r}}
7365
7383
  `;
7366
7384
  } else {
7367
7385
  let c = "", l = o;
7368
- !o.match(/^\w+$/) && !L.string.isNumber(o) && (l = i.nameDB_.getDistinctName(
7386
+ !o.match(/^\w+$/) && !N.string.isNumber(o) && (l = i.nameDB_.getDistinctName(
7369
7387
  `${n}_from`,
7370
7388
  rt.NameType.VARIABLE
7371
7389
  ), c += `var ${l} = ${o};
7372
7390
  `);
7373
7391
  let d = s;
7374
- !s.match(/^\w+$/) && !L.string.isNumber(s) && (d = i.nameDB_.getDistinctName(
7392
+ !s.match(/^\w+$/) && !N.string.isNumber(s) && (d = i.nameDB_.getDistinctName(
7375
7393
  `${n}_to`,
7376
7394
  rt.NameType.VARIABLE
7377
7395
  ), c += `var ${d} = ${s};
@@ -7380,7 +7398,7 @@ ${r}}
7380
7398
  `${n}_by`,
7381
7399
  rt.NameType.VARIABLE
7382
7400
  );
7383
- return c += `var ${u} = `, L.string.isNumber(a) ? c += `${Math.abs(Number(a))};
7401
+ return c += `var ${u} = `, N.string.isNumber(a) ? c += `${Math.abs(Number(a))};
7384
7402
  ` : c += `Math.abs(${a});
7385
7403
  `, c += `if (${l} > ${d}) {
7386
7404
  ${e}${u} = -${u};
@@ -7487,7 +7505,7 @@ i.forBlock.repeat_v1 = function(t) {
7487
7505
  rt.NameType.VARIABLE
7488
7506
  );
7489
7507
  let a = e;
7490
- return !e.match(/^\w+$/) && !L.string.isNumber(e) && (a = i.nameDB_.getDistinctName(
7508
+ return !e.match(/^\w+$/) && !N.string.isNumber(e) && (a = i.nameDB_.getDistinctName(
7491
7509
  "repeat_end",
7492
7510
  rt.NameType.VARIABLE
7493
7511
  ), o += `var ${a} = ${e};
@@ -8188,7 +8206,7 @@ i.forBlock.math_trig_v1 = function(t) {
8188
8206
  }
8189
8207
  return [o, _.DIVISION];
8190
8208
  };
8191
- const pa = L.xml, da = {
8209
+ const pa = N.xml, da = {
8192
8210
  init: function() {
8193
8211
  this.appendDummyInput().appendField(
8194
8212
  "%{BKY_OBJECT_V1_CREATE_CONTAINER_TITLE}"
@@ -8271,7 +8289,7 @@ const fa = {
8271
8289
  },
8272
8290
  updateShape_: function() {
8273
8291
  for (let t = 0; t < this.itemCount_; t++)
8274
- this.getInput("ADD" + t) || this.appendValueInput("ADD" + t).setAlign(N.Align.RIGHT).appendField(new Et("key"), "KEY" + t);
8292
+ this.getInput("ADD" + t) || this.appendValueInput("ADD" + t).setAlign(S.Align.RIGHT).appendField(new Et("key"), "KEY" + t);
8275
8293
  for (let t = this.itemCount_; this.getInput("ADD" + t); t++)
8276
8294
  this.removeInput("ADD" + t);
8277
8295
  }
@@ -8518,9 +8536,9 @@ g([
8518
8536
  i.forBlock.object_to_json_v1 = function(t) {
8519
8537
  return [`__jsonStringifyV1__(${i.valueToCode(t, "OBJECT", _.NONE) || "null"})`, _.FUNCTION_CALL];
8520
8538
  };
8521
- const xn = L.xml, ma = {
8539
+ const xn = N.xml, ma = {
8522
8540
  init: function() {
8523
- this.appendDummyInput().appendField("%{BKY_PROCEDURE_V1_DEF_CONTAINER_TITLE}").appendField(new Yo(!1), "WITHRETURN"), this.appendStatementInput("STACK"), this.setStyle("procedure_blocks"), this.contextMenu = !1;
8541
+ this.appendDummyInput().appendField("%{BKY_PROCEDURE_V1_DEF_CONTAINER_TITLE}").appendField(new xo(!1), "WITHRETURN"), this.appendStatementInput("STACK"), this.setStyle("procedure_blocks"), this.contextMenu = !1;
8524
8542
  }
8525
8543
  };
8526
8544
  A.procedure_def_container_v1 = ma;
@@ -8652,7 +8670,7 @@ const Ea = {
8652
8670
  }
8653
8671
  };
8654
8672
  A.procedure_def_v1 = Ea;
8655
- const ga = L.xml, Aa = {
8673
+ const ga = N.xml, Aa = {
8656
8674
  init: function() {
8657
8675
  this.withReturn = !1, this.appendDummyInput("DUMMY").appendField("%{BKY_PROCEDURE_RETURN}"), this.appendValueInput("VALUE").appendField("%{BKY_PROCEDURE_RETURN}").setVisible(!1), this.setPreviousStatement(!0), this.setStyle("procedure_blocks"), this.setTooltip("%{BKY_PROCEDURE_V1_RETURN_TOOLTIP}"), this.setHelpUrl("%{BKY_PROCEDURE_V1_RETURN_HELPURL}");
8658
8676
  },
@@ -8728,7 +8746,7 @@ const Ia = {
8728
8746
  }, 0);
8729
8747
  },
8730
8748
  updateShape_: function() {
8731
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_ASSET_DO}"), this.getInput("DATA") || (this.appendValueInput("DATA"), this.moveInputBefore("DATA", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_ASSET_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("ASSET") || (this.appendValueInput("ASSET").setCheck("Resource").setAlign(N.Align.RIGHT).appendField("%{BKY_ASSET_ASSET}"), this.moveInputBefore("ASSET", "SUCCESS"));
8749
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_ASSET_DO}"), this.getInput("DATA") || (this.appendValueInput("DATA"), this.moveInputBefore("DATA", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "DATA")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_ASSET_RETURN}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("ASSET") || (this.appendValueInput("ASSET").setCheck("Resource").setAlign(S.Align.RIGHT).appendField("%{BKY_ASSET_ASSET}"), this.moveInputBefore("ASSET", "SUCCESS"));
8732
8750
  },
8733
8751
  ensureBlocks_: function() {
8734
8752
  this.isInsertionMarker() || j(this, [
@@ -8750,7 +8768,7 @@ ${n}
8750
8768
  }
8751
8769
  `;
8752
8770
  };
8753
- function To(t) {
8771
+ function mo(t) {
8754
8772
  const e = I.resource.spaces.find((s) => s.id === t);
8755
8773
  if (!e)
8756
8774
  return [];
@@ -8768,11 +8786,11 @@ function To(t) {
8768
8786
  }
8769
8787
  function ya(t) {
8770
8788
  const e = [];
8771
- return To(t).forEach(({ id: o, name: s }) => {
8789
+ return mo(t).forEach(({ id: o, name: s }) => {
8772
8790
  e.push([s, o]);
8773
8791
  }), B(e);
8774
8792
  }
8775
- function Eo(t, e) {
8793
+ function To(t, e) {
8776
8794
  const n = I.resource.spaces.find((s) => s.id === t);
8777
8795
  if (!n)
8778
8796
  return [];
@@ -8783,11 +8801,11 @@ function Eo(t, e) {
8783
8801
  }
8784
8802
  function Oa(t, e) {
8785
8803
  const n = [];
8786
- return Eo(t, e).forEach(({ id: s, name: a }) => {
8804
+ return To(t, e).forEach(({ id: s, name: a }) => {
8787
8805
  n.push([a, s]);
8788
8806
  }), B(n);
8789
8807
  }
8790
- function go() {
8808
+ function Eo() {
8791
8809
  const t = [];
8792
8810
  return I.resource.spaces.forEach((e) => {
8793
8811
  e.resources.length > 0 && t.push(e);
@@ -8795,7 +8813,7 @@ function go() {
8795
8813
  }
8796
8814
  function va() {
8797
8815
  const t = [];
8798
- return go().forEach(({ id: n, name: o }) => {
8816
+ return Eo().forEach(({ id: n, name: o }) => {
8799
8817
  t.push([o, n]);
8800
8818
  }), B(t);
8801
8819
  }
@@ -8821,19 +8839,19 @@ const Ca = {
8821
8839
  initData_: function() {
8822
8840
  if (this.space.id)
8823
8841
  return;
8824
- const t = go()?.[0];
8842
+ const t = Eo()?.[0];
8825
8843
  if (!t)
8826
8844
  return;
8827
8845
  this.space.id = t.id, this.space.name = t.name;
8828
8846
  const e = this.getField("SPACE");
8829
8847
  e.getOptions(!1), e.setValue(this.space.id);
8830
- const n = To(this.space.id)?.[0];
8848
+ const n = mo(this.space.id)?.[0];
8831
8849
  if (!n)
8832
8850
  return;
8833
8851
  this.dir.id = n.id, this.dir.name = n.name;
8834
8852
  const o = this.getField("DIR");
8835
8853
  o.getOptions(!1), o.setValue(this.dir.id);
8836
- const s = Eo(this.space.id, this.dir.id)?.[0];
8854
+ const s = To(this.space.id, this.dir.id)?.[0];
8837
8855
  if (!s)
8838
8856
  return;
8839
8857
  this.resource.id = s.id, this.resource.name = s.name;
@@ -8879,7 +8897,7 @@ const ka = {
8879
8897
  }, 0);
8880
8898
  },
8881
8899
  updateShape_: function() {
8882
- this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_RESOURCE_DO}"), this.getInput("RESULT") || (this.appendValueInput("RESULT"), this.moveInputBefore("RESULT", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "RESULT")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_RESOURCE_RESULT}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("DATA") || (this.appendValueInput("DATA").setAlign(N.Align.RIGHT).appendField("%{BKY_RESOURCE_DATA}"), this.moveInputBefore("DATA", "SUCCESS")), this.getInput("DIR") || (this.appendValueInput("DIR").setCheck("SelectDir").setAlign(N.Align.RIGHT).appendField("%{BKY_RESOURCE_DIR}"), this.moveInputBefore("DIR", "DATA")), this.getInput("NAME") || (this.appendValueInput("NAME").setCheck("String").setAlign(N.Align.RIGHT).appendField("%{BKY_RESOURCE_NAME}"), this.moveInputBefore("NAME", "DIR"));
8900
+ this.getInput("HANDLE") || this.appendStatementInput("HANDLE").appendField("%{BKY_RESOURCE_DO}"), this.getInput("RESULT") || (this.appendValueInput("RESULT"), this.moveInputBefore("RESULT", "HANDLE")), this.getInput("MESSAGE") || (this.appendValueInput("MESSAGE"), this.moveInputBefore("MESSAGE", "RESULT")), this.getInput("SUCCESS") || (this.appendValueInput("SUCCESS").appendField("%{BKY_RESOURCE_RESULT}"), this.moveInputBefore("SUCCESS", "MESSAGE")), this.getInput("DATA") || (this.appendValueInput("DATA").setAlign(S.Align.RIGHT).appendField("%{BKY_RESOURCE_DATA}"), this.moveInputBefore("DATA", "SUCCESS")), this.getInput("DIR") || (this.appendValueInput("DIR").setCheck("SelectDir").setAlign(S.Align.RIGHT).appendField("%{BKY_RESOURCE_DIR}"), this.moveInputBefore("DIR", "DATA")), this.getInput("NAME") || (this.appendValueInput("NAME").setCheck("String").setAlign(S.Align.RIGHT).appendField("%{BKY_RESOURCE_NAME}"), this.moveInputBefore("NAME", "DIR"));
8883
8901
  },
8884
8902
  updateShadow_: function() {
8885
8903
  if (this.isInsertionMarker())
@@ -8928,9 +8946,9 @@ g([
8928
8946
  i.forBlock.text_v1 = function(t) {
8929
8947
  return [i.quote_(t.getFieldValue("TEXT")), _.ATOMIC];
8930
8948
  };
8931
- const Na = /^\s*'([^']|\\')*'\s*$/;
8949
+ const Sa = /^\s*'([^']|\\')*'\s*$/;
8932
8950
  function se(t) {
8933
- return Na.test(t) ? [t, _.ATOMIC] : [`String(${t})`, _.FUNCTION_CALL];
8951
+ return Sa.test(t) ? [t, _.ATOMIC] : [`String(${t})`, _.FUNCTION_CALL];
8934
8952
  }
8935
8953
  M.register(
8936
8954
  "text_append_tooltip_v1",
@@ -9134,10 +9152,10 @@ g([
9134
9152
  i.forBlock.text_is_empty_v1 = function(t) {
9135
9153
  return [`!${i.valueToCode(t, "VALUE", _.MEMBER) || "''"}.length`, _.LOGICAL_NOT];
9136
9154
  };
9137
- const Sa = L.xml, La = {
9155
+ const Na = N.xml, La = {
9138
9156
  itemCount_: 0,
9139
9157
  mutationToDom: function() {
9140
- const t = Sa.createElement("mutation");
9158
+ const t = Na.createElement("mutation");
9141
9159
  return t.setAttribute("items", `${this.itemCount_}`), t;
9142
9160
  },
9143
9161
  domToMutation: function(t) {
@@ -9201,7 +9219,7 @@ const Sa = L.xml, La = {
9201
9219
  for (let t = 0; t < this.itemCount_; t++)
9202
9220
  if (!this.getInput("ADD" + t)) {
9203
9221
  const e = this.appendValueInput("ADD" + t).setAlign(
9204
- N.Align.RIGHT
9222
+ S.Align.RIGHT
9205
9223
  );
9206
9224
  t === 0 && e.appendField("%{BKY_TEXT_V1_JOIN_TITLE}");
9207
9225
  }
@@ -9457,7 +9475,7 @@ const ba = {
9457
9475
  this.updateShape_(), this.updateShadow_();
9458
9476
  },
9459
9477
  updateShape_: function() {
9460
- this.getInput("CALLBACK") || this.appendStatementInput("CALLBACK").appendField("%{BKY_TIME_DO}"), this.getInput("IMMEDIATE") || (this.appendValueInput("IMMEDIATE").setCheck("Boolean").setAlign(N.Align.RIGHT).appendField("%{BKY_TIME_IMMEDIATE}"), this.moveInputBefore("IMMEDIATE", "CALLBACK")), this.getInput("COUNT") || (this.appendValueInput("COUNT").setCheck("Number").setAlign(N.Align.RIGHT).appendField("%{BKY_TIME_COUNT}"), this.moveInputBefore("COUNT", "IMMEDIATE")), this.getInput("LOOP") || (this.appendValueInput("LOOP").setCheck("Boolean").setAlign(N.Align.RIGHT).appendField("%{BKY_TIME_LOOP}"), this.moveInputBefore("LOOP", "COUNT")), this.getInput("INTERVAL") || (this.appendValueInput("INTERVAL").setCheck("Number").setAlign(N.Align.RIGHT).appendField("%{BKY_TIME_INTERVAL_MS}"), this.moveInputBefore("INTERVAL", "LOOP"));
9478
+ this.getInput("CALLBACK") || this.appendStatementInput("CALLBACK").appendField("%{BKY_TIME_DO}"), this.getInput("IMMEDIATE") || (this.appendValueInput("IMMEDIATE").setCheck("Boolean").setAlign(S.Align.RIGHT).appendField("%{BKY_TIME_IMMEDIATE}"), this.moveInputBefore("IMMEDIATE", "CALLBACK")), this.getInput("COUNT") || (this.appendValueInput("COUNT").setCheck("Number").setAlign(S.Align.RIGHT).appendField("%{BKY_TIME_COUNT}"), this.moveInputBefore("COUNT", "IMMEDIATE")), this.getInput("LOOP") || (this.appendValueInput("LOOP").setCheck("Boolean").setAlign(S.Align.RIGHT).appendField("%{BKY_TIME_LOOP}"), this.moveInputBefore("LOOP", "COUNT")), this.getInput("INTERVAL") || (this.appendValueInput("INTERVAL").setCheck("Number").setAlign(S.Align.RIGHT).appendField("%{BKY_TIME_INTERVAL_MS}"), this.moveInputBefore("INTERVAL", "LOOP"));
9461
9479
  },
9462
9480
  updateShadow_: function() {
9463
9481
  if (this.isInsertionMarker())
@@ -9600,14 +9618,14 @@ i.forBlock.variable_set_v1 = function(t) {
9600
9618
  `;
9601
9619
  };
9602
9620
  Hn.setConfirm(async (t, e) => {
9603
- const n = await ns({
9621
+ const n = await es({
9604
9622
  title: "",
9605
9623
  text: t
9606
9624
  });
9607
9625
  e(!!n);
9608
9626
  });
9609
9627
  Hn.setPrompt(async (t, e, n) => {
9610
- const o = await os({
9628
+ const o = await ns({
9611
9629
  title: "",
9612
9630
  value: e
9613
9631
  });
@@ -9625,7 +9643,7 @@ const Ua = te.getText_;
9625
9643
  te.getText_ = function() {
9626
9644
  if (this.selectedOption)
9627
9645
  return Ua.call(this);
9628
- const { i18n: t } = St, e = this.getSourceBlock();
9646
+ const { i18n: t } = Nt, e = this.getSourceBlock();
9629
9647
  if (this.name === "APP")
9630
9648
  return e.app.name;
9631
9649
  if (this.name === "PAGE")
@@ -9666,7 +9684,7 @@ te.getText_ = function() {
9666
9684
  return "<n/a>";
9667
9685
  };
9668
9686
  const Yn = 60;
9669
- Fo.prototype.cleanUp = function() {
9687
+ Yo.prototype.cleanUp = function() {
9670
9688
  this.setResizesEnabled(!1);
9671
9689
  const t = O.getGroup();
9672
9690
  t || O.setGroup(!0);
@@ -9689,22 +9707,22 @@ Fo.prototype.cleanUp = function() {
9689
9707
  }
9690
9708
  O.setGroup(t), this.setResizesEnabled(!0);
9691
9709
  };
9692
- function Ao(t) {
9710
+ function go(t) {
9693
9711
  const e = t.getParent();
9694
- return e && Ao(e) ? !0 : !e && !!(t.outputConnection || t.previousConnection);
9712
+ return e && go(e) ? !0 : !e && !!(t.outputConnection || t.previousConnection);
9695
9713
  }
9696
9714
  class Va {
9697
9715
  init() {
9698
- const e = wo.registry.getItem("blockDisable");
9716
+ const e = Fo.registry.getItem("blockDisable");
9699
9717
  e && (e.preconditionFn = function(n) {
9700
9718
  const o = n.block;
9701
- return o && !o.isInFlyout && o.workspace.options.disable && o.isEditable() ? o.getInheritedDisabled() || Ao(o) ? "disabled" : "enabled" : "hidden";
9719
+ return o && !o.isInFlyout && o.workspace.options.disable && o.isEditable() ? o.getInheritedDisabled() || go(o) ? "disabled" : "enabled" : "hidden";
9702
9720
  });
9703
9721
  }
9704
9722
  }
9705
- Ko.registerFieldColour();
9706
- $o.registry.unregister(Ho.names.ESCAPE);
9707
- const xa = new Go.CrossTabCopyPaste();
9723
+ wo.registerFieldColour();
9724
+ Ko.registry.unregister($o.names.ESCAPE);
9725
+ const xa = new Ho.CrossTabCopyPaste();
9708
9726
  xa.init({ contextMenu: !0, shortcut: !0 });
9709
9727
  const Ya = new Va();
9710
9728
  Ya.init();
@@ -9721,7 +9739,7 @@ function fn(t) {
9721
9739
  const s = o.getRelativeToSurfaceXY(), a = s.x * e.scale, r = s.y * e.scale;
9722
9740
  e.scroll(-a, -r);
9723
9741
  }
9724
- function Io() {
9742
+ function Ao() {
9725
9743
  const t = Xt();
9726
9744
  if (!t)
9727
9745
  return;
@@ -10051,12 +10069,12 @@ function ja(t) {
10051
10069
  }
10052
10070
  return e;
10053
10071
  }
10054
- const yo = Symbol();
10072
+ const Io = Symbol();
10055
10073
  function Xa(t) {
10056
- _s(yo, t);
10074
+ ls(Io, t);
10057
10075
  }
10058
10076
  function mn() {
10059
- return ps(yo);
10077
+ return _s(Io);
10060
10078
  }
10061
10079
  const Ja = /* @__PURE__ */ pt({
10062
10080
  __name: "index",
@@ -10154,8 +10172,8 @@ const Ja = /* @__PURE__ */ pt({
10154
10172
  pointerEvents: "none"
10155
10173
  }));
10156
10174
  return (u, h) => {
10157
- const p = F("v-spacer"), f = F("v-icon"), T = ds("ripple");
10158
- return hs((D(), it("div", {
10175
+ const p = F("v-spacer"), f = F("v-icon"), T = ps("ripple");
10176
+ return ds((D(), it("div", {
10159
10177
  class: "d-flex align-center cursor-pointer",
10160
10178
  style: z(l.value),
10161
10179
  onClick: h[1] || (h[1] = (E) => r("x-click", a.id)),
@@ -10202,7 +10220,7 @@ const Ja = /* @__PURE__ */ pt({
10202
10220
  }
10203
10221
  const p = [];
10204
10222
  s.workspace.getTopBlocks(!0).forEach((T) => {
10205
- const E = T.id === jo()?.id;
10223
+ const E = T.id === Wo()?.id;
10206
10224
  let y = "";
10207
10225
  if (T.type.startsWith("on_app_event_v")) {
10208
10226
  const P = T, Lt = V[P.node.key];
@@ -10259,7 +10277,7 @@ const Ja = /* @__PURE__ */ pt({
10259
10277
  E
10260
10278
  ).getRelativeToSurfaceXY().y + 10);
10261
10279
  const k = T.getRelativeToSurfaceXY();
10262
- T.moveTo(new L.Coordinate(k.x, y)), s.workspace.cleanUp(), Io();
10280
+ T.moveTo(new N.Coordinate(k.x, y)), s.workspace.cleanUp(), Ao();
10263
10281
  }, h = async (p) => {
10264
10282
  if (!s.workspace) {
10265
10283
  console.assert(!1);
@@ -10268,7 +10286,7 @@ const Ja = /* @__PURE__ */ pt({
10268
10286
  const f = s.workspace.getBlockById(p);
10269
10287
  Wn.setSelected(f), fn(p), o.value = !1;
10270
10288
  };
10271
- return (p, f) => a.value.length > 0 ? (D(), ut(Y(Wo), {
10289
+ return (p, f) => a.value.length > 0 ? (D(), ut(Y(Go), {
10272
10290
  key: 0,
10273
10291
  modelValue: a.value,
10274
10292
  "onUpdate:modelValue": f[0] || (f[0] = (T) => a.value = T),
@@ -10280,7 +10298,7 @@ const Ja = /* @__PURE__ */ pt({
10280
10298
  onStart: l
10281
10299
  }, {
10282
10300
  default: lt(() => [
10283
- (D(!0), it(Zn, null, fs(a.value, (T) => (D(), ut(tc, {
10301
+ (D(!0), it(Zn, null, hs(a.value, (T) => (D(), ut(tc, {
10284
10302
  id: T.id,
10285
10303
  key: T.id,
10286
10304
  desc: T.desc,
@@ -10348,7 +10366,7 @@ const Ja = /* @__PURE__ */ pt({
10348
10366
  }), d = $(() => ({
10349
10367
  height: "60px"
10350
10368
  })), { open: u } = rn(`blocklyNavigatorDlg${Ze()}`);
10351
- ms(() => {
10369
+ fs(() => {
10352
10370
  u.value = !1;
10353
10371
  });
10354
10372
  const h = $t("blockList"), p = $t("blockTree");
@@ -10443,7 +10461,7 @@ const Ja = /* @__PURE__ */ pt({
10443
10461
  ], 64);
10444
10462
  };
10445
10463
  }
10446
- }), W = L.xml;
10464
+ }), W = N.xml;
10447
10465
  function G(t) {
10448
10466
  const e = W.createElement("label");
10449
10467
  return e.setAttribute("text", t), e;
@@ -10455,7 +10473,7 @@ function C(t, e) {
10455
10473
  n.appendChild(o);
10456
10474
  return n;
10457
10475
  }
10458
- function Oo(t) {
10476
+ function yo(t) {
10459
10477
  const e = W.createElement("mutation");
10460
10478
  for (const { key: n, value: o } of t)
10461
10479
  e.setAttribute(n, o);
@@ -10520,10 +10538,10 @@ function _c() {
10520
10538
  function pc() {
10521
10539
  const t = [];
10522
10540
  return t.push(G(m("LABEL_EVENT"))), Z("onEvent") && t.push(C("on_app_event_v1")), uc() && t.push(C("trigger_app_event_v1")), t.push(
10523
- C("app_bind_v1", [Oo([{ key: "items", value: "2" }])])
10541
+ C("app_bind_v1", [yo([{ key: "items", value: "2" }])])
10524
10542
  ), t.push(C("watch_effect_v1")), (Z("getProperty") || Z("setProperty")) && t.push(G(m("LABEL_PROPERTY"))), Z("getProperty") && t.push(C("get_app_property_v1")), Z("setProperty") && t.push(C("set_app_property_v1")), lc() && (t.push(G(m("LABEL_STATE"))), t.push(C("get_app_state_v1")), t.push(C("set_app_state_v1"))), (Z("callMethod") || wn()) && t.push(G(m("LABEL_METHOD"))), Z("callMethod") && t.push(C("call_app_method_v1")), wn() && (t.push(C("implement_app_method_v1")), _c() && t.push(C("set_app_method_output_v1")), t.push(C("procedure_return_v1"))), t;
10525
10543
  }
10526
- const vo = { name: "APP_COMP_CATEGORY", callback: pc };
10544
+ const Oo = { name: "APP_COMP_CATEGORY", callback: pc };
10527
10545
  function dc() {
10528
10546
  const t = [];
10529
10547
  return t.push(G(m("LABEL_FUNC"))), t.push(G(m("LABEL_FLOW"))), t;
@@ -10556,15 +10574,15 @@ function Ec() {
10556
10574
  function gc() {
10557
10575
  const t = [];
10558
10576
  return t.push(G(m("LABEL_EVENT"))), Z("onEvent") && t.push(C("on_app_event_v1")), t.push(
10559
- C("app_bind_v1", [Oo([{ key: "items", value: "2" }])])
10577
+ C("app_bind_v1", [yo([{ key: "items", value: "2" }])])
10560
10578
  ), t.push(C("watch_effect_v1")), (Z("getProperty") || Z("setProperty")) && t.push(G(m("LABEL_PROPERTY"))), Z("getProperty") && t.push(C("get_app_property_v1")), Z("setProperty") && t.push(C("set_app_property_v1")), Tc() && (t.push(G(m("LABEL_STATE"))), t.push(C("get_app_state_v1")), t.push(C("set_app_state_v1"))), Z("callMethod") && (t.push(G(m("LABEL_METHOD"))), t.push(C("call_app_method_v1"))), Ec() && (t.push(G(m("LABEL_ARGUMENT"))), t.push(C("get_page_argument_v1"))), t;
10561
10579
  }
10562
- const Co = { name: "APP_PAGE_CATEGORY", callback: gc };
10580
+ const vo = { name: "APP_PAGE_CATEGORY", callback: gc };
10563
10581
  function Ac() {
10564
10582
  const t = [];
10565
10583
  return t.push(G(m("LABEL_RESOURCE"))), t.push(C("upload_resource_v1")), t;
10566
10584
  }
10567
- const Te = { name: "APP_RESOURCE_CATEGORY", callback: Ac }, Ft = L.xml;
10585
+ const Te = { name: "APP_RESOURCE_CATEGORY", callback: Ac }, Ft = N.xml;
10568
10586
  function Ic() {
10569
10587
  const t = [];
10570
10588
  {
@@ -10591,7 +10609,7 @@ function Ic() {
10591
10609
  const ft = {
10592
10610
  name: "PROCEDURE_CATEGORY",
10593
10611
  callback: Ic
10594
- }, ne = L.xml;
10612
+ }, ne = N.xml;
10595
10613
  function yc() {
10596
10614
  const t = Xt(), e = [];
10597
10615
  {
@@ -10666,18 +10684,18 @@ const ge = { name: "COMPUTE_FLOW_CATEGORY", callback: Cc };
10666
10684
  function kc() {
10667
10685
  return Zt("func").length > 0;
10668
10686
  }
10669
- function Nc() {
10687
+ function Sc() {
10670
10688
  const { activeObject: t, activeFunc: e } = I.compute, n = [];
10671
10689
  return t.type === "func" && (n.push(C("func_entry_v1")), e.outputs && e.outputs.length > 0 && n.push(C("set_func_output_v1")), n.push(C("procedure_return_v1"))), kc() && n.push(C("call_func_internal_v1")), n;
10672
10690
  }
10673
- const Ae = { name: "COMPUTE_FUNC_CATEGORY", callback: Nc };
10674
- function Sc() {
10691
+ const Ae = { name: "COMPUTE_FUNC_CATEGORY", callback: Sc };
10692
+ function Nc() {
10675
10693
  const t = [];
10676
10694
  return t.push(
10677
10695
  C("compute_debug_trace_v1", [Mt("OBJECT")])
10678
10696
  ), t;
10679
10697
  }
10680
- const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Sc }, Be = {
10698
+ const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Nc }, Be = {
10681
10699
  kind: "category",
10682
10700
  name: "%{BKY_CATEGORY_COLOR}",
10683
10701
  categorystyle: "color_category",
@@ -11356,7 +11374,7 @@ const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Sc }, Be = {
11356
11374
  type: "text_reverse_v1"
11357
11375
  }
11358
11376
  ]
11359
- }, ko = {
11377
+ }, Co = {
11360
11378
  kind: "category",
11361
11379
  name: "%{BKY_CATEGORY_TIME}",
11362
11380
  categorystyle: "time_category",
@@ -11387,7 +11405,7 @@ const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Sc }, Be = {
11387
11405
  kind: "category",
11388
11406
  name: "%{BKY_CATEGORY_COMP}",
11389
11407
  categorystyle: "misc_category",
11390
- custom: vo.name
11408
+ custom: Oo.name
11391
11409
  },
11392
11410
  {
11393
11411
  kind: "category",
@@ -11408,7 +11426,7 @@ const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Sc }, Be = {
11408
11426
  be,
11409
11427
  Me,
11410
11428
  Be,
11411
- ko,
11429
+ Co,
11412
11430
  {
11413
11431
  kind: "category",
11414
11432
  name: "%{BKY_CATEGORY_VARIABLE}",
@@ -11566,7 +11584,7 @@ const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Sc }, Be = {
11566
11584
  kind: "category",
11567
11585
  name: "%{BKY_CATEGORY_PAGE}",
11568
11586
  categorystyle: "misc_category",
11569
- custom: Co.name
11587
+ custom: vo.name
11570
11588
  },
11571
11589
  {
11572
11590
  kind: "category",
@@ -11587,7 +11605,7 @@ const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Sc }, Be = {
11587
11605
  be,
11588
11606
  Me,
11589
11607
  Be,
11590
- ko,
11608
+ Co,
11591
11609
  {
11592
11610
  kind: "category",
11593
11611
  name: "%{BKY_CATEGORY_VARIABLE}",
@@ -11641,8 +11659,8 @@ const Ie = { name: "COMPUTE_MISC_CATEGORY", callback: Sc }, Be = {
11641
11659
  };
11642
11660
  function Dc(t, e, n, o) {
11643
11661
  We.theme = o ? "dark" : "light", We.toolbox = Mc(e, n);
11644
- const s = Xo(t, We);
11645
- return s.addChangeListener(Jo.shadowBlockConversionChangeListener), Uc(s, e, n), Vc(s), s;
11662
+ const s = jo(t, We);
11663
+ return s.addChangeListener(Xo.shadowBlockConversionChangeListener), Uc(s, e, n), Vc(s), s;
11646
11664
  }
11647
11665
  function Mc(t, e) {
11648
11666
  let n;
@@ -11652,10 +11670,10 @@ function Uc(t, e, n) {
11652
11670
  function o({ name: s, callback: a }) {
11653
11671
  t.registerToolboxCategoryCallback(s, () => a(e));
11654
11672
  }
11655
- e === "page" ? n === "v1" && (o(Co), o(fe), o(me), o(mt), o(ft), o(Te), o(he)) : e === "comp" ? n === "v1" && (o(vo), o(fe), o(me), o(mt), o(ft), o(Te), o(he)) : e === "func" ? n === "v1" && (o(Ae), o(ge), o(Ee), o(Ie), o(mt), o(ft)) : e === "flow" && n === "v1" && (o(Ae), o(ge), o(Ee), o(Ie), o(mt), o(ft));
11673
+ e === "page" ? n === "v1" && (o(vo), o(fe), o(me), o(mt), o(ft), o(Te), o(he)) : e === "comp" ? n === "v1" && (o(Oo), o(fe), o(me), o(mt), o(ft), o(Te), o(he)) : e === "func" ? n === "v1" && (o(Ae), o(ge), o(Ee), o(Ie), o(mt), o(ft)) : e === "flow" && n === "v1" && (o(Ae), o(ge), o(Ee), o(Ie), o(mt), o(ft));
11656
11674
  }
11657
11675
  function Vc(t) {
11658
- const { router: e } = St;
11676
+ const { router: e } = Nt;
11659
11677
  t.registerButtonCallback("NO_COMPUTE", () => {
11660
11678
  const n = e.resolve({
11661
11679
  path: "/compute/" + Date.now()
@@ -11807,26 +11825,26 @@ const Fc = { class: "position-relative w-100 h-100" }, wc = /* @__PURE__ */ pt({
11807
11825
  left: 0,
11808
11826
  zIndex: 3e3
11809
11827
  })), { open: xt } = rn(`blocklyEditorFlyout${Ze()}`);
11810
- Sn(async () => {
11828
+ Nn(async () => {
11811
11829
  if (!l.value || !d.value) {
11812
11830
  console.assert(!1);
11813
11831
  return;
11814
11832
  }
11815
- qo(d.value), await Bn(t.locale), p.workspace = Dc(l.value, t.type, t.version, t.dark), p.workspace.addChangeListener(O.disableOrphans), p.workspace.addChangeListener(No);
11833
+ Jo(d.value), await Bn(t.locale), p.workspace = Dc(l.value, t.type, t.version, t.dark), p.workspace.addChangeListener(O.disableOrphans), p.workspace.addChangeListener(ko);
11816
11834
  const b = document.querySelector(`#${c} .blocklyFlyout`);
11817
11835
  new MutationObserver((xe) => {
11818
11836
  xe.forEach((ee) => {
11819
11837
  ee.type === "attributes" && ee.attributeName === "style" && (xt.value = p.workspace.getFlyout().isVisible());
11820
11838
  });
11821
- }).observe(b, { attributes: !0 }), xt.value = p.workspace.getFlyout().isVisible(), En(), gn(), await Ts(), r("ready");
11839
+ }).observe(b, { attributes: !0 }), xt.value = p.workspace.getFlyout().isVisible(), En(), gn(), await ms(), r("ready");
11822
11840
  }), Ln(() => {
11823
11841
  xt.value = !1;
11824
- }), Qo(l, () => {
11825
- p.workspace && zo(p.workspace);
11842
+ }), qo(l, () => {
11843
+ p.workspace && Qo(p.workspace);
11826
11844
  });
11827
- async function No(b) {
11845
+ async function ko(b) {
11828
11846
  if (b.type === O.FINISHED_LOADING) {
11829
- Io(), setTimeout(() => {
11847
+ Ao(), setTimeout(() => {
11830
11848
  h.value?.update();
11831
11849
  }, 0), f.value = !1;
11832
11850
  return;
@@ -11843,16 +11861,16 @@ const Fc = { class: "position-relative w-100 h-100" }, wc = /* @__PURE__ */ pt({
11843
11861
  }
11844
11862
  const So = (b) => {
11845
11863
  f.value = !0, t.type === "json" ? xc(b, p.workspace) : J.workspaces.load(b, p.workspace);
11846
- }, Lo = () => t.type === "json" ? Yc(p.workspace) : J.workspaces.save(p.workspace), Bo = () => {
11864
+ }, No = () => t.type === "json" ? Yc(p.workspace) : J.workspaces.save(p.workspace), Lo = () => {
11847
11865
  if (t.type === "json")
11848
11866
  console.assert(!1);
11849
11867
  else
11850
11868
  return i.workspaceToCode(p.workspace);
11851
- }, bo = () => ja(p.workspace), En = () => {
11869
+ }, Bo = () => ja(p.workspace), En = () => {
11852
11870
  p.workspace.setIsReadOnly(s.value), p.workspace.isReadOnly() && (xt.value = !1);
11853
11871
  }, gn = () => {
11854
11872
  p.workspace.setScale(a.value);
11855
- }, Po = () => {
11873
+ }, bo = () => {
11856
11874
  p.workspace.fireChangeListener(new eo());
11857
11875
  }, An = () => {
11858
11876
  u.value?.cleanWorkspace();
@@ -11861,7 +11879,7 @@ const Fc = { class: "position-relative w-100 h-100" }, wc = /* @__PURE__ */ pt({
11861
11879
  }, yn = () => {
11862
11880
  h.value && (h.value.open = !0);
11863
11881
  };
11864
- return Sn(() => {
11882
+ return Nn(() => {
11865
11883
  Bt.on("cleanWorkspace", An), Bt.on("toggleBlocklyLock", In), Bt.on("openBlocklyNavigator", yn);
11866
11884
  }), Ln(() => {
11867
11885
  Bt.off("cleanWorkspace", An), Bt.off("toggleBlocklyLock", In), Bt.off("openBlocklyNavigator", yn);
@@ -11884,10 +11902,10 @@ const Fc = { class: "position-relative w-100 h-100" }, wc = /* @__PURE__ */ pt({
11884
11902
  }), e({
11885
11903
  loading: f,
11886
11904
  load: So,
11887
- save: Lo,
11888
- generateCode: Bo,
11889
- generateReactivity: bo,
11890
- fireStateChange: Po
11905
+ save: No,
11906
+ generateCode: Lo,
11907
+ generateReactivity: Bo,
11908
+ fireStateChange: bo
11891
11909
  }), (b, vt) => {
11892
11910
  const xe = F("v-icon"), ee = F("x-loading");
11893
11911
  return D(), it("div", Fc, [
@@ -11900,7 +11918,7 @@ const Fc = { class: "position-relative w-100 h-100" }, wc = /* @__PURE__ */ pt({
11900
11918
  X("div", {
11901
11919
  style: z(k.value)
11902
11920
  }, [
11903
- Es(b.$slots, "bottom")
11921
+ Ts(b.$slots, "bottom")
11904
11922
  ], 4),
11905
11923
  T.value ? (D(), it("div", {
11906
11924
  key: 0,
@@ -11924,7 +11942,7 @@ const Fc = { class: "position-relative w-100 h-100" }, wc = /* @__PURE__ */ pt({
11924
11942
  }, null, 8, ["lock"]),
11925
11943
  R(qa, {
11926
11944
  modelValue: s.value,
11927
- "onUpdate:modelValue": vt[0] || (vt[0] = (Ro) => s.value = Ro)
11945
+ "onUpdate:modelValue": vt[0] || (vt[0] = (Po) => s.value = Po)
11928
11946
  }, null, 8, ["modelValue"]),
11929
11947
  R(cc, {
11930
11948
  ref_key: "navigator",
@@ -11960,8 +11978,8 @@ const Fc = { class: "position-relative w-100 h-100" }, wc = /* @__PURE__ */ pt({
11960
11978
  },
11961
11979
  setup(t) {
11962
11980
  const e = t;
11963
- Zo.registerLanguage("javascript", ts);
11964
- const n = es.component, { backgroundColor2: o } = Jt();
11981
+ zo.registerLanguage("javascript", Zo);
11982
+ const n = ts.component, { backgroundColor2: o } = Jt();
11965
11983
  return (s, a) => {
11966
11984
  const r = F("v-sheet");
11967
11985
  return D(), ut(r, {