x-block-lib 0.4.25 → 0.4.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +805 -785
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
1
  (function(){"use strict";try{if(typeof document<"u"){var o=document.createElement("style");o.id="x-block-lib",o.appendChild(document.createTextNode(".ghost[data-v-91f61557]{opacity:.4;pointer-events:none}.blocklyToolboxDiv{overflow-x:hidden;width:56px}.blocklyMainBackground{stroke-width:0}.blocklyToolboxCategory{margin-bottom:10px}.blocklyTreeRow{height:28px;display:flex;align-items:center;border-left-width:6px!important;border-right-width:6px!important}.blocklyTreeIcon{display:none!important}.blocklyFlyout{z-index:21}")),document.head.appendChild(o)}}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();
2
2
  var xn = Object.defineProperty;
3
3
  var Pn = (e, o, t) => o in e ? xn(e, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[o] = t;
4
- var he = (e, o, t) => Pn(e, typeof o != "symbol" ? o + "" : o, t);
5
- import { getCurrentScope as wn, onScopeDispose as Vn, unref as N, computed as ue, watch as Ge, ref as Pe, getCurrentInstance as Pt, onMounted as ze, defineComponent as Ve, onBeforeUnmount as Nt, resolveComponent as oe, openBlock as J, createBlock as Le, withCtx as We, createVNode as ne, mergeProps as mo, useModel as co, toRefs as Un, reactive as Yn, h as Kn, onUnmounted as Fn, nextTick as go, isRef as vt, resolveDirective as Hn, withDirectives as Gn, createElementBlock as ke, normalizeStyle as Ne, createElementVNode as ve, toDisplayString as Eo, withModifiers as yt, Fragment as Zo, renderList as Xn, withKeys as $n, createCommentVNode as nt, mergeModels as Lo } from "vue";
6
- import { d as g, j as a, O as c, u as m, X as jn, B as _e, E as F, M as j, i as wt, a as De, b as V, C as en, F as vo, c as Wn, P as uo, N as yo, V as bt, e as Jn, f as tn, s as zn, g as we, S as z, h as Jt, k as Fe, l as _t, m as zt, n as Qe, o as xe, p as ko, G as qt, q as qn, r as Qn, t as Qt, U as pt, D as dt, v as Ue, w as Zn, T as Vt, x as on, y as ei, z as ti, A as No, H as oi } from "./blockly-ou5p4kro.js";
4
+ var Te = (e, o, t) => Pn(e, typeof o != "symbol" ? o + "" : o, t);
5
+ import { getCurrentScope as wn, onScopeDispose as Vn, unref as N, computed as ae, watch as De, ref as we, getCurrentInstance as Pt, onMounted as qe, defineComponent as Ue, onBeforeUnmount as Nt, resolveComponent as ie, openBlock as j, createBlock as Se, withCtx as Je, createVNode as re, mergeProps as mo, useModel as co, toRefs as Un, reactive as Yn, h as Kn, onUnmounted as Fn, nextTick as go, isRef as vt, resolveDirective as Hn, withDirectives as Gn, createElementBlock as be, normalizeStyle as Oe, createElementVNode as ye, toDisplayString as Eo, withModifiers as yt, Fragment as Zo, renderList as Xn, withKeys as $n, createCommentVNode as Xe, mergeModels as Lo } from "vue";
6
+ import { d as m, j as a, O as c, u as T, X as jn, B as de, E as G, M as W, i as wt, a as xe, b as Y, C as en, F as vo, c as Wn, P as uo, N as yo, V as bt, e as Jn, f as tn, s as zn, g as Ve, S as q, h as Jt, k as He, l as _t, m as zt, n as Ze, o as Pe, p as ko, G as qt, q as qn, r as Qn, t as Qt, U as pt, D as dt, v as Ye, w as Zn, T as Vt, x as on, y as ei, z as ti, A as No, H as oi } from "./blockly-ou5p4kro.js";
7
7
  import { storeToRefs as ni } from "pinia";
8
- import { openConfirmDlg as ii, openPromptDlg as ri, eventBus as Te, useColor as nn, useViewStack as bo, useSystem as li, useGlobalStore as ai } from "x-essential-lib";
8
+ import { openConfirmDlg as ii, openPromptDlg as ri, eventBus as me, useColor as nn, useViewStack as bo, useSystem as li, useGlobalStore as ai } from "x-essential-lib";
9
9
  import { useI18n as Ut } from "vue-i18n";
10
10
  import { useDisplay as si } from "vuetify";
11
11
  var ci = "M19.36,2.72L20.78,4.14L15.06,9.85C16.13,11.39 16.28,13.24 15.38,14.44L9.06,8.12C10.26,7.22 12.11,7.37 13.65,8.44L19.36,2.72M5.93,17.57C3.92,15.56 2.69,13.16 2.35,10.92L7.23,8.83L14.67,16.27L12.58,21.15C10.34,20.81 7.94,19.58 5.93,17.57Z", ui = "M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z", _i = "M19,4H15.5L14.5,3H9.5L8.5,4H5V6H19M6,19A2,2 0 0,0 8,21H16A2,2 0 0,0 18,19V7H6V19Z", pi = "M21 11H3V9H21V11M21 13H3V15H21V13Z", di = "M12,17A2,2 0 0,0 14,15C14,13.89 13.1,13 12,13A2,2 0 0,0 10,15A2,2 0 0,0 12,17M18,8A2,2 0 0,1 20,10V20A2,2 0 0,1 18,22H6A2,2 0 0,1 4,20V10C4,8.89 4.9,8 6,8H7V6A5,5 0 0,1 12,1A5,5 0 0,1 17,6V8H18M12,3A3,3 0 0,0 9,6V8H15V6A3,3 0 0,0 12,3Z", fi = "M18,8A2,2 0 0,1 20,10V20A2,2 0 0,1 18,22H6C4.89,22 4,21.1 4,20V10A2,2 0 0,1 6,8H15V6A3,3 0 0,0 12,3A3,3 0 0,0 9,6H7A5,5 0 0,1 12,1A5,5 0 0,1 17,6V8H18M12,17A2,2 0 0,0 14,15A2,2 0 0,0 12,13A2,2 0 0,0 10,15A2,2 0 0,0 12,17Z", hi = "M21 3L3 10.53V11.5L9.84 14.16L12.5 21H13.46L21 3Z";
@@ -24,39 +24,39 @@ function So(e) {
24
24
  }
25
25
  const Ei = gi ? window : void 0;
26
26
  function vi() {
27
- const e = Pe(!1), o = Pt();
28
- return o && ze(() => {
27
+ const e = we(!1), o = Pt();
28
+ return o && qe(() => {
29
29
  e.value = !0;
30
30
  }, o), e;
31
31
  }
32
32
  function yi(e) {
33
33
  const o = vi();
34
- return ue(() => (o.value, !!e()));
34
+ return ae(() => (o.value, !!e()));
35
35
  }
36
36
  function bi(e, o, t = {}) {
37
37
  const { window: n = Ei, ...i } = t;
38
38
  let r;
39
39
  const l = yi(() => n && "ResizeObserver" in n), s = () => {
40
40
  r && (r.disconnect(), r = void 0);
41
- }, u = ue(() => Array.isArray(e) ? e.map((p) => So(p)) : [So(e)]), _ = Ge(
41
+ }, u = ae(() => Array.isArray(e) ? e.map((_) => So(_)) : [So(e)]), p = De(
42
42
  u,
43
- (p) => {
43
+ (_) => {
44
44
  if (s(), l.value && n) {
45
45
  r = new ResizeObserver(o);
46
- for (const T of p)
47
- T && r.observe(T, i);
46
+ for (const g of _)
47
+ g && r.observe(g, i);
48
48
  }
49
49
  },
50
50
  { immediate: !0, flush: "post" }
51
51
  ), d = () => {
52
- s(), _();
52
+ s(), p();
53
53
  };
54
54
  return Ti(d), {
55
55
  isSupported: l,
56
56
  stop: d
57
57
  };
58
58
  }
59
- g([
59
+ m([
60
60
  {
61
61
  type: "color_blend_v1",
62
62
  message0: "%{BKY_COLOR_V1_BLEND_TITLE}",
@@ -110,7 +110,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(c1, c2, ratio) {
110
110
  `
111
111
  )}(${o}, ${t}, ${n})`, c.FUNCTION_CALL];
112
112
  };
113
- g([
113
+ m([
114
114
  {
115
115
  type: "color_picker_v1",
116
116
  message0: "%1",
@@ -130,7 +130,7 @@ g([
130
130
  a.forBlock.color_picker_v1 = function(e) {
131
131
  return [a.quote_(e.getFieldValue("COLOR")), c.ATOMIC];
132
132
  };
133
- g([
133
+ m([
134
134
  {
135
135
  type: "color_random_v1",
136
136
  message0: "%{BKY_COLOR_V1_RANDOM_TITLE}",
@@ -151,7 +151,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}() {
151
151
  `
152
152
  )}()`, c.FUNCTION_CALL];
153
153
  };
154
- g([
154
+ m([
155
155
  {
156
156
  type: "color_rgb_v1",
157
157
  message0: "%{BKY_COLOR_V1_RGB_TITLE}",
@@ -241,13 +241,13 @@ function ft(e) {
241
241
  typeof e.default == "boolean" && (t = e.default ? "TRUE" : "FALSE"), o = `<shadow type="logic_boolean_v1"><field name="BOOL">${t}</field></shadow>`;
242
242
  } else
243
243
  console.assert(!1, "invalid param type", e.type);
244
- return m.xml.textToDom(o);
244
+ return T.xml.textToDom(o);
245
245
  }
246
246
  function rn(e, o, t) {
247
- const n = `<xml><block type="parameter_v1"><mutation key="${o}" name="${t}"/></block></xml>`, i = m.xml.textToDom(n), r = jn.domToWorkspace(i, e);
247
+ const n = `<xml><block type="parameter_v1"><mutation key="${o}" name="${t}"/></block></xml>`, i = T.xml.textToDom(n), r = jn.domToWorkspace(i, e);
248
248
  return e.getBlockById(r[0]);
249
249
  }
250
- const Ii = m.xml, Ci = [
250
+ const Ii = T.xml, Ci = [
251
251
  {
252
252
  type: "call_func_v1",
253
253
  prefixInputs: ["OUTPUT"]
@@ -306,7 +306,7 @@ const Li = {
306
306
  this.key = e, this.name = o, this.updateShape_();
307
307
  },
308
308
  onchange: function(e) {
309
- if (e.type === F.BLOCK_MOVE) {
309
+ if (e.type === G.BLOCK_MOVE) {
310
310
  const o = e;
311
311
  if (o.blockId !== this.id)
312
312
  return;
@@ -318,36 +318,36 @@ const Li = {
318
318
  const o = this.workspace.getBlockById(e.oldParentId);
319
319
  if (o && Ai(o.type, e.oldInputName))
320
320
  try {
321
- F.disable();
321
+ G.disable();
322
322
  const n = (t = o.getInput(e.oldInputName)) == null ? void 0 : t.connection;
323
323
  if (n) {
324
324
  const i = rn(this.workspace, this.key, this.name);
325
325
  n.connect(i.outputConnection);
326
326
  }
327
327
  } finally {
328
- F.enable();
328
+ G.enable();
329
329
  }
330
330
  },
331
331
  updateShape_: function() {
332
- this.name ? this.setFieldValue(j[this.name], "LABEL") : this.setFieldValue(this.key, "LABEL");
332
+ this.name ? this.setFieldValue(W[this.name], "LABEL") : this.setFieldValue(this.key, "LABEL");
333
333
  }
334
334
  };
335
- _e.parameter_v1 = Li;
335
+ de.parameter_v1 = Li;
336
336
  a.forBlock.parameter_v1 = function(e) {
337
337
  return [e.key, c.ATOMIC];
338
338
  };
339
- const ki = m.xml, Ni = {
339
+ const ki = T.xml, Ni = {
340
340
  init: function() {
341
341
  this.appendDummyInput().appendField("%{BKY_LIST_V1_CREATE_CONTAINER_TITLE}"), this.appendStatementInput("STACK"), this.setStyle("list_blocks"), this.contextMenu = !1;
342
342
  }
343
343
  };
344
- _e.list_create_container_v1 = Ni;
344
+ de.list_create_container_v1 = Ni;
345
345
  const Si = {
346
346
  init: function() {
347
347
  this.appendDummyInput().appendField("%{BKY_LIST_V1_CREATE_ITEM_TITLE}"), this.setPreviousStatement(!0), this.setNextStatement(!0), this.setStyle("list_blocks"), this.contextMenu = !1;
348
348
  }
349
349
  };
350
- _e.list_create_item_v1 = Si;
350
+ de.list_create_item_v1 = Si;
351
351
  const Bi = {
352
352
  init: function() {
353
353
  this.itemCount_ = 0, this.setMutator(
@@ -426,20 +426,20 @@ const Bi = {
426
426
  for (let e = 0; e < this.itemCount_; e++)
427
427
  if (!this.getInput("ADD" + e)) {
428
428
  const o = this.appendValueInput("ADD" + e);
429
- e === 0 && (o.setAlign(De.Align.RIGHT), o.appendField("%{BKY_LIST_V1_CREATE_TITLE}"));
429
+ e === 0 && (o.setAlign(xe.Align.RIGHT), o.appendField("%{BKY_LIST_V1_CREATE_TITLE}"));
430
430
  }
431
431
  for (let e = this.itemCount_; this.getInput("ADD" + e); e++)
432
432
  this.removeInput("ADD" + e);
433
433
  }
434
434
  };
435
- _e.list_create_v1 = Bi;
435
+ de.list_create_v1 = Bi;
436
436
  a.forBlock.list_create_v1 = function(e) {
437
437
  const o = e, t = new Array(o.itemCount_);
438
438
  for (let i = 0; i < o.itemCount_; i++)
439
439
  t[i] = a.valueToCode(o, "ADD" + i, c.NONE) || "null";
440
440
  return ["[" + t.join(", ") + "]", c.ATOMIC];
441
441
  };
442
- g([
442
+ m([
443
443
  {
444
444
  type: "list_delete_v1",
445
445
  message0: "%{BKY_LIST_V1_DELETE_TITLE}",
@@ -467,7 +467,7 @@ a.forBlock.list_delete_v1 = function(e) {
467
467
  const o = a.valueToCode(e, "VALUE", c.MEMBER) || "[]", t = a.getAdjusted(e, "AT");
468
468
  return `${o}.splice(${t}, 1)`;
469
469
  };
470
- g([
470
+ m([
471
471
  {
472
472
  type: "list_get_v1",
473
473
  message0: "%{BKY_LIST_V1_GET_TITLE}",
@@ -494,7 +494,7 @@ a.forBlock.list_get_v1 = function(e) {
494
494
  const o = a.valueToCode(e, "VALUE", c.MEMBER) || "[]", t = a.getAdjusted(e, "AT");
495
495
  return [`${o}[${t}]`, c.MEMBER];
496
496
  };
497
- g([
497
+ m([
498
498
  {
499
499
  type: "list_get_sublist_v1",
500
500
  message0: "%{BKY_LIST_V1_GET_SUBLIST_TITLE}",
@@ -526,7 +526,7 @@ a.forBlock.list_get_sublist_v1 = function(e) {
526
526
  const o = a.valueToCode(e, "LIST", c.MEMBER) || "[]", t = a.getAdjusted(e, "START"), n = a.getAdjusted(e, "END", 1);
527
527
  return [`${o}.slice(${t}, ${n})`, c.FUNCTION_CALL];
528
528
  };
529
- g([
529
+ m([
530
530
  {
531
531
  type: "list_is_empty_v1",
532
532
  message0: "%{BKY_LIST_V1_IS_EMPTY_TITLE}",
@@ -546,7 +546,7 @@ g([
546
546
  a.forBlock.list_is_empty_v1 = function(e) {
547
547
  return [`!${a.valueToCode(e, "VALUE", c.MEMBER) || "[]"}.length`, c.LOGICAL_NOT];
548
548
  };
549
- g([
549
+ m([
550
550
  {
551
551
  type: "list_join_v1",
552
552
  message0: "%{BKY_LIST_V1_JOIN_TITLE}",
@@ -573,7 +573,7 @@ a.forBlock.list_join_v1 = function(e) {
573
573
  const o = a.valueToCode(e, "LIST", c.MEMBER) || "[]", t = a.valueToCode(e, "DELIM", c.NONE) || "''";
574
574
  return [`${o}.join(${t})`, c.FUNCTION_CALL];
575
575
  };
576
- g([
576
+ m([
577
577
  {
578
578
  type: "list_length_v1",
579
579
  message0: "%{BKY_LIST_V1_LENGTH_TITLE}",
@@ -593,7 +593,7 @@ g([
593
593
  a.forBlock.list_length_v1 = function(e) {
594
594
  return [`${a.valueToCode(e, "VALUE", c.MEMBER) || "[]"}.length`, c.MEMBER];
595
595
  };
596
- g([
596
+ m([
597
597
  {
598
598
  type: "list_reverse_v1",
599
599
  message0: "%{BKY_LIST_V1_REVERSE_TITLE}",
@@ -614,7 +614,7 @@ g([
614
614
  a.forBlock.list_reverse_v1 = function(e) {
615
615
  return [`${a.valueToCode(e, "LIST", c.NONE) || "[]"}.slice().reverse()`, c.FUNCTION_CALL];
616
616
  };
617
- g([
617
+ m([
618
618
  {
619
619
  type: "list_set_v1",
620
620
  message0: "%{BKY_LIST_V1_SET_TITLE}",
@@ -660,11 +660,11 @@ const Ri = {
660
660
  AND: "%{BKY_LOGIC_V1_OPERATION_TOOLTIP_AND}",
661
661
  OR: "%{BKY_LOGIC_V1_OPERATION_TOOLTIP_OR}"
662
662
  };
663
- V.register(
663
+ Y.register(
664
664
  "logic_op_tooltip_v1",
665
- V.buildTooltipForDropdown("OP", Ri)
665
+ Y.buildTooltipForDropdown("OP", Ri)
666
666
  );
667
- g([
667
+ m([
668
668
  {
669
669
  type: "logic_boolean_v1",
670
670
  message0: "%1",
@@ -695,22 +695,22 @@ const Mi = {
695
695
  o.outputConnection,
696
696
  t.outputConnection
697
697
  )) {
698
- F.setGroup(e.group);
698
+ G.setGroup(e.group);
699
699
  const n = this.prevBlocks_[0];
700
700
  n !== o && (o.unplug(), n && !n.isDisposed() && !n.isShadow() && this.getInput("A").connection.connect(n.outputConnection));
701
701
  const i = this.prevBlocks_[1];
702
- i !== t && (t.unplug(), i && !i.isDisposed() && !i.isShadow() && this.getInput("B").connection.connect(i.outputConnection)), this.bumpNeighbours(), F.setGroup(!1);
702
+ i !== t && (t.unplug(), i && !i.isDisposed() && !i.isShadow() && this.getInput("B").connection.connect(i.outputConnection)), this.bumpNeighbours(), G.setGroup(!1);
703
703
  }
704
704
  this.prevBlocks_[0] = this.getInputTargetBlock("A"), this.prevBlocks_[1] = this.getInputTargetBlock("B");
705
705
  }
706
706
  };
707
- V.register(
707
+ Y.register(
708
708
  "logic_compare_v1",
709
709
  function() {
710
710
  this.mixin(Mi);
711
711
  }
712
712
  );
713
- g([
713
+ m([
714
714
  {
715
715
  type: "logic_compare_v1",
716
716
  message0: "%1 %2 %3",
@@ -763,7 +763,7 @@ const Di = {
763
763
  mutationToDom: function() {
764
764
  if (this.elseIfCount_ <= 0 && !this.hasElse_)
765
765
  return null;
766
- const e = m.xml.createElement("mutation");
766
+ const e = T.xml.createElement("mutation");
767
767
  return this.elseIfCount_ > 0 && e.setAttribute("elseIf", String(this.elseIfCount_)), this.hasElse_ && e.setAttribute("else", "TRUE"), e;
768
768
  },
769
769
  domToMutation: function(e) {
@@ -873,8 +873,8 @@ const Di = {
873
873
  for (let e = 1; this.getInput("IF" + e); e++)
874
874
  this.removeInput("IF" + e), this.removeInput("DO" + e);
875
875
  for (let e = 1; e <= this.elseIfCount_; e++)
876
- this.appendValueInput("IF" + e).setCheck("Boolean").appendField(j.LOGIC_ELSE_IF), this.appendStatementInput("DO" + e).appendField(j.LOGIC_DO);
877
- this.hasElse_ && this.appendStatementInput("ELSE").appendField(j.LOGIC_ELSE);
876
+ this.appendValueInput("IF" + e).setCheck("Boolean").appendField(W.LOGIC_ELSE_IF), this.appendStatementInput("DO" + e).appendField(W.LOGIC_DO);
877
+ this.hasElse_ && this.appendStatementInput("ELSE").appendField(W.LOGIC_ELSE);
878
878
  },
879
879
  reconnectChildBlocks_: function(e, o, t) {
880
880
  var n, i;
@@ -883,13 +883,13 @@ const Di = {
883
883
  t == null || t.reconnect(this, "ELSE");
884
884
  }
885
885
  };
886
- V.registerMutator(
886
+ Y.registerMutator(
887
887
  "logic_if_v1_mutator",
888
888
  Di,
889
889
  void 0,
890
890
  ["logic_if_else_if_v1", "logic_if_else_v1"]
891
891
  );
892
- g([
892
+ m([
893
893
  {
894
894
  type: "logic_if_v1",
895
895
  message0: "%{BKY_LOGIC_IF} %1",
@@ -969,7 +969,7 @@ a.forBlock.logic_if_v1 = function(e) {
969
969
  return t + `
970
970
  `;
971
971
  };
972
- g([
972
+ m([
973
973
  {
974
974
  type: "logic_negate_v1",
975
975
  message0: "%{BKY_LOGIC_V1_NEGATE_TITLE}",
@@ -989,7 +989,7 @@ g([
989
989
  a.forBlock.logic_negate_v1 = function(e) {
990
990
  return [`!${a.valueToCode(e, "BOOL", c.LOGICAL_NOT) || "true"}`, c.LOGICAL_NOT];
991
991
  };
992
- g([
992
+ m([
993
993
  {
994
994
  type: "logic_operation_v1",
995
995
  message0: "%1 %2 %3",
@@ -1041,13 +1041,13 @@ const xi = {
1041
1041
  r && !r.workspace.connectionChecker.doTypeChecks(
1042
1042
  r.outputConnection,
1043
1043
  n
1044
- ) && (F.setGroup(e.group), n === this.prevParentConnection_ ? (this.unplug(), n.getSourceBlock().bumpNeighbours()) : (r.unplug(), r.bumpNeighbours()), F.setGroup(!1));
1044
+ ) && (G.setGroup(e.group), n === this.prevParentConnection_ ? (this.unplug(), n.getSourceBlock().bumpNeighbours()) : (r.unplug(), r.bumpNeighbours()), G.setGroup(!1));
1045
1045
  }
1046
1046
  this.prevParentConnection_ = n;
1047
1047
  }
1048
1048
  };
1049
- V.registerMixin("logic_ternary_v1", xi);
1050
- g([
1049
+ Y.registerMixin("logic_ternary_v1", xi);
1050
+ m([
1051
1051
  {
1052
1052
  type: "logic_ternary_v1",
1053
1053
  message0: "%{BKY_LOGIC_TERNARY_CONDITION} %1",
@@ -1097,19 +1097,19 @@ const Pi = {
1097
1097
  };
1098
1098
  e.push({
1099
1099
  enabled: !0,
1100
- text: j.VARIABLES_SET_CREATE_GET.replace("%1", n),
1100
+ text: W.VARIABLES_SET_CREATE_GET.replace("%1", n),
1101
1101
  callback: en.callbackFactory(this, i)
1102
1102
  });
1103
1103
  }
1104
1104
  }
1105
1105
  };
1106
- V.registerMixin(
1106
+ Y.registerMixin(
1107
1107
  "contextMenu_newGetVariableBlock_v1",
1108
1108
  Pi
1109
1109
  );
1110
- V.register(
1110
+ Y.register(
1111
1111
  "flow_control_tooltip_v1",
1112
- V.buildTooltipForDropdown("MODE", {
1112
+ Y.buildTooltipForDropdown("MODE", {
1113
1113
  BREAK: "%{BKY_LOOP_V1_FLOW_CONTROL_TOOLTIP_BREAK}",
1114
1114
  CONTINUE: "%{BKY_LOOP_V1_FLOW_CONTROL_TOOLTIP_CONTINUE}"
1115
1115
  })
@@ -1131,24 +1131,24 @@ const wi = /* @__PURE__ */ new Set([
1131
1131
  },
1132
1132
  onchange: function(e) {
1133
1133
  const o = this.workspace;
1134
- if (!o.isDragging || o.isDragging() || e.type !== F.BLOCK_MOVE && e.type !== F.BLOCK_CREATE)
1134
+ if (!o.isDragging || o.isDragging() || e.type !== G.BLOCK_MOVE && e.type !== G.BLOCK_CREATE)
1135
1135
  return;
1136
1136
  const t = this.getSurroundLoop();
1137
1137
  if (console.log(e.type, t), this.setWarningText(
1138
- t ? null : j.LOOP_FLOW_CONTROL_WARNING
1138
+ t ? null : W.LOOP_FLOW_CONTROL_WARNING
1139
1139
  ), !this.isInFlyout)
1140
1140
  try {
1141
- F.setRecordUndo(!1), this.setDisabledReason(!t, "FLOW_CONTROL_NOT_IN_LOOP");
1141
+ G.setRecordUndo(!1), this.setDisabledReason(!t, "FLOW_CONTROL_NOT_IN_LOOP");
1142
1142
  } finally {
1143
- F.setRecordUndo(!0);
1143
+ G.setRecordUndo(!0);
1144
1144
  }
1145
1145
  }
1146
1146
  };
1147
- V.registerMixin(
1147
+ Y.registerMixin(
1148
1148
  "flow_control_in_loop_check_v1",
1149
1149
  Vi
1150
1150
  );
1151
- g([
1151
+ m([
1152
1152
  {
1153
1153
  type: "flow_control_v1",
1154
1154
  message0: "%1",
@@ -1169,14 +1169,14 @@ g([
1169
1169
  extensions: ["flow_control_tooltip_v1", "flow_control_in_loop_check_v1"]
1170
1170
  }
1171
1171
  ]);
1172
- V.register(
1172
+ Y.register(
1173
1173
  "for_tooltip_v1",
1174
- V.buildTooltipWithFieldText(
1174
+ Y.buildTooltipWithFieldText(
1175
1175
  "%{BKY_LOOP_V1_FOR_TOOLTIP}",
1176
1176
  "VAR"
1177
1177
  )
1178
1178
  );
1179
- g([
1179
+ m([
1180
1180
  {
1181
1181
  type: "for_v1",
1182
1182
  message0: "%{BKY_LOOP_V1_FOR_TITLE}",
@@ -1220,14 +1220,14 @@ g([
1220
1220
  extensions: ["contextMenu_newGetVariableBlock_v1", "for_tooltip_v1"]
1221
1221
  }
1222
1222
  ]);
1223
- V.register(
1223
+ Y.register(
1224
1224
  "for_each_tooltip_v1",
1225
- V.buildTooltipWithFieldText(
1225
+ Y.buildTooltipWithFieldText(
1226
1226
  "%{BKY_LOOP_V1_FOR_EACH_TOOLTIP}",
1227
1227
  "VAR"
1228
1228
  )
1229
1229
  );
1230
- g([
1230
+ m([
1231
1231
  {
1232
1232
  type: "for_each_v1",
1233
1233
  message0: "%{BKY_LOOP_V1_FOR_EACH_TITLE}",
@@ -1257,14 +1257,14 @@ g([
1257
1257
  extensions: ["contextMenu_newGetVariableBlock_v1", "for_each_tooltip_v1"]
1258
1258
  }
1259
1259
  ]);
1260
- V.register(
1260
+ Y.register(
1261
1261
  "loop_while_until_tooltip_v1",
1262
- V.buildTooltipForDropdown("MODE", {
1262
+ Y.buildTooltipForDropdown("MODE", {
1263
1263
  WHILE: "%{BKY_LOOP_V1_WHILE_UNTIL_TOOLTIP_WHILE}",
1264
1264
  UNTIL: "%{BKY_LOOP_V1_WHILE_UNTIL_TOOLTIP_UNTIL}"
1265
1265
  })
1266
1266
  );
1267
- g([
1267
+ m([
1268
1268
  {
1269
1269
  type: "loop_while_until_v1",
1270
1270
  message0: "%1 %2",
@@ -1343,11 +1343,11 @@ const Ui = {
1343
1343
  STD_DEV: "%{BKY_MATH_V1_ON_LIST_TOOLTIP_STD_DEV}",
1344
1344
  RANDOM: "%{BKY_MATH_V1_ON_LIST_TOOLTIP_RANDOM}"
1345
1345
  };
1346
- V.register(
1346
+ Y.register(
1347
1347
  "math_op_tooltip_v1",
1348
- V.buildTooltipForDropdown("OP", Ui)
1348
+ Y.buildTooltipForDropdown("OP", Ui)
1349
1349
  );
1350
- g([
1350
+ m([
1351
1351
  {
1352
1352
  type: "math_arithmetic_v1",
1353
1353
  message0: "%1 %2 %3",
@@ -1391,7 +1391,7 @@ a.forBlock.math_arithmetic_v1 = function(e) {
1391
1391
  }, [t, n] = o[e.getFieldValue("OP")], i = a.valueToCode(e, "A", n) || "0", r = a.valueToCode(e, "B", n) || "0";
1392
1392
  return t ? [i + t + r, n] : [`Math.pow(${i}, ${r})`, c.FUNCTION_CALL];
1393
1393
  };
1394
- g([
1394
+ m([
1395
1395
  {
1396
1396
  type: "math_constant_v1",
1397
1397
  message0: "%1",
@@ -1425,7 +1425,7 @@ a.forBlock.math_constant_v1 = function(e) {
1425
1425
  INFINITY: ["Infinity", c.ATOMIC]
1426
1426
  }[e.getFieldValue("CONSTANT")];
1427
1427
  };
1428
- g([
1428
+ m([
1429
1429
  {
1430
1430
  type: "math_constrain_v1",
1431
1431
  message0: "%{BKY_MATH_V1_CONSTRAIN_TITLE}",
@@ -1457,7 +1457,7 @@ a.forBlock.math_constrain_v1 = function(e) {
1457
1457
  const o = a.valueToCode(e, "VALUE", c.NONE) || "0", t = a.valueToCode(e, "LOW", c.NONE) || "0", n = a.valueToCode(e, "HIGH", c.NONE) || "Infinity";
1458
1458
  return [`Math.min(Math.max(${o}, ${t}), ${n})`, c.FUNCTION_CALL];
1459
1459
  };
1460
- g([
1460
+ m([
1461
1461
  {
1462
1462
  type: "math_modulo_v1",
1463
1463
  message0: "%{BKY_MATH_V1_MODULO_TITLE}",
@@ -1484,7 +1484,7 @@ a.forBlock.math_modulo_v1 = function(e) {
1484
1484
  const o = a.valueToCode(e, "DIVIDEND", c.MODULUS) || "0", t = a.valueToCode(e, "DIVISOR", c.MODULUS) || "0";
1485
1485
  return [o + " % " + t, c.MODULUS];
1486
1486
  };
1487
- g([
1487
+ m([
1488
1488
  {
1489
1489
  type: "math_number_v1",
1490
1490
  message0: "%1",
@@ -1506,7 +1506,7 @@ a.forBlock.math_number_v1 = function(e) {
1506
1506
  const o = Number(e.getFieldValue("NUM")), t = o >= 0 ? c.ATOMIC : c.UNARY_NEGATION;
1507
1507
  return [String(o), t];
1508
1508
  };
1509
- g([
1509
+ m([
1510
1510
  {
1511
1511
  type: "math_number_property_v1",
1512
1512
  message0: "%{BKY_MATH_V1_NUMBER_PROPERTY_TITLE}",
@@ -1578,7 +1578,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(n) {
1578
1578
  s = l + n;
1579
1579
  return [s, r];
1580
1580
  };
1581
- g([
1581
+ m([
1582
1582
  {
1583
1583
  type: "math_on_list_v1",
1584
1584
  message0: "%{BKY_MATH_V1_ON_LIST_TITLE}",
@@ -1728,7 +1728,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(list) {
1728
1728
  }
1729
1729
  return [n, c.FUNCTION_CALL];
1730
1730
  };
1731
- g([
1731
+ m([
1732
1732
  {
1733
1733
  type: "math_random_float_v1",
1734
1734
  message0: "%{BKY_MATH_V1_RANDOM_FLOAT_TITLE}",
@@ -1741,7 +1741,7 @@ g([
1741
1741
  a.forBlock.math_random_float_v1 = function() {
1742
1742
  return ["Math.random()", c.FUNCTION_CALL];
1743
1743
  };
1744
- g([
1744
+ m([
1745
1745
  {
1746
1746
  type: "math_random_int_v1",
1747
1747
  message0: "%{BKY_MATH_V1_RANDOM_INT_TITLE}",
@@ -1781,7 +1781,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(a, b) {
1781
1781
  `
1782
1782
  ) + "(" + o + ", " + t + ")", c.FUNCTION_CALL];
1783
1783
  };
1784
- g([
1784
+ m([
1785
1785
  {
1786
1786
  type: "math_round_v1",
1787
1787
  message0: "%1 %2",
@@ -1823,7 +1823,7 @@ a.forBlock.math_round_v1 = function(e) {
1823
1823
  }
1824
1824
  return [n, c.FUNCTION_CALL];
1825
1825
  };
1826
- g([
1826
+ m([
1827
1827
  {
1828
1828
  type: "math_single_v1",
1829
1829
  message0: "%1 %2",
@@ -1886,7 +1886,7 @@ a.forBlock.math_single_v1 = function(e) {
1886
1886
  }
1887
1887
  return [t, c.DIVISION];
1888
1888
  };
1889
- g([
1889
+ m([
1890
1890
  {
1891
1891
  type: "math_trig_v1",
1892
1892
  message0: "%1 %2",
@@ -1948,20 +1948,20 @@ a.forBlock.math_trig_v1 = function(e) {
1948
1948
  }
1949
1949
  return [n, c.DIVISION];
1950
1950
  };
1951
- const Yi = m.xml, Ki = {
1951
+ const Yi = T.xml, Ki = {
1952
1952
  init: function() {
1953
1953
  this.appendDummyInput().appendField(
1954
1954
  "%{BKY_OBJECT_V1_CREATE_CONTAINER_TITLE}"
1955
1955
  ), this.appendStatementInput("STACK"), this.setStyle("object_blocks"), this.contextMenu = !1;
1956
1956
  }
1957
1957
  };
1958
- _e.object_create_container_v1 = Ki;
1958
+ de.object_create_container_v1 = Ki;
1959
1959
  const Fi = {
1960
1960
  init: function() {
1961
1961
  this.appendDummyInput().appendField("%{BKY_OBJECT_V1_CREATE_ITEM_TITLE}"), this.setPreviousStatement(!0), this.setNextStatement(!0), this.setStyle("object_blocks"), this.contextMenu = !1;
1962
1962
  }
1963
1963
  };
1964
- _e.object_create_item_v1 = Fi;
1964
+ de.object_create_item_v1 = Fi;
1965
1965
  const Hi = {
1966
1966
  init: function() {
1967
1967
  this.itemCount_ = 0, this.appendDummyInput().appendField("%{BKY_OBJECT_V1_CREATE_TITLE}"), this.setMutator(
@@ -2037,12 +2037,12 @@ const Hi = {
2037
2037
  },
2038
2038
  updateShape_: function() {
2039
2039
  for (let e = 0; e < this.itemCount_; e++)
2040
- this.getInput("ADD" + e) || this.appendValueInput("ADD" + e).setAlign(De.Align.RIGHT).appendField(new vo("key"), "KEY" + e);
2040
+ this.getInput("ADD" + e) || this.appendValueInput("ADD" + e).setAlign(xe.Align.RIGHT).appendField(new vo("key"), "KEY" + e);
2041
2041
  for (let e = this.itemCount_; this.getInput("ADD" + e); e++)
2042
2042
  this.removeInput("ADD" + e);
2043
2043
  }
2044
2044
  };
2045
- _e.object_create_v1 = Hi;
2045
+ de.object_create_v1 = Hi;
2046
2046
  a.forBlock.object_create_v1 = function(e) {
2047
2047
  const o = e;
2048
2048
  let t = "{";
@@ -2052,7 +2052,7 @@ a.forBlock.object_create_v1 = function(e) {
2052
2052
  }
2053
2053
  return t += "}", [t, c.ATOMIC];
2054
2054
  };
2055
- g([
2055
+ m([
2056
2056
  {
2057
2057
  type: "object_delete_v1",
2058
2058
  message0: "%{BKY_OBJECT_V1_DELETE_TITLE}",
@@ -2119,7 +2119,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(obj, key) {
2119
2119
  return `${o}(${t}, ${n});
2120
2120
  `;
2121
2121
  };
2122
- g([
2122
+ m([
2123
2123
  {
2124
2124
  type: "object_from_json_v1",
2125
2125
  message0: "%{BKY_OBJECT_V1_FROM_JSON_TITLE}",
@@ -2140,7 +2140,7 @@ g([
2140
2140
  a.forBlock.object_from_json_v1 = function(e) {
2141
2141
  return [`__parseJsonV1__(${a.valueToCode(e, "JSON", c.NONE) || "''"})`, c.FUNCTION_CALL];
2142
2142
  };
2143
- g([
2143
+ m([
2144
2144
  {
2145
2145
  type: "object_get_v1",
2146
2146
  message0: "%{BKY_OBJECT_V1_GET_TITLE}",
@@ -2205,7 +2205,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(obj, key) {
2205
2205
  ), t = a.valueToCode(e, "OBJECT", c.ATOMIC) || "null", n = a.valueToCode(e, "KEY", c.ATOMIC) || "''";
2206
2206
  return [`${o}(${t}, ${n})`, c.FUNCTION_CALL];
2207
2207
  };
2208
- g([
2208
+ m([
2209
2209
  {
2210
2210
  type: "object_set_v1",
2211
2211
  message0: "%{BKY_OBJECT_V1_SET_TITLE}",
@@ -2279,7 +2279,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(obj, key, val) {
2279
2279
  return `${o}(${t}, ${n}, ${i});
2280
2280
  `;
2281
2281
  };
2282
- g([
2282
+ m([
2283
2283
  {
2284
2284
  type: "object_to_json_v1",
2285
2285
  message0: "%{BKY_OBJECT_V1_TO_JSON_TITLE}",
@@ -2300,12 +2300,12 @@ g([
2300
2300
  a.forBlock.object_to_json_v1 = function(e) {
2301
2301
  return [`__jsonStringifyV1__(${a.valueToCode(e, "OBJECT", c.NONE) || "null"})`, c.FUNCTION_CALL];
2302
2302
  };
2303
- const Bo = m.xml, Gi = {
2303
+ const Bo = T.xml, Gi = {
2304
2304
  init: function() {
2305
2305
  this.appendDummyInput().appendField("%{BKY_PROCEDURE_V1_DEF_CONTAINER_TITLE}").appendField(new Wn(!1), "WITHRETURN"), this.appendStatementInput("STACK"), this.setStyle("procedure_blocks"), this.contextMenu = !1;
2306
2306
  }
2307
2307
  };
2308
- _e.procedure_def_container_v1 = Gi;
2308
+ de.procedure_def_container_v1 = Gi;
2309
2309
  const Xi = {
2310
2310
  init: function() {
2311
2311
  const e = new vo(uo.DEFAULT_ARG);
@@ -2328,7 +2328,7 @@ const Xi = {
2328
2328
  return e;
2329
2329
  }
2330
2330
  };
2331
- _e.procedure_def_item_v1 = Xi;
2331
+ de.procedure_def_item_v1 = Xi;
2332
2332
  const $i = {
2333
2333
  init: function() {
2334
2334
  this.withReturn = !1, this.args = [];
@@ -2422,15 +2422,15 @@ const $i = {
2422
2422
  n.setKeyName(o.name, "");
2423
2423
  else
2424
2424
  try {
2425
- F.disable(), n = rn(this.workspace, o.name, ""), n.outputConnection.connect(t);
2425
+ G.disable(), n = rn(this.workspace, o.name, ""), n.outputConnection.connect(t);
2426
2426
  } finally {
2427
- F.enable();
2427
+ G.enable();
2428
2428
  }
2429
2429
  }
2430
2430
  }
2431
2431
  };
2432
- _e.procedure_def_v1 = $i;
2433
- const ji = m.xml, Wi = {
2432
+ de.procedure_def_v1 = $i;
2433
+ const ji = T.xml, Wi = {
2434
2434
  init: function() {
2435
2435
  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}");
2436
2436
  },
@@ -2455,7 +2455,7 @@ const ji = m.xml, Wi = {
2455
2455
  },
2456
2456
  onchange: function(e) {
2457
2457
  var o;
2458
- if (e.type === F.BLOCK_DRAG) {
2458
+ if (e.type === G.BLOCK_DRAG) {
2459
2459
  const t = e;
2460
2460
  if (t.isStart || !((o = t.blocks) != null && o.find((n) => n.id === this.id)))
2461
2461
  return;
@@ -2486,14 +2486,14 @@ const ji = m.xml, Wi = {
2486
2486
  e.type === "procedure_def_v1" || e.type === "func_entry_v1" ? this.setWarningText(null) : this.setWarningText("the block can only be used in procedure block");
2487
2487
  }
2488
2488
  };
2489
- _e.procedure_return_v1 = Wi;
2489
+ de.procedure_return_v1 = Wi;
2490
2490
  a.forBlock.procedure_return_v1 = function(e) {
2491
2491
  const o = e;
2492
2492
  return o.withReturn ? `return ${a.valueToCode(o, "VALUE", c.NONE) || "null"};
2493
2493
  ` : `return;
2494
2494
  `;
2495
2495
  };
2496
- g([
2496
+ m([
2497
2497
  {
2498
2498
  type: "text_v1",
2499
2499
  message0: "%{BKY_TEXT_V1_TEXT_TITLE}",
@@ -2518,14 +2518,14 @@ const Ji = /^\s*'([^']|\\')*'\s*$/;
2518
2518
  function Ot(e) {
2519
2519
  return Ji.test(e) ? [e, c.ATOMIC] : [`String(${e})`, c.FUNCTION_CALL];
2520
2520
  }
2521
- V.register(
2521
+ Y.register(
2522
2522
  "text_append_tooltip_v1",
2523
- V.buildTooltipWithFieldText(
2523
+ Y.buildTooltipWithFieldText(
2524
2524
  "%{BKY_TEXT_V1_APPEND_TOOLTIP}",
2525
2525
  "VAR"
2526
2526
  )
2527
2527
  );
2528
- g([
2528
+ m([
2529
2529
  {
2530
2530
  type: "text_append_v1",
2531
2531
  message0: "%{BKY_TEXT_V1_APPEND_TITLE}",
@@ -2555,7 +2555,7 @@ a.forBlock.text_append_v1 = function(e) {
2555
2555
  return `${o} += ${Ot(t)};
2556
2556
  `;
2557
2557
  };
2558
- g([
2558
+ m([
2559
2559
  {
2560
2560
  type: "text_change_case_v1",
2561
2561
  message0: "%{BKY_TEXT_V1_CHANGE_CASE_TITLE}",
@@ -2601,7 +2601,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(str) {
2601
2601
  `
2602
2602
  ) + "(" + n + ")", [i, c.FUNCTION_CALL];
2603
2603
  };
2604
- g([
2604
+ m([
2605
2605
  {
2606
2606
  type: "text_char_at_v1",
2607
2607
  message0: "%{BKY_TEXT_V1_CHAR_AT_TITLE}",
@@ -2628,7 +2628,7 @@ a.forBlock.text_char_at_v1 = function(e) {
2628
2628
  const o = a.valueToCode(e, "VALUE", c.MEMBER) || "[]", t = a.getAdjusted(e, "AT");
2629
2629
  return [`${o}.charAt(${t})`, c.FUNCTION_CALL];
2630
2630
  };
2631
- g([
2631
+ m([
2632
2632
  {
2633
2633
  type: "text_count_v1",
2634
2634
  message0: "%{BKY_TEXT_V1_COUNT_TITLE}",
@@ -2666,7 +2666,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(haystack, needle) {
2666
2666
  `
2667
2667
  )}(${o}, ${t})`, c.FUNCTION_CALL];
2668
2668
  };
2669
- g([
2669
+ m([
2670
2670
  {
2671
2671
  type: "text_index_of_v1",
2672
2672
  message0: "%{BKY_TEXT_V1_INDEX_OF_TITLE}",
@@ -2701,7 +2701,7 @@ a.forBlock.text_index_of_v1 = function(e) {
2701
2701
  const o = e.getFieldValue("OP") === "FIRST" ? "indexOf" : "lastIndexOf", t = a.valueToCode(e, "TEXT", c.MEMBER) || "''", n = a.valueToCode(e, "SUBSTR", c.NONE) || "''";
2702
2702
  return [`${t}.${o}(${n})`, c.FUNCTION_CALL];
2703
2703
  };
2704
- g([
2704
+ m([
2705
2705
  {
2706
2706
  type: "text_is_empty_v1",
2707
2707
  message0: "%{BKY_TEXT_V1_IS_EMPTY_TITLE}",
@@ -2721,7 +2721,7 @@ g([
2721
2721
  a.forBlock.text_is_empty_v1 = function(e) {
2722
2722
  return [`!${a.valueToCode(e, "VALUE", c.MEMBER) || "''"}.length`, c.LOGICAL_NOT];
2723
2723
  };
2724
- const zi = m.xml, qi = {
2724
+ const zi = T.xml, qi = {
2725
2725
  itemCount_: 0,
2726
2726
  mutationToDom: function() {
2727
2727
  const e = zi.createElement("mutation");
@@ -2789,7 +2789,7 @@ const zi = m.xml, qi = {
2789
2789
  for (let e = 0; e < this.itemCount_; e++)
2790
2790
  if (!this.getInput("ADD" + e)) {
2791
2791
  const o = this.appendValueInput("ADD" + e).setAlign(
2792
- De.Align.RIGHT
2792
+ xe.Align.RIGHT
2793
2793
  );
2794
2794
  e === 0 && o.appendField("%{BKY_TEXT_V1_JOIN_TITLE}");
2795
2795
  }
@@ -2799,12 +2799,12 @@ const zi = m.xml, qi = {
2799
2799
  }, Qi = function() {
2800
2800
  this.itemCount_ = 2, this.updateShape_(), this.setMutator(new wt.MutatorIcon(["text_join_item_v1"], this));
2801
2801
  };
2802
- V.registerMutator(
2802
+ Y.registerMutator(
2803
2803
  "text_join_mutator_v1",
2804
2804
  qi,
2805
2805
  Qi
2806
2806
  );
2807
- g([
2807
+ m([
2808
2808
  {
2809
2809
  type: "text_join_v1",
2810
2810
  message0: "",
@@ -2859,7 +2859,7 @@ a.forBlock.text_join_v1 = function(e) {
2859
2859
  }
2860
2860
  }
2861
2861
  };
2862
- g([
2862
+ m([
2863
2863
  {
2864
2864
  type: "text_length_v1",
2865
2865
  message0: "%{BKY_TEXT_V1_LENGTH_TITLE}",
@@ -2879,7 +2879,7 @@ g([
2879
2879
  a.forBlock.text_length_v1 = function(e) {
2880
2880
  return [`${a.valueToCode(e, "VALUE", c.MEMBER) || "''"}.length`, c.MEMBER];
2881
2881
  };
2882
- g([
2882
+ m([
2883
2883
  {
2884
2884
  type: "text_replace_v1",
2885
2885
  message0: "%{BKY_TEXT_V1_REPLACE_TITLE}",
@@ -2920,7 +2920,7 @@ function ${a.FUNCTION_NAME_PLACEHOLDER_}(haystack, needle, replacement) {
2920
2920
  `
2921
2921
  )}(${o}, ${t}, ${n})`, c.FUNCTION_CALL];
2922
2922
  };
2923
- g([
2923
+ m([
2924
2924
  {
2925
2925
  type: "text_reverse_v1",
2926
2926
  message0: "%{BKY_TEXT_V1_REVERSE_TITLE}",
@@ -2941,7 +2941,7 @@ g([
2941
2941
  a.forBlock.text_reverse_v1 = function(e) {
2942
2942
  return [(a.valueToCode(e, "TEXT", c.MEMBER) || "''") + ".split('').reverse().join('')", c.FUNCTION_CALL];
2943
2943
  };
2944
- g([
2944
+ m([
2945
2945
  {
2946
2946
  type: "text_split_v1",
2947
2947
  message0: "%{BKY_TEXT_V1_SPLIT_TITLE}",
@@ -2968,7 +2968,7 @@ a.forBlock.text_split_v1 = function(e) {
2968
2968
  const o = a.valueToCode(e, "TEXT", c.MEMBER) || "''", t = a.valueToCode(e, "DELIM", c.NONE) || "''";
2969
2969
  return [`${o}.split(${t})`, c.FUNCTION_CALL];
2970
2970
  };
2971
- g([
2971
+ m([
2972
2972
  {
2973
2973
  type: "text_substring_v1",
2974
2974
  message0: "%{BKY_TEXT_V1_SUBSTRING_TITLE}",
@@ -3000,7 +3000,7 @@ a.forBlock.text_substring_v1 = function(e) {
3000
3000
  const o = a.valueToCode(e, "TEXT", c.MEMBER) || "''", t = a.getAdjusted(e, "START"), n = a.getAdjusted(e, "END", 1);
3001
3001
  return [`${o}.slice(${t}, ${n})`, c.FUNCTION_CALL];
3002
3002
  };
3003
- g([
3003
+ m([
3004
3004
  {
3005
3005
  type: "text_trim_v1",
3006
3006
  message0: "%{BKY_TEXT_V1_TRIM_TITLE}",
@@ -3045,7 +3045,7 @@ const Zi = {
3045
3045
  this.updateShape_(), this.updateShadow_();
3046
3046
  },
3047
3047
  updateShape_: function() {
3048
- this.getInput("CALLBACK") || this.appendStatementInput("CALLBACK").appendField("%{BKY_TIME_DO}"), this.getInput("IMMEDIATE") || (this.appendValueInput("IMMEDIATE").setCheck("Boolean").setAlign(De.Align.RIGHT).appendField("%{BKY_TIME_IMMEDIATE}"), this.moveInputBefore("IMMEDIATE", "CALLBACK")), this.getInput("COUNT") || (this.appendValueInput("COUNT").setCheck("Number").setAlign(De.Align.RIGHT).appendField("%{BKY_TIME_COUNT}"), this.moveInputBefore("COUNT", "IMMEDIATE")), this.getInput("LOOP") || (this.appendValueInput("LOOP").setCheck("Boolean").setAlign(De.Align.RIGHT).appendField("%{BKY_TIME_LOOP}"), this.moveInputBefore("LOOP", "COUNT")), this.getInput("INTERVAL") || (this.appendValueInput("INTERVAL").setCheck("Number").setAlign(De.Align.RIGHT).appendField("%{BKY_TIME_INTERVAL_MS}"), this.moveInputBefore("INTERVAL", "LOOP"));
3048
+ this.getInput("CALLBACK") || this.appendStatementInput("CALLBACK").appendField("%{BKY_TIME_DO}"), this.getInput("IMMEDIATE") || (this.appendValueInput("IMMEDIATE").setCheck("Boolean").setAlign(xe.Align.RIGHT).appendField("%{BKY_TIME_IMMEDIATE}"), this.moveInputBefore("IMMEDIATE", "CALLBACK")), this.getInput("COUNT") || (this.appendValueInput("COUNT").setCheck("Number").setAlign(xe.Align.RIGHT).appendField("%{BKY_TIME_COUNT}"), this.moveInputBefore("COUNT", "IMMEDIATE")), this.getInput("LOOP") || (this.appendValueInput("LOOP").setCheck("Boolean").setAlign(xe.Align.RIGHT).appendField("%{BKY_TIME_LOOP}"), this.moveInputBefore("LOOP", "COUNT")), this.getInput("INTERVAL") || (this.appendValueInput("INTERVAL").setCheck("Number").setAlign(xe.Align.RIGHT).appendField("%{BKY_TIME_INTERVAL_MS}"), this.moveInputBefore("INTERVAL", "LOOP"));
3049
3049
  },
3050
3050
  updateShadow_: function() {
3051
3051
  var e, o, t, n, i, r, l, s;
@@ -3060,7 +3060,7 @@ const Zi = {
3060
3060
  ));
3061
3061
  }
3062
3062
  };
3063
- _e.create_timer_v1 = Zi;
3063
+ de.create_timer_v1 = Zi;
3064
3064
  a.forBlock.create_timer_v1 = function(e) {
3065
3065
  const o = a.valueToCode(e, "INTERVAL", c.ATOMIC) || "1000", t = a.valueToCode(e, "LOOP", c.ATOMIC) || "false", n = a.valueToCode(e, "COUNT", c.ATOMIC) || "1", i = a.valueToCode(e, "IMMEDIATE", c.ATOMIC) || "false", r = a.statementToCode(e, "CALLBACK");
3066
3066
  return `__createTimerV1__(${o}, ${t}, ${n}, ${i}, function() {
@@ -3068,7 +3068,7 @@ a.forBlock.create_timer_v1 = function(e) {
3068
3068
  });
3069
3069
  `;
3070
3070
  };
3071
- g([
3071
+ m([
3072
3072
  {
3073
3073
  type: "delay_v1",
3074
3074
  message0: "%{BKY_TIME_V1_DELAY_TITLE}",
@@ -3095,11 +3095,11 @@ const er = {
3095
3095
  if (this.isInFlyout) {
3096
3096
  if (this.type === "variables_get_v1" || this.type === "variables_get_v1_reporter") {
3097
3097
  const o = {
3098
- text: j.RENAME_VARIABLE,
3098
+ text: W.RENAME_VARIABLE,
3099
3099
  enabled: !0,
3100
3100
  callback: tr(this)
3101
3101
  }, t = this.getField("VAR").getText(), n = {
3102
- text: j.DELETE_VARIABLE.replace("%1", t),
3102
+ text: W.DELETE_VARIABLE.replace("%1", t),
3103
3103
  enabled: !0,
3104
3104
  callback: or(this)
3105
3105
  };
@@ -3107,7 +3107,7 @@ const er = {
3107
3107
  }
3108
3108
  } else {
3109
3109
  let o, t;
3110
- this.type === "variables_get_v1" ? (o = "variables_set_v1", t = j.VARIABLE_V1_GET_CREATE_SET) : this.type === "variables_set_v1" ? (o = "variables_get_v1", t = j.VARIABLE_V1_SET_CREATE_GET) : console.assert(!1);
3110
+ this.type === "variables_get_v1" ? (o = "variables_set_v1", t = W.VARIABLE_V1_GET_CREATE_SET) : this.type === "variables_set_v1" ? (o = "variables_get_v1", t = W.VARIABLE_V1_SET_CREATE_GET) : console.assert(!1);
3111
3111
  const n = this.getField("VAR"), i = {
3112
3112
  type: o,
3113
3113
  fields: { VAR: n.saveState(!0) }
@@ -3130,11 +3130,11 @@ const er = {
3130
3130
  o.deleteVariableById(n.getId()), o.refreshToolboxSelection();
3131
3131
  };
3132
3132
  };
3133
- V.registerMixin(
3133
+ Y.registerMixin(
3134
3134
  "context_menu_variable_v1",
3135
3135
  er
3136
3136
  );
3137
- g([
3137
+ m([
3138
3138
  {
3139
3139
  type: "variable_get_v1",
3140
3140
  message0: "%1",
@@ -3157,7 +3157,7 @@ a.forBlock.variable_get_v1 = function(e) {
3157
3157
  yo.NameType.VARIABLE
3158
3158
  ), c.ATOMIC];
3159
3159
  };
3160
- g([
3160
+ m([
3161
3161
  {
3162
3162
  type: "variable_set_v1",
3163
3163
  message0: "%{BKY_VARIABLE_V1_SET_TITLE}",
@@ -3188,12 +3188,12 @@ a.forBlock.variable_set_v1 = function(e) {
3188
3188
  return `${o} = ${t};
3189
3189
  `;
3190
3190
  };
3191
- const Ro = m.xml;
3191
+ const Ro = T.xml;
3192
3192
  function nr() {
3193
3193
  const e = [];
3194
3194
  {
3195
3195
  const o = Ro.createElement("label");
3196
- o.setAttribute("text", j.LABEL_ASSET_LAYER), e.push(o);
3196
+ o.setAttribute("text", W.LABEL_ASSET_LAYER), e.push(o);
3197
3197
  }
3198
3198
  {
3199
3199
  const o = Ro.createElement("block");
@@ -3204,33 +3204,33 @@ function nr() {
3204
3204
  const ln = {
3205
3205
  name: "INTERFACE_CATEGORY",
3206
3206
  callback: nr
3207
- }, Ze = m.xml;
3207
+ }, et = T.xml;
3208
3208
  function ir() {
3209
3209
  const e = [];
3210
3210
  {
3211
- const o = Ze.createElement("label");
3211
+ const o = et.createElement("label");
3212
3212
  o.setAttribute("text", "%{BKY_LABEL_PROCEDURE}"), e.push(o);
3213
3213
  }
3214
3214
  {
3215
- const o = Ze.createElement("block");
3215
+ const o = et.createElement("block");
3216
3216
  o.setAttribute("type", "procedure_def_v1");
3217
3217
  {
3218
- const t = Ze.createElement("field");
3218
+ const t = et.createElement("field");
3219
3219
  t.setAttribute("name", "NAME");
3220
- const n = Ze.createTextNode(
3221
- j.PROCEDURE_DEFAULT_NAME
3220
+ const n = et.createTextNode(
3221
+ W.PROCEDURE_DEFAULT_NAME
3222
3222
  );
3223
3223
  t.appendChild(n), o.appendChild(t);
3224
3224
  }
3225
3225
  e.push(o);
3226
3226
  }
3227
3227
  {
3228
- const o = Ze.createElement("block");
3228
+ const o = et.createElement("block");
3229
3229
  o.setAttribute("type", "procedure_return_v1"), e.push(o);
3230
3230
  }
3231
3231
  return e;
3232
3232
  }
3233
- const se = {
3233
+ const _e = {
3234
3234
  name: "PROCEDURE_CATEGORY",
3235
3235
  callback: ir
3236
3236
  };
@@ -3240,7 +3240,7 @@ function rr() {
3240
3240
  o.push({ id: t, name: n, type: i });
3241
3241
  }), o;
3242
3242
  }
3243
- const Mo = m.xml;
3243
+ const Mo = T.xml;
3244
3244
  function lr() {
3245
3245
  const e = [];
3246
3246
  if (rr().length > 0) {
@@ -3255,10 +3255,10 @@ function lr() {
3255
3255
  }
3256
3256
  return e;
3257
3257
  }
3258
- const Xe = {
3258
+ const $e = {
3259
3259
  name: "UI_CATEGORY",
3260
3260
  callback: lr
3261
- }, ht = m.xml;
3261
+ }, ht = T.xml;
3262
3262
  function ar(e) {
3263
3263
  const o = [];
3264
3264
  {
@@ -3282,7 +3282,7 @@ function ar(e) {
3282
3282
  t.sort(Jn.compareByName);
3283
3283
  {
3284
3284
  const n = ht.createElement("label");
3285
- n.setAttribute("text", j.LABEL_CREATED), o.push(n);
3285
+ n.setAttribute("text", W.LABEL_CREATED), o.push(n);
3286
3286
  }
3287
3287
  return t.forEach((n) => {
3288
3288
  {
@@ -3295,7 +3295,7 @@ function ar(e) {
3295
3295
  }
3296
3296
  }), o;
3297
3297
  }
3298
- const ce = {
3298
+ const pe = {
3299
3299
  name: "VARIABLE_CATEGORY",
3300
3300
  callback: ar
3301
3301
  };
@@ -3331,7 +3331,7 @@ async function Do(e) {
3331
3331
  zn(o.default);
3332
3332
  }
3333
3333
  function sn(e) {
3334
- const o = we();
3334
+ const o = Ve();
3335
3335
  if (!o)
3336
3336
  return;
3337
3337
  const t = o.getBlockById(e);
@@ -3345,7 +3345,7 @@ function sn(e) {
3345
3345
  }
3346
3346
  function cn() {
3347
3347
  var t;
3348
- const e = we();
3348
+ const e = Ve();
3349
3349
  if (!e)
3350
3350
  return;
3351
3351
  const o = (t = e.getTopBlocks(!0)) == null ? void 0 : t[0];
@@ -3356,22 +3356,22 @@ class sr {
3356
3356
  contextMenu: !0,
3357
3357
  shortcut: !0
3358
3358
  }) {
3359
- o && (this.blockCopyToStorageContextMenu(), this.blockPasteFromStorageContextMenu()), t && (z.registry.unregister(
3359
+ o && (this.blockCopyToStorageContextMenu(), this.blockPasteFromStorageContextMenu()), t && (q.registry.unregister(
3360
3360
  Jt.names.COPY
3361
- ), z.registry.unregister(
3361
+ ), q.registry.unregister(
3362
3362
  Jt.names.CUT
3363
- ), z.registry.unregister(
3363
+ ), q.registry.unregister(
3364
3364
  Jt.names.PASTE
3365
3365
  ), this.blockCopyToStorageShortcut(), this.blockCutToStorageShortcut(), this.blockPasteFromStorageShortcut());
3366
3366
  }
3367
3367
  blockCopyToStorageContextMenu() {
3368
3368
  const o = {
3369
3369
  displayText: function() {
3370
- return j.CROSS_TAB_COPY ? j.CROSS_TAB_COPY : "Copy";
3370
+ return W.CROSS_TAB_COPY ? W.CROSS_TAB_COPY : "Copy";
3371
3371
  },
3372
3372
  preconditionFn: function() {
3373
- const t = Fe();
3374
- return !t || !_t(t) || !t.isDeletable() || !zt(t) || !t.isMovable() || !Qe(t) ? "disabled" : "enabled";
3373
+ const t = He();
3374
+ return !t || !_t(t) || !t.isDeletable() || !zt(t) || !t.isMovable() || !Ze(t) ? "disabled" : "enabled";
3375
3375
  },
3376
3376
  callback: function(t) {
3377
3377
  var n;
@@ -3380,16 +3380,16 @@ class sr {
3380
3380
  JSON.stringify((n = t.block) == null ? void 0 : n.toCopyData())
3381
3381
  );
3382
3382
  },
3383
- scopeType: xe.ScopeType.BLOCK,
3383
+ scopeType: Pe.ScopeType.BLOCK,
3384
3384
  id: "blockCopyToStorage",
3385
3385
  weight: 0
3386
3386
  };
3387
- xe.registry.register(o);
3387
+ Pe.registry.register(o);
3388
3388
  }
3389
3389
  blockPasteFromStorageContextMenu() {
3390
3390
  const o = {
3391
3391
  displayText: function() {
3392
- return j.CROSS_TAB_PASTE ? j.CROSS_TAB_PASTE : "Paste";
3392
+ return W.CROSS_TAB_PASTE ? W.CROSS_TAB_PASTE : "Paste";
3393
3393
  },
3394
3394
  preconditionFn: function(t) {
3395
3395
  var r;
@@ -3406,82 +3406,82 @@ class sr {
3406
3406
  const i = JSON.parse(n);
3407
3407
  i && t.workspace && ko.paste(i, t.workspace);
3408
3408
  },
3409
- scopeType: xe.ScopeType.WORKSPACE,
3409
+ scopeType: Pe.ScopeType.WORKSPACE,
3410
3410
  id: "blockPasteFromStorage",
3411
3411
  weight: 0
3412
3412
  };
3413
- xe.registry.register(o);
3413
+ Pe.registry.register(o);
3414
3414
  }
3415
3415
  blockCopyToStorageShortcut() {
3416
- const o = z.registry.createSerializedKey(
3417
- m.KeyCodes.C,
3418
- [m.KeyCodes.CTRL]
3419
- ), t = z.registry.createSerializedKey(
3420
- m.KeyCodes.C,
3421
- [m.KeyCodes.ALT]
3422
- ), n = z.registry.createSerializedKey(
3423
- m.KeyCodes.C,
3424
- [m.KeyCodes.META]
3416
+ const o = q.registry.createSerializedKey(
3417
+ T.KeyCodes.C,
3418
+ [T.KeyCodes.CTRL]
3419
+ ), t = q.registry.createSerializedKey(
3420
+ T.KeyCodes.C,
3421
+ [T.KeyCodes.ALT]
3422
+ ), n = q.registry.createSerializedKey(
3423
+ T.KeyCodes.C,
3424
+ [T.KeyCodes.META]
3425
3425
  ), i = {
3426
3426
  name: "copy",
3427
3427
  preconditionFn: function(r) {
3428
3428
  if (r.options.readOnly || qt.inProgress())
3429
3429
  return !1;
3430
- const l = Fe();
3431
- return !(!l || !_t(l) || !l.isDeletable() || !zt(l) || !l.isMovable() || !Qe(l));
3430
+ const l = He();
3431
+ return !(!l || !_t(l) || !l.isDeletable() || !zt(l) || !l.isMovable() || !Ze(l));
3432
3432
  },
3433
3433
  callback: function(r, l) {
3434
3434
  l.preventDefault();
3435
- const s = Fe();
3436
- if (!s || !Qe(s))
3435
+ const s = He();
3436
+ if (!s || !Ze(s))
3437
3437
  return !1;
3438
3438
  const u = s.toCopyData();
3439
3439
  return u ? (r.hideChaff(), localStorage.setItem("blocklyStash", JSON.stringify(u)), !0) : !1;
3440
3440
  },
3441
3441
  keyCodes: [o, t, n]
3442
3442
  };
3443
- z.registry.register(i);
3443
+ q.registry.register(i);
3444
3444
  }
3445
3445
  blockCutToStorageShortcut() {
3446
- const o = z.registry.createSerializedKey(
3447
- m.KeyCodes.X,
3448
- [m.KeyCodes.CTRL]
3449
- ), t = z.registry.createSerializedKey(
3450
- m.KeyCodes.X,
3451
- [m.KeyCodes.ALT]
3452
- ), n = z.registry.createSerializedKey(
3453
- m.KeyCodes.X,
3454
- [m.KeyCodes.META]
3446
+ const o = q.registry.createSerializedKey(
3447
+ T.KeyCodes.X,
3448
+ [T.KeyCodes.CTRL]
3449
+ ), t = q.registry.createSerializedKey(
3450
+ T.KeyCodes.X,
3451
+ [T.KeyCodes.ALT]
3452
+ ), n = q.registry.createSerializedKey(
3453
+ T.KeyCodes.X,
3454
+ [T.KeyCodes.META]
3455
3455
  ), i = {
3456
3456
  name: "cut",
3457
3457
  preconditionFn: function(r) {
3458
3458
  if (r.options.readOnly || qt.inProgress())
3459
3459
  return !1;
3460
- const l = Fe();
3461
- return !(!l || !_t(l) || !l.isDeletable() || !zt(l) || !l.isMovable() || !Qe(l) || l.workspace.isFlyout);
3460
+ const l = He();
3461
+ return !(!l || !_t(l) || !l.isDeletable() || !zt(l) || !l.isMovable() || !Ze(l) || l.workspace.isFlyout);
3462
3462
  },
3463
3463
  callback: function(r, l) {
3464
3464
  l.preventDefault();
3465
- const s = Fe();
3466
- if (!s || !_t(s) || !s.isDeletable() || !Qe(s))
3465
+ const s = He();
3466
+ if (!s || !_t(s) || !s.isDeletable() || !Ze(s))
3467
3467
  return !1;
3468
3468
  const u = s.toCopyData();
3469
3469
  return u ? (localStorage.setItem("blocklyStash", JSON.stringify(u)), s instanceof qn ? s.checkAndDelete() : s.dispose(), !0) : !1;
3470
3470
  },
3471
3471
  keyCodes: [o, t, n]
3472
3472
  };
3473
- z.registry.register(i);
3473
+ q.registry.register(i);
3474
3474
  }
3475
3475
  blockPasteFromStorageShortcut() {
3476
- const o = z.registry.createSerializedKey(
3477
- m.KeyCodes.V,
3478
- [m.KeyCodes.CTRL]
3479
- ), t = z.registry.createSerializedKey(
3480
- m.KeyCodes.V,
3481
- [m.KeyCodes.ALT]
3482
- ), n = z.registry.createSerializedKey(
3483
- m.KeyCodes.V,
3484
- [m.KeyCodes.META]
3476
+ const o = q.registry.createSerializedKey(
3477
+ T.KeyCodes.V,
3478
+ [T.KeyCodes.CTRL]
3479
+ ), t = q.registry.createSerializedKey(
3480
+ T.KeyCodes.V,
3481
+ [T.KeyCodes.ALT]
3482
+ ), n = q.registry.createSerializedKey(
3483
+ T.KeyCodes.V,
3484
+ [T.KeyCodes.META]
3485
3485
  ), i = {
3486
3486
  name: "paste",
3487
3487
  preconditionFn: function(r) {
@@ -3503,17 +3503,17 @@ class sr {
3503
3503
  },
3504
3504
  keyCodes: [o, t, n]
3505
3505
  };
3506
- z.registry.register(i);
3506
+ q.registry.register(i);
3507
3507
  }
3508
3508
  }
3509
3509
  class cr {
3510
3510
  init() {
3511
- const o = xe.registry.getItem("cleanWorkspace");
3511
+ const o = Pe.registry.getItem("cleanWorkspace");
3512
3512
  o && (o.callback = function(t) {
3513
3513
  const n = t.workspace;
3514
3514
  if (!n)
3515
3515
  return;
3516
- n.setResizesEnabled(!1), F.setGroup(!0);
3516
+ n.setResizesEnabled(!1), G.setGroup(!0);
3517
3517
  const i = n.getTopBlocks(!0);
3518
3518
  let r = 0;
3519
3519
  for (let l = 0, s; s = i[l]; l++) {
@@ -3522,7 +3522,7 @@ class cr {
3522
3522
  const u = s.getRelativeToSurfaceXY();
3523
3523
  s.moveBy(-u.x, r - u.y, ["cleanup"]), s.snapToGrid(), r = s.getRelativeToSurfaceXY().y + s.getHeightWidth().height + 100;
3524
3524
  }
3525
- F.setGroup(!1), n.setResizesEnabled(!0);
3525
+ G.setGroup(!1), n.setResizesEnabled(!0);
3526
3526
  });
3527
3527
  }
3528
3528
  }
@@ -3532,7 +3532,7 @@ function un(e) {
3532
3532
  }
3533
3533
  class ur {
3534
3534
  init() {
3535
- const o = xe.registry.getItem("blockDisable");
3535
+ const o = Pe.registry.getItem("blockDisable");
3536
3536
  o && (o.preconditionFn = function(t) {
3537
3537
  const n = t.block;
3538
3538
  return n && !n.isInFlyout && n.workspace.options.disable && n.isEditable() ? n.getInheritedDisabled() || un(n) ? "disabled" : "enabled" : "hidden";
@@ -3543,33 +3543,33 @@ class _n extends Qt {
3543
3543
  constructor(t, n, i) {
3544
3544
  super(Qt.SKIP_SETUP);
3545
3545
  /** The field's colour picker element. */
3546
- he(this, "picker", null);
3546
+ Te(this, "picker", null);
3547
3547
  /** Index of the currently highlighted element. */
3548
- he(this, "highlightedIndex", null);
3548
+ Te(this, "highlightedIndex", null);
3549
3549
  /**
3550
3550
  * Array holding info needed to unbind events.
3551
3551
  * Used for disposing.
3552
3552
  * Ex: [[node, name, func], [node, name, func]].
3553
3553
  */
3554
- he(this, "boundEvents", []);
3554
+ Te(this, "boundEvents", []);
3555
3555
  /**
3556
3556
  * Serializable fields are saved by the serializer, non-serializable fields
3557
3557
  * are not. Editable fields should also be serializable.
3558
3558
  */
3559
- he(this, "SERIALIZABLE", !0);
3559
+ Te(this, "SERIALIZABLE", !0);
3560
3560
  /** Mouse cursor style when over the hotspot that initiates the editor. */
3561
- he(this, "CURSOR", "default");
3561
+ Te(this, "CURSOR", "default");
3562
3562
  /**
3563
3563
  * Used to tell if the field needs to be rendered the next time the block is
3564
3564
  * rendered. Colour fields are statically sized, and only need to be
3565
3565
  * rendered at initialization.
3566
3566
  */
3567
- he(this, "isDirty_", !1);
3567
+ Te(this, "isDirty_", !1);
3568
3568
  /**
3569
3569
  * An array of colour strings for the palette.
3570
3570
  * Copied from goog.ui.ColorPicker.SIMPLE_GRID_COLORS
3571
3571
  */
3572
- he(this, "colours", [
3572
+ Te(this, "colours", [
3573
3573
  // red
3574
3574
  "#F44336",
3575
3575
  // base
@@ -4131,11 +4131,11 @@ class _n extends Qt {
4131
4131
  * An array of tooltip strings for the palette. If not the same length as
4132
4132
  * COLOURS, the colour's hex code will be used for any missing titles.
4133
4133
  */
4134
- he(this, "titles", ["%{BKY_COLOR_RED}"]);
4134
+ Te(this, "titles", ["%{BKY_COLOR_RED}"]);
4135
4135
  /**
4136
4136
  * Number of columns in the palette.
4137
4137
  */
4138
- he(this, "columns", 14);
4138
+ Te(this, "columns", 14);
4139
4139
  t !== Qt.SKIP_SETUP && (i && this.configure_(i), this.setValue(t), n && this.setValidator(n));
4140
4140
  }
4141
4141
  configure_(t) {
@@ -4144,7 +4144,7 @@ class _n extends Qt {
4144
4144
  initView() {
4145
4145
  const t = this.getConstants();
4146
4146
  if (!t) throw Error("Constants not found");
4147
- this.size_ = new m.Size(
4147
+ this.size_ = new T.Size(
4148
4148
  t.FIELD_COLOUR_DEFAULT_WIDTH,
4149
4149
  t.FIELD_COLOUR_DEFAULT_HEIGHT
4150
4150
  ), this.createBorderRect_(), this.getBorderRect().style.fillOpacity = "1", this.getBorderRect().setAttribute("stroke", "#fff"), this.isFullBlockField() && (this.clickTarget_ = this.sourceBlock_.getSvgRoot());
@@ -4188,7 +4188,7 @@ class _n extends Qt {
4188
4188
  this.isFullBlockField() ? (i = (t ?? 0) * 2, r = n.FIELD_TEXT_HEIGHT) : (i = n.FIELD_COLOUR_DEFAULT_WIDTH, r = n.FIELD_COLOUR_DEFAULT_HEIGHT), this.size_.height = r, this.size_.width = i, this.positionBorderRect_();
4189
4189
  }
4190
4190
  doClassValidation_(t) {
4191
- return typeof t != "string" ? null : m.colour.parse(t);
4191
+ return typeof t != "string" ? null : T.colour.parse(t);
4192
4192
  }
4193
4193
  getText() {
4194
4194
  let t = this.value_;
@@ -4245,8 +4245,8 @@ class _n extends Qt {
4245
4245
  const i = this.colours, r = this.columns;
4246
4246
  let l = this.highlightedIndex % r, s = Math.floor(this.highlightedIndex / r);
4247
4247
  l += t, s += n, t < 0 ? l < 0 && s > 0 ? (l = r - 1, s--) : l < 0 && (l = 0) : t > 0 ? l > r - 1 && s < Math.floor(i.length / r) - 1 ? (l = 0, s++) : l > r - 1 && l-- : n < 0 ? s < 0 && (s = 0) : n > 0 && s > Math.floor(i.length / r) - 1 && (s = Math.floor(i.length / r) - 1);
4248
- const u = this.picker.childNodes[s].childNodes[l], _ = s * r + l;
4249
- this.setHighlightedCell(u, _);
4248
+ const u = this.picker.childNodes[s].childNodes[l], p = s * r + l;
4249
+ this.setHighlightedCell(u, p);
4250
4250
  }
4251
4251
  onMouseMove(t) {
4252
4252
  const n = t.target, i = n && Number(n.getAttribute("data-index"));
@@ -4260,7 +4260,7 @@ class _n extends Qt {
4260
4260
  var n;
4261
4261
  (n = this.picker) == null || n.blur();
4262
4262
  const t = this.getHighlighted();
4263
- t && m.dom.removeClass(t, "blocklyColourHighlighted");
4263
+ t && T.dom.removeClass(t, "blocklyColourHighlighted");
4264
4264
  }
4265
4265
  getHighlighted() {
4266
4266
  var r;
@@ -4271,41 +4271,41 @@ class _n extends Qt {
4271
4271
  }
4272
4272
  setHighlightedCell(t, n) {
4273
4273
  const i = this.getHighlighted();
4274
- i && m.dom.removeClass(i, "blocklyColourHighlighted"), m.dom.addClass(t, "blocklyColourHighlighted"), this.highlightedIndex = n;
4274
+ i && T.dom.removeClass(i, "blocklyColourHighlighted"), T.dom.addClass(t, "blocklyColourHighlighted"), this.highlightedIndex = n;
4275
4275
  const r = t.getAttribute("id");
4276
- r && this.picker && m.aria.setState(
4276
+ r && this.picker && T.aria.setState(
4277
4277
  this.picker,
4278
- m.aria.State.ACTIVEDESCENDANT,
4278
+ T.aria.State.ACTIVEDESCENDANT,
4279
4279
  r
4280
4280
  );
4281
4281
  }
4282
4282
  dropdownCreate() {
4283
4283
  const t = this.columns, n = this.colours, i = this.getValue(), r = document.createElement("table");
4284
- r.className = "blocklyColourTable", r.tabIndex = 0, r.dir = "ltr", m.aria.setRole(r, m.aria.Role.GRID), m.aria.setState(r, m.aria.State.EXPANDED, !0), m.aria.setState(
4284
+ r.className = "blocklyColourTable", r.tabIndex = 0, r.dir = "ltr", T.aria.setRole(r, T.aria.Role.GRID), T.aria.setState(r, T.aria.State.EXPANDED, !0), T.aria.setState(
4285
4285
  r,
4286
- m.aria.State.ROWCOUNT,
4286
+ T.aria.State.ROWCOUNT,
4287
4287
  Math.floor(n.length / t)
4288
- ), m.aria.setState(
4288
+ ), T.aria.setState(
4289
4289
  r,
4290
- m.aria.State.COLCOUNT,
4290
+ T.aria.State.COLCOUNT,
4291
4291
  t
4292
4292
  );
4293
4293
  let l = null;
4294
4294
  for (let s = 0; s < n.length; s++) {
4295
- s % t === 0 && (l = document.createElement("tr"), m.aria.setRole(l, m.aria.Role.ROW), r.appendChild(l));
4295
+ s % t === 0 && (l = document.createElement("tr"), T.aria.setRole(l, T.aria.Role.ROW), r.appendChild(l));
4296
4296
  const u = document.createElement("td");
4297
- l.appendChild(u), u.setAttribute("data-colour", n[s]), u.title = this.titles[s] || n[s], u.id = m.idGenerator.getNextUniqueId(), u.setAttribute("data-index", `${s}`), m.aria.setRole(u, m.aria.Role.GRIDCELL), m.aria.setState(
4297
+ l.appendChild(u), u.setAttribute("data-colour", n[s]), u.title = this.titles[s] || n[s], u.id = T.idGenerator.getNextUniqueId(), u.setAttribute("data-index", `${s}`), T.aria.setRole(u, T.aria.Role.GRIDCELL), T.aria.setState(
4298
4298
  u,
4299
- m.aria.State.LABEL,
4299
+ T.aria.State.LABEL,
4300
4300
  n[s]
4301
- ), m.aria.setState(
4301
+ ), T.aria.setState(
4302
4302
  u,
4303
- m.aria.State.SELECTED,
4303
+ T.aria.State.SELECTED,
4304
4304
  n[s] === i
4305
4305
  ), u.style.backgroundColor = n[s], n[s] === i && (u.className = "blocklyColourSelected", this.highlightedIndex = s);
4306
4306
  }
4307
4307
  this.boundEvents.push(
4308
- Ue.conditionalBind(
4308
+ Ye.conditionalBind(
4309
4309
  r,
4310
4310
  "pointerdown",
4311
4311
  this,
@@ -4313,7 +4313,7 @@ class _n extends Qt {
4313
4313
  !0
4314
4314
  )
4315
4315
  ), this.boundEvents.push(
4316
- Ue.conditionalBind(
4316
+ Ye.conditionalBind(
4317
4317
  r,
4318
4318
  "pointermove",
4319
4319
  this,
@@ -4321,7 +4321,7 @@ class _n extends Qt {
4321
4321
  !0
4322
4322
  )
4323
4323
  ), this.boundEvents.push(
4324
- Ue.conditionalBind(
4324
+ Ye.conditionalBind(
4325
4325
  r,
4326
4326
  "pointerenter",
4327
4327
  this,
@@ -4329,7 +4329,7 @@ class _n extends Qt {
4329
4329
  !0
4330
4330
  )
4331
4331
  ), this.boundEvents.push(
4332
- Ue.conditionalBind(
4332
+ Ye.conditionalBind(
4333
4333
  r,
4334
4334
  "pointerleave",
4335
4335
  this,
@@ -4337,7 +4337,7 @@ class _n extends Qt {
4337
4337
  !0
4338
4338
  )
4339
4339
  ), this.boundEvents.push(
4340
- Ue.conditionalBind(
4340
+ Ye.conditionalBind(
4341
4341
  r,
4342
4342
  "keydown",
4343
4343
  this,
@@ -4349,7 +4349,7 @@ class _n extends Qt {
4349
4349
  /** Disposes of events and DOM-references belonging to the colour editor. */
4350
4350
  dropdownDispose() {
4351
4351
  for (const t of this.boundEvents)
4352
- Ue.unbind(t);
4352
+ Ye.unbind(t);
4353
4353
  this.boundEvents.length = 0, this.picker = null, this.highlightedIndex = null;
4354
4354
  }
4355
4355
  static fromJson(t) {
@@ -4552,7 +4552,7 @@ const hr = on.defineTheme("light", {
4552
4552
  }
4553
4553
  });
4554
4554
  function mr(e) {
4555
- const o = we();
4555
+ const o = Ve();
4556
4556
  switch (console.log(o), e) {
4557
4557
  case "light":
4558
4558
  o.setTheme(hr);
@@ -5232,7 +5232,7 @@ const Yt = {
5232
5232
  kind: "category",
5233
5233
  name: "%{BKY_CATEGORY_UI}",
5234
5234
  categorystyle: "ui_category",
5235
- custom: Xe.name
5235
+ custom: $e.name
5236
5236
  },
5237
5237
  Ht,
5238
5238
  Ft,
@@ -5246,13 +5246,13 @@ const Yt = {
5246
5246
  kind: "category",
5247
5247
  name: "%{BKY_CATEGORY_VARIABLE}",
5248
5248
  categorystyle: "variable_category",
5249
- custom: ce.name
5249
+ custom: pe.name
5250
5250
  },
5251
5251
  {
5252
5252
  kind: "category",
5253
5253
  name: "%{BKY_CATEGORY_PROCEDURE}",
5254
5254
  categorystyle: "procedure_category",
5255
- custom: se.name
5255
+ custom: _e.name
5256
5256
  },
5257
5257
  {
5258
5258
  kind: "category",
@@ -5275,13 +5275,13 @@ const Yt = {
5275
5275
  kind: "category",
5276
5276
  name: "%{BKY_CATEGORY_VARIABLE}",
5277
5277
  categorystyle: "variable_category",
5278
- custom: ce.name
5278
+ custom: pe.name
5279
5279
  },
5280
5280
  {
5281
5281
  kind: "category",
5282
5282
  name: "%{BKY_CATEGORY_PROCEDURE}",
5283
5283
  categorystyle: "procedure_category",
5284
- custom: se.name
5284
+ custom: _e.name
5285
5285
  }
5286
5286
  ]
5287
5287
  }, vr = {
@@ -5298,13 +5298,13 @@ const Yt = {
5298
5298
  kind: "category",
5299
5299
  name: "%{BKY_CATEGORY_VARIABLE}",
5300
5300
  categorystyle: "variable_category",
5301
- custom: ce.name
5301
+ custom: pe.name
5302
5302
  },
5303
5303
  {
5304
5304
  kind: "category",
5305
5305
  name: "%{BKY_CATEGORY_PROCEDURE}",
5306
5306
  categorystyle: "procedure_category",
5307
- custom: se.name
5307
+ custom: _e.name
5308
5308
  }
5309
5309
  ]
5310
5310
  }, yr = {
@@ -5314,7 +5314,7 @@ const Yt = {
5314
5314
  kind: "category",
5315
5315
  name: "%{BKY_CATEGORY_UI}",
5316
5316
  categorystyle: "ui_category",
5317
- custom: Xe.name
5317
+ custom: $e.name
5318
5318
  },
5319
5319
  Ht,
5320
5320
  Ft,
@@ -5328,13 +5328,13 @@ const Yt = {
5328
5328
  kind: "category",
5329
5329
  name: "%{BKY_CATEGORY_VARIABLE}",
5330
5330
  categorystyle: "variable_category",
5331
- custom: ce.name
5331
+ custom: pe.name
5332
5332
  },
5333
5333
  {
5334
5334
  kind: "category",
5335
5335
  name: "%{BKY_CATEGORY_PROCEDURE}",
5336
5336
  categorystyle: "procedure_category",
5337
- custom: se.name
5337
+ custom: _e.name
5338
5338
  },
5339
5339
  {
5340
5340
  kind: "category",
@@ -5343,39 +5343,39 @@ const Yt = {
5343
5343
  custom: ln.name
5344
5344
  }
5345
5345
  ]
5346
- }, br = /* @__PURE__ */ Ve({
5346
+ }, br = /* @__PURE__ */ Ue({
5347
5347
  __name: "index",
5348
5348
  setup(e) {
5349
5349
  const { t: o } = Ut(), t = () => {
5350
- const n = we();
5350
+ const n = Ve();
5351
5351
  if (!n)
5352
5352
  return;
5353
- const i = xe.registry.getItem("cleanWorkspace");
5353
+ const i = Pe.registry.getItem("cleanWorkspace");
5354
5354
  i && i.callback({ workspace: n }, new PointerEvent("dummy"));
5355
5355
  };
5356
- return ze(() => {
5357
- Te.on("cleanWorkspace", t);
5356
+ return qe(() => {
5357
+ me.on("cleanWorkspace", t);
5358
5358
  }), Nt(() => {
5359
- Te.off("cleanWorkspace", t);
5359
+ me.off("cleanWorkspace", t);
5360
5360
  }), (n, i) => {
5361
- const r = oe("v-btn"), l = oe("v-tooltip");
5362
- return J(), Le(l, {
5361
+ const r = ie("v-btn"), l = ie("v-tooltip");
5362
+ return j(), Se(l, {
5363
5363
  text: N(o)("x-block-lib.tip.hotkeyCtrlQ")
5364
5364
  }, {
5365
- activator: We(({ props: s }) => [
5366
- ne(r, mo(s, {
5365
+ activator: Je(({ props: s }) => [
5366
+ re(r, mo(s, {
5367
5367
  class: "mr-3",
5368
5368
  variant: "outlined",
5369
5369
  density: "comfortable",
5370
5370
  icon: N(ci),
5371
- onClick: i[0] || (i[0] = (u) => N(Te).emit("cleanWorkspace"))
5371
+ onClick: i[0] || (i[0] = (u) => N(me).emit("cleanWorkspace"))
5372
5372
  }), null, 16, ["icon"])
5373
5373
  ]),
5374
5374
  _: 1
5375
5375
  }, 8, ["text"]);
5376
5376
  };
5377
5377
  }
5378
- }), Or = /* @__PURE__ */ Ve({
5378
+ }), Or = /* @__PURE__ */ Ue({
5379
5379
  __name: "index",
5380
5380
  props: {
5381
5381
  modelValue: { type: Boolean, required: !0 },
@@ -5385,12 +5385,12 @@ const Yt = {
5385
5385
  setup(e) {
5386
5386
  const { t: o } = Ut(), t = co(e, "modelValue");
5387
5387
  return (n, i) => {
5388
- const r = oe("v-btn"), l = oe("v-tooltip");
5389
- return J(), Le(l, {
5388
+ const r = ie("v-btn"), l = ie("v-tooltip");
5389
+ return j(), Se(l, {
5390
5390
  text: N(o)("x-block-lib.tip.hotkeyCtrlW")
5391
5391
  }, {
5392
- activator: We(({ props: s }) => [
5393
- ne(r, mo(s, {
5392
+ activator: Je(({ props: s }) => [
5393
+ re(r, mo(s, {
5394
5394
  class: "mr-3",
5395
5395
  variant: "outlined",
5396
5396
  density: "comfortable",
@@ -5403,7 +5403,7 @@ const Yt = {
5403
5403
  };
5404
5404
  }
5405
5405
  });
5406
- var Ir = Object.defineProperty, St = Object.getOwnPropertySymbols, dn = Object.prototype.hasOwnProperty, fn = Object.prototype.propertyIsEnumerable, xo = (e, o, t) => o in e ? Ir(e, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[o] = t, $e = (e, o) => {
5406
+ var Ir = Object.defineProperty, St = Object.getOwnPropertySymbols, dn = Object.prototype.hasOwnProperty, fn = Object.prototype.propertyIsEnumerable, xo = (e, o, t) => o in e ? Ir(e, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[o] = t, je = (e, o) => {
5407
5407
  for (var t in o || (o = {}))
5408
5408
  dn.call(o, t) && xo(e, t, o[t]);
5409
5409
  if (St)
@@ -5465,7 +5465,7 @@ function Rr(e, o, t = null) {
5465
5465
  };
5466
5466
  }
5467
5467
  function Mr(e, o) {
5468
- const t = $e({}, e);
5468
+ const t = je({}, e);
5469
5469
  return Object.keys(o).forEach((n) => {
5470
5470
  t[n] ? t[n] = Rr(e[n], o[n]) : t[n] = o[n];
5471
5471
  }), t;
@@ -5499,7 +5499,7 @@ function Ko(e, o) {
5499
5499
  }
5500
5500
  return t;
5501
5501
  }
5502
- function ge(e) {
5502
+ function Ee(e) {
5503
5503
  for (var o = 1; o < arguments.length; o++) {
5504
5504
  var t = arguments[o] != null ? arguments[o] : {};
5505
5505
  o % 2 ? Ko(Object(t), !0).forEach(function(n) {
@@ -5526,15 +5526,15 @@ function wr(e, o, t) {
5526
5526
  writable: !0
5527
5527
  }) : e[o] = t, e;
5528
5528
  }
5529
- function be() {
5530
- return be = Object.assign || function(e) {
5529
+ function Ce() {
5530
+ return Ce = Object.assign || function(e) {
5531
5531
  for (var o = 1; o < arguments.length; o++) {
5532
5532
  var t = arguments[o];
5533
5533
  for (var n in t)
5534
5534
  Object.prototype.hasOwnProperty.call(t, n) && (e[n] = t[n]);
5535
5535
  }
5536
5536
  return e;
5537
- }, be.apply(this, arguments);
5537
+ }, Ce.apply(this, arguments);
5538
5538
  }
5539
5539
  function Vr(e, o) {
5540
5540
  if (e == null)
@@ -5556,19 +5556,19 @@ function Ur(e, o) {
5556
5556
  return t;
5557
5557
  }
5558
5558
  var Yr = "1.15.2";
5559
- function ye(e) {
5559
+ function Ie(e) {
5560
5560
  if (typeof window < "u" && window.navigator)
5561
5561
  return !!/* @__PURE__ */ navigator.userAgent.match(e);
5562
5562
  }
5563
- var Oe = ye(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), ct = ye(/Edge/i), Fo = ye(/firefox/i), it = ye(/safari/i) && !ye(/chrome/i) && !ye(/android/i), mn = ye(/iP(ad|od|hone)/i), gn = ye(/chrome/i) && ye(/android/i), En = {
5563
+ var Ae = Ie(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), ct = Ie(/Edge/i), Fo = Ie(/firefox/i), it = Ie(/safari/i) && !Ie(/chrome/i) && !Ie(/android/i), mn = Ie(/iP(ad|od|hone)/i), gn = Ie(/chrome/i) && Ie(/android/i), En = {
5564
5564
  capture: !1,
5565
5565
  passive: !1
5566
5566
  };
5567
5567
  function k(e, o, t) {
5568
- e.addEventListener(o, t, !Oe && En);
5568
+ e.addEventListener(o, t, !Ae && En);
5569
5569
  }
5570
5570
  function L(e, o, t) {
5571
- e.removeEventListener(o, t, !Oe && En);
5571
+ e.removeEventListener(o, t, !Ae && En);
5572
5572
  }
5573
5573
  function Bt(e, o) {
5574
5574
  if (o) {
@@ -5589,7 +5589,7 @@ function Bt(e, o) {
5589
5589
  function Kr(e) {
5590
5590
  return e.host && e !== document && e.host.nodeType ? e.host : e.parentNode;
5591
5591
  }
5592
- function de(e, o, t, n) {
5592
+ function he(e, o, t, n) {
5593
5593
  if (e) {
5594
5594
  t = t || document;
5595
5595
  do {
@@ -5602,7 +5602,7 @@ function de(e, o, t, n) {
5602
5602
  return null;
5603
5603
  }
5604
5604
  var Ho = /\s+/g;
5605
- function ee(e, o, t) {
5605
+ function oe(e, o, t) {
5606
5606
  if (e && o)
5607
5607
  if (e.classList)
5608
5608
  e.classList[t ? "add" : "remove"](o);
@@ -5619,7 +5619,7 @@ function v(e, o, t) {
5619
5619
  !(o in n) && o.indexOf("webkit") === -1 && (o = "-webkit-" + o), n[o] = t + (typeof t == "string" ? "" : "px");
5620
5620
  }
5621
5621
  }
5622
- function Je(e, o) {
5622
+ function ze(e, o) {
5623
5623
  var t = "";
5624
5624
  if (typeof e == "string")
5625
5625
  t = e;
@@ -5641,49 +5641,49 @@ function vn(e, o, t) {
5641
5641
  }
5642
5642
  return [];
5643
5643
  }
5644
- function me() {
5644
+ function ge() {
5645
5645
  var e = document.scrollingElement;
5646
5646
  return e || document.documentElement;
5647
5647
  }
5648
- function K(e, o, t, n, i) {
5648
+ function H(e, o, t, n, i) {
5649
5649
  if (!(!e.getBoundingClientRect && e !== window)) {
5650
- var r, l, s, u, _, d, p;
5651
- if (e !== window && e.parentNode && e !== me() ? (r = e.getBoundingClientRect(), l = r.top, s = r.left, u = r.bottom, _ = r.right, d = r.height, p = r.width) : (l = 0, s = 0, u = window.innerHeight, _ = window.innerWidth, d = window.innerHeight, p = window.innerWidth), (o || t) && e !== window && (i = i || e.parentNode, !Oe))
5650
+ var r, l, s, u, p, d, _;
5651
+ if (e !== window && e.parentNode && e !== ge() ? (r = e.getBoundingClientRect(), l = r.top, s = r.left, u = r.bottom, p = r.right, d = r.height, _ = r.width) : (l = 0, s = 0, u = window.innerHeight, p = window.innerWidth, d = window.innerHeight, _ = window.innerWidth), (o || t) && e !== window && (i = i || e.parentNode, !Ae))
5652
5652
  do
5653
5653
  if (i && i.getBoundingClientRect && (v(i, "transform") !== "none" || t && v(i, "position") !== "static")) {
5654
- var T = i.getBoundingClientRect();
5655
- l -= T.top + parseInt(v(i, "border-top-width")), s -= T.left + parseInt(v(i, "border-left-width")), u = l + r.height, _ = s + r.width;
5654
+ var g = i.getBoundingClientRect();
5655
+ l -= g.top + parseInt(v(i, "border-top-width")), s -= g.left + parseInt(v(i, "border-left-width")), u = l + r.height, p = s + r.width;
5656
5656
  break;
5657
5657
  }
5658
5658
  while (i = i.parentNode);
5659
5659
  if (n && e !== window) {
5660
- var h = Je(i || e), A = h && h.a, b = h && h.d;
5661
- h && (l /= b, s /= A, p /= A, d /= b, u = l + d, _ = s + p);
5660
+ var h = ze(i || e), A = h && h.a, b = h && h.d;
5661
+ h && (l /= b, s /= A, _ /= A, d /= b, u = l + d, p = s + _);
5662
5662
  }
5663
5663
  return {
5664
5664
  top: l,
5665
5665
  left: s,
5666
5666
  bottom: u,
5667
- right: _,
5668
- width: p,
5667
+ right: p,
5668
+ width: _,
5669
5669
  height: d
5670
5670
  };
5671
5671
  }
5672
5672
  }
5673
5673
  function Go(e, o, t) {
5674
- for (var n = Ae(e, !0), i = K(e)[o]; n; ) {
5675
- var r = K(n)[t], l = void 0;
5674
+ for (var n = Ne(e, !0), i = H(e)[o]; n; ) {
5675
+ var r = H(n)[t], l = void 0;
5676
5676
  if (l = i >= r, !l)
5677
5677
  return n;
5678
- if (n === me())
5678
+ if (n === ge())
5679
5679
  break;
5680
- n = Ae(n, !1);
5680
+ n = Ne(n, !1);
5681
5681
  }
5682
5682
  return !1;
5683
5683
  }
5684
- function qe(e, o, t, n) {
5684
+ function Qe(e, o, t, n) {
5685
5685
  for (var i = 0, r = 0, l = e.children; r < l.length; ) {
5686
- if (l[r].style.display !== "none" && l[r] !== y.ghost && (n || l[r] !== y.dragged) && de(l[r], t.draggable, e, !1)) {
5686
+ if (l[r].style.display !== "none" && l[r] !== y.ghost && (n || l[r] !== y.dragged) && he(l[r], t.draggable, e, !1)) {
5687
5687
  if (i === o)
5688
5688
  return l[r];
5689
5689
  i++;
@@ -5697,7 +5697,7 @@ function Oo(e, o) {
5697
5697
  t = t.previousElementSibling;
5698
5698
  return t || null;
5699
5699
  }
5700
- function ae(e, o) {
5700
+ function ue(e, o) {
5701
5701
  var t = 0;
5702
5702
  if (!e || !e.parentNode)
5703
5703
  return -1;
@@ -5706,10 +5706,10 @@ function ae(e, o) {
5706
5706
  return t;
5707
5707
  }
5708
5708
  function Xo(e) {
5709
- var o = 0, t = 0, n = me();
5709
+ var o = 0, t = 0, n = ge();
5710
5710
  if (e)
5711
5711
  do {
5712
- var i = Je(e), r = i.a, l = i.d;
5712
+ var i = ze(e), r = i.a, l = i.d;
5713
5713
  o += e.scrollLeft * r, t += e.scrollTop * l;
5714
5714
  } while (e !== n && (e = e.parentNode));
5715
5715
  return [o, t];
@@ -5723,23 +5723,23 @@ function Fr(e, o) {
5723
5723
  }
5724
5724
  return -1;
5725
5725
  }
5726
- function Ae(e, o) {
5726
+ function Ne(e, o) {
5727
5727
  if (!e || !e.getBoundingClientRect)
5728
- return me();
5728
+ return ge();
5729
5729
  var t = e, n = !1;
5730
5730
  do
5731
5731
  if (t.clientWidth < t.scrollWidth || t.clientHeight < t.scrollHeight) {
5732
5732
  var i = v(t);
5733
5733
  if (t.clientWidth < t.scrollWidth && (i.overflowX == "auto" || i.overflowX == "scroll") || t.clientHeight < t.scrollHeight && (i.overflowY == "auto" || i.overflowY == "scroll")) {
5734
5734
  if (!t.getBoundingClientRect || t === document.body)
5735
- return me();
5735
+ return ge();
5736
5736
  if (n || o)
5737
5737
  return t;
5738
5738
  n = !0;
5739
5739
  }
5740
5740
  }
5741
5741
  while (t = t.parentNode);
5742
- return me();
5742
+ return ge();
5743
5743
  }
5744
5744
  function Hr(e, o) {
5745
5745
  if (e && o)
@@ -5775,13 +5775,13 @@ function In(e, o, t) {
5775
5775
  var n = {};
5776
5776
  return Array.from(e.children).forEach(function(i) {
5777
5777
  var r, l, s, u;
5778
- if (!(!de(i, o.draggable, e, !1) || i.animated || i === t)) {
5779
- var _ = K(i);
5780
- n.left = Math.min((r = n.left) !== null && r !== void 0 ? r : 1 / 0, _.left), n.top = Math.min((l = n.top) !== null && l !== void 0 ? l : 1 / 0, _.top), n.right = Math.max((s = n.right) !== null && s !== void 0 ? s : -1 / 0, _.right), n.bottom = Math.max((u = n.bottom) !== null && u !== void 0 ? u : -1 / 0, _.bottom);
5778
+ if (!(!he(i, o.draggable, e, !1) || i.animated || i === t)) {
5779
+ var p = H(i);
5780
+ n.left = Math.min((r = n.left) !== null && r !== void 0 ? r : 1 / 0, p.left), n.top = Math.min((l = n.top) !== null && l !== void 0 ? l : 1 / 0, p.top), n.right = Math.max((s = n.right) !== null && s !== void 0 ? s : -1 / 0, p.right), n.bottom = Math.max((u = n.bottom) !== null && u !== void 0 ? u : -1 / 0, p.bottom);
5781
5781
  }
5782
5782
  }), n.width = n.right - n.left, n.height = n.bottom - n.top, n.x = n.left, n.y = n.top, n;
5783
5783
  }
5784
- var ie = "Sortable" + (/* @__PURE__ */ new Date()).getTime();
5784
+ var le = "Sortable" + (/* @__PURE__ */ new Date()).getTime();
5785
5785
  function Xr() {
5786
5786
  var e = [], o;
5787
5787
  return {
@@ -5792,11 +5792,11 @@ function Xr() {
5792
5792
  if (!(v(n, "display") === "none" || n === y.ghost)) {
5793
5793
  e.push({
5794
5794
  target: n,
5795
- rect: K(n)
5795
+ rect: H(n)
5796
5796
  });
5797
- var i = ge({}, e[e.length - 1].rect);
5797
+ var i = Ee({}, e[e.length - 1].rect);
5798
5798
  if (n.thisAnimationDuration) {
5799
- var r = Je(n, !0);
5799
+ var r = ze(n, !0);
5800
5800
  r && (i.top -= r.f, i.left -= r.e);
5801
5801
  }
5802
5802
  n.fromRect = i;
@@ -5820,9 +5820,9 @@ function Xr() {
5820
5820
  }
5821
5821
  var i = !1, r = 0;
5822
5822
  e.forEach(function(l) {
5823
- var s = 0, u = l.target, _ = u.fromRect, d = K(u), p = u.prevFromRect, T = u.prevToRect, h = l.rect, A = Je(u, !0);
5824
- A && (d.top -= A.f, d.left -= A.e), u.toRect = d, u.thisAnimationDuration && eo(p, d) && !eo(_, d) && // Make sure animatingRect is on line between toRect & fromRect
5825
- (h.top - d.top) / (h.left - d.left) === (_.top - d.top) / (_.left - d.left) && (s = jr(h, p, T, n.options)), eo(d, _) || (u.prevFromRect = _, u.prevToRect = d, s || (s = n.options.animation), n.animate(u, h, d, s)), s && (i = !0, r = Math.max(r, s), clearTimeout(u.animationResetTimer), u.animationResetTimer = setTimeout(function() {
5823
+ var s = 0, u = l.target, p = u.fromRect, d = H(u), _ = u.prevFromRect, g = u.prevToRect, h = l.rect, A = ze(u, !0);
5824
+ A && (d.top -= A.f, d.left -= A.e), u.toRect = d, u.thisAnimationDuration && eo(_, d) && !eo(p, d) && // Make sure animatingRect is on line between toRect & fromRect
5825
+ (h.top - d.top) / (h.left - d.left) === (p.top - d.top) / (p.left - d.left) && (s = jr(h, _, g, n.options)), eo(d, p) || (u.prevFromRect = p, u.prevToRect = d, s || (s = n.options.animation), n.animate(u, h, d, s)), s && (i = !0, r = Math.max(r, s), clearTimeout(u.animationResetTimer), u.animationResetTimer = setTimeout(function() {
5826
5826
  u.animationTime = 0, u.prevFromRect = null, u.fromRect = null, u.prevToRect = null, u.thisAnimationDuration = null;
5827
5827
  }, s), u.thisAnimationDuration = s);
5828
5828
  }), clearTimeout(o), i ? o = setTimeout(function() {
@@ -5832,8 +5832,8 @@ function Xr() {
5832
5832
  animate: function(t, n, i, r) {
5833
5833
  if (r) {
5834
5834
  v(t, "transition", ""), v(t, "transform", "");
5835
- var l = Je(this.el), s = l && l.a, u = l && l.d, _ = (n.left - i.left) / (s || 1), d = (n.top - i.top) / (u || 1);
5836
- t.animatingX = !!_, t.animatingY = !!d, v(t, "transform", "translate3d(" + _ + "px," + d + "px,0)"), this.forRepaintDummy = $r(t), v(t, "transition", "transform " + r + "ms" + (this.options.easing ? " " + this.options.easing : "")), v(t, "transform", "translate3d(0,0,0)"), typeof t.animated == "number" && clearTimeout(t.animated), t.animated = setTimeout(function() {
5835
+ var l = ze(this.el), s = l && l.a, u = l && l.d, p = (n.left - i.left) / (s || 1), d = (n.top - i.top) / (u || 1);
5836
+ t.animatingX = !!p, t.animatingY = !!d, v(t, "transform", "translate3d(" + p + "px," + d + "px,0)"), this.forRepaintDummy = $r(t), v(t, "transition", "transform " + r + "ms" + (this.options.easing ? " " + this.options.easing : "")), v(t, "transform", "translate3d(0,0,0)"), typeof t.animated == "number" && clearTimeout(t.animated), t.animated = setTimeout(function() {
5837
5837
  v(t, "transition", ""), v(t, "transform", ""), t.animated = !1, t.animatingX = !1, t.animatingY = !1;
5838
5838
  }, r);
5839
5839
  }
@@ -5846,16 +5846,16 @@ function $r(e) {
5846
5846
  function jr(e, o, t, n) {
5847
5847
  return Math.sqrt(Math.pow(o.top - e.top, 2) + Math.pow(o.left - e.left, 2)) / Math.sqrt(Math.pow(o.top - t.top, 2) + Math.pow(o.left - t.left, 2)) * n.animation;
5848
5848
  }
5849
- var Ye = [], to = {
5849
+ var Ke = [], to = {
5850
5850
  initializeByDefault: !0
5851
5851
  }, ut = {
5852
5852
  mount: function(e) {
5853
5853
  for (var o in to)
5854
5854
  to.hasOwnProperty(o) && !(o in e) && (e[o] = to[o]);
5855
- Ye.forEach(function(t) {
5855
+ Ke.forEach(function(t) {
5856
5856
  if (t.pluginName === e.pluginName)
5857
5857
  throw "Sortable: Cannot mount plugin ".concat(e.pluginName, " more than once");
5858
- }), Ye.push(e);
5858
+ }), Ke.push(e);
5859
5859
  },
5860
5860
  pluginEvent: function(e, o, t) {
5861
5861
  var n = this;
@@ -5863,20 +5863,20 @@ var Ye = [], to = {
5863
5863
  n.eventCanceled = !0;
5864
5864
  };
5865
5865
  var i = e + "Global";
5866
- Ye.forEach(function(r) {
5867
- o[r.pluginName] && (o[r.pluginName][i] && o[r.pluginName][i](ge({
5866
+ Ke.forEach(function(r) {
5867
+ o[r.pluginName] && (o[r.pluginName][i] && o[r.pluginName][i](Ee({
5868
5868
  sortable: o
5869
- }, t)), o.options[r.pluginName] && o[r.pluginName][e] && o[r.pluginName][e](ge({
5869
+ }, t)), o.options[r.pluginName] && o[r.pluginName][e] && o[r.pluginName][e](Ee({
5870
5870
  sortable: o
5871
5871
  }, t)));
5872
5872
  });
5873
5873
  },
5874
5874
  initializePlugins: function(e, o, t, n) {
5875
- Ye.forEach(function(l) {
5875
+ Ke.forEach(function(l) {
5876
5876
  var s = l.pluginName;
5877
5877
  if (!(!e.options[s] && !l.initializeByDefault)) {
5878
5878
  var u = new l(e, o, e.options);
5879
- u.sortable = e, u.options = e.options, e[s] = u, be(t, u.defaults);
5879
+ u.sortable = e, u.options = e.options, e[s] = u, Ce(t, u.defaults);
5880
5880
  }
5881
5881
  });
5882
5882
  for (var i in e.options)
@@ -5887,60 +5887,60 @@ var Ye = [], to = {
5887
5887
  },
5888
5888
  getEventProperties: function(e, o) {
5889
5889
  var t = {};
5890
- return Ye.forEach(function(n) {
5891
- typeof n.eventProperties == "function" && be(t, n.eventProperties.call(o[n.pluginName], e));
5890
+ return Ke.forEach(function(n) {
5891
+ typeof n.eventProperties == "function" && Ce(t, n.eventProperties.call(o[n.pluginName], e));
5892
5892
  }), t;
5893
5893
  },
5894
5894
  modifyOption: function(e, o, t) {
5895
5895
  var n;
5896
- return Ye.forEach(function(i) {
5896
+ return Ke.forEach(function(i) {
5897
5897
  e[i.pluginName] && i.optionListeners && typeof i.optionListeners[o] == "function" && (n = i.optionListeners[o].call(e[i.pluginName], t));
5898
5898
  }), n;
5899
5899
  }
5900
5900
  };
5901
5901
  function Wr(e) {
5902
- var o = e.sortable, t = e.rootEl, n = e.name, i = e.targetEl, r = e.cloneEl, l = e.toEl, s = e.fromEl, u = e.oldIndex, _ = e.newIndex, d = e.oldDraggableIndex, p = e.newDraggableIndex, T = e.originalEvent, h = e.putSortable, A = e.extraEventProperties;
5903
- if (o = o || t && t[ie], !!o) {
5904
- var b, H = o.options, S = "on" + n.charAt(0).toUpperCase() + n.substr(1);
5905
- window.CustomEvent && !Oe && !ct ? b = new CustomEvent(n, {
5902
+ var o = e.sortable, t = e.rootEl, n = e.name, i = e.targetEl, r = e.cloneEl, l = e.toEl, s = e.fromEl, u = e.oldIndex, p = e.newIndex, d = e.oldDraggableIndex, _ = e.newDraggableIndex, g = e.originalEvent, h = e.putSortable, A = e.extraEventProperties;
5903
+ if (o = o || t && t[le], !!o) {
5904
+ var b, X = o.options, S = "on" + n.charAt(0).toUpperCase() + n.substr(1);
5905
+ window.CustomEvent && !Ae && !ct ? b = new CustomEvent(n, {
5906
5906
  bubbles: !0,
5907
5907
  cancelable: !0
5908
- }) : (b = document.createEvent("Event"), b.initEvent(n, !0, !0)), b.to = l || t, b.from = s || t, b.item = i || t, b.clone = r, b.oldIndex = u, b.newIndex = _, b.oldDraggableIndex = d, b.newDraggableIndex = p, b.originalEvent = T, b.pullMode = h ? h.lastPutMode : void 0;
5909
- var Q = ge(ge({}, A), ut.getEventProperties(n, o));
5910
- for (var w in Q)
5911
- b[w] = Q[w];
5912
- t && t.dispatchEvent(b), H[S] && H[S].call(o, b);
5908
+ }) : (b = document.createEvent("Event"), b.initEvent(n, !0, !0)), b.to = l || t, b.from = s || t, b.item = i || t, b.clone = r, b.oldIndex = u, b.newIndex = p, b.oldDraggableIndex = d, b.newDraggableIndex = _, b.originalEvent = g, b.pullMode = h ? h.lastPutMode : void 0;
5909
+ var Z = Ee(Ee({}, A), ut.getEventProperties(n, o));
5910
+ for (var V in Z)
5911
+ b[V] = Z[V];
5912
+ t && t.dispatchEvent(b), X[S] && X[S].call(o, b);
5913
5913
  }
5914
5914
  }
5915
- var Jr = ["evt"], Z = function(e, o) {
5915
+ var Jr = ["evt"], ee = function(e, o) {
5916
5916
  var t = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, n = t.evt, i = Ur(t, Jr);
5917
- ut.pluginEvent.bind(y)(e, o, ge({
5917
+ ut.pluginEvent.bind(y)(e, o, Ee({
5918
5918
  dragEl: f,
5919
- parentEl: P,
5919
+ parentEl: w,
5920
5920
  ghostEl: I,
5921
- rootEl: M,
5921
+ rootEl: D,
5922
5922
  nextEl: Me,
5923
5923
  lastDownEl: Ct,
5924
- cloneEl: D,
5925
- cloneHidden: Ce,
5926
- dragStarted: et,
5924
+ cloneEl: x,
5925
+ cloneHidden: ke,
5926
+ dragStarted: tt,
5927
5927
  putSortable: $,
5928
5928
  activeSortable: y.active,
5929
5929
  originalEvent: n,
5930
- oldIndex: je,
5930
+ oldIndex: We,
5931
5931
  oldDraggableIndex: lt,
5932
- newIndex: te,
5933
- newDraggableIndex: Ie,
5932
+ newIndex: ne,
5933
+ newDraggableIndex: Le,
5934
5934
  hideGhostForTarget: kn,
5935
5935
  unhideGhostForTarget: Nn,
5936
5936
  cloneNowHidden: function() {
5937
- Ce = !0;
5937
+ ke = !0;
5938
5938
  },
5939
5939
  cloneNowShown: function() {
5940
- Ce = !1;
5940
+ ke = !1;
5941
5941
  },
5942
5942
  dispatchSortableEvent: function(r) {
5943
- q({
5943
+ Q({
5944
5944
  sortable: o,
5945
5945
  name: r,
5946
5946
  originalEvent: n
@@ -5948,27 +5948,27 @@ var Jr = ["evt"], Z = function(e, o) {
5948
5948
  }
5949
5949
  }, i));
5950
5950
  };
5951
- function q(e) {
5952
- Wr(ge({
5951
+ function Q(e) {
5952
+ Wr(Ee({
5953
5953
  putSortable: $,
5954
- cloneEl: D,
5954
+ cloneEl: x,
5955
5955
  targetEl: f,
5956
- rootEl: M,
5957
- oldIndex: je,
5956
+ rootEl: D,
5957
+ oldIndex: We,
5958
5958
  oldDraggableIndex: lt,
5959
- newIndex: te,
5960
- newDraggableIndex: Ie
5959
+ newIndex: ne,
5960
+ newDraggableIndex: Le
5961
5961
  }, e));
5962
5962
  }
5963
- var f, P, I, M, Me, Ct, D, Ce, je, te, lt, Ie, Tt, $, He = !1, Rt = !1, Mt = [], Be, pe, oo, no, $o, jo, et, Ke, at, st = !1, mt = !1, At, W, io = [], _o = !1, Dt = [], jt = typeof document < "u", gt = mn, Wo = ct || Oe ? "cssFloat" : "float", zr = jt && !gn && !mn && "draggable" in document.createElement("div"), Cn = function() {
5963
+ var f, w, I, D, Me, Ct, x, ke, We, ne, lt, Le, Tt, $, Ge = !1, Rt = !1, Mt = [], Be, fe, oo, no, $o, jo, tt, Fe, at, st = !1, mt = !1, At, J, io = [], _o = !1, Dt = [], jt = typeof document < "u", gt = mn, Wo = ct || Ae ? "cssFloat" : "float", zr = jt && !gn && !mn && "draggable" in document.createElement("div"), Cn = function() {
5964
5964
  if (jt) {
5965
- if (Oe)
5965
+ if (Ae)
5966
5966
  return !1;
5967
5967
  var e = document.createElement("x");
5968
5968
  return e.style.cssText = "pointer-events:auto", e.style.pointerEvents === "auto";
5969
5969
  }
5970
5970
  }(), An = function(e, o) {
5971
- var t = v(e), n = parseInt(t.width) - parseInt(t.paddingLeft) - parseInt(t.paddingRight) - parseInt(t.borderLeftWidth) - parseInt(t.borderRightWidth), i = qe(e, 0, o), r = qe(e, 1, o), l = i && v(i), s = r && v(r), u = l && parseInt(l.marginLeft) + parseInt(l.marginRight) + K(i).width, _ = s && parseInt(s.marginLeft) + parseInt(s.marginRight) + K(r).width;
5971
+ var t = v(e), n = parseInt(t.width) - parseInt(t.paddingLeft) - parseInt(t.paddingRight) - parseInt(t.borderLeftWidth) - parseInt(t.borderRightWidth), i = Qe(e, 0, o), r = Qe(e, 1, o), l = i && v(i), s = r && v(r), u = l && parseInt(l.marginLeft) + parseInt(l.marginRight) + H(i).width, p = s && parseInt(s.marginLeft) + parseInt(s.marginRight) + H(r).width;
5972
5972
  if (t.display === "flex")
5973
5973
  return t.flexDirection === "column" || t.flexDirection === "column-reverse" ? "vertical" : "horizontal";
5974
5974
  if (t.display === "grid")
@@ -5977,23 +5977,23 @@ var f, P, I, M, Me, Ct, D, Ce, je, te, lt, Ie, Tt, $, He = !1, Rt = !1, Mt = [],
5977
5977
  var d = l.float === "left" ? "left" : "right";
5978
5978
  return r && (s.clear === "both" || s.clear === d) ? "vertical" : "horizontal";
5979
5979
  }
5980
- return i && (l.display === "block" || l.display === "flex" || l.display === "table" || l.display === "grid" || u >= n && t[Wo] === "none" || r && t[Wo] === "none" && u + _ > n) ? "vertical" : "horizontal";
5980
+ return i && (l.display === "block" || l.display === "flex" || l.display === "table" || l.display === "grid" || u >= n && t[Wo] === "none" || r && t[Wo] === "none" && u + p > n) ? "vertical" : "horizontal";
5981
5981
  }, qr = function(e, o, t) {
5982
5982
  var n = t ? e.left : e.top, i = t ? e.right : e.bottom, r = t ? e.width : e.height, l = t ? o.left : o.top, s = t ? o.right : o.bottom, u = t ? o.width : o.height;
5983
5983
  return n === l || i === s || n + r / 2 === l + u / 2;
5984
5984
  }, Qr = function(e, o) {
5985
5985
  var t;
5986
5986
  return Mt.some(function(n) {
5987
- var i = n[ie].options.emptyInsertThreshold;
5987
+ var i = n[le].options.emptyInsertThreshold;
5988
5988
  if (!(!i || Oo(n))) {
5989
- var r = K(n), l = e >= r.left - i && e <= r.right + i, s = o >= r.top - i && o <= r.bottom + i;
5989
+ var r = H(n), l = e >= r.left - i && e <= r.right + i, s = o >= r.top - i && o <= r.bottom + i;
5990
5990
  if (l && s)
5991
5991
  return t = n;
5992
5992
  }
5993
5993
  }), t;
5994
5994
  }, Ln = function(e) {
5995
5995
  function o(i, r) {
5996
- return function(l, s, u, _) {
5996
+ return function(l, s, u, p) {
5997
5997
  var d = l.options.group.name && s.options.group.name && l.options.group.name === s.options.group.name;
5998
5998
  if (i == null && (r || d))
5999
5999
  return !0;
@@ -6002,9 +6002,9 @@ var f, P, I, M, Me, Ct, D, Ce, je, te, lt, Ie, Tt, $, He = !1, Rt = !1, Mt = [],
6002
6002
  if (r && i === "clone")
6003
6003
  return i;
6004
6004
  if (typeof i == "function")
6005
- return o(i(l, s, u, _), r)(l, s, u, _);
6006
- var p = (r ? l : s).options.group.name;
6007
- return i === !0 || typeof i == "string" && i === p || i.join && i.indexOf(p) > -1;
6005
+ return o(i(l, s, u, p), r)(l, s, u, p);
6006
+ var _ = (r ? l : s).options.group.name;
6007
+ return i === !0 || typeof i == "string" && i === _ || i.join && i.indexOf(_) > -1;
6008
6008
  };
6009
6009
  }
6010
6010
  var t = {}, n = e.group;
@@ -6028,16 +6028,16 @@ var Re = function(e) {
6028
6028
  var t = {};
6029
6029
  for (var n in e)
6030
6030
  e.hasOwnProperty(n) && (t[n] = e[n]);
6031
- t.target = t.rootEl = o, t.preventDefault = void 0, t.stopPropagation = void 0, o[ie]._onDragOver(t);
6031
+ t.target = t.rootEl = o, t.preventDefault = void 0, t.stopPropagation = void 0, o[le]._onDragOver(t);
6032
6032
  }
6033
6033
  }
6034
6034
  }, Zr = function(e) {
6035
- f && f.parentNode[ie]._isOutsideThisEl(e.target);
6035
+ f && f.parentNode[le]._isOutsideThisEl(e.target);
6036
6036
  };
6037
6037
  function y(e, o) {
6038
6038
  if (!(e && e.nodeType && e.nodeType === 1))
6039
6039
  throw "Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));
6040
- this.el = e, this.options = o = be({}, o), e[ie] = this;
6040
+ this.el = e, this.options = o = Ce({}, o), e[le] = this;
6041
6041
  var t = {
6042
6042
  group: null,
6043
6043
  sort: !0,
@@ -6089,80 +6089,80 @@ function y(e, o) {
6089
6089
  Ln(o);
6090
6090
  for (var i in this)
6091
6091
  i.charAt(0) === "_" && typeof this[i] == "function" && (this[i] = this[i].bind(this));
6092
- this.nativeDraggable = o.forceFallback ? !1 : zr, this.nativeDraggable && (this.options.touchStartThreshold = 1), o.supportPointer ? k(e, "pointerdown", this._onTapStart) : (k(e, "mousedown", this._onTapStart), k(e, "touchstart", this._onTapStart)), this.nativeDraggable && (k(e, "dragover", this), k(e, "dragenter", this)), Mt.push(this.el), o.store && o.store.get && this.sort(o.store.get(this) || []), be(this, Xr());
6092
+ this.nativeDraggable = o.forceFallback ? !1 : zr, this.nativeDraggable && (this.options.touchStartThreshold = 1), o.supportPointer ? k(e, "pointerdown", this._onTapStart) : (k(e, "mousedown", this._onTapStart), k(e, "touchstart", this._onTapStart)), this.nativeDraggable && (k(e, "dragover", this), k(e, "dragenter", this)), Mt.push(this.el), o.store && o.store.get && this.sort(o.store.get(this) || []), Ce(this, Xr());
6093
6093
  }
6094
6094
  y.prototype = /** @lends Sortable.prototype */
6095
6095
  {
6096
6096
  constructor: y,
6097
6097
  _isOutsideThisEl: function(e) {
6098
- !this.el.contains(e) && e !== this.el && (Ke = null);
6098
+ !this.el.contains(e) && e !== this.el && (Fe = null);
6099
6099
  },
6100
6100
  _getDirection: function(e, o) {
6101
6101
  return typeof this.options.direction == "function" ? this.options.direction.call(this, e, o, f) : this.options.direction;
6102
6102
  },
6103
6103
  _onTapStart: function(e) {
6104
6104
  if (e.cancelable) {
6105
- var o = this, t = this.el, n = this.options, i = n.preventOnFilter, r = e.type, l = e.touches && e.touches[0] || e.pointerType && e.pointerType === "touch" && e, s = (l || e).target, u = e.target.shadowRoot && (e.path && e.path[0] || e.composedPath && e.composedPath()[0]) || s, _ = n.filter;
6106
- if (al(t), !f && !(/mousedown|pointerdown/.test(r) && e.button !== 0 || n.disabled) && !u.isContentEditable && !(!this.nativeDraggable && it && s && s.tagName.toUpperCase() === "SELECT") && (s = de(s, n.draggable, t, !1), !(s && s.animated) && Ct !== s)) {
6107
- if (je = ae(s), lt = ae(s, n.draggable), typeof _ == "function") {
6108
- if (_.call(this, e, s, this)) {
6109
- q({
6105
+ var o = this, t = this.el, n = this.options, i = n.preventOnFilter, r = e.type, l = e.touches && e.touches[0] || e.pointerType && e.pointerType === "touch" && e, s = (l || e).target, u = e.target.shadowRoot && (e.path && e.path[0] || e.composedPath && e.composedPath()[0]) || s, p = n.filter;
6106
+ if (al(t), !f && !(/mousedown|pointerdown/.test(r) && e.button !== 0 || n.disabled) && !u.isContentEditable && !(!this.nativeDraggable && it && s && s.tagName.toUpperCase() === "SELECT") && (s = he(s, n.draggable, t, !1), !(s && s.animated) && Ct !== s)) {
6107
+ if (We = ue(s), lt = ue(s, n.draggable), typeof p == "function") {
6108
+ if (p.call(this, e, s, this)) {
6109
+ Q({
6110
6110
  sortable: o,
6111
6111
  rootEl: u,
6112
6112
  name: "filter",
6113
6113
  targetEl: s,
6114
6114
  toEl: t,
6115
6115
  fromEl: t
6116
- }), Z("filter", o, {
6116
+ }), ee("filter", o, {
6117
6117
  evt: e
6118
6118
  }), i && e.cancelable && e.preventDefault();
6119
6119
  return;
6120
6120
  }
6121
- } else if (_ && (_ = _.split(",").some(function(d) {
6122
- if (d = de(u, d.trim(), t, !1), d)
6123
- return q({
6121
+ } else if (p && (p = p.split(",").some(function(d) {
6122
+ if (d = he(u, d.trim(), t, !1), d)
6123
+ return Q({
6124
6124
  sortable: o,
6125
6125
  rootEl: d,
6126
6126
  name: "filter",
6127
6127
  targetEl: s,
6128
6128
  fromEl: t,
6129
6129
  toEl: t
6130
- }), Z("filter", o, {
6130
+ }), ee("filter", o, {
6131
6131
  evt: e
6132
6132
  }), !0;
6133
- }), _)) {
6133
+ }), p)) {
6134
6134
  i && e.cancelable && e.preventDefault();
6135
6135
  return;
6136
6136
  }
6137
- n.handle && !de(u, n.handle, t, !1) || this._prepareDragStart(e, l, s);
6137
+ n.handle && !he(u, n.handle, t, !1) || this._prepareDragStart(e, l, s);
6138
6138
  }
6139
6139
  }
6140
6140
  },
6141
6141
  _prepareDragStart: function(e, o, t) {
6142
6142
  var n = this, i = n.el, r = n.options, l = i.ownerDocument, s;
6143
6143
  if (t && !f && t.parentNode === i) {
6144
- var u = K(t);
6145
- if (M = i, f = t, P = f.parentNode, Me = f.nextSibling, Ct = t, Tt = r.group, y.dragged = f, Be = {
6144
+ var u = H(t);
6145
+ if (D = i, f = t, w = f.parentNode, Me = f.nextSibling, Ct = t, Tt = r.group, y.dragged = f, Be = {
6146
6146
  target: f,
6147
6147
  clientX: (o || e).clientX,
6148
6148
  clientY: (o || e).clientY
6149
6149
  }, $o = Be.clientX - u.left, jo = Be.clientY - u.top, this._lastX = (o || e).clientX, this._lastY = (o || e).clientY, f.style["will-change"] = "all", s = function() {
6150
- if (Z("delayEnded", n, {
6150
+ if (ee("delayEnded", n, {
6151
6151
  evt: e
6152
6152
  }), y.eventCanceled) {
6153
6153
  n._onDrop();
6154
6154
  return;
6155
6155
  }
6156
- n._disableDelayedDragEvents(), !Fo && n.nativeDraggable && (f.draggable = !0), n._triggerDragStart(e, o), q({
6156
+ n._disableDelayedDragEvents(), !Fo && n.nativeDraggable && (f.draggable = !0), n._triggerDragStart(e, o), Q({
6157
6157
  sortable: n,
6158
6158
  name: "choose",
6159
6159
  originalEvent: e
6160
- }), ee(f, r.chosenClass, !0);
6161
- }, r.ignore.split(",").forEach(function(_) {
6162
- vn(f, _.trim(), ro);
6163
- }), k(l, "dragover", Re), k(l, "mousemove", Re), k(l, "touchmove", Re), k(l, "mouseup", n._onDrop), k(l, "touchend", n._onDrop), k(l, "touchcancel", n._onDrop), Fo && this.nativeDraggable && (this.options.touchStartThreshold = 4, f.draggable = !0), Z("delayStart", this, {
6160
+ }), oe(f, r.chosenClass, !0);
6161
+ }, r.ignore.split(",").forEach(function(p) {
6162
+ vn(f, p.trim(), ro);
6163
+ }), k(l, "dragover", Re), k(l, "mousemove", Re), k(l, "touchmove", Re), k(l, "mouseup", n._onDrop), k(l, "touchend", n._onDrop), k(l, "touchcancel", n._onDrop), Fo && this.nativeDraggable && (this.options.touchStartThreshold = 4, f.draggable = !0), ee("delayStart", this, {
6164
6164
  evt: e
6165
- }), r.delay && (!r.delayOnTouchOnly || o) && (!this.nativeDraggable || !(ct || Oe))) {
6165
+ }), r.delay && (!r.delayOnTouchOnly || o) && (!this.nativeDraggable || !(ct || Ae))) {
6166
6166
  if (y.eventCanceled) {
6167
6167
  this._onDrop();
6168
6168
  return;
@@ -6184,7 +6184,7 @@ y.prototype = /** @lends Sortable.prototype */
6184
6184
  L(e, "mouseup", this._disableDelayedDrag), L(e, "touchend", this._disableDelayedDrag), L(e, "touchcancel", this._disableDelayedDrag), L(e, "mousemove", this._delayedDragTouchMoveHandler), L(e, "touchmove", this._delayedDragTouchMoveHandler), L(e, "pointermove", this._delayedDragTouchMoveHandler);
6185
6185
  },
6186
6186
  _triggerDragStart: function(e, o) {
6187
- o = o || e.pointerType == "touch" && e, !this.nativeDraggable || o ? this.options.supportPointer ? k(document, "pointermove", this._onTouchMove) : o ? k(document, "touchmove", this._onTouchMove) : k(document, "mousemove", this._onTouchMove) : (k(f, "dragend", this), k(M, "dragstart", this._onDragStart));
6187
+ o = o || e.pointerType == "touch" && e, !this.nativeDraggable || o ? this.options.supportPointer ? k(document, "pointermove", this._onTouchMove) : o ? k(document, "touchmove", this._onTouchMove) : k(document, "mousemove", this._onTouchMove) : (k(f, "dragend", this), k(D, "dragstart", this._onDragStart));
6188
6188
  try {
6189
6189
  document.selection ? Lt(function() {
6190
6190
  document.selection.empty();
@@ -6193,12 +6193,12 @@ y.prototype = /** @lends Sortable.prototype */
6193
6193
  }
6194
6194
  },
6195
6195
  _dragStarted: function(e, o) {
6196
- if (He = !1, M && f) {
6197
- Z("dragStarted", this, {
6196
+ if (Ge = !1, D && f) {
6197
+ ee("dragStarted", this, {
6198
6198
  evt: o
6199
6199
  }), this.nativeDraggable && k(document, "dragover", Zr);
6200
6200
  var t = this.options;
6201
- !e && ee(f, t.dragClass, !1), ee(f, t.ghostClass, !0), y.active = this, e && this._appendGhost(), q({
6201
+ !e && oe(f, t.dragClass, !1), oe(f, t.ghostClass, !0), y.active = this, e && this._appendGhost(), Q({
6202
6202
  sortable: this,
6203
6203
  name: "start",
6204
6204
  originalEvent: o
@@ -6207,17 +6207,17 @@ y.prototype = /** @lends Sortable.prototype */
6207
6207
  this._nulling();
6208
6208
  },
6209
6209
  _emulateDragOver: function() {
6210
- if (pe) {
6211
- this._lastX = pe.clientX, this._lastY = pe.clientY, kn();
6212
- for (var e = document.elementFromPoint(pe.clientX, pe.clientY), o = e; e && e.shadowRoot && (e = e.shadowRoot.elementFromPoint(pe.clientX, pe.clientY), e !== o); )
6210
+ if (fe) {
6211
+ this._lastX = fe.clientX, this._lastY = fe.clientY, kn();
6212
+ for (var e = document.elementFromPoint(fe.clientX, fe.clientY), o = e; e && e.shadowRoot && (e = e.shadowRoot.elementFromPoint(fe.clientX, fe.clientY), e !== o); )
6213
6213
  o = e;
6214
- if (f.parentNode[ie]._isOutsideThisEl(e), o)
6214
+ if (f.parentNode[le]._isOutsideThisEl(e), o)
6215
6215
  do {
6216
- if (o[ie]) {
6216
+ if (o[le]) {
6217
6217
  var t = void 0;
6218
- if (t = o[ie]._onDragOver({
6219
- clientX: pe.clientX,
6220
- clientY: pe.clientY,
6218
+ if (t = o[le]._onDragOver({
6219
+ clientX: fe.clientX,
6220
+ clientY: fe.clientY,
6221
6221
  target: e,
6222
6222
  rootEl: o
6223
6223
  }), t && !this.options.dragoverBubble)
@@ -6230,136 +6230,136 @@ y.prototype = /** @lends Sortable.prototype */
6230
6230
  },
6231
6231
  _onTouchMove: function(e) {
6232
6232
  if (Be) {
6233
- var o = this.options, t = o.fallbackTolerance, n = o.fallbackOffset, i = e.touches ? e.touches[0] : e, r = I && Je(I, !0), l = I && r && r.a, s = I && r && r.d, u = gt && W && Xo(W), _ = (i.clientX - Be.clientX + n.x) / (l || 1) + (u ? u[0] - io[0] : 0) / (l || 1), d = (i.clientY - Be.clientY + n.y) / (s || 1) + (u ? u[1] - io[1] : 0) / (s || 1);
6234
- if (!y.active && !He) {
6233
+ var o = this.options, t = o.fallbackTolerance, n = o.fallbackOffset, i = e.touches ? e.touches[0] : e, r = I && ze(I, !0), l = I && r && r.a, s = I && r && r.d, u = gt && J && Xo(J), p = (i.clientX - Be.clientX + n.x) / (l || 1) + (u ? u[0] - io[0] : 0) / (l || 1), d = (i.clientY - Be.clientY + n.y) / (s || 1) + (u ? u[1] - io[1] : 0) / (s || 1);
6234
+ if (!y.active && !Ge) {
6235
6235
  if (t && Math.max(Math.abs(i.clientX - this._lastX), Math.abs(i.clientY - this._lastY)) < t)
6236
6236
  return;
6237
6237
  this._onDragStart(e, !0);
6238
6238
  }
6239
6239
  if (I) {
6240
- r ? (r.e += _ - (oo || 0), r.f += d - (no || 0)) : r = {
6240
+ r ? (r.e += p - (oo || 0), r.f += d - (no || 0)) : r = {
6241
6241
  a: 1,
6242
6242
  b: 0,
6243
6243
  c: 0,
6244
6244
  d: 1,
6245
- e: _,
6245
+ e: p,
6246
6246
  f: d
6247
6247
  };
6248
- var p = "matrix(".concat(r.a, ",").concat(r.b, ",").concat(r.c, ",").concat(r.d, ",").concat(r.e, ",").concat(r.f, ")");
6249
- v(I, "webkitTransform", p), v(I, "mozTransform", p), v(I, "msTransform", p), v(I, "transform", p), oo = _, no = d, pe = i;
6248
+ var _ = "matrix(".concat(r.a, ",").concat(r.b, ",").concat(r.c, ",").concat(r.d, ",").concat(r.e, ",").concat(r.f, ")");
6249
+ v(I, "webkitTransform", _), v(I, "mozTransform", _), v(I, "msTransform", _), v(I, "transform", _), oo = p, no = d, fe = i;
6250
6250
  }
6251
6251
  e.cancelable && e.preventDefault();
6252
6252
  }
6253
6253
  },
6254
6254
  _appendGhost: function() {
6255
6255
  if (!I) {
6256
- var e = this.options.fallbackOnBody ? document.body : M, o = K(f, !0, gt, !0, e), t = this.options;
6256
+ var e = this.options.fallbackOnBody ? document.body : D, o = H(f, !0, gt, !0, e), t = this.options;
6257
6257
  if (gt) {
6258
- for (W = e; v(W, "position") === "static" && v(W, "transform") === "none" && W !== document; )
6259
- W = W.parentNode;
6260
- W !== document.body && W !== document.documentElement ? (W === document && (W = me()), o.top += W.scrollTop, o.left += W.scrollLeft) : W = me(), io = Xo(W);
6258
+ for (J = e; v(J, "position") === "static" && v(J, "transform") === "none" && J !== document; )
6259
+ J = J.parentNode;
6260
+ J !== document.body && J !== document.documentElement ? (J === document && (J = ge()), o.top += J.scrollTop, o.left += J.scrollLeft) : J = ge(), io = Xo(J);
6261
6261
  }
6262
- I = f.cloneNode(!0), ee(I, t.ghostClass, !1), ee(I, t.fallbackClass, !0), ee(I, t.dragClass, !0), v(I, "transition", ""), v(I, "transform", ""), v(I, "box-sizing", "border-box"), v(I, "margin", 0), v(I, "top", o.top), v(I, "left", o.left), v(I, "width", o.width), v(I, "height", o.height), v(I, "opacity", "0.8"), v(I, "position", gt ? "absolute" : "fixed"), v(I, "zIndex", "100000"), v(I, "pointerEvents", "none"), y.ghost = I, e.appendChild(I), v(I, "transform-origin", $o / parseInt(I.style.width) * 100 + "% " + jo / parseInt(I.style.height) * 100 + "%");
6262
+ I = f.cloneNode(!0), oe(I, t.ghostClass, !1), oe(I, t.fallbackClass, !0), oe(I, t.dragClass, !0), v(I, "transition", ""), v(I, "transform", ""), v(I, "box-sizing", "border-box"), v(I, "margin", 0), v(I, "top", o.top), v(I, "left", o.left), v(I, "width", o.width), v(I, "height", o.height), v(I, "opacity", "0.8"), v(I, "position", gt ? "absolute" : "fixed"), v(I, "zIndex", "100000"), v(I, "pointerEvents", "none"), y.ghost = I, e.appendChild(I), v(I, "transform-origin", $o / parseInt(I.style.width) * 100 + "% " + jo / parseInt(I.style.height) * 100 + "%");
6263
6263
  }
6264
6264
  },
6265
6265
  _onDragStart: function(e, o) {
6266
6266
  var t = this, n = e.dataTransfer, i = t.options;
6267
- if (Z("dragStart", this, {
6267
+ if (ee("dragStart", this, {
6268
6268
  evt: e
6269
6269
  }), y.eventCanceled) {
6270
6270
  this._onDrop();
6271
6271
  return;
6272
6272
  }
6273
- Z("setupClone", this), y.eventCanceled || (D = On(f), D.removeAttribute("id"), D.draggable = !1, D.style["will-change"] = "", this._hideClone(), ee(D, this.options.chosenClass, !1), y.clone = D), t.cloneId = Lt(function() {
6274
- Z("clone", t), !y.eventCanceled && (t.options.removeCloneOnHide || M.insertBefore(D, f), t._hideClone(), q({
6273
+ ee("setupClone", this), y.eventCanceled || (x = On(f), x.removeAttribute("id"), x.draggable = !1, x.style["will-change"] = "", this._hideClone(), oe(x, this.options.chosenClass, !1), y.clone = x), t.cloneId = Lt(function() {
6274
+ ee("clone", t), !y.eventCanceled && (t.options.removeCloneOnHide || D.insertBefore(x, f), t._hideClone(), Q({
6275
6275
  sortable: t,
6276
6276
  name: "clone"
6277
6277
  }));
6278
- }), !o && ee(f, i.dragClass, !0), o ? (Rt = !0, t._loopId = setInterval(t._emulateDragOver, 50)) : (L(document, "mouseup", t._onDrop), L(document, "touchend", t._onDrop), L(document, "touchcancel", t._onDrop), n && (n.effectAllowed = "move", i.setData && i.setData.call(t, n, f)), k(document, "drop", t), v(f, "transform", "translateZ(0)")), He = !0, t._dragStartId = Lt(t._dragStarted.bind(t, o, e)), k(document, "selectstart", t), et = !0, it && v(document.body, "user-select", "none");
6278
+ }), !o && oe(f, i.dragClass, !0), o ? (Rt = !0, t._loopId = setInterval(t._emulateDragOver, 50)) : (L(document, "mouseup", t._onDrop), L(document, "touchend", t._onDrop), L(document, "touchcancel", t._onDrop), n && (n.effectAllowed = "move", i.setData && i.setData.call(t, n, f)), k(document, "drop", t), v(f, "transform", "translateZ(0)")), Ge = !0, t._dragStartId = Lt(t._dragStarted.bind(t, o, e)), k(document, "selectstart", t), tt = !0, it && v(document.body, "user-select", "none");
6279
6279
  },
6280
6280
  // Returns true - if no further action is needed (either inserted or another condition)
6281
6281
  _onDragOver: function(e) {
6282
- var o = this.el, t = e.target, n, i, r, l = this.options, s = l.group, u = y.active, _ = Tt === s, d = l.sort, p = $ || u, T, h = this, A = !1;
6282
+ var o = this.el, t = e.target, n, i, r, l = this.options, s = l.group, u = y.active, p = Tt === s, d = l.sort, _ = $ || u, g, h = this, A = !1;
6283
6283
  if (_o)
6284
6284
  return;
6285
- function b(Se, Wt) {
6286
- Z(Se, h, ge({
6285
+ function b(ve, Wt) {
6286
+ ee(ve, h, Ee({
6287
6287
  evt: e,
6288
- isOwner: _,
6289
- axis: T ? "vertical" : "horizontal",
6288
+ isOwner: p,
6289
+ axis: g ? "vertical" : "horizontal",
6290
6290
  revert: r,
6291
6291
  dragRect: n,
6292
6292
  targetRect: i,
6293
6293
  canSort: d,
6294
- fromSortable: p,
6294
+ fromSortable: _,
6295
6295
  target: t,
6296
6296
  completed: S,
6297
6297
  onMove: function(Ao, Dn) {
6298
- return Et(M, o, f, n, Ao, K(Ao), e, Dn);
6298
+ return Et(D, o, f, n, Ao, H(Ao), e, Dn);
6299
6299
  },
6300
- changed: Q
6300
+ changed: Z
6301
6301
  }, Wt));
6302
6302
  }
6303
- function H() {
6304
- b("dragOverAnimationCapture"), h.captureAnimationState(), h !== p && p.captureAnimationState();
6303
+ function X() {
6304
+ b("dragOverAnimationCapture"), h.captureAnimationState(), h !== _ && _.captureAnimationState();
6305
6305
  }
6306
- function S(Se) {
6306
+ function S(ve) {
6307
6307
  return b("dragOverCompleted", {
6308
- insertion: Se
6309
- }), Se && (_ ? u._hideClone() : u._showClone(h), h !== p && (ee(f, $ ? $.options.ghostClass : u.options.ghostClass, !1), ee(f, l.ghostClass, !0)), $ !== h && h !== y.active ? $ = h : h === y.active && $ && ($ = null), p === h && (h._ignoreWhileAnimating = t), h.animateAll(function() {
6308
+ insertion: ve
6309
+ }), ve && (p ? u._hideClone() : u._showClone(h), h !== _ && (oe(f, $ ? $.options.ghostClass : u.options.ghostClass, !1), oe(f, l.ghostClass, !0)), $ !== h && h !== y.active ? $ = h : h === y.active && $ && ($ = null), _ === h && (h._ignoreWhileAnimating = t), h.animateAll(function() {
6310
6310
  b("dragOverAnimationComplete"), h._ignoreWhileAnimating = null;
6311
- }), h !== p && (p.animateAll(), p._ignoreWhileAnimating = null)), (t === f && !f.animated || t === o && !t.animated) && (Ke = null), !l.dragoverBubble && !e.rootEl && t !== document && (f.parentNode[ie]._isOutsideThisEl(e.target), !Se && Re(e)), !l.dragoverBubble && e.stopPropagation && e.stopPropagation(), A = !0;
6311
+ }), h !== _ && (_.animateAll(), _._ignoreWhileAnimating = null)), (t === f && !f.animated || t === o && !t.animated) && (Fe = null), !l.dragoverBubble && !e.rootEl && t !== document && (f.parentNode[le]._isOutsideThisEl(e.target), !ve && Re(e)), !l.dragoverBubble && e.stopPropagation && e.stopPropagation(), A = !0;
6312
6312
  }
6313
- function Q() {
6314
- te = ae(f), Ie = ae(f, l.draggable), q({
6313
+ function Z() {
6314
+ ne = ue(f), Le = ue(f, l.draggable), Q({
6315
6315
  sortable: h,
6316
6316
  name: "change",
6317
6317
  toEl: o,
6318
- newIndex: te,
6319
- newDraggableIndex: Ie,
6318
+ newIndex: ne,
6319
+ newDraggableIndex: Le,
6320
6320
  originalEvent: e
6321
6321
  });
6322
6322
  }
6323
- if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), t = de(t, l.draggable, o, !0), b("dragOver"), y.eventCanceled)
6323
+ if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), t = he(t, l.draggable, o, !0), b("dragOver"), y.eventCanceled)
6324
6324
  return A;
6325
6325
  if (f.contains(e.target) || t.animated && t.animatingX && t.animatingY || h._ignoreWhileAnimating === t)
6326
6326
  return S(!1);
6327
- if (Rt = !1, u && !l.disabled && (_ ? d || (r = P !== M) : $ === this || (this.lastPutMode = Tt.checkPull(this, u, f, e)) && s.checkPut(this, u, f, e))) {
6328
- if (T = this._getDirection(e, t) === "vertical", n = K(f), b("dragOverValid"), y.eventCanceled)
6327
+ if (Rt = !1, u && !l.disabled && (p ? d || (r = w !== D) : $ === this || (this.lastPutMode = Tt.checkPull(this, u, f, e)) && s.checkPut(this, u, f, e))) {
6328
+ if (g = this._getDirection(e, t) === "vertical", n = H(f), b("dragOverValid"), y.eventCanceled)
6329
6329
  return A;
6330
6330
  if (r)
6331
- return P = M, H(), this._hideClone(), b("revert"), y.eventCanceled || (Me ? M.insertBefore(f, Me) : M.appendChild(f)), S(!0);
6332
- var w = Oo(o, l.draggable);
6333
- if (!w || nl(e, T, this) && !w.animated) {
6334
- if (w === f)
6331
+ return w = D, X(), this._hideClone(), b("revert"), y.eventCanceled || (Me ? D.insertBefore(f, Me) : D.appendChild(f)), S(!0);
6332
+ var V = Oo(o, l.draggable);
6333
+ if (!V || nl(e, g, this) && !V.animated) {
6334
+ if (V === f)
6335
6335
  return S(!1);
6336
- if (w && o === e.target && (t = w), t && (i = K(t)), Et(M, o, f, n, t, i, e, !!t) !== !1)
6337
- return H(), w && w.nextSibling ? o.insertBefore(f, w.nextSibling) : o.appendChild(f), P = o, Q(), S(!0);
6338
- } else if (w && ol(e, T, this)) {
6339
- var re = qe(o, 0, l, !0);
6340
- if (re === f)
6336
+ if (V && o === e.target && (t = V), t && (i = H(t)), Et(D, o, f, n, t, i, e, !!t) !== !1)
6337
+ return X(), V && V.nextSibling ? o.insertBefore(f, V.nextSibling) : o.appendChild(f), w = o, Z(), S(!0);
6338
+ } else if (V && ol(e, g, this)) {
6339
+ var se = Qe(o, 0, l, !0);
6340
+ if (se === f)
6341
6341
  return S(!1);
6342
- if (t = re, i = K(t), Et(M, o, f, n, t, i, e, !1) !== !1)
6343
- return H(), o.insertBefore(f, re), P = o, Q(), S(!0);
6342
+ if (t = se, i = H(t), Et(D, o, f, n, t, i, e, !1) !== !1)
6343
+ return X(), o.insertBefore(f, se), w = o, Z(), S(!0);
6344
6344
  } else if (t.parentNode === o) {
6345
- i = K(t);
6346
- var U = 0, le, Ee = f.parentNode !== o, O = !qr(f.animated && f.toRect || n, t.animated && t.toRect || i, T), C = T ? "top" : "left", E = Go(t, "top", "top") || Go(f, "top", "top"), B = E ? E.scrollTop : void 0;
6347
- Ke !== t && (le = i[C], st = !1, mt = !O && l.invertSwap || Ee), U = il(e, t, i, T, O ? 1 : l.swapThreshold, l.invertedSwapThreshold == null ? l.swapThreshold : l.invertedSwapThreshold, mt, Ke === t);
6348
- var R;
6345
+ i = H(t);
6346
+ var U = 0, ce, te = f.parentNode !== o, O = !qr(f.animated && f.toRect || n, t.animated && t.toRect || i, g), C = g ? "top" : "left", R = Go(t, "top", "top") || Go(f, "top", "top"), K = R ? R.scrollTop : void 0;
6347
+ Fe !== t && (ce = i[C], st = !1, mt = !O && l.invertSwap || te), U = il(e, t, i, g, O ? 1 : l.swapThreshold, l.invertedSwapThreshold == null ? l.swapThreshold : l.invertedSwapThreshold, mt, Fe === t);
6348
+ var B;
6349
6349
  if (U !== 0) {
6350
- var x = ae(f);
6350
+ var E = ue(f);
6351
6351
  do
6352
- x -= U, R = P.children[x];
6353
- while (R && (v(R, "display") === "none" || R === I));
6352
+ E -= U, B = w.children[E];
6353
+ while (B && (v(B, "display") === "none" || B === I));
6354
6354
  }
6355
- if (U === 0 || R === t)
6355
+ if (U === 0 || B === t)
6356
6356
  return S(!1);
6357
- Ke = t, at = U;
6358
- var G = t.nextElementSibling, X = !1;
6359
- X = U === 1;
6360
- var fe = Et(M, o, f, n, t, i, e, X);
6361
- if (fe !== !1)
6362
- return (fe === 1 || fe === -1) && (X = fe === 1), _o = !0, setTimeout(tl, 30), H(), X && !G ? o.appendChild(f) : t.parentNode.insertBefore(f, X ? G : t), E && bn(E, 0, B - E.scrollTop), P = f.parentNode, le !== void 0 && !mt && (At = Math.abs(le - K(t)[C])), Q(), S(!0);
6357
+ Fe = t, at = U;
6358
+ var M = t.nextElementSibling, P = !1;
6359
+ P = U === 1;
6360
+ var z = Et(D, o, f, n, t, i, e, P);
6361
+ if (z !== !1)
6362
+ return (z === 1 || z === -1) && (P = z === 1), _o = !0, setTimeout(tl, 30), X(), P && !M ? o.appendChild(f) : t.parentNode.insertBefore(f, P ? M : t), R && bn(R, 0, K - R.scrollTop), w = f.parentNode, ce !== void 0 && !mt && (At = Math.abs(ce - H(t)[C])), Z(), S(!0);
6363
6363
  }
6364
6364
  if (o.contains(f))
6365
6365
  return S(!1);
@@ -6376,60 +6376,60 @@ y.prototype = /** @lends Sortable.prototype */
6376
6376
  },
6377
6377
  _onDrop: function(e) {
6378
6378
  var o = this.el, t = this.options;
6379
- if (te = ae(f), Ie = ae(f, t.draggable), Z("drop", this, {
6379
+ if (ne = ue(f), Le = ue(f, t.draggable), ee("drop", this, {
6380
6380
  evt: e
6381
- }), P = f && f.parentNode, te = ae(f), Ie = ae(f, t.draggable), y.eventCanceled) {
6381
+ }), w = f && f.parentNode, ne = ue(f), Le = ue(f, t.draggable), y.eventCanceled) {
6382
6382
  this._nulling();
6383
6383
  return;
6384
6384
  }
6385
- He = !1, mt = !1, st = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), po(this.cloneId), po(this._dragStartId), this.nativeDraggable && (L(document, "drop", this), L(o, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), it && v(document.body, "user-select", ""), v(f, "transform", ""), e && (et && (e.cancelable && e.preventDefault(), !t.dropBubble && e.stopPropagation()), I && I.parentNode && I.parentNode.removeChild(I), (M === P || $ && $.lastPutMode !== "clone") && D && D.parentNode && D.parentNode.removeChild(D), f && (this.nativeDraggable && L(f, "dragend", this), ro(f), f.style["will-change"] = "", et && !He && ee(f, $ ? $.options.ghostClass : this.options.ghostClass, !1), ee(f, this.options.chosenClass, !1), q({
6385
+ Ge = !1, mt = !1, st = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), po(this.cloneId), po(this._dragStartId), this.nativeDraggable && (L(document, "drop", this), L(o, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), it && v(document.body, "user-select", ""), v(f, "transform", ""), e && (tt && (e.cancelable && e.preventDefault(), !t.dropBubble && e.stopPropagation()), I && I.parentNode && I.parentNode.removeChild(I), (D === w || $ && $.lastPutMode !== "clone") && x && x.parentNode && x.parentNode.removeChild(x), f && (this.nativeDraggable && L(f, "dragend", this), ro(f), f.style["will-change"] = "", tt && !Ge && oe(f, $ ? $.options.ghostClass : this.options.ghostClass, !1), oe(f, this.options.chosenClass, !1), Q({
6386
6386
  sortable: this,
6387
6387
  name: "unchoose",
6388
- toEl: P,
6388
+ toEl: w,
6389
6389
  newIndex: null,
6390
6390
  newDraggableIndex: null,
6391
6391
  originalEvent: e
6392
- }), M !== P ? (te >= 0 && (q({
6393
- rootEl: P,
6392
+ }), D !== w ? (ne >= 0 && (Q({
6393
+ rootEl: w,
6394
6394
  name: "add",
6395
- toEl: P,
6396
- fromEl: M,
6395
+ toEl: w,
6396
+ fromEl: D,
6397
6397
  originalEvent: e
6398
- }), q({
6398
+ }), Q({
6399
6399
  sortable: this,
6400
6400
  name: "remove",
6401
- toEl: P,
6401
+ toEl: w,
6402
6402
  originalEvent: e
6403
- }), q({
6404
- rootEl: P,
6403
+ }), Q({
6404
+ rootEl: w,
6405
6405
  name: "sort",
6406
- toEl: P,
6407
- fromEl: M,
6406
+ toEl: w,
6407
+ fromEl: D,
6408
6408
  originalEvent: e
6409
- }), q({
6409
+ }), Q({
6410
6410
  sortable: this,
6411
6411
  name: "sort",
6412
- toEl: P,
6412
+ toEl: w,
6413
6413
  originalEvent: e
6414
- })), $ && $.save()) : te !== je && te >= 0 && (q({
6414
+ })), $ && $.save()) : ne !== We && ne >= 0 && (Q({
6415
6415
  sortable: this,
6416
6416
  name: "update",
6417
- toEl: P,
6417
+ toEl: w,
6418
6418
  originalEvent: e
6419
- }), q({
6419
+ }), Q({
6420
6420
  sortable: this,
6421
6421
  name: "sort",
6422
- toEl: P,
6422
+ toEl: w,
6423
6423
  originalEvent: e
6424
- })), y.active && ((te == null || te === -1) && (te = je, Ie = lt), q({
6424
+ })), y.active && ((ne == null || ne === -1) && (ne = We, Le = lt), Q({
6425
6425
  sortable: this,
6426
6426
  name: "end",
6427
- toEl: P,
6427
+ toEl: w,
6428
6428
  originalEvent: e
6429
6429
  }), this.save()))), this._nulling();
6430
6430
  },
6431
6431
  _nulling: function() {
6432
- Z("nulling", this), M = f = P = I = Me = D = Ct = Ce = Be = pe = et = te = Ie = je = lt = Ke = at = $ = Tt = y.dragged = y.ghost = y.clone = y.active = null, Dt.forEach(function(e) {
6432
+ ee("nulling", this), D = f = w = I = Me = x = Ct = ke = Be = fe = tt = ne = Le = We = lt = Fe = at = $ = Tt = y.dragged = y.ghost = y.clone = y.active = null, Dt.forEach(function(e) {
6433
6433
  e.checked = !0;
6434
6434
  }), Dt.length = oo = no = 0;
6435
6435
  },
@@ -6454,7 +6454,7 @@ y.prototype = /** @lends Sortable.prototype */
6454
6454
  */
6455
6455
  toArray: function() {
6456
6456
  for (var e = [], o, t = this.el.children, n = 0, i = t.length, r = this.options; n < i; n++)
6457
- o = t[n], de(o, r.draggable, this.el, !1) && e.push(o.getAttribute(r.dataIdAttr) || ll(o));
6457
+ o = t[n], he(o, r.draggable, this.el, !1) && e.push(o.getAttribute(r.dataIdAttr) || ll(o));
6458
6458
  return e;
6459
6459
  },
6460
6460
  /**
@@ -6465,7 +6465,7 @@ y.prototype = /** @lends Sortable.prototype */
6465
6465
  var t = {}, n = this.el;
6466
6466
  this.toArray().forEach(function(i, r) {
6467
6467
  var l = n.children[r];
6468
- de(l, this.options.draggable, n, !1) && (t[i] = l);
6468
+ he(l, this.options.draggable, n, !1) && (t[i] = l);
6469
6469
  }, this), o && this.captureAnimationState(), e.forEach(function(i) {
6470
6470
  t[i] && (n.removeChild(t[i]), n.appendChild(t[i]));
6471
6471
  }), o && this.animateAll();
@@ -6484,7 +6484,7 @@ y.prototype = /** @lends Sortable.prototype */
6484
6484
  * @returns {HTMLElement|null}
6485
6485
  */
6486
6486
  closest: function(e, o) {
6487
- return de(e, o || this.options.draggable, this.el, !1);
6487
+ return he(e, o || this.options.draggable, this.el, !1);
6488
6488
  },
6489
6489
  /**
6490
6490
  * Set/get option
@@ -6503,17 +6503,17 @@ y.prototype = /** @lends Sortable.prototype */
6503
6503
  * Destroy
6504
6504
  */
6505
6505
  destroy: function() {
6506
- Z("destroy", this);
6506
+ ee("destroy", this);
6507
6507
  var e = this.el;
6508
- e[ie] = null, L(e, "mousedown", this._onTapStart), L(e, "touchstart", this._onTapStart), L(e, "pointerdown", this._onTapStart), this.nativeDraggable && (L(e, "dragover", this), L(e, "dragenter", this)), Array.prototype.forEach.call(e.querySelectorAll("[draggable]"), function(o) {
6508
+ e[le] = null, L(e, "mousedown", this._onTapStart), L(e, "touchstart", this._onTapStart), L(e, "pointerdown", this._onTapStart), this.nativeDraggable && (L(e, "dragover", this), L(e, "dragenter", this)), Array.prototype.forEach.call(e.querySelectorAll("[draggable]"), function(o) {
6509
6509
  o.removeAttribute("draggable");
6510
6510
  }), this._onDrop(), this._disableDelayedDragEvents(), Mt.splice(Mt.indexOf(this.el), 1), this.el = e = null;
6511
6511
  },
6512
6512
  _hideClone: function() {
6513
- if (!Ce) {
6514
- if (Z("hideClone", this), y.eventCanceled)
6513
+ if (!ke) {
6514
+ if (ee("hideClone", this), y.eventCanceled)
6515
6515
  return;
6516
- v(D, "display", "none"), this.options.removeCloneOnHide && D.parentNode && D.parentNode.removeChild(D), Ce = !0;
6516
+ v(x, "display", "none"), this.options.removeCloneOnHide && x.parentNode && x.parentNode.removeChild(x), ke = !0;
6517
6517
  }
6518
6518
  },
6519
6519
  _showClone: function(e) {
@@ -6521,10 +6521,10 @@ y.prototype = /** @lends Sortable.prototype */
6521
6521
  this._hideClone();
6522
6522
  return;
6523
6523
  }
6524
- if (Ce) {
6525
- if (Z("showClone", this), y.eventCanceled)
6524
+ if (ke) {
6525
+ if (ee("showClone", this), y.eventCanceled)
6526
6526
  return;
6527
- f.parentNode == M && !this.options.group.revertClone ? M.insertBefore(D, f) : Me ? M.insertBefore(D, Me) : M.appendChild(D), this.options.group.revertClone && this.animate(f, D), v(D, "display", ""), Ce = !1;
6527
+ f.parentNode == D && !this.options.group.revertClone ? D.insertBefore(x, f) : Me ? D.insertBefore(x, Me) : D.appendChild(x), this.options.group.revertClone && this.animate(f, x), v(x, "display", ""), ke = !1;
6528
6528
  }
6529
6529
  }
6530
6530
  };
@@ -6532,11 +6532,11 @@ function el(e) {
6532
6532
  e.dataTransfer && (e.dataTransfer.dropEffect = "move"), e.cancelable && e.preventDefault();
6533
6533
  }
6534
6534
  function Et(e, o, t, n, i, r, l, s) {
6535
- var u, _ = e[ie], d = _.options.onMove, p;
6536
- return window.CustomEvent && !Oe && !ct ? u = new CustomEvent("move", {
6535
+ var u, p = e[le], d = p.options.onMove, _;
6536
+ return window.CustomEvent && !Ae && !ct ? u = new CustomEvent("move", {
6537
6537
  bubbles: !0,
6538
6538
  cancelable: !0
6539
- }) : (u = document.createEvent("Event"), u.initEvent("move", !0, !0)), u.to = o, u.from = e, u.dragged = t, u.draggedRect = n, u.related = i || o, u.relatedRect = r || K(o), u.willInsertAfter = s, u.originalEvent = l, e.dispatchEvent(u), d && (p = d.call(_, u, l)), p;
6539
+ }) : (u = document.createEvent("Event"), u.initEvent("move", !0, !0)), u.to = o, u.from = e, u.dragged = t, u.draggedRect = n, u.related = i || o, u.relatedRect = r || H(o), u.willInsertAfter = s, u.originalEvent = l, e.dispatchEvent(u), d && (_ = d.call(p, u, l)), _;
6540
6540
  }
6541
6541
  function ro(e) {
6542
6542
  e.draggable = !1;
@@ -6545,28 +6545,28 @@ function tl() {
6545
6545
  _o = !1;
6546
6546
  }
6547
6547
  function ol(e, o, t) {
6548
- var n = K(qe(t.el, 0, t.options, !0)), i = In(t.el, t.options, I), r = 10;
6548
+ var n = H(Qe(t.el, 0, t.options, !0)), i = In(t.el, t.options, I), r = 10;
6549
6549
  return o ? e.clientX < i.left - r || e.clientY < n.top && e.clientX < n.right : e.clientY < i.top - r || e.clientY < n.bottom && e.clientX < n.left;
6550
6550
  }
6551
6551
  function nl(e, o, t) {
6552
- var n = K(Oo(t.el, t.options.draggable)), i = In(t.el, t.options, I), r = 10;
6552
+ var n = H(Oo(t.el, t.options.draggable)), i = In(t.el, t.options, I), r = 10;
6553
6553
  return o ? e.clientX > i.right + r || e.clientY > n.bottom && e.clientX > n.left : e.clientY > i.bottom + r || e.clientX > n.right && e.clientY > n.top;
6554
6554
  }
6555
6555
  function il(e, o, t, n, i, r, l, s) {
6556
- var u = n ? e.clientY : e.clientX, _ = n ? t.height : t.width, d = n ? t.top : t.left, p = n ? t.bottom : t.right, T = !1;
6556
+ var u = n ? e.clientY : e.clientX, p = n ? t.height : t.width, d = n ? t.top : t.left, _ = n ? t.bottom : t.right, g = !1;
6557
6557
  if (!l) {
6558
- if (s && At < _ * i) {
6559
- if (!st && (at === 1 ? u > d + _ * r / 2 : u < p - _ * r / 2) && (st = !0), st)
6560
- T = !0;
6561
- else if (at === 1 ? u < d + At : u > p - At)
6558
+ if (s && At < p * i) {
6559
+ if (!st && (at === 1 ? u > d + p * r / 2 : u < _ - p * r / 2) && (st = !0), st)
6560
+ g = !0;
6561
+ else if (at === 1 ? u < d + At : u > _ - At)
6562
6562
  return -at;
6563
- } else if (u > d + _ * (1 - i) / 2 && u < p - _ * (1 - i) / 2)
6563
+ } else if (u > d + p * (1 - i) / 2 && u < _ - p * (1 - i) / 2)
6564
6564
  return rl(o);
6565
6565
  }
6566
- return T = T || l, T && (u < d + _ * r / 2 || u > p - _ * r / 2) ? u > d + _ / 2 ? 1 : -1 : 0;
6566
+ return g = g || l, g && (u < d + p * r / 2 || u > _ - p * r / 2) ? u > d + p / 2 ? 1 : -1 : 0;
6567
6567
  }
6568
6568
  function rl(e) {
6569
- return ae(f) < ae(e) ? 1 : -1;
6569
+ return ue(f) < ue(e) ? 1 : -1;
6570
6570
  }
6571
6571
  function ll(e) {
6572
6572
  for (var o = e.tagName + e.className + e.src + e.href + e.textContent, t = o.length, n = 0; t--; )
@@ -6587,7 +6587,7 @@ function po(e) {
6587
6587
  return clearTimeout(e);
6588
6588
  }
6589
6589
  jt && k(document, "touchmove", function(e) {
6590
- (y.active || He) && e.cancelable && e.preventDefault();
6590
+ (y.active || Ge) && e.cancelable && e.preventDefault();
6591
6591
  });
6592
6592
  y.utils = {
6593
6593
  on: k,
@@ -6595,21 +6595,21 @@ y.utils = {
6595
6595
  css: v,
6596
6596
  find: vn,
6597
6597
  is: function(e, o) {
6598
- return !!de(e, o, e, !1);
6598
+ return !!he(e, o, e, !1);
6599
6599
  },
6600
6600
  extend: Hr,
6601
6601
  throttle: yn,
6602
- closest: de,
6603
- toggleClass: ee,
6602
+ closest: he,
6603
+ toggleClass: oe,
6604
6604
  clone: On,
6605
- index: ae,
6605
+ index: ue,
6606
6606
  nextTick: Lt,
6607
6607
  cancelNextTick: po,
6608
6608
  detectDirection: An,
6609
- getChild: qe
6609
+ getChild: Qe
6610
6610
  };
6611
6611
  y.get = function(e) {
6612
- return e[ie];
6612
+ return e[le];
6613
6613
  };
6614
6614
  y.mount = function() {
6615
6615
  for (var e = arguments.length, o = new Array(e), t = 0; t < e; t++)
@@ -6617,14 +6617,14 @@ y.mount = function() {
6617
6617
  o[0].constructor === Array && (o = o[0]), o.forEach(function(n) {
6618
6618
  if (!n.prototype || !n.prototype.constructor)
6619
6619
  throw "Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(n));
6620
- n.utils && (y.utils = ge(ge({}, y.utils), n.utils)), ut.mount(n);
6620
+ n.utils && (y.utils = Ee(Ee({}, y.utils), n.utils)), ut.mount(n);
6621
6621
  });
6622
6622
  };
6623
6623
  y.create = function(e, o) {
6624
6624
  return new y(e, o);
6625
6625
  };
6626
6626
  y.version = Yr;
6627
- var Y = [], tt, fo, ho = !1, lo, ao, xt, ot;
6627
+ var F = [], ot, fo, ho = !1, lo, ao, xt, nt;
6628
6628
  function sl() {
6629
6629
  function e() {
6630
6630
  this.defaults = {
@@ -6650,69 +6650,69 @@ function sl() {
6650
6650
  this.sortable.nativeDraggable ? L(document, "dragover", this._handleAutoScroll) : (L(document, "pointermove", this._handleFallbackAutoScroll), L(document, "touchmove", this._handleFallbackAutoScroll), L(document, "mousemove", this._handleFallbackAutoScroll)), Jo(), kt(), Gr();
6651
6651
  },
6652
6652
  nulling: function() {
6653
- xt = fo = tt = ho = ot = lo = ao = null, Y.length = 0;
6653
+ xt = fo = ot = ho = nt = lo = ao = null, F.length = 0;
6654
6654
  },
6655
6655
  _handleFallbackAutoScroll: function(o) {
6656
6656
  this._handleAutoScroll(o, !0);
6657
6657
  },
6658
6658
  _handleAutoScroll: function(o, t) {
6659
6659
  var n = this, i = (o.touches ? o.touches[0] : o).clientX, r = (o.touches ? o.touches[0] : o).clientY, l = document.elementFromPoint(i, r);
6660
- if (xt = o, t || this.options.forceAutoScrollFallback || ct || Oe || it) {
6660
+ if (xt = o, t || this.options.forceAutoScrollFallback || ct || Ae || it) {
6661
6661
  so(o, this.options, l, t);
6662
- var s = Ae(l, !0);
6663
- ho && (!ot || i !== lo || r !== ao) && (ot && Jo(), ot = setInterval(function() {
6664
- var u = Ae(document.elementFromPoint(i, r), !0);
6662
+ var s = Ne(l, !0);
6663
+ ho && (!nt || i !== lo || r !== ao) && (nt && Jo(), nt = setInterval(function() {
6664
+ var u = Ne(document.elementFromPoint(i, r), !0);
6665
6665
  u !== s && (s = u, kt()), so(o, n.options, u, t);
6666
6666
  }, 10), lo = i, ao = r);
6667
6667
  } else {
6668
- if (!this.options.bubbleScroll || Ae(l, !0) === me()) {
6668
+ if (!this.options.bubbleScroll || Ne(l, !0) === ge()) {
6669
6669
  kt();
6670
6670
  return;
6671
6671
  }
6672
- so(o, this.options, Ae(l, !1), !1);
6672
+ so(o, this.options, Ne(l, !1), !1);
6673
6673
  }
6674
6674
  }
6675
- }, be(e, {
6675
+ }, Ce(e, {
6676
6676
  pluginName: "scroll",
6677
6677
  initializeByDefault: !0
6678
6678
  });
6679
6679
  }
6680
6680
  function kt() {
6681
- Y.forEach(function(e) {
6681
+ F.forEach(function(e) {
6682
6682
  clearInterval(e.pid);
6683
- }), Y = [];
6683
+ }), F = [];
6684
6684
  }
6685
6685
  function Jo() {
6686
- clearInterval(ot);
6686
+ clearInterval(nt);
6687
6687
  }
6688
6688
  var so = yn(function(e, o, t, n) {
6689
6689
  if (o.scroll) {
6690
- var i = (e.touches ? e.touches[0] : e).clientX, r = (e.touches ? e.touches[0] : e).clientY, l = o.scrollSensitivity, s = o.scrollSpeed, u = me(), _ = !1, d;
6691
- fo !== t && (fo = t, kt(), tt = o.scroll, d = o.scrollFn, tt === !0 && (tt = Ae(t, !0)));
6692
- var p = 0, T = tt;
6690
+ var i = (e.touches ? e.touches[0] : e).clientX, r = (e.touches ? e.touches[0] : e).clientY, l = o.scrollSensitivity, s = o.scrollSpeed, u = ge(), p = !1, d;
6691
+ fo !== t && (fo = t, kt(), ot = o.scroll, d = o.scrollFn, ot === !0 && (ot = Ne(t, !0)));
6692
+ var _ = 0, g = ot;
6693
6693
  do {
6694
- var h = T, A = K(h), b = A.top, H = A.bottom, S = A.left, Q = A.right, w = A.width, re = A.height, U = void 0, le = void 0, Ee = h.scrollWidth, O = h.scrollHeight, C = v(h), E = h.scrollLeft, B = h.scrollTop;
6695
- h === u ? (U = w < Ee && (C.overflowX === "auto" || C.overflowX === "scroll" || C.overflowX === "visible"), le = re < O && (C.overflowY === "auto" || C.overflowY === "scroll" || C.overflowY === "visible")) : (U = w < Ee && (C.overflowX === "auto" || C.overflowX === "scroll"), le = re < O && (C.overflowY === "auto" || C.overflowY === "scroll"));
6696
- var R = U && (Math.abs(Q - i) <= l && E + w < Ee) - (Math.abs(S - i) <= l && !!E), x = le && (Math.abs(H - r) <= l && B + re < O) - (Math.abs(b - r) <= l && !!B);
6697
- if (!Y[p])
6698
- for (var G = 0; G <= p; G++)
6699
- Y[G] || (Y[G] = {});
6700
- (Y[p].vx != R || Y[p].vy != x || Y[p].el !== h) && (Y[p].el = h, Y[p].vx = R, Y[p].vy = x, clearInterval(Y[p].pid), (R != 0 || x != 0) && (_ = !0, Y[p].pid = setInterval((function() {
6694
+ var h = g, A = H(h), b = A.top, X = A.bottom, S = A.left, Z = A.right, V = A.width, se = A.height, U = void 0, ce = void 0, te = h.scrollWidth, O = h.scrollHeight, C = v(h), R = h.scrollLeft, K = h.scrollTop;
6695
+ h === u ? (U = V < te && (C.overflowX === "auto" || C.overflowX === "scroll" || C.overflowX === "visible"), ce = se < O && (C.overflowY === "auto" || C.overflowY === "scroll" || C.overflowY === "visible")) : (U = V < te && (C.overflowX === "auto" || C.overflowX === "scroll"), ce = se < O && (C.overflowY === "auto" || C.overflowY === "scroll"));
6696
+ var B = U && (Math.abs(Z - i) <= l && R + V < te) - (Math.abs(S - i) <= l && !!R), E = ce && (Math.abs(X - r) <= l && K + se < O) - (Math.abs(b - r) <= l && !!K);
6697
+ if (!F[_])
6698
+ for (var M = 0; M <= _; M++)
6699
+ F[M] || (F[M] = {});
6700
+ (F[_].vx != B || F[_].vy != E || F[_].el !== h) && (F[_].el = h, F[_].vx = B, F[_].vy = E, clearInterval(F[_].pid), (B != 0 || E != 0) && (p = !0, F[_].pid = setInterval((function() {
6701
6701
  n && this.layer === 0 && y.active._onTouchMove(xt);
6702
- var X = Y[this.layer].vy ? Y[this.layer].vy * s : 0, fe = Y[this.layer].vx ? Y[this.layer].vx * s : 0;
6703
- typeof d == "function" && d.call(y.dragged.parentNode[ie], fe, X, e, xt, Y[this.layer].el) !== "continue" || bn(Y[this.layer].el, fe, X);
6702
+ var P = F[this.layer].vy ? F[this.layer].vy * s : 0, z = F[this.layer].vx ? F[this.layer].vx * s : 0;
6703
+ typeof d == "function" && d.call(y.dragged.parentNode[le], z, P, e, xt, F[this.layer].el) !== "continue" || bn(F[this.layer].el, z, P);
6704
6704
  }).bind({
6705
- layer: p
6706
- }), 24))), p++;
6707
- } while (o.bubbleScroll && T !== u && (T = Ae(T, !1)));
6708
- ho = _;
6705
+ layer: _
6706
+ }), 24))), _++;
6707
+ } while (o.bubbleScroll && g !== u && (g = Ne(g, !1)));
6708
+ ho = p;
6709
6709
  }
6710
6710
  }, 30), Sn = function(e) {
6711
6711
  var o = e.originalEvent, t = e.putSortable, n = e.dragEl, i = e.activeSortable, r = e.dispatchSortableEvent, l = e.hideGhostForTarget, s = e.unhideGhostForTarget;
6712
6712
  if (o) {
6713
6713
  var u = t || i;
6714
6714
  l();
6715
- var _ = o.changedTouches && o.changedTouches.length ? o.changedTouches[0] : o, d = document.elementFromPoint(_.clientX, _.clientY);
6715
+ var p = o.changedTouches && o.changedTouches.length ? o.changedTouches[0] : o, d = document.elementFromPoint(p.clientX, p.clientY);
6716
6716
  s(), u && !u.el.contains(d) && (r("spill"), this.onSpill({
6717
6717
  dragEl: n,
6718
6718
  putSortable: t
@@ -6730,12 +6730,12 @@ Io.prototype = {
6730
6730
  onSpill: function(e) {
6731
6731
  var o = e.dragEl, t = e.putSortable;
6732
6732
  this.sortable.captureAnimationState(), t && t.captureAnimationState();
6733
- var n = qe(this.sortable.el, this.startIndex, this.options);
6733
+ var n = Qe(this.sortable.el, this.startIndex, this.options);
6734
6734
  n ? this.sortable.el.insertBefore(o, n) : this.sortable.el.appendChild(o), this.sortable.animateAll(), t && t.animateAll();
6735
6735
  },
6736
6736
  drop: Sn
6737
6737
  };
6738
- be(Io, {
6738
+ Ce(Io, {
6739
6739
  pluginName: "revertOnSpill"
6740
6740
  });
6741
6741
  function Co() {
@@ -6747,7 +6747,7 @@ Co.prototype = {
6747
6747
  },
6748
6748
  drop: Sn
6749
6749
  };
6750
- be(Co, {
6750
+ Ce(Co, {
6751
6751
  pluginName: "removeOnSpill"
6752
6752
  });
6753
6753
  y.mount(new sl());
@@ -6759,7 +6759,7 @@ function ul(e) {
6759
6759
  Pt() && Fn(e);
6760
6760
  }
6761
6761
  function _l(e) {
6762
- Pt() ? ze(e) : go(e);
6762
+ Pt() ? qe(e) : go(e);
6763
6763
  }
6764
6764
  let Bn = null, Rn = null;
6765
6765
  function zo(e = null, o = null) {
@@ -6781,109 +6781,109 @@ function dl(...e) {
6781
6781
  Array.isArray(N(l)) || (s = l, l = null);
6782
6782
  let u = null;
6783
6783
  const {
6784
- immediate: _ = !0,
6784
+ immediate: p = !0,
6785
6785
  clone: d = cl,
6786
- customUpdate: p
6786
+ customUpdate: _
6787
6787
  } = (t = N(s)) != null ? t : {};
6788
- function T(O) {
6788
+ function g(O) {
6789
6789
  var C;
6790
- const { from: E, oldIndex: B, item: R } = O;
6791
- i = Array.from(E.childNodes);
6792
- const x = N((C = N(l)) == null ? void 0 : C[B]), G = d(x);
6793
- zo(x, G), R[qo] = G;
6790
+ const { from: R, oldIndex: K, item: B } = O;
6791
+ i = Array.from(R.childNodes);
6792
+ const E = N((C = N(l)) == null ? void 0 : C[K]), M = d(E);
6793
+ zo(E, M), B[qo] = M;
6794
6794
  }
6795
6795
  function h(O) {
6796
6796
  const C = O.item[qo];
6797
6797
  if (!Nr(C)) {
6798
6798
  if (Zt(O.item), vt(l)) {
6799
- const E = [...N(l)];
6800
- l.value = Vo(E, O.newDraggableIndex, C);
6799
+ const R = [...N(l)];
6800
+ l.value = Vo(R, O.newDraggableIndex, C);
6801
6801
  return;
6802
6802
  }
6803
6803
  Vo(N(l), O.newDraggableIndex, C);
6804
6804
  }
6805
6805
  }
6806
6806
  function A(O) {
6807
- const { from: C, item: E, oldIndex: B, oldDraggableIndex: R, pullMode: x, clone: G } = O;
6808
- if (Uo(C, E, B), x === "clone") {
6809
- Zt(G);
6807
+ const { from: C, item: R, oldIndex: K, oldDraggableIndex: B, pullMode: E, clone: M } = O;
6808
+ if (Uo(C, R, K), E === "clone") {
6809
+ Zt(M);
6810
6810
  return;
6811
6811
  }
6812
6812
  if (vt(l)) {
6813
- const X = [...N(l)];
6814
- l.value = wo(X, R);
6813
+ const P = [...N(l)];
6814
+ l.value = wo(P, B);
6815
6815
  return;
6816
6816
  }
6817
- wo(N(l), R);
6817
+ wo(N(l), B);
6818
6818
  }
6819
6819
  function b(O) {
6820
- if (p) {
6821
- p(O);
6820
+ if (_) {
6821
+ _(O);
6822
6822
  return;
6823
6823
  }
6824
- const { from: C, item: E, oldIndex: B, newIndex: R } = O;
6825
- if (Zt(E), Uo(C, E, B), vt(l)) {
6826
- const x = [...N(l)];
6827
- l.value = Po(x, B, R);
6824
+ const { from: C, item: R, oldIndex: K, newIndex: B } = O;
6825
+ if (Zt(R), Uo(C, R, K), vt(l)) {
6826
+ const E = [...N(l)];
6827
+ l.value = Po(E, K, B);
6828
6828
  return;
6829
6829
  }
6830
- Po(N(l), B, R);
6830
+ Po(N(l), K, B);
6831
6831
  }
6832
- function H(O) {
6833
- const { newIndex: C, oldIndex: E, from: B, to: R } = O;
6834
- let x = null;
6835
- const G = C === E && B === R;
6832
+ function X(O) {
6833
+ const { newIndex: C, oldIndex: R, from: K, to: B } = O;
6834
+ let E = null;
6835
+ const M = C === R && K === B;
6836
6836
  try {
6837
- if (G) {
6838
- let X = null;
6839
- i == null || i.some((fe, Se) => {
6840
- if (X && (i == null ? void 0 : i.length) !== R.childNodes.length)
6841
- return B.insertBefore(X, fe.nextSibling), !0;
6842
- const Wt = R.childNodes[Se];
6843
- X = R == null ? void 0 : R.replaceChild(fe, Wt);
6837
+ if (M) {
6838
+ let P = null;
6839
+ i == null || i.some((z, ve) => {
6840
+ if (P && (i == null ? void 0 : i.length) !== B.childNodes.length)
6841
+ return K.insertBefore(P, z.nextSibling), !0;
6842
+ const Wt = B.childNodes[ve];
6843
+ P = B == null ? void 0 : B.replaceChild(z, Wt);
6844
6844
  });
6845
6845
  }
6846
- } catch (X) {
6847
- x = X;
6846
+ } catch (P) {
6847
+ E = P;
6848
6848
  } finally {
6849
6849
  i = null;
6850
6850
  }
6851
6851
  go(() => {
6852
- if (zo(), x)
6853
- throw x;
6852
+ if (zo(), E)
6853
+ throw E;
6854
6854
  });
6855
6855
  }
6856
6856
  const S = {
6857
6857
  onUpdate: b,
6858
- onStart: T,
6858
+ onStart: g,
6859
6859
  onAdd: h,
6860
6860
  onRemove: A,
6861
- onEnd: H
6861
+ onEnd: X
6862
6862
  };
6863
- function Q(O) {
6863
+ function Z(O) {
6864
6864
  const C = N(r);
6865
6865
  return O || (O = Sr(C) ? Br(C, n == null ? void 0 : n.$el) : C), O && !Dr(O) && (O = O.$el), O || Ar("Root element not found"), O;
6866
6866
  }
6867
- function w() {
6867
+ function V() {
6868
6868
  var O;
6869
- const C = (O = N(s)) != null ? O : {}, E = hn(C, ["immediate", "clone"]);
6870
- return Yo(E, (B, R) => {
6871
- xr(B) && (E[B] = (x, ...G) => {
6872
- const X = pl();
6873
- return Pr(x, X), R(x, ...G);
6869
+ const C = (O = N(s)) != null ? O : {}, R = hn(C, ["immediate", "clone"]);
6870
+ return Yo(R, (K, B) => {
6871
+ xr(K) && (R[K] = (E, ...M) => {
6872
+ const P = pl();
6873
+ return Pr(E, P), B(E, ...M);
6874
6874
  });
6875
6875
  }), Mr(
6876
6876
  l === null ? {} : S,
6877
- E
6877
+ R
6878
6878
  );
6879
6879
  }
6880
- const re = (O) => {
6881
- O = Q(O), u && U.destroy(), u = new y(O, w());
6880
+ const se = (O) => {
6881
+ O = Z(O), u && U.destroy(), u = new y(O, V());
6882
6882
  };
6883
- Ge(
6883
+ De(
6884
6884
  () => s,
6885
6885
  () => {
6886
- u && Yo(w(), (O, C) => {
6886
+ u && Yo(V(), (O, C) => {
6887
6887
  u == null || u.option(O, C);
6888
6888
  });
6889
6889
  },
@@ -6897,10 +6897,10 @@ function dl(...e) {
6897
6897
  save: () => u == null ? void 0 : u.save(),
6898
6898
  toArray: () => u == null ? void 0 : u.toArray(),
6899
6899
  closest: (...O) => u == null ? void 0 : u.closest(...O)
6900
- }, le = () => U == null ? void 0 : U.option("disabled", !0), Ee = () => U == null ? void 0 : U.option("disabled", !1);
6900
+ }, ce = () => U == null ? void 0 : U.option("disabled", !0), te = () => U == null ? void 0 : U.option("disabled", !1);
6901
6901
  return _l(() => {
6902
- _ && re();
6903
- }), ul(U.destroy), $e({ start: re, pause: le, resume: Ee }, U);
6902
+ p && se();
6903
+ }), ul(U.destroy), je({ start: se, pause: ce, resume: te }, U);
6904
6904
  }
6905
6905
  const To = [
6906
6906
  "update",
@@ -6960,7 +6960,7 @@ const To = [
6960
6960
  "target",
6961
6961
  "customUpdate",
6962
6962
  ...To.map((e) => `on${e.replace(/^\S/, (o) => o.toUpperCase())}`)
6963
- ], hl = Ve({
6963
+ ], hl = Ue({
6964
6964
  name: "VueDraggable",
6965
6965
  model: {
6966
6966
  prop: "modelValue",
@@ -6969,27 +6969,27 @@ const To = [
6969
6969
  props: fl,
6970
6970
  emits: ["update:modelValue", ...To],
6971
6971
  setup(e, { slots: o, emit: t, expose: n, attrs: i }) {
6972
- const r = To.reduce((d, p) => {
6973
- const T = `on${p.replace(/^\S/, (h) => h.toUpperCase())}`;
6974
- return d[T] = (...h) => t(p, ...h), d;
6975
- }, {}), l = ue(() => {
6976
- const d = Un(e), p = hn(d, ["modelValue"]), T = Object.entries(p).reduce((h, [A, b]) => {
6977
- const H = N(b);
6978
- return H !== void 0 && (h[A] = H), h;
6972
+ const r = To.reduce((d, _) => {
6973
+ const g = `on${_.replace(/^\S/, (h) => h.toUpperCase())}`;
6974
+ return d[g] = (...h) => t(_, ...h), d;
6975
+ }, {}), l = ae(() => {
6976
+ const d = Un(e), _ = hn(d, ["modelValue"]), g = Object.entries(_).reduce((h, [A, b]) => {
6977
+ const X = N(b);
6978
+ return X !== void 0 && (h[A] = X), h;
6979
6979
  }, {});
6980
- return $e($e({}, r), kr($e($e({}, i), T)));
6981
- }), s = ue({
6980
+ return je(je({}, r), kr(je(je({}, i), g)));
6981
+ }), s = ae({
6982
6982
  get: () => e.modelValue,
6983
6983
  set: (d) => t("update:modelValue", d)
6984
- }), u = Pe(), _ = Yn(
6984
+ }), u = we(), p = Yn(
6985
6985
  dl(e.target || u, s, l)
6986
6986
  );
6987
- return n(_), () => {
6987
+ return n(p), () => {
6988
6988
  var d;
6989
- return Kn(e.tag || "div", { ref: u }, (d = o == null ? void 0 : o.default) == null ? void 0 : d.call(o, _));
6989
+ return Kn(e.tag || "div", { ref: u }, (d = o == null ? void 0 : o.default) == null ? void 0 : d.call(o, p));
6990
6990
  };
6991
6991
  }
6992
- }), Tl = { class: "text-subtitle-1 ml-6" }, ml = /* @__PURE__ */ Ve({
6992
+ }), Tl = { class: "text-subtitle-1 ml-6" }, ml = /* @__PURE__ */ Ue({
6993
6993
  __name: "item",
6994
6994
  props: {
6995
6995
  id: {},
@@ -6998,13 +6998,13 @@ const To = [
6998
6998
  },
6999
6999
  emits: ["x-click"],
7000
7000
  setup(e, { emit: o }) {
7001
- const { primaryColor: t, backgroundColor2: n, highlightColor: i } = nn(), r = e, l = o, s = Pe(!1), u = ue(() => ({
7001
+ const { primaryColor: t, backgroundColor2: n, highlightColor: i } = nn(), r = e, l = o, s = we(!1), u = ae(() => ({
7002
7002
  position: "relative",
7003
7003
  background: s.value ? i.value : n.value,
7004
7004
  height: "48px",
7005
7005
  marginBottom: "1px",
7006
7006
  userSelect: "none"
7007
- })), _ = ue(() => ({
7007
+ })), p = ae(() => ({
7008
7008
  display: r.select ? "block" : "none",
7009
7009
  position: "absolute",
7010
7010
  top: "0px",
@@ -7014,25 +7014,25 @@ const To = [
7014
7014
  border: "1px solid " + t.value,
7015
7015
  pointerEvents: "none"
7016
7016
  }));
7017
- return (d, p) => {
7018
- const T = oe("v-spacer"), h = oe("v-icon"), A = Hn("ripple");
7019
- return Gn((J(), ke("div", {
7017
+ return (d, _) => {
7018
+ const g = ie("v-spacer"), h = ie("v-icon"), A = Hn("ripple");
7019
+ return Gn((j(), be("div", {
7020
7020
  class: "d-flex align-center cursor-pointer",
7021
- style: Ne(u.value),
7022
- onClick: p[1] || (p[1] = (b) => l("x-click", r.id)),
7023
- onMouseover: p[2] || (p[2] = (b) => s.value = !0),
7024
- onMouseout: p[3] || (p[3] = (b) => s.value = !1)
7021
+ style: Oe(u.value),
7022
+ onClick: _[1] || (_[1] = (b) => l("x-click", r.id)),
7023
+ onMouseover: _[2] || (_[2] = (b) => s.value = !0),
7024
+ onMouseout: _[3] || (_[3] = (b) => s.value = !1)
7025
7025
  }, [
7026
- ve("span", Tl, Eo(r.title), 1),
7027
- ne(T),
7028
- ne(h, {
7026
+ ye("span", Tl, Eo(r.title), 1),
7027
+ re(g),
7028
+ re(h, {
7029
7029
  class: "x-handle cursor-move mr-3",
7030
7030
  icon: N(pi),
7031
- onMousedown: p[0] || (p[0] = yt(() => {
7031
+ onMousedown: _[0] || (_[0] = yt(() => {
7032
7032
  }, ["stop"]))
7033
7033
  }, null, 8, ["icon"]),
7034
- ve("div", {
7035
- style: Ne(_.value)
7034
+ ye("div", {
7035
+ style: Oe(p.value)
7036
7036
  }, null, 4)
7037
7037
  ], 36)), [
7038
7038
  [A]
@@ -7042,27 +7042,27 @@ const To = [
7042
7042
  }), gl = {
7043
7043
  key: 1,
7044
7044
  class: "text-caption text-grey"
7045
- }, El = /* @__PURE__ */ Ve({
7045
+ }, El = /* @__PURE__ */ Ue({
7046
7046
  __name: "index",
7047
7047
  setup(e) {
7048
- const { t: o } = Ut(), t = Pe([]), n = () => {
7049
- const _ = we();
7050
- if (!_) {
7048
+ const { t: o } = Ut(), t = we([]), n = () => {
7049
+ const p = Ve();
7050
+ if (!p) {
7051
7051
  console.assert(!1);
7052
7052
  return;
7053
7053
  }
7054
7054
  const d = [];
7055
- _.getTopBlocks(!0).forEach((T) => {
7055
+ p.getTopBlocks(!0).forEach((g) => {
7056
7056
  var A;
7057
- const h = T.id === ((A = Fe()) == null ? void 0 : A.id);
7058
- if (T.type.startsWith("on_node_event_v"))
7057
+ const h = g.id === ((A = He()) == null ? void 0 : A.id);
7058
+ if (g.type.startsWith("on_node_event_v"))
7059
7059
  console.log("1");
7060
- else if (T.type.startsWith("procedure_def_v"))
7060
+ else if (g.type.startsWith("procedure_def_v"))
7061
7061
  console.log("2");
7062
7062
  else {
7063
- const b = T.getRelativeToSurfaceXY();
7063
+ const b = g.getRelativeToSurfaceXY();
7064
7064
  d.push({
7065
- id: T.id,
7065
+ id: g.id,
7066
7066
  name: o("x-block-lib.temporaryBlock"),
7067
7067
  x: b.x,
7068
7068
  y: b.y,
@@ -7071,70 +7071,70 @@ const To = [
7071
7071
  }
7072
7072
  }), t.value = d;
7073
7073
  };
7074
- ze(() => {
7075
- Te.on("codeUpdate", n);
7074
+ qe(() => {
7075
+ me.on("codeUpdate", n);
7076
7076
  }), Nt(() => {
7077
- Te.off("codeUpdate", n);
7077
+ me.off("codeUpdate", n);
7078
7078
  });
7079
7079
  let i = [];
7080
7080
  const r = () => {
7081
- const _ = [];
7081
+ const p = [];
7082
7082
  t.value.forEach(({ id: d }) => {
7083
- _.push(d);
7084
- }), i = _;
7085
- }, l = (_) => {
7086
- const d = we();
7083
+ p.push(d);
7084
+ }), i = p;
7085
+ }, l = (p) => {
7086
+ const d = Ve();
7087
7087
  if (!d) {
7088
7088
  console.assert(!1);
7089
7089
  return;
7090
7090
  }
7091
- if (_.oldIndex === void 0 || _.newIndex === void 0) {
7091
+ if (p.oldIndex === void 0 || p.newIndex === void 0) {
7092
7092
  console.assert(!1);
7093
7093
  return;
7094
7094
  }
7095
- if (_.oldIndex === _.newIndex)
7095
+ if (p.oldIndex === p.newIndex)
7096
7096
  return;
7097
- const p = i[_.oldIndex], T = d.getBlockById(p);
7098
- if (!T) {
7097
+ const _ = i[p.oldIndex], g = d.getBlockById(_);
7098
+ if (!g) {
7099
7099
  console.assert(!1);
7100
7100
  return;
7101
7101
  }
7102
7102
  let h = "";
7103
- _.newIndex > _.oldIndex ? h = i[_.newIndex] : _.newIndex > 0 && (h = i[_.newIndex - 1]);
7103
+ p.newIndex > p.oldIndex ? h = i[p.newIndex] : p.newIndex > 0 && (h = i[p.newIndex - 1]);
7104
7104
  let A = -10;
7105
7105
  h !== "" && (A = d.getBlockById(h).getRelativeToSurfaceXY().y + 10);
7106
- const b = T.getRelativeToSurfaceXY();
7107
- T.moveTo(new m.Coordinate(b.x, A)), Te.emit("cleanWorkspace"), cn();
7108
- }, { open: s } = bo("blocklyNavigatorDlg"), u = async (_) => {
7109
- const d = we();
7106
+ const b = g.getRelativeToSurfaceXY();
7107
+ g.moveTo(new T.Coordinate(b.x, A)), me.emit("cleanWorkspace"), cn();
7108
+ }, { open: s } = bo("blocklyNavigatorDlg"), u = async (p) => {
7109
+ const d = Ve();
7110
7110
  if (!d) {
7111
7111
  console.assert(!1);
7112
7112
  return;
7113
7113
  }
7114
- const p = d.getBlockById(_);
7115
- ei.setSelected(p), sn(_), s.value = !1;
7114
+ const _ = d.getBlockById(p);
7115
+ ei.setSelected(_), sn(p), s.value = !1;
7116
7116
  };
7117
- return (_, d) => t.value.length > 0 ? (J(), Le(N(hl), {
7117
+ return (p, d) => t.value.length > 0 ? (j(), Se(N(hl), {
7118
7118
  key: 0,
7119
7119
  modelValue: t.value,
7120
- "onUpdate:modelValue": d[0] || (d[0] = (p) => t.value = p),
7120
+ "onUpdate:modelValue": d[0] || (d[0] = (_) => t.value = _),
7121
7121
  animation: 150,
7122
7122
  "ghost-class": "ghost",
7123
7123
  handle: ".x-handle",
7124
7124
  onStart: r,
7125
7125
  onEnd: l
7126
7126
  }, {
7127
- default: We(() => [
7128
- (J(!0), ke(Zo, null, Xn(t.value, (p) => (J(), Le(ml, {
7129
- id: p.id,
7130
- key: p.id,
7131
- title: p.name,
7132
- select: p.select,
7127
+ default: Je(() => [
7128
+ (j(!0), be(Zo, null, Xn(t.value, (_) => (j(), Se(ml, {
7129
+ id: _.id,
7130
+ key: _.id,
7131
+ title: _.name,
7132
+ select: _.select,
7133
7133
  onXClick: u
7134
7134
  }, null, 8, ["id", "title", "select"]))), 128))
7135
7135
  ]),
7136
7136
  _: 1
7137
- }, 8, ["modelValue"])) : (J(), ke("span", gl, Eo(N(o)("x-block-lib.noOption")), 1));
7137
+ }, 8, ["modelValue"])) : (j(), be("span", gl, Eo(N(o)("x-block-lib.noOption")), 1));
7138
7138
  }
7139
7139
  }), Mn = (e, o) => {
7140
7140
  const t = e.__vccOpts || e;
@@ -7143,80 +7143,80 @@ const To = [
7143
7143
  return t;
7144
7144
  }, vl = /* @__PURE__ */ Mn(El, [["__scopeId", "data-v-91f61557"]]), yl = {};
7145
7145
  function bl(e, o) {
7146
- return J(), ke("div", null, "blockTree");
7146
+ return j(), be("div", null, "blockTree");
7147
7147
  }
7148
- const Ol = /* @__PURE__ */ Mn(yl, [["render", bl]]), Il = { class: "text-subtitle-1 ml-3" }, Cl = /* @__PURE__ */ Ve({
7148
+ const Ol = /* @__PURE__ */ Mn(yl, [["render", bl]]), Il = { class: "text-subtitle-1 ml-3" }, Cl = /* @__PURE__ */ Ue({
7149
7149
  __name: "index",
7150
7150
  props: {
7151
7151
  type: {}
7152
7152
  },
7153
7153
  setup(e) {
7154
- const { t: o } = Ut(), t = si(), { sysBarAvail: n } = li(), { backgroundColor1: i } = nn(), r = e, l = ue(() => {
7154
+ const { t: o } = Ut(), t = si(), { sysBarAvail: n } = li(), { backgroundColor1: i } = nn(), r = e, l = ae(() => {
7155
7155
  let d = "100%";
7156
7156
  return t.mdAndUp.value && (d = "400px"), {
7157
7157
  background: i.value,
7158
7158
  width: d,
7159
7159
  height: "100%"
7160
7160
  };
7161
- }), s = ue(() => {
7161
+ }), s = ae(() => {
7162
7162
  let d = 48;
7163
7163
  return n.value && (d += 24), {
7164
7164
  position: "relative",
7165
7165
  width: "100%",
7166
7166
  height: `calc(100% - ${d}px)`
7167
7167
  };
7168
- }), u = ue(() => ({
7168
+ }), u = ae(() => ({
7169
7169
  height: "60px"
7170
- })), { open: _ } = bo("blocklyNavigatorDlg");
7171
- return (d, p) => {
7172
- const T = oe("v-sheet"), h = oe("v-icon"), A = oe("v-dialog"), b = oe("v-btn"), H = oe("v-tooltip");
7173
- return J(), ke(Zo, null, [
7174
- ne(A, {
7175
- modelValue: N(_),
7176
- "onUpdate:modelValue": p[3] || (p[3] = (S) => vt(_) ? _.value = S : null),
7170
+ })), { open: p } = bo("blocklyNavigatorDlg");
7171
+ return (d, _) => {
7172
+ const g = ie("v-sheet"), h = ie("v-icon"), A = ie("v-dialog"), b = ie("v-btn"), X = ie("v-tooltip");
7173
+ return j(), be(Zo, null, [
7174
+ re(A, {
7175
+ modelValue: N(p),
7176
+ "onUpdate:modelValue": _[3] || (_[3] = (S) => vt(p) ? p.value = S : null),
7177
7177
  transition: "scroll-x-reverse-transition",
7178
7178
  persistent: "",
7179
7179
  "no-click-animation": "",
7180
7180
  fullscreen: "",
7181
7181
  eager: "",
7182
- onKeydown: p[4] || (p[4] = $n(yt((S) => _.value = !1, ["stop", "prevent"]), ["esc"]))
7182
+ onKeydown: _[4] || (_[4] = $n(yt((S) => p.value = !1, ["stop", "prevent"]), ["esc"]))
7183
7183
  }, {
7184
- default: We(() => [
7185
- ve("div", {
7184
+ default: Je(() => [
7185
+ ye("div", {
7186
7186
  class: "w-100 h-100 d-flex flex-row-reverse",
7187
- onClick: p[1] || (p[1] = yt((S) => _.value = !1, ["self"])),
7188
- onContextmenu: p[2] || (p[2] = yt((S) => _.value = !1, ["self", "prevent"]))
7187
+ onClick: _[1] || (_[1] = yt((S) => p.value = !1, ["self"])),
7188
+ onContextmenu: _[2] || (_[2] = yt((S) => p.value = !1, ["self", "prevent"]))
7189
7189
  }, [
7190
- ve("div", {
7190
+ ye("div", {
7191
7191
  class: "elevation-2",
7192
- style: Ne(l.value)
7192
+ style: Oe(l.value)
7193
7193
  }, [
7194
- N(n) ? (J(), Le(T, {
7194
+ N(n) ? (j(), Se(g, {
7195
7195
  key: 0,
7196
7196
  color: "transparent",
7197
7197
  height: 24
7198
- })) : nt("", !0),
7199
- ne(T, {
7198
+ })) : Xe("", !0),
7199
+ re(g, {
7200
7200
  class: "d-flex align-center px-3",
7201
7201
  color: "transparent",
7202
7202
  height: 48
7203
7203
  }, {
7204
- default: We(() => [
7205
- ne(h, {
7204
+ default: Je(() => [
7205
+ re(h, {
7206
7206
  icon: N(ui),
7207
- onClick: p[0] || (p[0] = (S) => _.value = !1)
7207
+ onClick: _[0] || (_[0] = (S) => p.value = !1)
7208
7208
  }, null, 8, ["icon"]),
7209
- ve("span", Il, Eo(N(o)("x-block-lib.navigator")), 1)
7209
+ ye("span", Il, Eo(N(o)("x-block-lib.navigator")), 1)
7210
7210
  ]),
7211
7211
  _: 1
7212
7212
  }),
7213
- ve("div", {
7213
+ ye("div", {
7214
7214
  class: "overflow-y-auto",
7215
- style: Ne(s.value)
7215
+ style: Oe(s.value)
7216
7216
  }, [
7217
- r.type === "list" ? (J(), Le(vl, { key: 0 })) : r.type === "tree" ? (J(), Le(Ol, { key: 1 })) : nt("", !0),
7218
- ve("div", {
7219
- style: Ne(u.value)
7217
+ r.type === "list" ? (j(), Se(vl, { key: 0 })) : r.type === "tree" ? (j(), Se(Ol, { key: 1 })) : Xe("", !0),
7218
+ ye("div", {
7219
+ style: Oe(u.value)
7220
7220
  }, null, 4)
7221
7221
  ], 4)
7222
7222
  ], 4)
@@ -7224,15 +7224,15 @@ const Ol = /* @__PURE__ */ Mn(yl, [["render", bl]]), Il = { class: "text-subtitl
7224
7224
  ]),
7225
7225
  _: 1
7226
7226
  }, 8, ["modelValue"]),
7227
- ne(H, {
7227
+ re(X, {
7228
7228
  text: N(o)("x-block-lib.tip.hotkeyCtrlE")
7229
7229
  }, {
7230
- activator: We(({ props: S }) => [
7231
- ne(b, mo(S, {
7230
+ activator: Je(({ props: S }) => [
7231
+ re(b, mo(S, {
7232
7232
  variant: "outlined",
7233
7233
  density: "comfortable",
7234
7234
  icon: N(hi),
7235
- onClick: p[5] || (p[5] = (Q) => _.value = !0)
7235
+ onClick: _[5] || (_[5] = (Z) => p.value = !0)
7236
7236
  }), null, 16, ["icon"])
7237
7237
  ]),
7238
7238
  _: 1
@@ -7268,29 +7268,29 @@ function Al(e, o, t) {
7268
7268
  o === "page" ? t === "v1" && (n = yr) : o === "comp" ? t === "v1" && (n = gr) : o === "func" ? t === "v1" && (n = vr) : o === "flow" && t === "v1" && (n = Er), console.assert(!!n), Qo.toolbox = n;
7269
7269
  const i = ti(e, Qo);
7270
7270
  return o === "page" || o === "comp" ? t === "v1" && (i.registerToolboxCategoryCallback(
7271
- Xe.name,
7272
- Xe.callback
7271
+ $e.name,
7272
+ $e.callback
7273
7273
  ), i.registerToolboxCategoryCallback(
7274
- se.name,
7275
- se.callback
7274
+ _e.name,
7275
+ _e.callback
7276
7276
  ), i.registerToolboxCategoryCallback(
7277
- ce.name,
7278
- ce.callback
7277
+ pe.name,
7278
+ pe.callback
7279
7279
  )) : o === "func" ? t === "v1" && (i.registerToolboxCategoryCallback(
7280
- se.name,
7281
- se.callback
7280
+ _e.name,
7281
+ _e.callback
7282
7282
  ), i.registerToolboxCategoryCallback(
7283
- ce.name,
7284
- ce.callback
7283
+ pe.name,
7284
+ pe.callback
7285
7285
  )) : o === "flow" && t === "v1" && (i.registerToolboxCategoryCallback(
7286
- se.name,
7287
- se.callback
7286
+ _e.name,
7287
+ _e.callback
7288
7288
  ), i.registerToolboxCategoryCallback(
7289
- ce.name,
7290
- ce.callback
7289
+ pe.name,
7290
+ pe.callback
7291
7291
  )), i;
7292
7292
  }
7293
- const Ll = { class: "position-relative w-100 h-100" }, kl = /* @__PURE__ */ Ve({
7293
+ const Ll = { class: "position-relative w-100 h-100" }, kl = /* @__PURE__ */ Ue({
7294
7294
  __name: "index",
7295
7295
  props: /* @__PURE__ */ Lo({
7296
7296
  type: {},
@@ -7303,9 +7303,9 @@ const Ll = { class: "position-relative w-100 h-100" }, kl = /* @__PURE__ */ Ve({
7303
7303
  }),
7304
7304
  emits: /* @__PURE__ */ Lo(["ready"], ["update:lock", "update:scale"]),
7305
7305
  setup(e, { expose: o, emit: t }) {
7306
- const n = ai(), { locale: i, dark: r } = ni(n), { open: l } = bo("blocklyEditorFlyout"), s = co(e, "lock"), u = co(e, "scale"), _ = e, d = t, p = Pe();
7307
- let T;
7308
- const h = Pe(!1), A = Pe(!1), b = ue(() => ({
7306
+ const n = ai(), { locale: i, dark: r } = ni(n), l = co(e, "lock"), s = co(e, "scale"), u = e, p = t, d = we();
7307
+ let _;
7308
+ const g = we(!1), h = we(!1), A = ae(() => ({
7309
7309
  position: "absolute",
7310
7310
  background: r.value ? "#0000007f" : "#ffffff7f",
7311
7311
  top: "1px",
@@ -7314,116 +7314,136 @@ const Ll = { class: "position-relative w-100 h-100" }, kl = /* @__PURE__ */ Ve({
7314
7314
  height: "calc(100% - 1px)",
7315
7315
  pointerEvents: "none",
7316
7316
  zIndex: 999
7317
- })), H = ue(() => ({
7317
+ })), b = ae(() => ({
7318
7318
  position: "absolute",
7319
7319
  background: r.value ? "#0000007f" : "#ffffff7f",
7320
- top: "0px",
7320
+ top: "1px",
7321
7321
  left: "0px",
7322
- width: "100%",
7323
- height: "100%",
7324
- pointerEvents: "none"
7325
- })), S = ue(() => ({
7322
+ width: "56px",
7323
+ height: "calc(100% - 1px)",
7324
+ zIndex: 999
7325
+ })), X = ae(() => ({
7326
7326
  position: "absolute",
7327
7327
  top: "0px",
7328
7328
  right: "0px",
7329
7329
  zIndex: 20
7330
- })), Q = (E) => {
7331
- h.value = !0, No.workspaces.load(E, T);
7332
- }, w = () => No.workspaces.save(T), re = () => a.workspaceToCode(T);
7333
- ze(async () => {
7334
- if (!p.value) {
7330
+ })), S = ae(() => ({
7331
+ position: "absolute",
7332
+ background: r.value ? "#0000007f" : "#ffffff7f",
7333
+ top: "0px",
7334
+ left: "0px",
7335
+ width: "100%",
7336
+ height: "100%",
7337
+ pointerEvents: "none"
7338
+ })), Z = (E) => {
7339
+ g.value = !0, No.workspaces.load(E, _);
7340
+ }, V = () => No.workspaces.save(_), se = () => a.workspaceToCode(_), U = () => {
7341
+ _.options.readOnly = l.value, _.options.readOnly && (te.value = !1);
7342
+ }, ce = () => {
7343
+ _.setScale(s.value);
7344
+ }, { open: te } = bo("blocklyEditorFlyout");
7345
+ qe(async () => {
7346
+ if (!d.value) {
7335
7347
  console.assert(!1);
7336
7348
  return;
7337
7349
  }
7338
- await Do(i.value), T = Al(p.value, _.type, _.version), T.addChangeListener(F.disableOrphans), T.addChangeListener(U), T.setScale(u.value), await go(), d("ready");
7350
+ await Do(i.value), _ = Al(d.value, u.type, u.version), _.addChangeListener(G.disableOrphans), _.addChangeListener(O);
7351
+ const E = document.querySelector("#blocklyEditor .blocklyFlyout");
7352
+ new MutationObserver((P) => {
7353
+ P.forEach((z) => {
7354
+ z.type === "attributes" && z.attributeName === "style" && (te.value = _.getFlyout().isVisible());
7355
+ });
7356
+ }).observe(E, { attributes: !0 }), te.value = _.getFlyout().isVisible(), U(), ce(), await go(), p("ready");
7339
7357
  }), Nt(() => {
7340
- l.value = !1;
7341
- }), bi(p, () => {
7342
- T && oi(T);
7358
+ te.value = !1;
7359
+ }), bi(d, () => {
7360
+ _ && oi(_);
7343
7361
  });
7344
- async function U(E) {
7345
- if (E.type === F.FINISHED_LOADING) {
7346
- cn(), Te.emit("codeUpdate"), h.value = !1;
7362
+ async function O(E) {
7363
+ if (E.type === G.FINISHED_LOADING) {
7364
+ cn(), me.emit("codeUpdate"), g.value = !1;
7347
7365
  return;
7348
7366
  }
7349
- h.value || (E.type === F.VIEWPORT_CHANGE && (u.value = T.getScale()), E.type === F.BLOCK_DRAG && (E.isStart ? A.value = !0 : A.value = !1), Te.emit("codeUpdate"));
7367
+ g.value || (E.type === G.VIEWPORT_CHANGE && (s.value = _.getScale()), E.type === G.BLOCK_DRAG && (E.isStart ? h.value = !0 : h.value = !1), me.emit("codeUpdate"));
7350
7368
  }
7351
- const le = (E) => {
7369
+ const C = (E) => {
7352
7370
  if (E.key === "q" && E.ctrlKey) {
7353
- Ee();
7371
+ R();
7354
7372
  return;
7355
7373
  }
7356
7374
  if (E.key === "w" && E.ctrlKey) {
7357
- O();
7375
+ K();
7358
7376
  return;
7359
7377
  }
7360
7378
  if (E.key === "e" && E.ctrlKey) {
7361
- C();
7379
+ B();
7362
7380
  return;
7363
7381
  }
7364
- }, Ee = () => {
7365
- Te.emit("cleanWorkspace");
7366
- }, O = () => {
7367
- s.value = !s.value;
7368
- }, C = () => {
7369
- Te.emit("blocklyNavigatorDlg");
7382
+ }, R = () => {
7383
+ me.emit("cleanWorkspace");
7384
+ }, K = () => {
7385
+ l.value = !l.value;
7386
+ }, B = () => {
7387
+ me.emit("blocklyNavigatorDlg");
7370
7388
  };
7371
- return ze(() => {
7372
- window.addEventListener("keydown", le, !1);
7389
+ return qe(() => {
7390
+ window.addEventListener("keydown", C, !1);
7373
7391
  }), Nt(() => {
7374
- window.addEventListener("keydown", le, !1);
7375
- }), Ge(i, (E) => {
7392
+ window.addEventListener("keydown", C, !1);
7393
+ }), De(i, (E) => {
7376
7394
  Do(E);
7377
- }), Ge(r, (E) => {
7395
+ }), De(r, (E) => {
7378
7396
  mr(E ? "dark" : "light");
7379
- }), Ge(l, (E) => {
7380
- var B;
7381
- E || (B = T.getToolbox()) == null || B.clearSelection();
7382
- }), Ge(
7383
- () => u.value,
7384
- (E) => {
7385
- T.setScale(E);
7386
- }
7387
- ), o({ loading: h, load: Q, save: w, generateCode: re }), (E, B) => {
7388
- const R = oe("v-icon"), x = oe("x-loading");
7389
- return J(), ke("div", Ll, [
7390
- ve("div", {
7397
+ }), De(te, (E) => {
7398
+ E || _.hideChaff();
7399
+ }), De(l, () => {
7400
+ U();
7401
+ }), De(s, () => {
7402
+ ce();
7403
+ }), o({ loading: g, load: Z, save: V, generateCode: se }), (E, M) => {
7404
+ const P = ie("v-icon"), z = ie("x-loading");
7405
+ return j(), be("div", Ll, [
7406
+ ye("div", {
7391
7407
  id: "blocklyEditor",
7392
7408
  ref_key: "blocklyDiv",
7393
- ref: p,
7409
+ ref: d,
7394
7410
  class: "w-100 h-100"
7395
7411
  }, null, 512),
7396
- A.value ? (J(), ke("div", {
7412
+ h.value ? (j(), be("div", {
7397
7413
  key: 0,
7398
7414
  class: "d-flex flex-column align-center justify-center",
7399
- style: Ne(b.value)
7415
+ style: Oe(A.value)
7400
7416
  }, [
7401
- ne(R, {
7417
+ re(P, {
7402
7418
  icon: N(_i),
7403
7419
  size: "x-large"
7404
7420
  }, null, 8, ["icon"])
7405
- ], 4)) : nt("", !0),
7406
- s.value ? (J(), ke("div", {
7421
+ ], 4)) : Xe("", !0),
7422
+ l.value ? (j(), be("div", {
7407
7423
  key: 1,
7408
- style: Ne(H.value)
7409
- }, null, 4)) : nt("", !0),
7410
- ve("div", {
7424
+ style: Oe(b.value)
7425
+ }, null, 4)) : Xe("", !0),
7426
+ ye("div", {
7411
7427
  class: "d-flex align-end pt-3 pr-3",
7412
- style: Ne(S.value)
7428
+ style: Oe(X.value)
7413
7429
  }, [
7414
- ne(br),
7415
- ne(Or, {
7416
- modelValue: s.value,
7417
- "onUpdate:modelValue": B[0] || (B[0] = (G) => s.value = G)
7430
+ re(br),
7431
+ re(Or, {
7432
+ modelValue: l.value,
7433
+ "onUpdate:modelValue": M[0] || (M[0] = (ve) => l.value = ve)
7418
7434
  }, null, 8, ["modelValue"]),
7419
- ne(Cl, {
7435
+ re(Cl, {
7420
7436
  type: E.type === "json" ? "tree" : "list"
7421
7437
  }, null, 8, ["type"])
7422
7438
  ], 4),
7423
- h.value ? (J(), Le(x, {
7439
+ l.value ? (j(), be("div", {
7424
7440
  key: 2,
7441
+ style: Oe(S.value)
7442
+ }, null, 4)) : Xe("", !0),
7443
+ g.value ? (j(), Se(z, {
7444
+ key: 3,
7425
7445
  "z-index": 99
7426
- })) : nt("", !0)
7446
+ })) : Xe("", !0)
7427
7447
  ]);
7428
7448
  };
7429
7449
  }