ss-component-new 1.2.22 → 1.2.23

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 (136) hide show
  1. package/dist/{MTLLoader-Cgu6hVsY.cjs → MTLLoader-B8MnfNfT.cjs} +1 -1
  2. package/dist/{MTLLoader-6BGR4SPQ.js → MTLLoader-BD3cbBAW.js} +1 -1
  3. package/dist/{OrbitControls-KuEu6kM3.cjs → OrbitControls-2UHRU9Fu.cjs} +1 -1
  4. package/dist/{OrbitControls-CqrkpfUW.js → OrbitControls-D1pz0uFI.js} +1 -1
  5. package/dist/{animationData-FMGneVai.cjs → animationData-Bwh55Xw6.cjs} +1 -1
  6. package/dist/{animationData-OlBnUG8w.js → animationData-D0TJ-9dd.js} +4 -4
  7. package/dist/array-DMPAgNcb.cjs +11 -0
  8. package/dist/array-DTXrs6ZK.js +1207 -0
  9. package/dist/{dataUtil-DPRubJA4.js → dataUtil-gEKo7CEq.js} +2 -2
  10. package/dist/{dataUtil-D2dUTgHP.cjs → dataUtil-i5X2xhin.cjs} +1 -1
  11. package/dist/{fileUtil-D4f4EJ9p.js → fileUtil-CN00xr9W.js} +1 -1
  12. package/dist/{fileUtil-DWuPXxGz.cjs → fileUtil-GIRXMs25.cjs} +1 -1
  13. package/dist/{iconfont-CiYOe1nN.cjs → iconfont-C9-pGpAJ.cjs} +1 -1
  14. package/dist/{iconfont-D1aDkauN.js → iconfont-DTSZW2AU.js} +2 -2
  15. package/dist/icons/svg/LowCodeEvent.svg +1 -1
  16. package/dist/icons/svg/LowCodeExtend.svg +1 -1
  17. package/dist/icons/svg/LowCodeSetting.svg +1 -1
  18. package/dist/icons/svg/LowCodeStyle.svg +1 -1
  19. package/dist/{index-Dv32OdnH.js → index-2fqHNrPg.js} +4 -4
  20. package/dist/{index-CfrqPhLf.cjs → index-7Ru3e632.cjs} +1 -1
  21. package/dist/{index-DyA4ALuY.cjs → index-7gU0r1We.cjs} +1 -1
  22. package/dist/{index-Cgs7cequ.js → index-7oJ8Ile4.js} +1 -1
  23. package/dist/{index-C9o3guTc.js → index-B0dydZDW.js} +17 -17
  24. package/dist/{index-CIn_YMID.js → index-BD5yZDAq.js} +2 -2
  25. package/dist/index-BLwwxnzs.cjs +1 -0
  26. package/dist/{index-BQ1gqL2T.cjs → index-BNYeBPmi.cjs} +1 -1
  27. package/dist/{index-DEBf-IBT.cjs → index-BOJUyAaV.cjs} +9 -9
  28. package/dist/{index-BsXwkKZt.js → index-BQBxzTyE.js} +2 -2
  29. package/dist/{index-CJhLlcnS.js → index-BTTpV9o2.js} +3 -3
  30. package/dist/{index-CdNhl58g.cjs → index-BTfg83yY.cjs} +1 -1
  31. package/dist/{index-CkdrE77c.js → index-BVFL7Z_0.js} +3 -3
  32. package/dist/index-BVdolwlx.js +7293 -0
  33. package/dist/{index-D_zs3Ywk.cjs → index-BXEOQo2c.cjs} +1 -1
  34. package/dist/{index-C0eoTBsi.js → index-Be1LJMUR.js} +2 -2
  35. package/dist/{index-y9I5saNf.cjs → index-BkIFY0hK.cjs} +1 -1
  36. package/dist/{index-BvyKSIqa.js → index-Bm3FE_ss.js} +3 -3
  37. package/dist/{index-i1HrhN2m.js → index-BpTrDbkf.js} +4 -4
  38. package/dist/{index-DcgnW8IS.js → index-Bt2MaT2G.js} +6 -6
  39. package/dist/{index-BOwTBtjA.js → index-BuSsSHAY.js} +2733 -2817
  40. package/dist/{index-Vo9hn1HO.js → index-Bvk4OpkL.js} +2 -2
  41. package/dist/{index-Br1HQap-.js → index-BwEfrokO.js} +2 -2
  42. package/dist/{index-dJ_vyooa.cjs → index-C54wX50t.cjs} +1 -1
  43. package/dist/{index-CMSMrWWB.cjs → index-C6C5VWbs.cjs} +1 -1
  44. package/dist/{index-wFocLxVz.cjs → index-CADH_aSQ.cjs} +1 -1
  45. package/dist/{index-GVURdQmb.cjs → index-CFriKZ-T.cjs} +1 -1
  46. package/dist/index-CK54pscx.cjs +1 -0
  47. package/dist/{index-DdYGa8y9.js → index-Cl6HMOao.js} +1 -1
  48. package/dist/{index-C1xFocJD.js → index-CptCatmL.js} +2 -2
  49. package/dist/{index-BdEr19ln.js → index-CqYUVCh5.js} +12 -12
  50. package/dist/index-CsOz5vsv.cjs +1 -0
  51. package/dist/{index-kFjfkR4F.cjs → index-CtXpoEg0.cjs} +1 -1
  52. package/dist/{index-Dw_mx2E5.js → index-CvC2498b.js} +2 -2
  53. package/dist/{index-DN2RDo7w.js → index-CvrBt7bU.js} +3 -3
  54. package/dist/{index-B0mK1X2Z.js → index-D4pN9YmB.js} +2 -2
  55. package/dist/index-D8Y3imz9.cjs +1 -0
  56. package/dist/index-DEEZPcpU.cjs +1 -0
  57. package/dist/index-DEs8s152.js +3621 -0
  58. package/dist/{index-DV1Onr_-.cjs → index-DHp714Ep.cjs} +1 -1
  59. package/dist/index-DMbCaqEC.cjs +15 -0
  60. package/dist/{index-C7Wgog15.js → index-DNs9XPOG.js} +2 -2
  61. package/dist/{index-B3vewIE0.js → index-DOhvzke2.js} +5 -5
  62. package/dist/index-DPX3w6cO.js +2643 -0
  63. package/dist/{index-D6aL_qQ4.cjs → index-DQ3y1xkr.cjs} +1 -1
  64. package/dist/{index-Gqf0Dw_K.cjs → index-DR9beXhk.cjs} +1 -1
  65. package/dist/{index-C8YYklCT.cjs → index-DSchKIyh.cjs} +1 -1
  66. package/dist/{index-vIQwCbI-.cjs → index-DSlPg3dk.cjs} +1 -1
  67. package/dist/{index-CYvWTBiC.cjs → index-DbCNaQ87.cjs} +1 -1
  68. package/dist/{index-B1KcMjms.cjs → index-Dfwm0xPp.cjs} +1 -1
  69. package/dist/index-DiRBJiMW.js +43 -0
  70. package/dist/{index-BuQNI1CB.js → index-DlIkbsRf.js} +6 -6
  71. package/dist/{index-B__9hFoC.cjs → index-DllJulGH.cjs} +1 -1
  72. package/dist/{index-BJadEVee.js → index-Dm_WlV6R.js} +5542 -5543
  73. package/dist/{index-D4nuGSp1.cjs → index-Do8zI4DM.cjs} +1 -1
  74. package/dist/{index-7w9QLGZ8.cjs → index-DrWIUUZK.cjs} +1 -1
  75. package/dist/index-G_cKl_J4.js +2379 -0
  76. package/dist/{index-CkJaR30x.js → index-NlkdTb--.js} +4 -4
  77. package/dist/{index-CuYt_7-p.js → index-ThNNBX7h.js} +1 -1
  78. package/dist/{index-DzuOO-jn.js → index-XXKsLOYd.js} +2 -2
  79. package/dist/{index-_7Qm6usF.cjs → index-dwX_BHyo.cjs} +1 -1
  80. package/dist/{index-D-ygp57X.cjs → index-eH9RMVXv.cjs} +1 -1
  81. package/dist/index-pmcRbjPd.cjs +1 -0
  82. package/dist/{index-B5KCSN4c.cjs → index-tttYIzsn.cjs} +1 -1
  83. package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-Bhj73Dii.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CtycIAIT.js} +2 -2
  84. package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-DAjyk3_9.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-D6X3fCNs.cjs} +1 -1
  85. package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-DbaX17jD.js → index.vue_vue_type_style_index_0_scoped_92477073_lang-De0avjy5.js} +6 -6
  86. package/dist/{index.vue_vue_type_style_index_0_scoped_92477073_lang-B0Slk6gv.cjs → index.vue_vue_type_style_index_0_scoped_92477073_lang-DhMDLOg8.cjs} +1 -1
  87. package/dist/{index.vue_vue_type_style_index_0_scoped_980cb04a_lang-BmYxcD8z.js → index.vue_vue_type_style_index_0_scoped_bcdf4fb0_lang-CEcxaThh.js} +13 -13
  88. package/dist/{index.vue_vue_type_style_index_0_scoped_980cb04a_lang-DGpKXuuO.cjs → index.vue_vue_type_style_index_0_scoped_bcdf4fb0_lang-DLuOs1IZ.cjs} +1 -1
  89. package/dist/{index.vue_vue_type_style_index_1_lang-8MlG6f_5.js → index.vue_vue_type_style_index_1_lang-B0l6QIWy.js} +531 -536
  90. package/dist/{index.vue_vue_type_style_index_1_lang-BMAOkg3Y.cjs → index.vue_vue_type_style_index_1_lang-CC1o5rIu.cjs} +8 -8
  91. package/dist/{index.vue_vue_type_style_index_1_lang-C5-R1ghT.cjs → index.vue_vue_type_style_index_1_lang-Chzrrthw.cjs} +1 -1
  92. package/dist/{index.vue_vue_type_style_index_1_lang-QVwLsuO7.js → index.vue_vue_type_style_index_1_lang-DzZEPkuk.js} +5 -5
  93. package/dist/{isString-D6Z6SOrb.cjs → isString-CELwppr9.cjs} +1 -1
  94. package/dist/{isString-DOZgMp8l.js → isString-DvY0kl3S.js} +1 -1
  95. package/dist/{main-BCD-Orm3.js → main-DQXqHTYg.js} +5 -5
  96. package/dist/{main-DUUTokjq.cjs → main-yiUkyrA7.cjs} +1 -1
  97. package/dist/ss-component.cjs +1 -1
  98. package/dist/ss-component.css +2 -2
  99. package/dist/ss-component.js +12 -12
  100. package/dist/ss-component2.cjs +1 -1
  101. package/dist/ss-component2.js +12 -12
  102. package/dist/{threeModel-DWfIRtBe.js → threeModel-BiWZCOOI.js} +5 -5
  103. package/dist/{threeModel-D-cNRyXR.cjs → threeModel-Cva5i9Dy.cjs} +1 -1
  104. package/dist/{threePreview-CB4s2usq.cjs → threePreview-BNvDY6xx.cjs} +1 -1
  105. package/dist/{threePreview-BelyhkDx.js → threePreview-CjFKHY3_.js} +4 -4
  106. package/dist/{threeSceneView-9pPPVjCA.cjs → threeSceneView-DM8uof_D.cjs} +1 -1
  107. package/dist/{threeSceneView-C66YfUi3.js → threeSceneView-DPTQ_xR-.js} +11 -11
  108. package/dist/{threeSceneViewForCPMPIP-WBguXbnU.js → threeSceneViewForCPMPIP-Bqb44i-c.js} +50 -50
  109. package/dist/{threeSceneViewForCPMPIP-DLVSylJ7.cjs → threeSceneViewForCPMPIP-D5jl1r-h.cjs} +1 -1
  110. package/dist/{threeTrackPathView-DxO-9BKu.js → threeTrackPathView-BvxoafSz.js} +6 -6
  111. package/dist/{threeTrackPathView-C4c7FI2n.cjs → threeTrackPathView-DgnuPrBe.cjs} +1 -1
  112. package/dist/{threeViewerHost-CNs819Rf.js → threeViewerHost-CKmZPGir.js} +4 -4
  113. package/dist/{threeViewerHost-Ihdu1cjR.cjs → threeViewerHost-D80V4Cfh.cjs} +1 -1
  114. package/dist/{urdfTree-CLhAUUAD.js → urdfTree-BxuavyNQ.js} +1 -1
  115. package/dist/{urdfTree-Di3A1LA8.cjs → urdfTree-wR2vnG4s.cjs} +1 -1
  116. package/dist/{workpieceTreePanel-CzDrMcRN.cjs → workpieceTreePanel-C2BXrv3k.cjs} +1 -1
  117. package/dist/{workpieceTreePanel--iaoqT8x.js → workpieceTreePanel-CSKzSdIt.js} +5 -5
  118. package/package.json +1 -1
  119. package/public/icons/svg/LowCodeEvent.svg +1 -1
  120. package/public/icons/svg/LowCodeExtend.svg +1 -1
  121. package/public/icons/svg/LowCodeSetting.svg +1 -1
  122. package/public/icons/svg/LowCodeStyle.svg +1 -1
  123. package/dist/array-Ct7vOLI-.cjs +0 -11
  124. package/dist/array-W5079asF.js +0 -691
  125. package/dist/index-4WD9Ho5n.js +0 -2933
  126. package/dist/index-BA9JRDoC.cjs +0 -1
  127. package/dist/index-BVaHwt5f.cjs +0 -1
  128. package/dist/index-CFI3jKGA.js +0 -2671
  129. package/dist/index-CO41Br9G.cjs +0 -1
  130. package/dist/index-CTq3U1p_.cjs +0 -1
  131. package/dist/index-CvZk_MDD.cjs +0 -15
  132. package/dist/index-Db9w-sM_.cjs +0 -1
  133. package/dist/index-DitsEkB9.js +0 -673
  134. package/dist/index-DooNp_Nd.js +0 -12047
  135. package/dist/index-JAuJmfCC.cjs +0 -1
  136. package/dist/index-rlStojTL.js +0 -52
@@ -0,0 +1,3621 @@
1
+ import { ref as me, computed as vt, resolveComponent as $t, createElementBlock as be, openBlock as fe, Fragment as Nt, renderList as Ht, createElementVNode as ve, toDisplayString as st, createVNode as he, watch as ue, withCtx as Me, createBlock as Wt, resolveDynamicComponent as gr, createTextVNode as pn, createCommentVNode as gt, normalizeStyle as mn, withModifiers as Dt, defineComponent as mr, inject as rr, shallowRef as Ni, reactive as Yt, toRef as Hi, onBeforeMount as yr, onMounted as br, watchEffect as Wi, onBeforeUnmount as xr, normalizeClass as ir, renderSlot as dn, nextTick as Ye, provide as or, toRefs as ar, withDirectives as Yi, mergeProps as Xi, vShow as Vi, unref as sr } from "vue";
2
+ import { r as fn, g as wr } from "./index-BVdolwlx.js";
3
+ import { p as yn, s as bn, c as De, E as Gi } from "./index-Dm_WlV6R.js";
4
+ import { a as xn, E as Ui } from "./index.vue_vue_type_style_index_1_lang-B0l6QIWy.js";
5
+ import { i as Ce, o as ke, b as lr, w as qi, Z as Ki, n as Ji } from "./array-DTXrs6ZK.js";
6
+ import { _ as wn } from "./_plugin-vue_export-helper-CHgC5LLL.js";
7
+ import Zi from "./index-DiRBJiMW.js";
8
+ import { a as Qi, b as eo } from "./index-BuSsSHAY.js";
9
+ import { g as to } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CtycIAIT.js";
10
+ const no = { class: "type-select" }, ro = { class: "group-label" }, io = { class: "group-items" }, oo = ["onDragstart"], ao = {
11
+ __name: "index",
12
+ props: {
13
+ compContainerRef: Object
14
+ },
15
+ emits: [""],
16
+ setup(y, { emit: m }) {
17
+ const b = xn(yn), { itemData: f, activeItemIndex: D } = bn(b), v = m, I = me(null), T = vt(() => {
18
+ var xe, we, _e;
19
+ const q = { label: "布局", items: ["TABS", "LAYOUT"] }, V = { label: "常用", items: ["FORM", "TABLE"] }, F = { label: "高级", items: ["STEP", "TIMELINE", "CHART", "SIGNATURE", "AVATAR", "FOLD"] }, re = (xe = fn.value) == null ? void 0 : xe.filter((R) => {
20
+ var C, E;
21
+ return (E = q == null ? void 0 : q.items) == null ? void 0 : E.includes((C = R == null ? void 0 : R.type) == null ? void 0 : C.toUpperCase());
22
+ }), ie = (we = fn.value) == null ? void 0 : we.filter((R) => {
23
+ var C, E;
24
+ return (E = V == null ? void 0 : V.items) == null ? void 0 : E.includes((C = R == null ? void 0 : R.type) == null ? void 0 : C.toUpperCase());
25
+ }), ge = (_e = fn.value) == null ? void 0 : _e.filter((R) => {
26
+ var C, E;
27
+ return (E = F == null ? void 0 : F.items) == null ? void 0 : E.includes((C = R == null ? void 0 : R.type) == null ? void 0 : C.toUpperCase());
28
+ });
29
+ return [
30
+ {
31
+ ...q,
32
+ items: re
33
+ },
34
+ {
35
+ ...V,
36
+ items: ie
37
+ },
38
+ {
39
+ ...F,
40
+ items: ge
41
+ }
42
+ ];
43
+ }), d = (q, V) => {
44
+ try {
45
+ q.dataTransfer.clearData();
46
+ const F = {
47
+ ...V,
48
+ timestamp: Date.now()
49
+ // 添加时间戳确保唯一性
50
+ };
51
+ q.dataTransfer.setData("application/json", JSON.stringify(F)), q.dataTransfer.effectAllowed = "copyMove", q.target.classList.add("dragging"), v("handleDragStart", V);
52
+ } catch (F) {
53
+ console.error("Drag start error:", F);
54
+ }
55
+ };
56
+ return (q, V) => {
57
+ const F = $t("svg-icon");
58
+ return fe(), be("div", no, [
59
+ (fe(!0), be(Nt, null, Ht(T.value, (re) => (fe(), be("div", {
60
+ class: "group-item",
61
+ key: re == null ? void 0 : re.label
62
+ }, [
63
+ ve("div", ro, st(re == null ? void 0 : re.label), 1),
64
+ ve("div", io, [
65
+ (fe(!0), be(Nt, null, Ht(re == null ? void 0 : re.items, (ie, ge) => (fe(), be("div", {
66
+ class: "type-list",
67
+ ref_for: !0,
68
+ ref_key: "dragItem",
69
+ ref: I,
70
+ key: ge,
71
+ draggable: !0,
72
+ onDragstart: (xe) => d(xe, ie)
73
+ }, [
74
+ he(F, {
75
+ name: ie.icon,
76
+ style: { width: "15px", height: "15px" }
77
+ }, null, 8, ["name"]),
78
+ ve("div", null, st(ie.name), 1)
79
+ ], 40, oo))), 128))
80
+ ])
81
+ ]))), 128))
82
+ ]);
83
+ };
84
+ }
85
+ }, na = /* @__PURE__ */ wn(ao, [["__scopeId", "data-v-f91dc8de"]]), so = { class: "fill-content" }, lo = { class: "operate-content" }, co = ["onClick"], uo = { class: "collapse-title-item" }, po = { key: 1 }, fo = ["onClick"], ho = { class: "icon-content" }, vo = {
86
+ key: 0,
87
+ class: "edit-content"
88
+ }, go = ["onClick"], mo = { title: "设置" }, yo = ["onClick"], bo = { class: "parent-main" }, xo = { style: { display: "flex", "justify-content": "space-between" } }, wo = { title: "样式" }, _o = { title: "事件" }, Eo = { title: "扩展功能" }, So = {
89
+ __name: "index",
90
+ setup(y) {
91
+ const m = xn(yn), { itemData: b, originalData: f } = bn(m), D = me([]);
92
+ me([]);
93
+ const v = me([]), I = me([]), T = me([]), d = me("data"), q = (R) => {
94
+ var E;
95
+ let C = (E = De(I.value)) == null ? void 0 : E.map((O, z) => (R === z && (O.content = !0), O));
96
+ I.value = C;
97
+ }, V = (R) => {
98
+ var E;
99
+ let C = (E = De(I.value)) == null ? void 0 : E.map((O, z) => (R === z && (O.content = !1), O));
100
+ I.value = C, D.value = De(b.value);
101
+ }, F = (R, C) => {
102
+ var h;
103
+ let E = (h = De(I.value)) == null ? void 0 : h.map((N, U) => (R === U && (N.content = !1), N));
104
+ I.value = E;
105
+ const O = De(b.value), z = O == null ? void 0 : O.filter((N, U) => (U === R && (N.name = C), N));
106
+ m.setOriginalData(z), m.setItemData(z);
107
+ }, re = (R) => {
108
+ const C = De(b.value), E = C == null ? void 0 : C.map((O, z) => ((O == null ? void 0 : O.name) === (R == null ? void 0 : R.name) ? O.isShow = !(R != null && R.isShow) : O.isShow = O.isShow, O));
109
+ b.value = E;
110
+ };
111
+ ue(
112
+ () => b.value,
113
+ () => {
114
+ var R, C, E, O;
115
+ !b.value || ((R = b.value) == null ? void 0 : R.length) === 0 ? D.value = [] : D.value = (C = De(b.value)) == null ? void 0 : C.filter((z) => (z == null ? void 0 : z.comp) !== "methodButton"), v.value = D.value, I.value = (E = De(v.value)) == null ? void 0 : E.map((z, h) => ({
116
+ id: h,
117
+ content: !1
118
+ })), T.value = (O = De(v.value)) == null ? void 0 : O.map((z, h) => ({
119
+ id: h,
120
+ isShow: z == null ? void 0 : z.isShow
121
+ }));
122
+ },
123
+ { deep: !0, immediate: !0 }
124
+ );
125
+ const ie = (R) => wr(R), ge = (R, C, E, O) => {
126
+ var h, N;
127
+ if (!R) return;
128
+ let z = De(b.value);
129
+ z = (h = z == null ? void 0 : z.map((U, se) => {
130
+ if (O && se === E) {
131
+ const { compData: k, itemChildData: j } = R;
132
+ return U.compData = k, U.itemChildData = j, U;
133
+ }
134
+ return se === E && (U.compData = R), U;
135
+ })) == null ? void 0 : h.filter((U) => (U == null ? void 0 : U.comp) !== "methodButton"), I.value = (N = De(z)) == null ? void 0 : N.map((U, se) => ({
136
+ id: se,
137
+ content: !1
138
+ })), m.setOriginalData(z), m.setItemData(z);
139
+ }, xe = me(null), we = (R, C) => {
140
+ if (!C) {
141
+ m.setActiveItemIndex(R);
142
+ return;
143
+ }
144
+ m.setActiveItemIndex(-1);
145
+ }, _e = (R) => {
146
+ Ui.confirm("是否确认要删除", "", {
147
+ confirmButtonText: "确认",
148
+ cancelButtonText: "取消",
149
+ type: "warning"
150
+ }).then(
151
+ () => {
152
+ const C = De(b.value), E = C == null ? void 0 : C.filter((O, z) => z !== R);
153
+ m.setOriginalData(E), m.setItemData(E), m.setActiveItemIndex(-1), Gi({
154
+ type: "success",
155
+ message: "删除成功"
156
+ });
157
+ }
158
+ ).catch(() => {
159
+ });
160
+ };
161
+ return (R, C) => {
162
+ const E = $t("svg-icon"), O = $t("el-tab-pane"), z = $t("el-tabs");
163
+ return fe(), be("div", so, [
164
+ C[7] || (C[7] = ve("div", { class: "fill-operate" }, st("操作栏"), -1)),
165
+ ve("div", lo, [
166
+ he(Zi, {
167
+ class: "collapse-content",
168
+ collapseContents: D.value,
169
+ ref_key: "ssCollapseRef",
170
+ ref: xe
171
+ }, {
172
+ title: Me(({ item: h, index: N, isActive: U }) => {
173
+ var se, k, j, Q, ee, oe, ae, W, ze, de;
174
+ return [
175
+ ve("div", {
176
+ class: "collapse-title-content",
177
+ onClick: (K) => we(N, U)
178
+ }, [
179
+ ve("div", uo, [
180
+ (k = (se = I.value) == null ? void 0 : se.find((K) => K.id === N)) != null && k.content ? gt("", !0) : (fe(), be("div", {
181
+ key: 0,
182
+ class: "collapse-title",
183
+ style: mn({ marginRight: h.name && h.name !== "" ? "8px" : "0px" })
184
+ }, st(h.name), 5)),
185
+ (Q = (j = I.value) == null ? void 0 : j.find((K) => K.id === N)) != null && Q.content ? (fe(), be("div", po, [
186
+ he(eo, {
187
+ modelValue: h.name,
188
+ "onUpdate:modelValue": (K) => h.name = K,
189
+ onClick: C[0] || (C[0] = Dt(() => {
190
+ }, ["stop"]))
191
+ }, null, 8, ["modelValue", "onUpdate:modelValue"])
192
+ ])) : gt("", !0),
193
+ (oe = (ee = I.value) == null ? void 0 : ee.find((K) => K.id === N)) != null && oe.content ? gt("", !0) : (fe(), be("div", {
194
+ key: 2,
195
+ onClick: Dt((K) => q(N), ["stop"]),
196
+ class: "icon-content"
197
+ }, [
198
+ he(E, {
199
+ name: "Edit",
200
+ style: { width: "16px", height: "16px" }
201
+ })
202
+ ], 8, fo))
203
+ ]),
204
+ ve("div", ho, [
205
+ (W = (ae = I.value) == null ? void 0 : ae.find((K) => K.id === N)) != null && W.content ? (fe(), be("div", vo, [
206
+ he(E, {
207
+ name: "Cancel",
208
+ style: { width: "16px", height: "16px" },
209
+ class: "icon-content",
210
+ onClick: Dt((K) => V(N), ["stop"])
211
+ }, null, 8, ["onClick"]),
212
+ he(E, {
213
+ name: "Save",
214
+ onClick: Dt((K) => F(N, h.name), ["stop"]),
215
+ style: { width: "16px", height: "16px", fill: "var(--ssComponent-primary-color)" },
216
+ class: "icon-content"
217
+ }, null, 8, ["onClick"])
218
+ ])) : gt("", !0),
219
+ (de = (ze = I.value) == null ? void 0 : ze.find((K) => K.id === N)) != null && de.content ? gt("", !0) : (fe(), be("div", {
220
+ key: 1,
221
+ onClick: Dt((K) => _e(N), ["stop"]),
222
+ class: "icon-content"
223
+ }, [
224
+ he(E, {
225
+ name: "Delete",
226
+ style: { width: "16px", height: "16px" }
227
+ })
228
+ ], 8, go))
229
+ ])
230
+ ], 8, co)
231
+ ];
232
+ }),
233
+ content: Me(({ item: h, index: N }) => [
234
+ he(z, {
235
+ modelValue: d.value,
236
+ "onUpdate:modelValue": C[1] || (C[1] = (U) => d.value = U),
237
+ class: "config-tabs",
238
+ onTabClick: we
239
+ }, {
240
+ default: Me(() => [
241
+ he(O, {
242
+ label: "设置",
243
+ name: "data"
244
+ }, {
245
+ label: Me(() => [
246
+ ve("span", mo, [
247
+ he(E, {
248
+ name: "LowCodeSetting",
249
+ style: { width: "15px", height: "15px" }
250
+ })
251
+ ])
252
+ ]),
253
+ default: Me(() => {
254
+ var U, se;
255
+ return [
256
+ ve("div", {
257
+ class: "comp-child",
258
+ onClick: (k) => we(N)
259
+ }, [
260
+ (fe(), Wt(gr(ie(h.comp + "Operate")), {
261
+ itemContents: h == null ? void 0 : h.compData,
262
+ originalItemContents: (se = (U = v.value) == null ? void 0 : U.find((k, j) => j === N)) == null ? void 0 : se.compData,
263
+ itemChildData: h == null ? void 0 : h.itemChildData,
264
+ onChange: (k, j) => ge(k, h, N, j)
265
+ }, null, 40, ["itemContents", "originalItemContents", "itemChildData", "onChange"]))
266
+ ], 8, yo),
267
+ ve("div", bo, [
268
+ C[3] || (C[3] = ve("div", { class: "operate-title" }, [
269
+ ve("div", null, st("显隐控制"))
270
+ ], -1)),
271
+ ve("div", xo, [
272
+ C[2] || (C[2] = ve("div", { class: "operate-center-content" }, st("是否显示"), -1)),
273
+ he(Qi, {
274
+ value: T.value.find((k) => k.id === N).isShow,
275
+ "onUpdate:value": (k) => T.value.find((j) => j.id === N).isShow = k,
276
+ onClick: (k) => re(h)
277
+ }, null, 8, ["value", "onUpdate:value", "onClick"])
278
+ ])
279
+ ])
280
+ ];
281
+ }),
282
+ _: 2
283
+ }, 1024),
284
+ he(O, {
285
+ label: "样式",
286
+ name: "style"
287
+ }, {
288
+ label: Me(() => [
289
+ ve("span", wo, [
290
+ he(E, {
291
+ name: "LowCodeStyle",
292
+ style: { width: "15px", height: "15px" }
293
+ })
294
+ ])
295
+ ]),
296
+ default: Me(() => [
297
+ C[4] || (C[4] = pn(" 样式 "))
298
+ ]),
299
+ _: 1,
300
+ __: [4]
301
+ }),
302
+ he(O, {
303
+ label: "事件",
304
+ name: "event"
305
+ }, {
306
+ label: Me(() => [
307
+ ve("span", _o, [
308
+ he(E, {
309
+ name: "LowCodeEvent",
310
+ style: { width: "15px", height: "15px" }
311
+ })
312
+ ])
313
+ ]),
314
+ default: Me(() => [
315
+ C[5] || (C[5] = pn("事件"))
316
+ ]),
317
+ _: 1,
318
+ __: [5]
319
+ }),
320
+ he(O, {
321
+ label: "扩展功能",
322
+ name: "extend"
323
+ }, {
324
+ label: Me(() => [
325
+ ve("span", Eo, [
326
+ he(E, {
327
+ name: "LowCodeExtend",
328
+ style: { width: "15px", height: "15px" }
329
+ })
330
+ ])
331
+ ]),
332
+ default: Me(() => [
333
+ C[6] || (C[6] = pn("扩展功能"))
334
+ ]),
335
+ _: 1,
336
+ __: [6]
337
+ })
338
+ ]),
339
+ _: 2
340
+ }, 1032, ["modelValue"])
341
+ ]),
342
+ _: 1
343
+ }, 8, ["collapseContents"])
344
+ ])
345
+ ]);
346
+ };
347
+ }
348
+ }, ra = /* @__PURE__ */ wn(So, [["__scopeId", "data-v-aacccc96"]]), _r = Symbol("LAYOUT_KEY"), Er = Symbol("EMITTER_KEY");
349
+ function To(y) {
350
+ let m = 0, b;
351
+ for (let f = 0, D = y.length; f < D; f++)
352
+ b = y[f].y + y[f].h, b > m && (m = b);
353
+ return m;
354
+ }
355
+ function hn(y) {
356
+ const m = Array(y.length);
357
+ for (let b = 0, f = y.length; b < f; b++)
358
+ m[b] = ko(y[b]);
359
+ return m;
360
+ }
361
+ function ko(y) {
362
+ return { ...y };
363
+ }
364
+ function Sr(y, m) {
365
+ return !(y === m || y.x + y.w <= m.x || y.x >= m.x + m.w || y.y + y.h <= m.y || y.y >= m.y + m.h);
366
+ }
367
+ function mt(y, m, b) {
368
+ const f = kr(y), D = Dr(y), v = Array(y.length);
369
+ for (let I = 0, T = D.length; I < T; I++) {
370
+ let d = D[I];
371
+ d.static || (d = Do(f, d, m, b), f.push(d)), v[y.findIndex((q) => q.i === d.i)] = d, d.moved = !1;
372
+ }
373
+ return v;
374
+ }
375
+ function Do(y, m, b, f) {
376
+ if (b)
377
+ for (; m.y > 0 && !Ot(y, m); )
378
+ m.y--;
379
+ else if (f) {
380
+ const v = f[m.i].y;
381
+ for (; m.y > v && !Ot(y, m); )
382
+ m.y--;
383
+ }
384
+ let D;
385
+ for (; D = Ot(y, m); )
386
+ m.y = D.y + D.h;
387
+ return m;
388
+ }
389
+ function zo(y, m) {
390
+ const b = kr(y);
391
+ for (let f = 0, D = y.length; f < D; f++) {
392
+ const v = y[f];
393
+ if (v.x + v.w > m.cols && (v.x = m.cols - v.w), v.x < 0 && (v.x = 0, v.w = m.cols), !v.static) b.push(v);
394
+ else
395
+ for (; Ot(b, v); )
396
+ v.y++;
397
+ }
398
+ return y;
399
+ }
400
+ function cr(y, m) {
401
+ for (let b = 0, f = y.length; b < f; b++)
402
+ if (y[b].i === m) return y[b];
403
+ }
404
+ function Ot(y, m) {
405
+ for (let b = 0, f = y.length; b < f; b++)
406
+ if (Sr(y[b], m)) return y[b];
407
+ }
408
+ function Tr(y, m) {
409
+ return y.filter((b) => Sr(b, m));
410
+ }
411
+ function kr(y) {
412
+ return y.filter((m) => m.static);
413
+ }
414
+ function vn(y, m, b, f, D = !1, v = !1) {
415
+ if (m.static) return y;
416
+ const I = m.x, T = m.y, d = f && m.y > f;
417
+ typeof b == "number" && (m.x = b), typeof f == "number" && (m.y = f), m.moved = !0;
418
+ let q = Dr(y);
419
+ d && (q = q.reverse());
420
+ const V = Tr(q, m);
421
+ if (v && V.length)
422
+ return m.x = I, m.y = T, m.moved = !1, y;
423
+ for (let F = 0, re = V.length; F < re; F++) {
424
+ const ie = V[F];
425
+ ie.moved || m.y > ie.y && m.y - ie.y > ie.h / 4 || (ie.static ? y = ur(y, ie, m, D) : y = ur(y, m, ie, D));
426
+ }
427
+ return y;
428
+ }
429
+ function ur(y, m, b, f) {
430
+ if (f) {
431
+ const D = {
432
+ x: b.x,
433
+ y: b.y,
434
+ w: b.w,
435
+ h: b.h
436
+ };
437
+ if (D.y = Math.max(m.y - b.h, 0), !Ot(y, D))
438
+ return vn(y, b, void 0, D.y, !1);
439
+ }
440
+ return vn(y, b, void 0, b.y + 1, !1);
441
+ }
442
+ function Oo(y, m, b, f) {
443
+ const D = "translate3d(" + m + "px," + y + "px, 0)";
444
+ return {
445
+ transform: D,
446
+ WebkitTransform: D,
447
+ MozTransform: D,
448
+ msTransform: D,
449
+ OTransform: D,
450
+ width: b + "px",
451
+ height: f + "px",
452
+ position: "absolute"
453
+ };
454
+ }
455
+ function Mo(y, m, b, f) {
456
+ const D = "translate3d(" + m * -1 + "px," + y + "px, 0)";
457
+ return {
458
+ transform: D,
459
+ WebkitTransform: D,
460
+ MozTransform: D,
461
+ msTransform: D,
462
+ OTransform: D,
463
+ width: b + "px",
464
+ height: f + "px",
465
+ position: "absolute"
466
+ };
467
+ }
468
+ function Io(y, m, b, f) {
469
+ return {
470
+ top: y + "px",
471
+ left: m + "px",
472
+ width: b + "px",
473
+ height: f + "px",
474
+ position: "absolute"
475
+ };
476
+ }
477
+ function Po(y, m, b, f) {
478
+ return {
479
+ top: y + "px",
480
+ right: m + "px",
481
+ width: b + "px",
482
+ height: f + "px",
483
+ position: "absolute"
484
+ };
485
+ }
486
+ function Dr(y) {
487
+ return Array.from(y).sort(function(m, b) {
488
+ return m.y === b.y && m.x === b.x ? 0 : m.y > b.y || m.y === b.y && m.x > b.x ? 1 : -1;
489
+ });
490
+ }
491
+ function Co(y, m) {
492
+ m = m || "Layout";
493
+ const b = ["x", "y", "w", "h"], f = [];
494
+ if (!Array.isArray(y)) throw new Error(m + " must be an array!");
495
+ for (let D = 0, v = y.length; D < v; D++) {
496
+ const I = y[D];
497
+ for (let T = 0; T < b.length; T++)
498
+ if (typeof I[b[T]] != "number")
499
+ throw new Error(
500
+ "VueGridLayout: " + m + "[" + D + "]." + b[T] + " must be a number!"
501
+ );
502
+ if (I.i === void 0 || I.i === null)
503
+ throw new Error("VueGridLayout: " + m + "[" + D + "].i cannot be null!");
504
+ if (typeof I.i != "number" && typeof I.i != "string")
505
+ throw new Error("VueGridLayout: " + m + "[" + D + "].i must be a string or number!");
506
+ if (f.indexOf(I.i) >= 0)
507
+ throw new Error("VueGridLayout: " + m + "[" + D + "].i must be unique!");
508
+ if (f.push(I.i), I.static !== void 0 && typeof I.static != "boolean")
509
+ throw new Error("VueGridLayout: " + m + "[" + D + "].static must be a boolean!");
510
+ }
511
+ }
512
+ function Ro(y, m = "vgl") {
513
+ const b = () => `${m}-${y}`;
514
+ return {
515
+ b,
516
+ be: (f) => `${b()}__${f}`,
517
+ bm: (f) => `${b()}--${f}`,
518
+ bem: (f, D) => `${b()}__${f}--${D}`
519
+ };
520
+ }
521
+ function pr(y) {
522
+ return Ao(y);
523
+ }
524
+ function Ao(y) {
525
+ var m;
526
+ const b = ((m = y.target) == null ? void 0 : m.offsetParent) || document.body, f = y.offsetParent === document.body ? { left: 0, top: 0 } : b.getBoundingClientRect(), D = y.clientX + b.scrollLeft - f.left, v = y.clientY + b.scrollTop - f.top;
527
+ return { x: D, y: v };
528
+ }
529
+ function fr(y, m, b, f) {
530
+ return Bo(y) ? {
531
+ deltaX: b - y,
532
+ deltaY: f - m,
533
+ lastX: y,
534
+ lastY: m,
535
+ x: b,
536
+ y: f
537
+ } : {
538
+ deltaX: 0,
539
+ deltaY: 0,
540
+ lastX: b,
541
+ lastY: f,
542
+ x: b,
543
+ y: f
544
+ };
545
+ }
546
+ function Bo(y) {
547
+ return typeof y == "number" && !Number.isNaN(y);
548
+ }
549
+ function jo(y, m) {
550
+ const b = Or(y);
551
+ let f = b[0];
552
+ for (let D = 1, v = b.length; D < v; D++) {
553
+ const I = b[D];
554
+ m > y[I] && (f = I);
555
+ }
556
+ return f;
557
+ }
558
+ function zr(y, m) {
559
+ if (!m[y])
560
+ throw new Error(
561
+ "ResponsiveGridLayout: `cols` entry for breakpoint " + y + " is missing!"
562
+ );
563
+ return m[y];
564
+ }
565
+ function Fo(y, m, b, f, D, v, I) {
566
+ if (m[f]) return hn(m[f]);
567
+ let T = y;
568
+ const d = Or(b), q = d.slice(d.indexOf(f));
569
+ for (let V = 0, F = q.length; V < F; V++) {
570
+ const re = q[V];
571
+ if (m[re]) {
572
+ T = m[re];
573
+ break;
574
+ }
575
+ }
576
+ return T = hn(T || []), mt(zo(T, { cols: v }), I);
577
+ }
578
+ function Or(y) {
579
+ return Object.keys(y).sort((m, b) => y[m] - y[b]);
580
+ }
581
+ let Lo = "auto";
582
+ function $o() {
583
+ return typeof document < "u";
584
+ }
585
+ function dr() {
586
+ return $o() ? typeof document.dir < "u" ? document.dir : document.getElementsByTagName("html")[0].getAttribute("dir") : Lo;
587
+ }
588
+ var zt = { exports: {} }, No = zt.exports, hr;
589
+ function Ho() {
590
+ return hr || (hr = 1, function(y, m) {
591
+ (function(b, f) {
592
+ y.exports = f();
593
+ })(No, function() {
594
+ function b(t, e) {
595
+ var n = Object.keys(t);
596
+ if (Object.getOwnPropertySymbols) {
597
+ var r = Object.getOwnPropertySymbols(t);
598
+ e && (r = r.filter(function(i) {
599
+ return Object.getOwnPropertyDescriptor(t, i).enumerable;
600
+ })), n.push.apply(n, r);
601
+ }
602
+ return n;
603
+ }
604
+ function f(t) {
605
+ for (var e = 1; e < arguments.length; e++) {
606
+ var n = arguments[e] != null ? arguments[e] : {};
607
+ e % 2 ? b(Object(n), !0).forEach(function(r) {
608
+ d(t, r, n[r]);
609
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(n)) : b(Object(n)).forEach(function(r) {
610
+ Object.defineProperty(t, r, Object.getOwnPropertyDescriptor(n, r));
611
+ });
612
+ }
613
+ return t;
614
+ }
615
+ function D(t) {
616
+ return D = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
617
+ return typeof e;
618
+ } : function(e) {
619
+ return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
620
+ }, D(t);
621
+ }
622
+ function v(t, e) {
623
+ if (!(t instanceof e)) throw new TypeError("Cannot call a class as a function");
624
+ }
625
+ function I(t, e) {
626
+ for (var n = 0; n < e.length; n++) {
627
+ var r = e[n];
628
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0), Object.defineProperty(t, xe(r.key), r);
629
+ }
630
+ }
631
+ function T(t, e, n) {
632
+ return e && I(t.prototype, e), Object.defineProperty(t, "prototype", { writable: !1 }), t;
633
+ }
634
+ function d(t, e, n) {
635
+ return (e = xe(e)) in t ? Object.defineProperty(t, e, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = n, t;
636
+ }
637
+ function q(t, e) {
638
+ if (typeof e != "function" && e !== null) throw new TypeError("Super expression must either be null or a function");
639
+ t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && F(t, e);
640
+ }
641
+ function V(t) {
642
+ return V = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
643
+ return e.__proto__ || Object.getPrototypeOf(e);
644
+ }, V(t);
645
+ }
646
+ function F(t, e) {
647
+ return F = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(n, r) {
648
+ return n.__proto__ = r, n;
649
+ }, F(t, e);
650
+ }
651
+ function re(t) {
652
+ if (t === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
653
+ return t;
654
+ }
655
+ function ie(t) {
656
+ var e = function() {
657
+ if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
658
+ if (typeof Proxy == "function") return !0;
659
+ try {
660
+ return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
661
+ })), !0;
662
+ } catch {
663
+ return !1;
664
+ }
665
+ }();
666
+ return function() {
667
+ var n, r = V(t);
668
+ if (e) {
669
+ var i = V(this).constructor;
670
+ n = Reflect.construct(r, arguments, i);
671
+ } else n = r.apply(this, arguments);
672
+ return function(o, a) {
673
+ if (a && (typeof a == "object" || typeof a == "function")) return a;
674
+ if (a !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
675
+ return re(o);
676
+ }(this, n);
677
+ };
678
+ }
679
+ function ge() {
680
+ return ge = typeof Reflect < "u" && Reflect.get ? Reflect.get.bind() : function(t, e, n) {
681
+ var r = function(o, a) {
682
+ for (; !Object.prototype.hasOwnProperty.call(o, a) && (o = V(o)) !== null; ) ;
683
+ return o;
684
+ }(t, e);
685
+ if (r) {
686
+ var i = Object.getOwnPropertyDescriptor(r, e);
687
+ return i.get ? i.get.call(arguments.length < 3 ? t : n) : i.value;
688
+ }
689
+ }, ge.apply(this, arguments);
690
+ }
691
+ function xe(t) {
692
+ var e = function(n, r) {
693
+ if (typeof n != "object" || n === null) return n;
694
+ var i = n[Symbol.toPrimitive];
695
+ if (i !== void 0) {
696
+ var o = i.call(n, r);
697
+ if (typeof o != "object") return o;
698
+ throw new TypeError("@@toPrimitive must return a primitive value.");
699
+ }
700
+ return String(n);
701
+ }(t, "string");
702
+ return typeof e == "symbol" ? e : e + "";
703
+ }
704
+ var we = function(t) {
705
+ return !(!t || !t.Window) && t instanceof t.Window;
706
+ }, _e = void 0, R = void 0;
707
+ function C(t) {
708
+ _e = t;
709
+ var e = t.document.createTextNode("");
710
+ e.ownerDocument !== t.document && typeof t.wrap == "function" && t.wrap(e) === e && (t = t.wrap(t)), R = t;
711
+ }
712
+ function E(t) {
713
+ return we(t) ? t : (t.ownerDocument || t).defaultView || R.window;
714
+ }
715
+ typeof window < "u" && window && C(window);
716
+ var O = function(t) {
717
+ return !!t && D(t) === "object";
718
+ }, z = function(t) {
719
+ return typeof t == "function";
720
+ }, h = { window: function(t) {
721
+ return t === R || we(t);
722
+ }, docFrag: function(t) {
723
+ return O(t) && t.nodeType === 11;
724
+ }, object: O, func: z, number: function(t) {
725
+ return typeof t == "number";
726
+ }, bool: function(t) {
727
+ return typeof t == "boolean";
728
+ }, string: function(t) {
729
+ return typeof t == "string";
730
+ }, element: function(t) {
731
+ if (!t || D(t) !== "object") return !1;
732
+ var e = E(t) || R;
733
+ return /object|function/.test(typeof Element > "u" ? "undefined" : D(Element)) ? t instanceof Element || t instanceof e.Element : t.nodeType === 1 && typeof t.nodeName == "string";
734
+ }, plainObject: function(t) {
735
+ return O(t) && !!t.constructor && /function Object\b/.test(t.constructor.toString());
736
+ }, array: function(t) {
737
+ return O(t) && t.length !== void 0 && z(t.splice);
738
+ } };
739
+ function N(t) {
740
+ var e = t.interaction;
741
+ if (e.prepared.name === "drag") {
742
+ var n = e.prepared.axis;
743
+ n === "x" ? (e.coords.cur.page.y = e.coords.start.page.y, e.coords.cur.client.y = e.coords.start.client.y, e.coords.velocity.client.y = 0, e.coords.velocity.page.y = 0) : n === "y" && (e.coords.cur.page.x = e.coords.start.page.x, e.coords.cur.client.x = e.coords.start.client.x, e.coords.velocity.client.x = 0, e.coords.velocity.page.x = 0);
744
+ }
745
+ }
746
+ function U(t) {
747
+ var e = t.iEvent, n = t.interaction;
748
+ if (n.prepared.name === "drag") {
749
+ var r = n.prepared.axis;
750
+ if (r === "x" || r === "y") {
751
+ var i = r === "x" ? "y" : "x";
752
+ e.page[i] = n.coords.start.page[i], e.client[i] = n.coords.start.client[i], e.delta[i] = 0;
753
+ }
754
+ }
755
+ }
756
+ var se = { id: "actions/drag", install: function(t) {
757
+ var e = t.actions, n = t.Interactable, r = t.defaults;
758
+ n.prototype.draggable = se.draggable, e.map.drag = se, e.methodDict.drag = "draggable", r.actions.drag = se.defaults;
759
+ }, listeners: { "interactions:before-action-move": N, "interactions:action-resume": N, "interactions:action-move": U, "auto-start:check": function(t) {
760
+ var e = t.interaction, n = t.interactable, r = t.buttons, i = n.options.drag;
761
+ if (i && i.enabled && (!e.pointerIsDown || !/mouse|pointer/.test(e.pointerType) || (r & n.options.drag.mouseButtons) != 0)) return t.action = { name: "drag", axis: i.lockAxis === "start" ? i.startAxis : i.lockAxis }, !1;
762
+ } }, draggable: function(t) {
763
+ return h.object(t) ? (this.options.drag.enabled = t.enabled !== !1, this.setPerAction("drag", t), this.setOnEvents("drag", t), /^(xy|x|y|start)$/.test(t.lockAxis) && (this.options.drag.lockAxis = t.lockAxis), /^(xy|x|y)$/.test(t.startAxis) && (this.options.drag.startAxis = t.startAxis), this) : h.bool(t) ? (this.options.drag.enabled = t, this) : this.options.drag;
764
+ }, beforeMove: N, move: U, defaults: { startAxis: "xy", lockAxis: "xy" }, getCursor: function() {
765
+ return "move";
766
+ }, filterEventType: function(t) {
767
+ return t.search("drag") === 0;
768
+ } }, k = se, j = { init: function(t) {
769
+ var e = t;
770
+ j.document = e.document, j.DocumentFragment = e.DocumentFragment || Q, j.SVGElement = e.SVGElement || Q, j.SVGSVGElement = e.SVGSVGElement || Q, j.SVGElementInstance = e.SVGElementInstance || Q, j.Element = e.Element || Q, j.HTMLElement = e.HTMLElement || j.Element, j.Event = e.Event, j.Touch = e.Touch || Q, j.PointerEvent = e.PointerEvent || e.MSPointerEvent;
771
+ }, document: null, DocumentFragment: null, SVGElement: null, SVGSVGElement: null, SVGElementInstance: null, Element: null, HTMLElement: null, Event: null, Touch: null, PointerEvent: null };
772
+ function Q() {
773
+ }
774
+ var ee = j, oe = { init: function(t) {
775
+ var e = ee.Element, n = t.navigator || {};
776
+ oe.supportsTouch = "ontouchstart" in t || h.func(t.DocumentTouch) && ee.document instanceof t.DocumentTouch, oe.supportsPointerEvent = n.pointerEnabled !== !1 && !!ee.PointerEvent, oe.isIOS = /iP(hone|od|ad)/.test(n.platform), oe.isIOS7 = /iP(hone|od|ad)/.test(n.platform) && /OS 7[^\d]/.test(n.appVersion), oe.isIe9 = /MSIE 9/.test(n.userAgent), oe.isOperaMobile = n.appName === "Opera" && oe.supportsTouch && /Presto/.test(n.userAgent), oe.prefixedMatchesSelector = "matches" in e.prototype ? "matches" : "webkitMatchesSelector" in e.prototype ? "webkitMatchesSelector" : "mozMatchesSelector" in e.prototype ? "mozMatchesSelector" : "oMatchesSelector" in e.prototype ? "oMatchesSelector" : "msMatchesSelector", oe.pEventTypes = oe.supportsPointerEvent ? ee.PointerEvent === t.MSPointerEvent ? { up: "MSPointerUp", down: "MSPointerDown", over: "mouseover", out: "mouseout", move: "MSPointerMove", cancel: "MSPointerCancel" } : { up: "pointerup", down: "pointerdown", over: "pointerover", out: "pointerout", move: "pointermove", cancel: "pointercancel" } : null, oe.wheelEvent = ee.document && "onmousewheel" in ee.document ? "mousewheel" : "wheel";
777
+ }, supportsTouch: null, supportsPointerEvent: null, isIOS7: null, isIOS: null, isIe9: null, isOperaMobile: null, prefixedMatchesSelector: null, pEventTypes: null, wheelEvent: null }, ae = oe;
778
+ function W(t, e) {
779
+ if (t.contains) return t.contains(e);
780
+ for (; e; ) {
781
+ if (e === t) return !0;
782
+ e = e.parentNode;
783
+ }
784
+ return !1;
785
+ }
786
+ function ze(t, e) {
787
+ for (; h.element(t); ) {
788
+ if (K(t, e)) return t;
789
+ t = de(t);
790
+ }
791
+ return null;
792
+ }
793
+ function de(t) {
794
+ var e = t.parentNode;
795
+ if (h.docFrag(e)) {
796
+ for (; (e = e.host) && h.docFrag(e); ) ;
797
+ return e;
798
+ }
799
+ return e;
800
+ }
801
+ function K(t, e) {
802
+ return R !== _e && (e = e.replace(/\/deep\//g, " ")), t[ae.prefixedMatchesSelector](e);
803
+ }
804
+ var le = function(t) {
805
+ return t.parentNode || t.host;
806
+ };
807
+ function Be(t, e) {
808
+ for (var n, r = [], i = t; (n = le(i)) && i !== e && n !== i.ownerDocument; ) r.unshift(i), i = n;
809
+ return r;
810
+ }
811
+ function Oe(t, e, n) {
812
+ for (; h.element(t); ) {
813
+ if (K(t, e)) return !0;
814
+ if ((t = de(t)) === n) return K(t, e);
815
+ }
816
+ return !1;
817
+ }
818
+ function Mt(t) {
819
+ return t.correspondingUseElement || t;
820
+ }
821
+ function Xe(t) {
822
+ var e = t instanceof ee.SVGElement ? t.getBoundingClientRect() : t.getClientRects()[0];
823
+ return e && { left: e.left, right: e.right, top: e.top, bottom: e.bottom, width: e.width || e.right - e.left, height: e.height || e.bottom - e.top };
824
+ }
825
+ function Ae(t) {
826
+ var e, n = Xe(t);
827
+ if (!ae.isIOS7 && n) {
828
+ var r = { x: (e = (e = E(t)) || R).scrollX || e.document.documentElement.scrollLeft, y: e.scrollY || e.document.documentElement.scrollTop };
829
+ n.left += r.x, n.right += r.x, n.top += r.y, n.bottom += r.y;
830
+ }
831
+ return n;
832
+ }
833
+ function lt(t) {
834
+ for (var e = []; t; ) e.push(t), t = de(t);
835
+ return e;
836
+ }
837
+ function yt(t) {
838
+ return !!h.string(t) && (ee.document.querySelector(t), !0);
839
+ }
840
+ function A(t, e) {
841
+ for (var n in e) t[n] = e[n];
842
+ return t;
843
+ }
844
+ function Ve(t, e, n) {
845
+ return t === "parent" ? de(n) : t === "self" ? e.getRect(n) : ze(n, t);
846
+ }
847
+ function Ge(t, e, n, r) {
848
+ var i = t;
849
+ return h.string(i) ? i = Ve(i, e, n) : h.func(i) && (i = i.apply(void 0, r)), h.element(i) && (i = Ae(i)), i;
850
+ }
851
+ function je(t) {
852
+ return t && { x: "x" in t ? t.x : t.left, y: "y" in t ? t.y : t.top };
853
+ }
854
+ function ct(t) {
855
+ return !t || "x" in t && "y" in t || ((t = A({}, t)).x = t.left || 0, t.y = t.top || 0, t.width = t.width || (t.right || 0) - t.x, t.height = t.height || (t.bottom || 0) - t.y), t;
856
+ }
857
+ function nt(t, e, n) {
858
+ t.left && (e.left += n.x), t.right && (e.right += n.x), t.top && (e.top += n.y), t.bottom && (e.bottom += n.y), e.width = e.right - e.left, e.height = e.bottom - e.top;
859
+ }
860
+ function rt(t, e, n) {
861
+ var r = n && t.options[n];
862
+ return je(Ge(r && r.origin || t.options.origin, t, e, [t && e])) || { x: 0, y: 0 };
863
+ }
864
+ function Fe(t, e) {
865
+ var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : function(l) {
866
+ return !0;
867
+ }, r = arguments.length > 3 ? arguments[3] : void 0;
868
+ if (r = r || {}, h.string(t) && t.search(" ") !== -1 && (t = bt(t)), h.array(t)) return t.forEach(function(l) {
869
+ return Fe(l, e, n, r);
870
+ }), r;
871
+ if (h.object(t) && (e = t, t = ""), h.func(e) && n(t)) r[t] = r[t] || [], r[t].push(e);
872
+ else if (h.array(e)) for (var i = 0, o = e; i < o.length; i++) {
873
+ var a = o[i];
874
+ Fe(t, a, n, r);
875
+ }
876
+ else if (h.object(e)) for (var s in e)
877
+ Fe(bt(s).map(function(l) {
878
+ return "".concat(t).concat(l);
879
+ }), e[s], n, r);
880
+ return r;
881
+ }
882
+ function bt(t) {
883
+ return t.trim().split(/ +/);
884
+ }
885
+ var Ue = function(t, e) {
886
+ return Math.sqrt(t * t + e * e);
887
+ }, Xt = ["webkit", "moz"];
888
+ function it(t, e) {
889
+ t.__set || (t.__set = {});
890
+ var n = function(i) {
891
+ if (Xt.some(function(o) {
892
+ return i.indexOf(o) === 0;
893
+ })) return 1;
894
+ typeof t[i] != "function" && i !== "__set" && Object.defineProperty(t, i, { get: function() {
895
+ return i in t.__set ? t.__set[i] : t.__set[i] = e[i];
896
+ }, set: function(o) {
897
+ t.__set[i] = o;
898
+ }, configurable: !0 });
899
+ };
900
+ for (var r in e) n(r);
901
+ return t;
902
+ }
903
+ function ut(t, e) {
904
+ t.page = t.page || {}, t.page.x = e.page.x, t.page.y = e.page.y, t.client = t.client || {}, t.client.x = e.client.x, t.client.y = e.client.y, t.timeStamp = e.timeStamp;
905
+ }
906
+ function Le(t) {
907
+ t.page.x = 0, t.page.y = 0, t.client.x = 0, t.client.y = 0;
908
+ }
909
+ function _(t) {
910
+ return t instanceof ee.Event || t instanceof ee.Touch;
911
+ }
912
+ function Y(t, e, n) {
913
+ return t = t || "page", (n = n || {}).x = e[t + "X"], n.y = e[t + "Y"], n;
914
+ }
915
+ function te(t, e) {
916
+ return e = e || { x: 0, y: 0 }, ae.isOperaMobile && _(t) ? (Y("screen", t, e), e.x += window.scrollX, e.y += window.scrollY) : Y("page", t, e), e;
917
+ }
918
+ function ne(t) {
919
+ return h.number(t.pointerId) ? t.pointerId : t.identifier;
920
+ }
921
+ function pe(t, e, n) {
922
+ var r = e.length > 1 ? L(e) : e[0];
923
+ te(r, t.page), function(i, o) {
924
+ o = o || {}, ae.isOperaMobile && _(i) ? Y("screen", i, o) : Y("client", i, o);
925
+ }(r, t.client), t.timeStamp = n;
926
+ }
927
+ function J(t) {
928
+ var e = [];
929
+ return h.array(t) ? (e[0] = t[0], e[1] = t[1]) : t.type === "touchend" ? t.touches.length === 1 ? (e[0] = t.touches[0], e[1] = t.changedTouches[0]) : t.touches.length === 0 && (e[0] = t.changedTouches[0], e[1] = t.changedTouches[1]) : (e[0] = t.touches[0], e[1] = t.touches[1]), e;
930
+ }
931
+ function L(t) {
932
+ for (var e = { pageX: 0, pageY: 0, clientX: 0, clientY: 0, screenX: 0, screenY: 0 }, n = 0; n < t.length; n++) {
933
+ var r = t[n];
934
+ for (var i in e) e[i] += r[i];
935
+ }
936
+ for (var o in e) e[o] /= t.length;
937
+ return e;
938
+ }
939
+ function ye(t) {
940
+ if (!t.length) return null;
941
+ var e = J(t), n = Math.min(e[0].pageX, e[1].pageX), r = Math.min(e[0].pageY, e[1].pageY), i = Math.max(e[0].pageX, e[1].pageX), o = Math.max(e[0].pageY, e[1].pageY);
942
+ return { x: n, y: r, left: n, top: r, right: i, bottom: o, width: i - n, height: o - r };
943
+ }
944
+ function Ee(t, e) {
945
+ var n = e + "X", r = e + "Y", i = J(t), o = i[0][n] - i[1][n], a = i[0][r] - i[1][r];
946
+ return Ue(o, a);
947
+ }
948
+ function Ie(t, e) {
949
+ var n = e + "X", r = e + "Y", i = J(t), o = i[1][n] - i[0][n], a = i[1][r] - i[0][r];
950
+ return 180 * Math.atan2(a, o) / Math.PI;
951
+ }
952
+ function qe(t) {
953
+ return h.string(t.pointerType) ? t.pointerType : h.number(t.pointerType) ? [void 0, void 0, "touch", "pen", "mouse"][t.pointerType] : /touch/.test(t.type || "") || t instanceof ee.Touch ? "touch" : "mouse";
954
+ }
955
+ function Ke(t) {
956
+ var e = h.func(t.composedPath) ? t.composedPath() : t.path;
957
+ return [Mt(e ? e[0] : t.target), Mt(t.currentTarget)];
958
+ }
959
+ var Je = function() {
960
+ function t(e) {
961
+ v(this, t), this.immediatePropagationStopped = !1, this.propagationStopped = !1, this._interaction = e;
962
+ }
963
+ return T(t, [{ key: "preventDefault", value: function() {
964
+ } }, { key: "stopPropagation", value: function() {
965
+ this.propagationStopped = !0;
966
+ } }, { key: "stopImmediatePropagation", value: function() {
967
+ this.immediatePropagationStopped = this.propagationStopped = !0;
968
+ } }]), t;
969
+ }();
970
+ Object.defineProperty(Je.prototype, "interaction", { get: function() {
971
+ return this._interaction._proxy;
972
+ }, set: function() {
973
+ } });
974
+ var pt = function(t, e) {
975
+ for (var n = 0; n < e.length; n++) {
976
+ var r = e[n];
977
+ t.push(r);
978
+ }
979
+ return t;
980
+ }, ft = function(t) {
981
+ return pt([], t);
982
+ }, $e = function(t, e) {
983
+ for (var n = 0; n < t.length; n++) if (e(t[n], n, t)) return n;
984
+ return -1;
985
+ }, xt = function(t, e) {
986
+ return t[$e(t, e)];
987
+ }, dt = function(t) {
988
+ q(n, t);
989
+ var e = ie(n);
990
+ function n(r, i, o) {
991
+ var a;
992
+ v(this, n), (a = e.call(this, i._interaction)).dropzone = void 0, a.dragEvent = void 0, a.relatedTarget = void 0, a.draggable = void 0, a.propagationStopped = !1, a.immediatePropagationStopped = !1;
993
+ var s = o === "dragleave" ? r.prev : r.cur, l = s.element, u = s.dropzone;
994
+ return a.type = o, a.target = l, a.currentTarget = l, a.dropzone = u, a.dragEvent = i, a.relatedTarget = i.target, a.draggable = i.interactable, a.timeStamp = i.timeStamp, a;
995
+ }
996
+ return T(n, [{ key: "reject", value: function() {
997
+ var r = this, i = this._interaction.dropState;
998
+ if (this.type === "dropactivate" || this.dropzone && i.cur.dropzone === this.dropzone && i.cur.element === this.target) if (i.prev.dropzone = this.dropzone, i.prev.element = this.target, i.rejected = !0, i.events.enter = null, this.stopImmediatePropagation(), this.type === "dropactivate") {
999
+ var o = i.activeDrops, a = $e(o, function(l) {
1000
+ var u = l.dropzone, c = l.element;
1001
+ return u === r.dropzone && c === r.target;
1002
+ });
1003
+ i.activeDrops.splice(a, 1);
1004
+ var s = new n(i, this.dragEvent, "dropdeactivate");
1005
+ s.dropzone = this.dropzone, s.target = this.target, this.dropzone.fire(s);
1006
+ } else this.dropzone.fire(new n(i, this.dragEvent, "dragleave"));
1007
+ } }, { key: "preventDefault", value: function() {
1008
+ } }, { key: "stopPropagation", value: function() {
1009
+ this.propagationStopped = !0;
1010
+ } }, { key: "stopImmediatePropagation", value: function() {
1011
+ this.immediatePropagationStopped = this.propagationStopped = !0;
1012
+ } }]), n;
1013
+ }(Je);
1014
+ function _n(t, e) {
1015
+ for (var n = 0, r = t.slice(); n < r.length; n++) {
1016
+ var i = r[n], o = i.dropzone, a = i.element;
1017
+ e.dropzone = o, e.target = a, o.fire(e), e.propagationStopped = e.immediatePropagationStopped = !1;
1018
+ }
1019
+ }
1020
+ function Vt(t, e) {
1021
+ for (var n = function(o, a) {
1022
+ for (var s = [], l = 0, u = o.interactables.list; l < u.length; l++) {
1023
+ var c = u[l];
1024
+ if (c.options.drop.enabled) {
1025
+ var p = c.options.drop.accept;
1026
+ if (!(h.element(p) && p !== a || h.string(p) && !K(a, p) || h.func(p) && !p({ dropzone: c, draggableElement: a }))) for (var g = 0, w = c.getAllElements(); g < w.length; g++) {
1027
+ var x = w[g];
1028
+ x !== a && s.push({ dropzone: c, element: x, rect: c.getRect(x) });
1029
+ }
1030
+ }
1031
+ }
1032
+ return s;
1033
+ }(t, e), r = 0; r < n.length; r++) {
1034
+ var i = n[r];
1035
+ i.rect = i.dropzone.getRect(i.element);
1036
+ }
1037
+ return n;
1038
+ }
1039
+ function En(t, e, n) {
1040
+ for (var r = t.dropState, i = t.interactable, o = t.element, a = [], s = 0, l = r.activeDrops; s < l.length; s++) {
1041
+ var u = l[s], c = u.dropzone, p = u.element, g = u.rect, w = c.dropCheck(e, n, i, o, p, g);
1042
+ a.push(w ? p : null);
1043
+ }
1044
+ var x = function(S) {
1045
+ for (var P, M, B, X = [], Z = 0; Z < S.length; Z++) {
1046
+ var $ = S[Z], G = S[P];
1047
+ if ($ && Z !== P) if (G) {
1048
+ var Te = le($), ce = le(G);
1049
+ if (Te !== $.ownerDocument) if (ce !== $.ownerDocument) if (Te !== ce) {
1050
+ X = X.length ? X : Be(G);
1051
+ var Pe = void 0;
1052
+ if (G instanceof ee.HTMLElement && $ instanceof ee.SVGElement && !($ instanceof ee.SVGSVGElement)) {
1053
+ if ($ === ce) continue;
1054
+ Pe = $.ownerSVGElement;
1055
+ } else Pe = $;
1056
+ for (var Re = Be(Pe, G.ownerDocument), We = 0; Re[We] && Re[We] === X[We]; ) We++;
1057
+ var Lt = [Re[We - 1], Re[We], X[We]];
1058
+ if (Lt[0]) for (var kt = Lt[0].lastChild; kt; ) {
1059
+ if (kt === Lt[1]) {
1060
+ P = Z, X = Re;
1061
+ break;
1062
+ }
1063
+ if (kt === Lt[2]) break;
1064
+ kt = kt.previousSibling;
1065
+ }
1066
+ } else B = G, (parseInt(E(M = $).getComputedStyle(M).zIndex, 10) || 0) >= (parseInt(E(B).getComputedStyle(B).zIndex, 10) || 0) && (P = Z);
1067
+ else P = Z;
1068
+ } else P = Z;
1069
+ }
1070
+ return P;
1071
+ }(a);
1072
+ return r.activeDrops[x] || null;
1073
+ }
1074
+ function Gt(t, e, n) {
1075
+ var r = t.dropState, i = { enter: null, leave: null, activate: null, deactivate: null, move: null, drop: null };
1076
+ return n.type === "dragstart" && (i.activate = new dt(r, n, "dropactivate"), i.activate.target = null, i.activate.dropzone = null), n.type === "dragend" && (i.deactivate = new dt(r, n, "dropdeactivate"), i.deactivate.target = null, i.deactivate.dropzone = null), r.rejected || (r.cur.element !== r.prev.element && (r.prev.dropzone && (i.leave = new dt(r, n, "dragleave"), n.dragLeave = i.leave.target = r.prev.element, n.prevDropzone = i.leave.dropzone = r.prev.dropzone), r.cur.dropzone && (i.enter = new dt(r, n, "dragenter"), n.dragEnter = r.cur.element, n.dropzone = r.cur.dropzone)), n.type === "dragend" && r.cur.dropzone && (i.drop = new dt(r, n, "drop"), n.dropzone = r.cur.dropzone, n.relatedTarget = r.cur.element), n.type === "dragmove" && r.cur.dropzone && (i.move = new dt(r, n, "dropmove"), n.dropzone = r.cur.dropzone)), i;
1077
+ }
1078
+ function Ut(t, e) {
1079
+ var n = t.dropState, r = n.activeDrops, i = n.cur, o = n.prev;
1080
+ e.leave && o.dropzone.fire(e.leave), e.enter && i.dropzone.fire(e.enter), e.move && i.dropzone.fire(e.move), e.drop && i.dropzone.fire(e.drop), e.deactivate && _n(r, e.deactivate), n.prev.dropzone = i.dropzone, n.prev.element = i.element;
1081
+ }
1082
+ function Sn(t, e) {
1083
+ var n = t.interaction, r = t.iEvent, i = t.event;
1084
+ if (r.type === "dragmove" || r.type === "dragend") {
1085
+ var o = n.dropState;
1086
+ e.dynamicDrop && (o.activeDrops = Vt(e, n.element));
1087
+ var a = r, s = En(n, a, i);
1088
+ o.rejected = o.rejected && !!s && s.dropzone === o.cur.dropzone && s.element === o.cur.element, o.cur.dropzone = s && s.dropzone, o.cur.element = s && s.element, o.events = Gt(n, 0, a);
1089
+ }
1090
+ }
1091
+ var Tn = { id: "actions/drop", install: function(t) {
1092
+ var e = t.actions, n = t.interactStatic, r = t.Interactable, i = t.defaults;
1093
+ t.usePlugin(k), r.prototype.dropzone = function(o) {
1094
+ return function(a, s) {
1095
+ if (h.object(s)) {
1096
+ if (a.options.drop.enabled = s.enabled !== !1, s.listeners) {
1097
+ var l = Fe(s.listeners), u = Object.keys(l).reduce(function(p, g) {
1098
+ return p[/^(enter|leave)/.test(g) ? "drag".concat(g) : /^(activate|deactivate|move)/.test(g) ? "drop".concat(g) : g] = l[g], p;
1099
+ }, {}), c = a.options.drop.listeners;
1100
+ c && a.off(c), a.on(u), a.options.drop.listeners = u;
1101
+ }
1102
+ return h.func(s.ondrop) && a.on("drop", s.ondrop), h.func(s.ondropactivate) && a.on("dropactivate", s.ondropactivate), h.func(s.ondropdeactivate) && a.on("dropdeactivate", s.ondropdeactivate), h.func(s.ondragenter) && a.on("dragenter", s.ondragenter), h.func(s.ondragleave) && a.on("dragleave", s.ondragleave), h.func(s.ondropmove) && a.on("dropmove", s.ondropmove), /^(pointer|center)$/.test(s.overlap) ? a.options.drop.overlap = s.overlap : h.number(s.overlap) && (a.options.drop.overlap = Math.max(Math.min(1, s.overlap), 0)), "accept" in s && (a.options.drop.accept = s.accept), "checker" in s && (a.options.drop.checker = s.checker), a;
1103
+ }
1104
+ return h.bool(s) ? (a.options.drop.enabled = s, a) : a.options.drop;
1105
+ }(this, o);
1106
+ }, r.prototype.dropCheck = function(o, a, s, l, u, c) {
1107
+ return function(p, g, w, x, S, P, M) {
1108
+ var B = !1;
1109
+ if (!(M = M || p.getRect(P))) return !!p.options.drop.checker && p.options.drop.checker(g, w, B, p, P, x, S);
1110
+ var X = p.options.drop.overlap;
1111
+ if (X === "pointer") {
1112
+ var Z = rt(x, S, "drag"), $ = te(g);
1113
+ $.x += Z.x, $.y += Z.y;
1114
+ var G = $.x > M.left && $.x < M.right, Te = $.y > M.top && $.y < M.bottom;
1115
+ B = G && Te;
1116
+ }
1117
+ var ce = x.getRect(S);
1118
+ if (ce && X === "center") {
1119
+ var Pe = ce.left + ce.width / 2, Re = ce.top + ce.height / 2;
1120
+ B = Pe >= M.left && Pe <= M.right && Re >= M.top && Re <= M.bottom;
1121
+ }
1122
+ return ce && h.number(X) && (B = Math.max(0, Math.min(M.right, ce.right) - Math.max(M.left, ce.left)) * Math.max(0, Math.min(M.bottom, ce.bottom) - Math.max(M.top, ce.top)) / (ce.width * ce.height) >= X), p.options.drop.checker && (B = p.options.drop.checker(g, w, B, p, P, x, S)), B;
1123
+ }(this, o, a, s, l, u, c);
1124
+ }, n.dynamicDrop = function(o) {
1125
+ return h.bool(o) ? (t.dynamicDrop = o, n) : t.dynamicDrop;
1126
+ }, A(e.phaselessTypes, { dragenter: !0, dragleave: !0, dropactivate: !0, dropdeactivate: !0, dropmove: !0, drop: !0 }), e.methodDict.drop = "dropzone", t.dynamicDrop = !1, i.actions.drop = Tn.defaults;
1127
+ }, listeners: { "interactions:before-action-start": function(t) {
1128
+ var e = t.interaction;
1129
+ e.prepared.name === "drag" && (e.dropState = { cur: { dropzone: null, element: null }, prev: { dropzone: null, element: null }, rejected: null, events: null, activeDrops: [] });
1130
+ }, "interactions:after-action-start": function(t, e) {
1131
+ var n = t.interaction, r = (t.event, t.iEvent);
1132
+ if (n.prepared.name === "drag") {
1133
+ var i = n.dropState;
1134
+ i.activeDrops = [], i.events = {}, i.activeDrops = Vt(e, n.element), i.events = Gt(n, 0, r), i.events.activate && (_n(i.activeDrops, i.events.activate), e.fire("actions/drop:start", { interaction: n, dragEvent: r }));
1135
+ }
1136
+ }, "interactions:action-move": Sn, "interactions:after-action-move": function(t, e) {
1137
+ var n = t.interaction, r = t.iEvent;
1138
+ if (n.prepared.name === "drag") {
1139
+ var i = n.dropState;
1140
+ Ut(n, i.events), e.fire("actions/drop:move", { interaction: n, dragEvent: r }), i.events = {};
1141
+ }
1142
+ }, "interactions:action-end": function(t, e) {
1143
+ if (t.interaction.prepared.name === "drag") {
1144
+ var n = t.interaction, r = t.iEvent;
1145
+ Sn(t, e), Ut(n, n.dropState.events), e.fire("actions/drop:end", { interaction: n, dragEvent: r });
1146
+ }
1147
+ }, "interactions:stop": function(t) {
1148
+ var e = t.interaction;
1149
+ if (e.prepared.name === "drag") {
1150
+ var n = e.dropState;
1151
+ n && (n.activeDrops = null, n.events = null, n.cur.dropzone = null, n.cur.element = null, n.prev.dropzone = null, n.prev.element = null, n.rejected = !1);
1152
+ }
1153
+ } }, getActiveDrops: Vt, getDrop: En, getDropEvents: Gt, fireDropEvents: Ut, filterEventType: function(t) {
1154
+ return t.search("drag") === 0 || t.search("drop") === 0;
1155
+ }, defaults: { enabled: !1, accept: null, overlap: "pointer" } }, Mr = Tn;
1156
+ function qt(t) {
1157
+ var e = t.interaction, n = t.iEvent, r = t.phase;
1158
+ if (e.prepared.name === "gesture") {
1159
+ var i = e.pointers.map(function(u) {
1160
+ return u.pointer;
1161
+ }), o = r === "start", a = r === "end", s = e.interactable.options.deltaSource;
1162
+ if (n.touches = [i[0], i[1]], o) n.distance = Ee(i, s), n.box = ye(i), n.scale = 1, n.ds = 0, n.angle = Ie(i, s), n.da = 0, e.gesture.startDistance = n.distance, e.gesture.startAngle = n.angle;
1163
+ else if (a || e.pointers.length < 2) {
1164
+ var l = e.prevEvent;
1165
+ n.distance = l.distance, n.box = l.box, n.scale = l.scale, n.ds = 0, n.angle = l.angle, n.da = 0;
1166
+ } else n.distance = Ee(i, s), n.box = ye(i), n.scale = n.distance / e.gesture.startDistance, n.angle = Ie(i, s), n.ds = n.scale - e.gesture.scale, n.da = n.angle - e.gesture.angle;
1167
+ e.gesture.distance = n.distance, e.gesture.angle = n.angle, h.number(n.scale) && n.scale !== 1 / 0 && !isNaN(n.scale) && (e.gesture.scale = n.scale);
1168
+ }
1169
+ }
1170
+ var Kt = { id: "actions/gesture", before: ["actions/drag", "actions/resize"], install: function(t) {
1171
+ var e = t.actions, n = t.Interactable, r = t.defaults;
1172
+ n.prototype.gesturable = function(i) {
1173
+ return h.object(i) ? (this.options.gesture.enabled = i.enabled !== !1, this.setPerAction("gesture", i), this.setOnEvents("gesture", i), this) : h.bool(i) ? (this.options.gesture.enabled = i, this) : this.options.gesture;
1174
+ }, e.map.gesture = Kt, e.methodDict.gesture = "gesturable", r.actions.gesture = Kt.defaults;
1175
+ }, listeners: { "interactions:action-start": qt, "interactions:action-move": qt, "interactions:action-end": qt, "interactions:new": function(t) {
1176
+ t.interaction.gesture = { angle: 0, distance: 0, scale: 1, startAngle: 0, startDistance: 0 };
1177
+ }, "auto-start:check": function(t) {
1178
+ if (!(t.interaction.pointers.length < 2)) {
1179
+ var e = t.interactable.options.gesture;
1180
+ if (e && e.enabled) return t.action = { name: "gesture" }, !1;
1181
+ }
1182
+ } }, defaults: {}, getCursor: function() {
1183
+ return "";
1184
+ }, filterEventType: function(t) {
1185
+ return t.search("gesture") === 0;
1186
+ } }, Ir = Kt;
1187
+ function Pr(t, e, n, r, i, o, a) {
1188
+ if (!e) return !1;
1189
+ if (e === !0) {
1190
+ var s = h.number(o.width) ? o.width : o.right - o.left, l = h.number(o.height) ? o.height : o.bottom - o.top;
1191
+ if (a = Math.min(a, Math.abs((t === "left" || t === "right" ? s : l) / 2)), s < 0 && (t === "left" ? t = "right" : t === "right" && (t = "left")), l < 0 && (t === "top" ? t = "bottom" : t === "bottom" && (t = "top")), t === "left") {
1192
+ var u = s >= 0 ? o.left : o.right;
1193
+ return n.x < u + a;
1194
+ }
1195
+ if (t === "top") {
1196
+ var c = l >= 0 ? o.top : o.bottom;
1197
+ return n.y < c + a;
1198
+ }
1199
+ if (t === "right") return n.x > (s >= 0 ? o.right : o.left) - a;
1200
+ if (t === "bottom") return n.y > (l >= 0 ? o.bottom : o.top) - a;
1201
+ }
1202
+ return !!h.element(r) && (h.element(e) ? e === r : Oe(r, e, i));
1203
+ }
1204
+ function kn(t) {
1205
+ var e = t.iEvent, n = t.interaction;
1206
+ if (n.prepared.name === "resize" && n.resizeAxes) {
1207
+ var r = e;
1208
+ n.interactable.options.resize.square ? (n.resizeAxes === "y" ? r.delta.x = r.delta.y : r.delta.y = r.delta.x, r.axes = "xy") : (r.axes = n.resizeAxes, n.resizeAxes === "x" ? r.delta.y = 0 : n.resizeAxes === "y" && (r.delta.x = 0));
1209
+ }
1210
+ }
1211
+ var Ne, ot, He = { id: "actions/resize", before: ["actions/drag"], install: function(t) {
1212
+ var e = t.actions, n = t.browser, r = t.Interactable, i = t.defaults;
1213
+ He.cursors = function(o) {
1214
+ return o.isIe9 ? { x: "e-resize", y: "s-resize", xy: "se-resize", top: "n-resize", left: "w-resize", bottom: "s-resize", right: "e-resize", topleft: "se-resize", bottomright: "se-resize", topright: "ne-resize", bottomleft: "ne-resize" } : { x: "ew-resize", y: "ns-resize", xy: "nwse-resize", top: "ns-resize", left: "ew-resize", bottom: "ns-resize", right: "ew-resize", topleft: "nwse-resize", bottomright: "nwse-resize", topright: "nesw-resize", bottomleft: "nesw-resize" };
1215
+ }(n), He.defaultMargin = n.supportsTouch || n.supportsPointerEvent ? 20 : 10, r.prototype.resizable = function(o) {
1216
+ return function(a, s, l) {
1217
+ return h.object(s) ? (a.options.resize.enabled = s.enabled !== !1, a.setPerAction("resize", s), a.setOnEvents("resize", s), h.string(s.axis) && /^x$|^y$|^xy$/.test(s.axis) ? a.options.resize.axis = s.axis : s.axis === null && (a.options.resize.axis = l.defaults.actions.resize.axis), h.bool(s.preserveAspectRatio) ? a.options.resize.preserveAspectRatio = s.preserveAspectRatio : h.bool(s.square) && (a.options.resize.square = s.square), a) : h.bool(s) ? (a.options.resize.enabled = s, a) : a.options.resize;
1218
+ }(this, o, t);
1219
+ }, e.map.resize = He, e.methodDict.resize = "resizable", i.actions.resize = He.defaults;
1220
+ }, listeners: { "interactions:new": function(t) {
1221
+ t.interaction.resizeAxes = "xy";
1222
+ }, "interactions:action-start": function(t) {
1223
+ (function(e) {
1224
+ var n = e.iEvent, r = e.interaction;
1225
+ if (r.prepared.name === "resize" && r.prepared.edges) {
1226
+ var i = n, o = r.rect;
1227
+ r._rects = { start: A({}, o), corrected: A({}, o), previous: A({}, o), delta: { left: 0, right: 0, width: 0, top: 0, bottom: 0, height: 0 } }, i.edges = r.prepared.edges, i.rect = r._rects.corrected, i.deltaRect = r._rects.delta;
1228
+ }
1229
+ })(t), kn(t);
1230
+ }, "interactions:action-move": function(t) {
1231
+ (function(e) {
1232
+ var n = e.iEvent, r = e.interaction;
1233
+ if (r.prepared.name === "resize" && r.prepared.edges) {
1234
+ var i = n, o = r.interactable.options.resize.invert, a = o === "reposition" || o === "negate", s = r.rect, l = r._rects, u = l.start, c = l.corrected, p = l.delta, g = l.previous;
1235
+ if (A(g, c), a) {
1236
+ if (A(c, s), o === "reposition") {
1237
+ if (c.top > c.bottom) {
1238
+ var w = c.top;
1239
+ c.top = c.bottom, c.bottom = w;
1240
+ }
1241
+ if (c.left > c.right) {
1242
+ var x = c.left;
1243
+ c.left = c.right, c.right = x;
1244
+ }
1245
+ }
1246
+ } else c.top = Math.min(s.top, u.bottom), c.bottom = Math.max(s.bottom, u.top), c.left = Math.min(s.left, u.right), c.right = Math.max(s.right, u.left);
1247
+ for (var S in c.width = c.right - c.left, c.height = c.bottom - c.top, c) p[S] = c[S] - g[S];
1248
+ i.edges = r.prepared.edges, i.rect = c, i.deltaRect = p;
1249
+ }
1250
+ })(t), kn(t);
1251
+ }, "interactions:action-end": function(t) {
1252
+ var e = t.iEvent, n = t.interaction;
1253
+ if (n.prepared.name === "resize" && n.prepared.edges) {
1254
+ var r = e;
1255
+ r.edges = n.prepared.edges, r.rect = n._rects.corrected, r.deltaRect = n._rects.delta;
1256
+ }
1257
+ }, "auto-start:check": function(t) {
1258
+ var e = t.interaction, n = t.interactable, r = t.element, i = t.rect, o = t.buttons;
1259
+ if (i) {
1260
+ var a = A({}, e.coords.cur.page), s = n.options.resize;
1261
+ if (s && s.enabled && (!e.pointerIsDown || !/mouse|pointer/.test(e.pointerType) || (o & s.mouseButtons) != 0)) {
1262
+ if (h.object(s.edges)) {
1263
+ var l = { left: !1, right: !1, top: !1, bottom: !1 };
1264
+ for (var u in l) l[u] = Pr(u, s.edges[u], a, e._latestPointer.eventTarget, r, i, s.margin || He.defaultMargin);
1265
+ l.left = l.left && !l.right, l.top = l.top && !l.bottom, (l.left || l.right || l.top || l.bottom) && (t.action = { name: "resize", edges: l });
1266
+ } else {
1267
+ var c = s.axis !== "y" && a.x > i.right - He.defaultMargin, p = s.axis !== "x" && a.y > i.bottom - He.defaultMargin;
1268
+ (c || p) && (t.action = { name: "resize", axes: (c ? "x" : "") + (p ? "y" : "") });
1269
+ }
1270
+ return !t.action && void 0;
1271
+ }
1272
+ }
1273
+ } }, defaults: { square: !1, preserveAspectRatio: !1, axis: "xy", margin: NaN, edges: null, invert: "none" }, cursors: null, getCursor: function(t) {
1274
+ var e = t.edges, n = t.axis, r = t.name, i = He.cursors, o = null;
1275
+ if (n) o = i[r + n];
1276
+ else if (e) {
1277
+ for (var a = "", s = 0, l = ["top", "bottom", "left", "right"]; s < l.length; s++) {
1278
+ var u = l[s];
1279
+ e[u] && (a += u);
1280
+ }
1281
+ o = i[a];
1282
+ }
1283
+ return o;
1284
+ }, filterEventType: function(t) {
1285
+ return t.search("resize") === 0;
1286
+ }, defaultMargin: null }, Cr = He, Rr = { id: "actions", install: function(t) {
1287
+ t.usePlugin(Ir), t.usePlugin(Cr), t.usePlugin(k), t.usePlugin(Mr);
1288
+ } }, Dn = 0, Ze = { request: function(t) {
1289
+ return Ne(t);
1290
+ }, cancel: function(t) {
1291
+ return ot(t);
1292
+ }, init: function(t) {
1293
+ if (Ne = t.requestAnimationFrame, ot = t.cancelAnimationFrame, !Ne) for (var e = ["ms", "moz", "webkit", "o"], n = 0; n < e.length; n++) {
1294
+ var r = e[n];
1295
+ Ne = t["".concat(r, "RequestAnimationFrame")], ot = t["".concat(r, "CancelAnimationFrame")] || t["".concat(r, "CancelRequestAnimationFrame")];
1296
+ }
1297
+ Ne = Ne && Ne.bind(t), ot = ot && ot.bind(t), Ne || (Ne = function(i) {
1298
+ var o = Date.now(), a = Math.max(0, 16 - (o - Dn)), s = t.setTimeout(function() {
1299
+ i(o + a);
1300
+ }, a);
1301
+ return Dn = o + a, s;
1302
+ }, ot = function(i) {
1303
+ return clearTimeout(i);
1304
+ });
1305
+ } }, H = { defaults: { enabled: !1, margin: 60, container: null, speed: 300 }, now: Date.now, interaction: null, i: 0, x: 0, y: 0, isScrolling: !1, prevTime: 0, margin: 0, speed: 0, start: function(t) {
1306
+ H.isScrolling = !0, Ze.cancel(H.i), t.autoScroll = H, H.interaction = t, H.prevTime = H.now(), H.i = Ze.request(H.scroll);
1307
+ }, stop: function() {
1308
+ H.isScrolling = !1, H.interaction && (H.interaction.autoScroll = null), Ze.cancel(H.i);
1309
+ }, scroll: function() {
1310
+ var t = H.interaction, e = t.interactable, n = t.element, r = t.prepared.name, i = e.options[r].autoScroll, o = zn(i.container, e, n), a = H.now(), s = (a - H.prevTime) / 1e3, l = i.speed * s;
1311
+ if (l >= 1) {
1312
+ var u = { x: H.x * l, y: H.y * l };
1313
+ if (u.x || u.y) {
1314
+ var c = On(o);
1315
+ h.window(o) ? o.scrollBy(u.x, u.y) : o && (o.scrollLeft += u.x, o.scrollTop += u.y);
1316
+ var p = On(o), g = { x: p.x - c.x, y: p.y - c.y };
1317
+ (g.x || g.y) && e.fire({ type: "autoscroll", target: n, interactable: e, delta: g, interaction: t, container: o });
1318
+ }
1319
+ H.prevTime = a;
1320
+ }
1321
+ H.isScrolling && (Ze.cancel(H.i), H.i = Ze.request(H.scroll));
1322
+ }, check: function(t, e) {
1323
+ var n;
1324
+ return (n = t.options[e].autoScroll) == null ? void 0 : n.enabled;
1325
+ }, onInteractionMove: function(t) {
1326
+ var e = t.interaction, n = t.pointer;
1327
+ if (e.interacting() && H.check(e.interactable, e.prepared.name)) if (e.simulation) H.x = H.y = 0;
1328
+ else {
1329
+ var r, i, o, a, s = e.interactable, l = e.element, u = e.prepared.name, c = s.options[u].autoScroll, p = zn(c.container, s, l);
1330
+ if (h.window(p)) a = n.clientX < H.margin, r = n.clientY < H.margin, i = n.clientX > p.innerWidth - H.margin, o = n.clientY > p.innerHeight - H.margin;
1331
+ else {
1332
+ var g = Xe(p);
1333
+ a = n.clientX < g.left + H.margin, r = n.clientY < g.top + H.margin, i = n.clientX > g.right - H.margin, o = n.clientY > g.bottom - H.margin;
1334
+ }
1335
+ H.x = i ? 1 : a ? -1 : 0, H.y = o ? 1 : r ? -1 : 0, H.isScrolling || (H.margin = c.margin, H.speed = c.speed, H.start(e));
1336
+ }
1337
+ } };
1338
+ function zn(t, e, n) {
1339
+ return (h.string(t) ? Ve(t, e, n) : t) || E(n);
1340
+ }
1341
+ function On(t) {
1342
+ return h.window(t) && (t = window.document.body), { x: t.scrollLeft, y: t.scrollTop };
1343
+ }
1344
+ var Ar = { id: "auto-scroll", install: function(t) {
1345
+ var e = t.defaults, n = t.actions;
1346
+ t.autoScroll = H, H.now = function() {
1347
+ return t.now();
1348
+ }, n.phaselessTypes.autoscroll = !0, e.perAction.autoScroll = H.defaults;
1349
+ }, listeners: { "interactions:new": function(t) {
1350
+ t.interaction.autoScroll = null;
1351
+ }, "interactions:destroy": function(t) {
1352
+ t.interaction.autoScroll = null, H.stop(), H.interaction && (H.interaction = null);
1353
+ }, "interactions:stop": H.stop, "interactions:action-move": function(t) {
1354
+ return H.onInteractionMove(t);
1355
+ } } }, Br = Ar;
1356
+ function wt(t, e) {
1357
+ var n = !1;
1358
+ return function() {
1359
+ return n || (R.console.warn(e), n = !0), t.apply(this, arguments);
1360
+ };
1361
+ }
1362
+ function Jt(t, e) {
1363
+ return t.name = e.name, t.axis = e.axis, t.edges = e.edges, t;
1364
+ }
1365
+ function jr(t) {
1366
+ return h.bool(t) ? (this.options.styleCursor = t, this) : t === null ? (delete this.options.styleCursor, this) : this.options.styleCursor;
1367
+ }
1368
+ function Fr(t) {
1369
+ return h.func(t) ? (this.options.actionChecker = t, this) : t === null ? (delete this.options.actionChecker, this) : this.options.actionChecker;
1370
+ }
1371
+ var Lr = { id: "auto-start/interactableMethods", install: function(t) {
1372
+ var e = t.Interactable;
1373
+ e.prototype.getAction = function(n, r, i, o) {
1374
+ var a = function(s, l, u, c, p) {
1375
+ var g = s.getRect(c), w = l.buttons || { 0: 1, 1: 4, 3: 8, 4: 16 }[l.button], x = { action: null, interactable: s, interaction: u, element: c, rect: g, buttons: w };
1376
+ return p.fire("auto-start:check", x), x.action;
1377
+ }(this, r, i, o, t);
1378
+ return this.options.actionChecker ? this.options.actionChecker(n, r, a, this, o, i) : a;
1379
+ }, e.prototype.ignoreFrom = wt(function(n) {
1380
+ return this._backCompatOption("ignoreFrom", n);
1381
+ }, "Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."), e.prototype.allowFrom = wt(function(n) {
1382
+ return this._backCompatOption("allowFrom", n);
1383
+ }, "Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."), e.prototype.actionChecker = Fr, e.prototype.styleCursor = jr;
1384
+ } };
1385
+ function Mn(t, e, n, r, i) {
1386
+ return e.testIgnoreAllow(e.options[t.name], n, r) && e.options[t.name].enabled && It(e, n, t, i) ? t : null;
1387
+ }
1388
+ function $r(t, e, n, r, i, o, a) {
1389
+ for (var s = 0, l = r.length; s < l; s++) {
1390
+ var u = r[s], c = i[s], p = u.getAction(e, n, t, c);
1391
+ if (p) {
1392
+ var g = Mn(p, u, c, o, a);
1393
+ if (g) return { action: g, interactable: u, element: c };
1394
+ }
1395
+ }
1396
+ return { action: null, interactable: null, element: null };
1397
+ }
1398
+ function In(t, e, n, r, i) {
1399
+ var o = [], a = [], s = r;
1400
+ function l(c) {
1401
+ o.push(c), a.push(s);
1402
+ }
1403
+ for (; h.element(s); ) {
1404
+ o = [], a = [], i.interactables.forEachMatch(s, l);
1405
+ var u = $r(t, e, n, o, a, r, i);
1406
+ if (u.action && !u.interactable.options[u.action.name].manualStart) return u;
1407
+ s = de(s);
1408
+ }
1409
+ return { action: null, interactable: null, element: null };
1410
+ }
1411
+ function Pn(t, e, n) {
1412
+ var r = e.action, i = e.interactable, o = e.element;
1413
+ r = r || { name: null }, t.interactable = i, t.element = o, Jt(t.prepared, r), t.rect = i && r.name ? i.getRect(o) : null, Rn(t, n), n.fire("autoStart:prepared", { interaction: t });
1414
+ }
1415
+ function It(t, e, n, r) {
1416
+ var i = t.options, o = i[n.name].max, a = i[n.name].maxPerElement, s = r.autoStart.maxInteractions, l = 0, u = 0, c = 0;
1417
+ if (!(o && a && s)) return !1;
1418
+ for (var p = 0, g = r.interactions.list; p < g.length; p++) {
1419
+ var w = g[p], x = w.prepared.name;
1420
+ if (w.interacting() && (++l >= s || w.interactable === t && ((u += x === n.name ? 1 : 0) >= o || w.element === e && (c++, x === n.name && c >= a))))
1421
+ return !1;
1422
+ }
1423
+ return s > 0;
1424
+ }
1425
+ function Cn(t, e) {
1426
+ return h.number(t) ? (e.autoStart.maxInteractions = t, this) : e.autoStart.maxInteractions;
1427
+ }
1428
+ function Zt(t, e, n) {
1429
+ var r = n.autoStart.cursorElement;
1430
+ r && r !== t && (r.style.cursor = ""), t.ownerDocument.documentElement.style.cursor = e, t.style.cursor = e, n.autoStart.cursorElement = e ? t : null;
1431
+ }
1432
+ function Rn(t, e) {
1433
+ var n = t.interactable, r = t.element, i = t.prepared;
1434
+ if (t.pointerType === "mouse" && n && n.options.styleCursor) {
1435
+ var o = "";
1436
+ if (i.name) {
1437
+ var a = n.options[i.name].cursorChecker;
1438
+ o = h.func(a) ? a(i, n, r, t._interacting) : e.actions.map[i.name].getCursor(i);
1439
+ }
1440
+ Zt(t.element, o || "", e);
1441
+ } else e.autoStart.cursorElement && Zt(e.autoStart.cursorElement, "", e);
1442
+ }
1443
+ var Nr = { id: "auto-start/base", before: ["actions"], install: function(t) {
1444
+ var e = t.interactStatic, n = t.defaults;
1445
+ t.usePlugin(Lr), n.base.actionChecker = null, n.base.styleCursor = !0, A(n.perAction, { manualStart: !1, max: 1 / 0, maxPerElement: 1, allowFrom: null, ignoreFrom: null, mouseButtons: 1 }), e.maxInteractions = function(r) {
1446
+ return Cn(r, t);
1447
+ }, t.autoStart = { maxInteractions: 1 / 0, withinInteractionLimit: It, cursorElement: null };
1448
+ }, listeners: { "interactions:down": function(t, e) {
1449
+ var n = t.interaction, r = t.pointer, i = t.event, o = t.eventTarget;
1450
+ n.interacting() || Pn(n, In(n, r, i, o, e), e);
1451
+ }, "interactions:move": function(t, e) {
1452
+ (function(n, r) {
1453
+ var i = n.interaction, o = n.pointer, a = n.event, s = n.eventTarget;
1454
+ i.pointerType !== "mouse" || i.pointerIsDown || i.interacting() || Pn(i, In(i, o, a, s, r), r);
1455
+ })(t, e), function(n, r) {
1456
+ var i = n.interaction;
1457
+ if (i.pointerIsDown && !i.interacting() && i.pointerWasMoved && i.prepared.name) {
1458
+ r.fire("autoStart:before-start", n);
1459
+ var o = i.interactable, a = i.prepared.name;
1460
+ a && o && (o.options[a].manualStart || !It(o, i.element, i.prepared, r) ? i.stop() : (i.start(i.prepared, o, i.element), Rn(i, r)));
1461
+ }
1462
+ }(t, e);
1463
+ }, "interactions:stop": function(t, e) {
1464
+ var n = t.interaction, r = n.interactable;
1465
+ r && r.options.styleCursor && Zt(n.element, "", e);
1466
+ } }, maxInteractions: Cn, withinInteractionLimit: It, validateAction: Mn }, Qt = Nr, Hr = { id: "auto-start/dragAxis", listeners: { "autoStart:before-start": function(t, e) {
1467
+ var n = t.interaction, r = t.eventTarget, i = t.dx, o = t.dy;
1468
+ if (n.prepared.name === "drag") {
1469
+ var a = Math.abs(i), s = Math.abs(o), l = n.interactable.options.drag, u = l.startAxis, c = a > s ? "x" : a < s ? "y" : "xy";
1470
+ if (n.prepared.axis = l.lockAxis === "start" ? c[0] : l.lockAxis, c !== "xy" && u !== "xy" && u !== c) {
1471
+ n.prepared.name = null;
1472
+ for (var p = r, g = function(x) {
1473
+ if (x !== n.interactable) {
1474
+ var S = n.interactable.options.drag;
1475
+ if (!S.manualStart && x.testIgnoreAllow(S, p, r)) {
1476
+ var P = x.getAction(n.downPointer, n.downEvent, n, p);
1477
+ if (P && P.name === "drag" && function(M, B) {
1478
+ if (!B) return !1;
1479
+ var X = B.options.drag.startAxis;
1480
+ return M === "xy" || X === "xy" || X === M;
1481
+ }(c, x) && Qt.validateAction(P, x, p, r, e)) return x;
1482
+ }
1483
+ }
1484
+ }; h.element(p); ) {
1485
+ var w = e.interactables.forEachMatch(p, g);
1486
+ if (w) {
1487
+ n.prepared.name = "drag", n.interactable = w, n.element = p;
1488
+ break;
1489
+ }
1490
+ p = de(p);
1491
+ }
1492
+ }
1493
+ }
1494
+ } } };
1495
+ function en(t) {
1496
+ var e = t.prepared && t.prepared.name;
1497
+ if (!e) return null;
1498
+ var n = t.interactable.options;
1499
+ return n[e].hold || n[e].delay;
1500
+ }
1501
+ var Wr = { id: "auto-start/hold", install: function(t) {
1502
+ var e = t.defaults;
1503
+ t.usePlugin(Qt), e.perAction.hold = 0, e.perAction.delay = 0;
1504
+ }, listeners: { "interactions:new": function(t) {
1505
+ t.interaction.autoStartHoldTimer = null;
1506
+ }, "autoStart:prepared": function(t) {
1507
+ var e = t.interaction, n = en(e);
1508
+ n > 0 && (e.autoStartHoldTimer = setTimeout(function() {
1509
+ e.start(e.prepared, e.interactable, e.element);
1510
+ }, n));
1511
+ }, "interactions:move": function(t) {
1512
+ var e = t.interaction, n = t.duplicate;
1513
+ e.autoStartHoldTimer && e.pointerWasMoved && !n && (clearTimeout(e.autoStartHoldTimer), e.autoStartHoldTimer = null);
1514
+ }, "autoStart:before-start": function(t) {
1515
+ var e = t.interaction;
1516
+ en(e) > 0 && (e.prepared.name = null);
1517
+ } }, getHoldDuration: en }, Yr = Wr, Xr = { id: "auto-start", install: function(t) {
1518
+ t.usePlugin(Qt), t.usePlugin(Yr), t.usePlugin(Hr);
1519
+ } }, Vr = function(t) {
1520
+ return /^(always|never|auto)$/.test(t) ? (this.options.preventDefault = t, this) : h.bool(t) ? (this.options.preventDefault = t ? "always" : "never", this) : this.options.preventDefault;
1521
+ };
1522
+ function Gr(t) {
1523
+ var e = t.interaction, n = t.event;
1524
+ e.interactable && e.interactable.checkAndPreventDefault(n);
1525
+ }
1526
+ var An = { id: "core/interactablePreventDefault", install: function(t) {
1527
+ var e = t.Interactable;
1528
+ e.prototype.preventDefault = Vr, e.prototype.checkAndPreventDefault = function(n) {
1529
+ return function(r, i, o) {
1530
+ var a = r.options.preventDefault;
1531
+ if (a !== "never") if (a !== "always") {
1532
+ if (i.events.supportsPassive && /^touch(start|move)$/.test(o.type)) {
1533
+ var s = E(o.target).document, l = i.getDocOptions(s);
1534
+ if (!l || !l.events || l.events.passive !== !1) return;
1535
+ }
1536
+ /^(mouse|pointer|touch)*(down|start)/i.test(o.type) || h.element(o.target) && K(o.target, "input,select,textarea,[contenteditable=true],[contenteditable=true] *") || o.preventDefault();
1537
+ } else o.preventDefault();
1538
+ }(this, t, n);
1539
+ }, t.interactions.docEvents.push({ type: "dragstart", listener: function(n) {
1540
+ for (var r = 0, i = t.interactions.list; r < i.length; r++) {
1541
+ var o = i[r];
1542
+ if (o.element && (o.element === n.target || W(o.element, n.target))) return void o.interactable.checkAndPreventDefault(n);
1543
+ }
1544
+ } });
1545
+ }, listeners: ["down", "move", "up", "cancel"].reduce(function(t, e) {
1546
+ return t["interactions:".concat(e)] = Gr, t;
1547
+ }, {}) };
1548
+ function Pt(t, e) {
1549
+ if (e.phaselessTypes[t]) return !0;
1550
+ for (var n in e.map) if (t.indexOf(n) === 0 && t.substr(n.length) in e.phases) return !0;
1551
+ return !1;
1552
+ }
1553
+ function ht(t) {
1554
+ var e = {};
1555
+ for (var n in t) {
1556
+ var r = t[n];
1557
+ h.plainObject(r) ? e[n] = ht(r) : h.array(r) ? e[n] = ft(r) : e[n] = r;
1558
+ }
1559
+ return e;
1560
+ }
1561
+ var tn = function() {
1562
+ function t(e) {
1563
+ v(this, t), this.states = [], this.startOffset = { left: 0, right: 0, top: 0, bottom: 0 }, this.startDelta = void 0, this.result = void 0, this.endResult = void 0, this.startEdges = void 0, this.edges = void 0, this.interaction = void 0, this.interaction = e, this.result = Ct(), this.edges = { left: !1, right: !1, top: !1, bottom: !1 };
1564
+ }
1565
+ return T(t, [{ key: "start", value: function(e, n) {
1566
+ var r, i, o = e.phase, a = this.interaction, s = function(u) {
1567
+ var c = u.interactable.options[u.prepared.name], p = c.modifiers;
1568
+ return p && p.length ? p : ["snap", "snapSize", "snapEdges", "restrict", "restrictEdges", "restrictSize"].map(function(g) {
1569
+ var w = c[g];
1570
+ return w && w.enabled && { options: w, methods: w._methods };
1571
+ }).filter(function(g) {
1572
+ return !!g;
1573
+ });
1574
+ }(a);
1575
+ this.prepareStates(s), this.startEdges = A({}, a.edges), this.edges = A({}, this.startEdges), this.startOffset = (r = a.rect, i = n, r ? { left: i.x - r.left, top: i.y - r.top, right: r.right - i.x, bottom: r.bottom - i.y } : { left: 0, top: 0, right: 0, bottom: 0 }), this.startDelta = { x: 0, y: 0 };
1576
+ var l = this.fillArg({ phase: o, pageCoords: n, preEnd: !1 });
1577
+ return this.result = Ct(), this.startAll(l), this.result = this.setAll(l);
1578
+ } }, { key: "fillArg", value: function(e) {
1579
+ var n = this.interaction;
1580
+ return e.interaction = n, e.interactable = n.interactable, e.element = n.element, e.rect || (e.rect = n.rect), e.edges || (e.edges = this.startEdges), e.startOffset = this.startOffset, e;
1581
+ } }, { key: "startAll", value: function(e) {
1582
+ for (var n = 0, r = this.states; n < r.length; n++) {
1583
+ var i = r[n];
1584
+ i.methods.start && (e.state = i, i.methods.start(e));
1585
+ }
1586
+ } }, { key: "setAll", value: function(e) {
1587
+ var n = e.phase, r = e.preEnd, i = e.skipModifiers, o = e.rect, a = e.edges;
1588
+ e.coords = A({}, e.pageCoords), e.rect = A({}, o), e.edges = A({}, a);
1589
+ for (var s = i ? this.states.slice(i) : this.states, l = Ct(e.coords, e.rect), u = 0; u < s.length; u++) {
1590
+ var c, p = s[u], g = p.options, w = A({}, e.coords), x = null;
1591
+ (c = p.methods) != null && c.set && this.shouldDo(g, r, n) && (e.state = p, x = p.methods.set(e), nt(e.edges, e.rect, { x: e.coords.x - w.x, y: e.coords.y - w.y })), l.eventProps.push(x);
1592
+ }
1593
+ A(this.edges, e.edges), l.delta.x = e.coords.x - e.pageCoords.x, l.delta.y = e.coords.y - e.pageCoords.y, l.rectDelta.left = e.rect.left - o.left, l.rectDelta.right = e.rect.right - o.right, l.rectDelta.top = e.rect.top - o.top, l.rectDelta.bottom = e.rect.bottom - o.bottom;
1594
+ var S = this.result.coords, P = this.result.rect;
1595
+ if (S && P) {
1596
+ var M = l.rect.left !== P.left || l.rect.right !== P.right || l.rect.top !== P.top || l.rect.bottom !== P.bottom;
1597
+ l.changed = M || S.x !== l.coords.x || S.y !== l.coords.y;
1598
+ }
1599
+ return l;
1600
+ } }, { key: "applyToInteraction", value: function(e) {
1601
+ var n = this.interaction, r = e.phase, i = n.coords.cur, o = n.coords.start, a = this.result, s = this.startDelta, l = a.delta;
1602
+ r === "start" && A(this.startDelta, a.delta);
1603
+ for (var u = 0, c = [[o, s], [i, l]]; u < c.length; u++) {
1604
+ var p = c[u], g = p[0], w = p[1];
1605
+ g.page.x += w.x, g.page.y += w.y, g.client.x += w.x, g.client.y += w.y;
1606
+ }
1607
+ var x = this.result.rectDelta, S = e.rect || n.rect;
1608
+ S.left += x.left, S.right += x.right, S.top += x.top, S.bottom += x.bottom, S.width = S.right - S.left, S.height = S.bottom - S.top;
1609
+ } }, { key: "setAndApply", value: function(e) {
1610
+ var n = this.interaction, r = e.phase, i = e.preEnd, o = e.skipModifiers, a = this.setAll(this.fillArg({ preEnd: i, phase: r, pageCoords: e.modifiedCoords || n.coords.cur.page }));
1611
+ if (this.result = a, !a.changed && (!o || o < this.states.length) && n.interacting()) return !1;
1612
+ if (e.modifiedCoords) {
1613
+ var s = n.coords.cur.page, l = { x: e.modifiedCoords.x - s.x, y: e.modifiedCoords.y - s.y };
1614
+ a.coords.x += l.x, a.coords.y += l.y, a.delta.x += l.x, a.delta.y += l.y;
1615
+ }
1616
+ this.applyToInteraction(e);
1617
+ } }, { key: "beforeEnd", value: function(e) {
1618
+ var n = e.interaction, r = e.event, i = this.states;
1619
+ if (i && i.length) {
1620
+ for (var o = !1, a = 0; a < i.length; a++) {
1621
+ var s = i[a];
1622
+ e.state = s;
1623
+ var l = s.options, u = s.methods, c = u.beforeEnd && u.beforeEnd(e);
1624
+ if (c) return this.endResult = c, !1;
1625
+ o = o || !o && this.shouldDo(l, !0, e.phase, !0);
1626
+ }
1627
+ o && n.move({ event: r, preEnd: !0 });
1628
+ }
1629
+ } }, { key: "stop", value: function(e) {
1630
+ var n = e.interaction;
1631
+ if (this.states && this.states.length) {
1632
+ var r = A({ states: this.states, interactable: n.interactable, element: n.element, rect: null }, e);
1633
+ this.fillArg(r);
1634
+ for (var i = 0, o = this.states; i < o.length; i++) {
1635
+ var a = o[i];
1636
+ r.state = a, a.methods.stop && a.methods.stop(r);
1637
+ }
1638
+ this.states = null, this.endResult = null;
1639
+ }
1640
+ } }, { key: "prepareStates", value: function(e) {
1641
+ this.states = [];
1642
+ for (var n = 0; n < e.length; n++) {
1643
+ var r = e[n], i = r.options, o = r.methods, a = r.name;
1644
+ this.states.push({ options: i, methods: o, index: n, name: a });
1645
+ }
1646
+ return this.states;
1647
+ } }, { key: "restoreInteractionCoords", value: function(e) {
1648
+ var n = e.interaction, r = n.coords, i = n.rect, o = n.modification;
1649
+ if (o.result) {
1650
+ for (var a = o.startDelta, s = o.result, l = s.delta, u = s.rectDelta, c = 0, p = [[r.start, a], [r.cur, l]]; c < p.length; c++) {
1651
+ var g = p[c], w = g[0], x = g[1];
1652
+ w.page.x -= x.x, w.page.y -= x.y, w.client.x -= x.x, w.client.y -= x.y;
1653
+ }
1654
+ i.left -= u.left, i.right -= u.right, i.top -= u.top, i.bottom -= u.bottom;
1655
+ }
1656
+ } }, { key: "shouldDo", value: function(e, n, r, i) {
1657
+ return !(!e || e.enabled === !1 || i && !e.endOnly || e.endOnly && !n || r === "start" && !e.setStart);
1658
+ } }, { key: "copyFrom", value: function(e) {
1659
+ this.startOffset = e.startOffset, this.startDelta = e.startDelta, this.startEdges = e.startEdges, this.edges = e.edges, this.states = e.states.map(function(n) {
1660
+ return ht(n);
1661
+ }), this.result = Ct(A({}, e.result.coords), A({}, e.result.rect));
1662
+ } }, { key: "destroy", value: function() {
1663
+ for (var e in this) this[e] = null;
1664
+ } }]), t;
1665
+ }();
1666
+ function Ct(t, e) {
1667
+ return { rect: e, coords: t, delta: { x: 0, y: 0 }, rectDelta: { left: 0, right: 0, top: 0, bottom: 0 }, eventProps: [], changed: !0 };
1668
+ }
1669
+ function Qe(t, e) {
1670
+ var n = t.defaults, r = { start: t.start, set: t.set, beforeEnd: t.beforeEnd, stop: t.stop }, i = function(o) {
1671
+ var a = o || {};
1672
+ for (var s in a.enabled = a.enabled !== !1, n) s in a || (a[s] = n[s]);
1673
+ var l = { options: a, methods: r, name: e, enable: function() {
1674
+ return a.enabled = !0, l;
1675
+ }, disable: function() {
1676
+ return a.enabled = !1, l;
1677
+ } };
1678
+ return l;
1679
+ };
1680
+ return e && typeof e == "string" && (i._defaults = n, i._methods = r), i;
1681
+ }
1682
+ function _t(t) {
1683
+ var e = t.iEvent, n = t.interaction.modification.result;
1684
+ n && (e.modifiers = n.eventProps);
1685
+ }
1686
+ var Ur = { id: "modifiers/base", before: ["actions"], install: function(t) {
1687
+ t.defaults.perAction.modifiers = [];
1688
+ }, listeners: { "interactions:new": function(t) {
1689
+ var e = t.interaction;
1690
+ e.modification = new tn(e);
1691
+ }, "interactions:before-action-start": function(t) {
1692
+ var e = t.interaction, n = t.interaction.modification;
1693
+ n.start(t, e.coords.start.page), e.edges = n.edges, n.applyToInteraction(t);
1694
+ }, "interactions:before-action-move": function(t) {
1695
+ var e = t.interaction, n = e.modification, r = n.setAndApply(t);
1696
+ return e.edges = n.edges, r;
1697
+ }, "interactions:before-action-end": function(t) {
1698
+ var e = t.interaction, n = e.modification, r = n.beforeEnd(t);
1699
+ return e.edges = n.startEdges, r;
1700
+ }, "interactions:action-start": _t, "interactions:action-move": _t, "interactions:action-end": _t, "interactions:after-action-start": function(t) {
1701
+ return t.interaction.modification.restoreInteractionCoords(t);
1702
+ }, "interactions:after-action-move": function(t) {
1703
+ return t.interaction.modification.restoreInteractionCoords(t);
1704
+ }, "interactions:stop": function(t) {
1705
+ return t.interaction.modification.stop(t);
1706
+ } } }, Bn = Ur, jn = { base: { preventDefault: "auto", deltaSource: "page" }, perAction: { enabled: !1, origin: { x: 0, y: 0 } }, actions: {} }, nn = function(t) {
1707
+ q(n, t);
1708
+ var e = ie(n);
1709
+ function n(r, i, o, a, s, l, u) {
1710
+ var c;
1711
+ v(this, n), (c = e.call(this, r)).relatedTarget = null, c.screenX = void 0, c.screenY = void 0, c.button = void 0, c.buttons = void 0, c.ctrlKey = void 0, c.shiftKey = void 0, c.altKey = void 0, c.metaKey = void 0, c.page = void 0, c.client = void 0, c.delta = void 0, c.rect = void 0, c.x0 = void 0, c.y0 = void 0, c.t0 = void 0, c.dt = void 0, c.duration = void 0, c.clientX0 = void 0, c.clientY0 = void 0, c.velocity = void 0, c.speed = void 0, c.swipe = void 0, c.axes = void 0, c.preEnd = void 0, s = s || r.element;
1712
+ var p = r.interactable, g = (p && p.options || jn).deltaSource, w = rt(p, s, o), x = a === "start", S = a === "end", P = x ? re(c) : r.prevEvent, M = x ? r.coords.start : S ? { page: P.page, client: P.client, timeStamp: r.coords.cur.timeStamp } : r.coords.cur;
1713
+ return c.page = A({}, M.page), c.client = A({}, M.client), c.rect = A({}, r.rect), c.timeStamp = M.timeStamp, S || (c.page.x -= w.x, c.page.y -= w.y, c.client.x -= w.x, c.client.y -= w.y), c.ctrlKey = i.ctrlKey, c.altKey = i.altKey, c.shiftKey = i.shiftKey, c.metaKey = i.metaKey, c.button = i.button, c.buttons = i.buttons, c.target = s, c.currentTarget = s, c.preEnd = l, c.type = u || o + (a || ""), c.interactable = p, c.t0 = x ? r.pointers[r.pointers.length - 1].downTime : P.t0, c.x0 = r.coords.start.page.x - w.x, c.y0 = r.coords.start.page.y - w.y, c.clientX0 = r.coords.start.client.x - w.x, c.clientY0 = r.coords.start.client.y - w.y, c.delta = x || S ? { x: 0, y: 0 } : { x: c[g].x - P[g].x, y: c[g].y - P[g].y }, c.dt = r.coords.delta.timeStamp, c.duration = c.timeStamp - c.t0, c.velocity = A({}, r.coords.velocity[g]), c.speed = Ue(c.velocity.x, c.velocity.y), c.swipe = S || a === "inertiastart" ? c.getSwipe() : null, c;
1714
+ }
1715
+ return T(n, [{ key: "getSwipe", value: function() {
1716
+ var r = this._interaction;
1717
+ if (r.prevEvent.speed < 600 || this.timeStamp - r.prevEvent.timeStamp > 150) return null;
1718
+ var i = 180 * Math.atan2(r.prevEvent.velocityY, r.prevEvent.velocityX) / Math.PI;
1719
+ i < 0 && (i += 360);
1720
+ var o = 112.5 <= i && i < 247.5, a = 202.5 <= i && i < 337.5;
1721
+ return { up: a, down: !a && 22.5 <= i && i < 157.5, left: o, right: !o && (292.5 <= i || i < 67.5), angle: i, speed: r.prevEvent.speed, velocity: { x: r.prevEvent.velocityX, y: r.prevEvent.velocityY } };
1722
+ } }, { key: "preventDefault", value: function() {
1723
+ } }, { key: "stopImmediatePropagation", value: function() {
1724
+ this.immediatePropagationStopped = this.propagationStopped = !0;
1725
+ } }, { key: "stopPropagation", value: function() {
1726
+ this.propagationStopped = !0;
1727
+ } }]), n;
1728
+ }(Je);
1729
+ Object.defineProperties(nn.prototype, { pageX: { get: function() {
1730
+ return this.page.x;
1731
+ }, set: function(t) {
1732
+ this.page.x = t;
1733
+ } }, pageY: { get: function() {
1734
+ return this.page.y;
1735
+ }, set: function(t) {
1736
+ this.page.y = t;
1737
+ } }, clientX: { get: function() {
1738
+ return this.client.x;
1739
+ }, set: function(t) {
1740
+ this.client.x = t;
1741
+ } }, clientY: { get: function() {
1742
+ return this.client.y;
1743
+ }, set: function(t) {
1744
+ this.client.y = t;
1745
+ } }, dx: { get: function() {
1746
+ return this.delta.x;
1747
+ }, set: function(t) {
1748
+ this.delta.x = t;
1749
+ } }, dy: { get: function() {
1750
+ return this.delta.y;
1751
+ }, set: function(t) {
1752
+ this.delta.y = t;
1753
+ } }, velocityX: { get: function() {
1754
+ return this.velocity.x;
1755
+ }, set: function(t) {
1756
+ this.velocity.x = t;
1757
+ } }, velocityY: { get: function() {
1758
+ return this.velocity.y;
1759
+ }, set: function(t) {
1760
+ this.velocity.y = t;
1761
+ } } });
1762
+ var qr = T(function t(e, n, r, i, o) {
1763
+ v(this, t), this.id = void 0, this.pointer = void 0, this.event = void 0, this.downTime = void 0, this.downTarget = void 0, this.id = e, this.pointer = n, this.event = r, this.downTime = i, this.downTarget = o;
1764
+ }), Kr = function(t) {
1765
+ return t.interactable = "", t.element = "", t.prepared = "", t.pointerIsDown = "", t.pointerWasMoved = "", t._proxy = "", t;
1766
+ }({}), Fn = function(t) {
1767
+ return t.start = "", t.move = "", t.end = "", t.stop = "", t.interacting = "", t;
1768
+ }({}), Jr = 0, Zr = function() {
1769
+ function t(e) {
1770
+ var n = this, r = e.pointerType, i = e.scopeFire;
1771
+ v(this, t), this.interactable = null, this.element = null, this.rect = null, this._rects = void 0, this.edges = null, this._scopeFire = void 0, this.prepared = { name: null, axis: null, edges: null }, this.pointerType = void 0, this.pointers = [], this.downEvent = null, this.downPointer = {}, this._latestPointer = { pointer: null, event: null, eventTarget: null }, this.prevEvent = null, this.pointerIsDown = !1, this.pointerWasMoved = !1, this._interacting = !1, this._ending = !1, this._stopped = !0, this._proxy = void 0, this.simulation = null, this.doMove = wt(function(c) {
1772
+ this.move(c);
1773
+ }, "The interaction.doMove() method has been renamed to interaction.move()"), this.coords = { start: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, prev: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, cur: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, delta: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 }, velocity: { page: { x: 0, y: 0 }, client: { x: 0, y: 0 }, timeStamp: 0 } }, this._id = Jr++, this._scopeFire = i, this.pointerType = r;
1774
+ var o = this;
1775
+ this._proxy = {};
1776
+ var a = function(c) {
1777
+ Object.defineProperty(n._proxy, c, { get: function() {
1778
+ return o[c];
1779
+ } });
1780
+ };
1781
+ for (var s in Kr) a(s);
1782
+ var l = function(c) {
1783
+ Object.defineProperty(n._proxy, c, { value: function() {
1784
+ return o[c].apply(o, arguments);
1785
+ } });
1786
+ };
1787
+ for (var u in Fn) l(u);
1788
+ this._scopeFire("interactions:new", { interaction: this });
1789
+ }
1790
+ return T(t, [{ key: "pointerMoveTolerance", get: function() {
1791
+ return 1;
1792
+ } }, { key: "pointerDown", value: function(e, n, r) {
1793
+ var i = this.updatePointer(e, n, r, !0), o = this.pointers[i];
1794
+ this._scopeFire("interactions:down", { pointer: e, event: n, eventTarget: r, pointerIndex: i, pointerInfo: o, type: "down", interaction: this });
1795
+ } }, { key: "start", value: function(e, n, r) {
1796
+ return !(this.interacting() || !this.pointerIsDown || this.pointers.length < (e.name === "gesture" ? 2 : 1) || !n.options[e.name].enabled) && (Jt(this.prepared, e), this.interactable = n, this.element = r, this.rect = n.getRect(r), this.edges = this.prepared.edges ? A({}, this.prepared.edges) : { left: !0, right: !0, top: !0, bottom: !0 }, this._stopped = !1, this._interacting = this._doPhase({ interaction: this, event: this.downEvent, phase: "start" }) && !this._stopped, this._interacting);
1797
+ } }, { key: "pointerMove", value: function(e, n, r) {
1798
+ this.simulation || this.modification && this.modification.endResult || this.updatePointer(e, n, r, !1);
1799
+ var i, o, a = this.coords.cur.page.x === this.coords.prev.page.x && this.coords.cur.page.y === this.coords.prev.page.y && this.coords.cur.client.x === this.coords.prev.client.x && this.coords.cur.client.y === this.coords.prev.client.y;
1800
+ this.pointerIsDown && !this.pointerWasMoved && (i = this.coords.cur.client.x - this.coords.start.client.x, o = this.coords.cur.client.y - this.coords.start.client.y, this.pointerWasMoved = Ue(i, o) > this.pointerMoveTolerance);
1801
+ var s, l, u, c = this.getPointerIndex(e), p = { pointer: e, pointerIndex: c, pointerInfo: this.pointers[c], event: n, type: "move", eventTarget: r, dx: i, dy: o, duplicate: a, interaction: this };
1802
+ a || (s = this.coords.velocity, l = this.coords.delta, u = Math.max(l.timeStamp / 1e3, 1e-3), s.page.x = l.page.x / u, s.page.y = l.page.y / u, s.client.x = l.client.x / u, s.client.y = l.client.y / u, s.timeStamp = u), this._scopeFire("interactions:move", p), a || this.simulation || (this.interacting() && (p.type = null, this.move(p)), this.pointerWasMoved && ut(this.coords.prev, this.coords.cur));
1803
+ } }, { key: "move", value: function(e) {
1804
+ e && e.event || Le(this.coords.delta), (e = A({ pointer: this._latestPointer.pointer, event: this._latestPointer.event, eventTarget: this._latestPointer.eventTarget, interaction: this }, e || {})).phase = "move", this._doPhase(e);
1805
+ } }, { key: "pointerUp", value: function(e, n, r, i) {
1806
+ var o = this.getPointerIndex(e);
1807
+ o === -1 && (o = this.updatePointer(e, n, r, !1));
1808
+ var a = /cancel$/i.test(n.type) ? "cancel" : "up";
1809
+ this._scopeFire("interactions:".concat(a), { pointer: e, pointerIndex: o, pointerInfo: this.pointers[o], event: n, eventTarget: r, type: a, curEventTarget: i, interaction: this }), this.simulation || this.end(n), this.removePointer(e, n);
1810
+ } }, { key: "documentBlur", value: function(e) {
1811
+ this.end(e), this._scopeFire("interactions:blur", { event: e, type: "blur", interaction: this });
1812
+ } }, { key: "end", value: function(e) {
1813
+ var n;
1814
+ this._ending = !0, e = e || this._latestPointer.event, this.interacting() && (n = this._doPhase({ event: e, interaction: this, phase: "end" })), this._ending = !1, n === !0 && this.stop();
1815
+ } }, { key: "currentAction", value: function() {
1816
+ return this._interacting ? this.prepared.name : null;
1817
+ } }, { key: "interacting", value: function() {
1818
+ return this._interacting;
1819
+ } }, { key: "stop", value: function() {
1820
+ this._scopeFire("interactions:stop", { interaction: this }), this.interactable = this.element = null, this._interacting = !1, this._stopped = !0, this.prepared.name = this.prevEvent = null;
1821
+ } }, { key: "getPointerIndex", value: function(e) {
1822
+ var n = ne(e);
1823
+ return this.pointerType === "mouse" || this.pointerType === "pen" ? this.pointers.length - 1 : $e(this.pointers, function(r) {
1824
+ return r.id === n;
1825
+ });
1826
+ } }, { key: "getPointerInfo", value: function(e) {
1827
+ return this.pointers[this.getPointerIndex(e)];
1828
+ } }, { key: "updatePointer", value: function(e, n, r, i) {
1829
+ var o, a, s, l = ne(e), u = this.getPointerIndex(e), c = this.pointers[u];
1830
+ return i = i !== !1 && (i || /(down|start)$/i.test(n.type)), c ? c.pointer = e : (c = new qr(l, e, n, null, null), u = this.pointers.length, this.pointers.push(c)), pe(this.coords.cur, this.pointers.map(function(p) {
1831
+ return p.pointer;
1832
+ }), this._now()), o = this.coords.delta, a = this.coords.prev, s = this.coords.cur, o.page.x = s.page.x - a.page.x, o.page.y = s.page.y - a.page.y, o.client.x = s.client.x - a.client.x, o.client.y = s.client.y - a.client.y, o.timeStamp = s.timeStamp - a.timeStamp, i && (this.pointerIsDown = !0, c.downTime = this.coords.cur.timeStamp, c.downTarget = r, it(this.downPointer, e), this.interacting() || (ut(this.coords.start, this.coords.cur), ut(this.coords.prev, this.coords.cur), this.downEvent = n, this.pointerWasMoved = !1)), this._updateLatestPointer(e, n, r), this._scopeFire("interactions:update-pointer", { pointer: e, event: n, eventTarget: r, down: i, pointerInfo: c, pointerIndex: u, interaction: this }), u;
1833
+ } }, { key: "removePointer", value: function(e, n) {
1834
+ var r = this.getPointerIndex(e);
1835
+ if (r !== -1) {
1836
+ var i = this.pointers[r];
1837
+ this._scopeFire("interactions:remove-pointer", { pointer: e, event: n, eventTarget: null, pointerIndex: r, pointerInfo: i, interaction: this }), this.pointers.splice(r, 1), this.pointerIsDown = !1;
1838
+ }
1839
+ } }, { key: "_updateLatestPointer", value: function(e, n, r) {
1840
+ this._latestPointer.pointer = e, this._latestPointer.event = n, this._latestPointer.eventTarget = r;
1841
+ } }, { key: "destroy", value: function() {
1842
+ this._latestPointer.pointer = null, this._latestPointer.event = null, this._latestPointer.eventTarget = null;
1843
+ } }, { key: "_createPreparedEvent", value: function(e, n, r, i) {
1844
+ return new nn(this, e, this.prepared.name, n, this.element, r, i);
1845
+ } }, { key: "_fireEvent", value: function(e) {
1846
+ var n;
1847
+ (n = this.interactable) == null || n.fire(e), (!this.prevEvent || e.timeStamp >= this.prevEvent.timeStamp) && (this.prevEvent = e);
1848
+ } }, { key: "_doPhase", value: function(e) {
1849
+ var n = e.event, r = e.phase, i = e.preEnd, o = e.type, a = this.rect;
1850
+ if (a && r === "move" && (nt(this.edges, a, this.coords.delta[this.interactable.options.deltaSource]), a.width = a.right - a.left, a.height = a.bottom - a.top), this._scopeFire("interactions:before-action-".concat(r), e) === !1) return !1;
1851
+ var s = e.iEvent = this._createPreparedEvent(n, r, i, o);
1852
+ return this._scopeFire("interactions:action-".concat(r), e), r === "start" && (this.prevEvent = s), this._fireEvent(s), this._scopeFire("interactions:after-action-".concat(r), e), !0;
1853
+ } }, { key: "_now", value: function() {
1854
+ return Date.now();
1855
+ } }]), t;
1856
+ }();
1857
+ function Ln(t) {
1858
+ $n(t.interaction);
1859
+ }
1860
+ function $n(t) {
1861
+ if (!function(n) {
1862
+ return !(!n.offset.pending.x && !n.offset.pending.y);
1863
+ }(t)) return !1;
1864
+ var e = t.offset.pending;
1865
+ return rn(t.coords.cur, e), rn(t.coords.delta, e), nt(t.edges, t.rect, e), e.x = 0, e.y = 0, !0;
1866
+ }
1867
+ function Qr(t) {
1868
+ var e = t.x, n = t.y;
1869
+ this.offset.pending.x += e, this.offset.pending.y += n, this.offset.total.x += e, this.offset.total.y += n;
1870
+ }
1871
+ function rn(t, e) {
1872
+ var n = t.page, r = t.client, i = e.x, o = e.y;
1873
+ n.x += i, n.y += o, r.x += i, r.y += o;
1874
+ }
1875
+ Fn.offsetBy = "";
1876
+ var ei = { id: "offset", before: ["modifiers", "pointer-events", "actions", "inertia"], install: function(t) {
1877
+ t.Interaction.prototype.offsetBy = Qr;
1878
+ }, listeners: { "interactions:new": function(t) {
1879
+ t.interaction.offset = { total: { x: 0, y: 0 }, pending: { x: 0, y: 0 } };
1880
+ }, "interactions:update-pointer": function(t) {
1881
+ return function(e) {
1882
+ e.pointerIsDown && (rn(e.coords.cur, e.offset.total), e.offset.pending.x = 0, e.offset.pending.y = 0);
1883
+ }(t.interaction);
1884
+ }, "interactions:before-action-start": Ln, "interactions:before-action-move": Ln, "interactions:before-action-end": function(t) {
1885
+ var e = t.interaction;
1886
+ if ($n(e)) return e.move({ offset: !0 }), e.end(), !1;
1887
+ }, "interactions:stop": function(t) {
1888
+ var e = t.interaction;
1889
+ e.offset.total.x = 0, e.offset.total.y = 0, e.offset.pending.x = 0, e.offset.pending.y = 0;
1890
+ } } }, Nn = ei, ti = function() {
1891
+ function t(e) {
1892
+ v(this, t), this.active = !1, this.isModified = !1, this.smoothEnd = !1, this.allowResume = !1, this.modification = void 0, this.modifierCount = 0, this.modifierArg = void 0, this.startCoords = void 0, this.t0 = 0, this.v0 = 0, this.te = 0, this.targetOffset = void 0, this.modifiedOffset = void 0, this.currentOffset = void 0, this.lambda_v0 = 0, this.one_ve_v0 = 0, this.timeout = void 0, this.interaction = void 0, this.interaction = e;
1893
+ }
1894
+ return T(t, [{ key: "start", value: function(e) {
1895
+ var n = this.interaction, r = Rt(n);
1896
+ if (!r || !r.enabled) return !1;
1897
+ var i = n.coords.velocity.client, o = Ue(i.x, i.y), a = this.modification || (this.modification = new tn(n));
1898
+ if (a.copyFrom(n.modification), this.t0 = n._now(), this.allowResume = r.allowResume, this.v0 = o, this.currentOffset = { x: 0, y: 0 }, this.startCoords = n.coords.cur.page, this.modifierArg = a.fillArg({ pageCoords: this.startCoords, preEnd: !0, phase: "inertiastart" }), this.t0 - n.coords.cur.timeStamp < 50 && o > r.minSpeed && o > r.endSpeed) this.startInertia();
1899
+ else {
1900
+ if (a.result = a.setAll(this.modifierArg), !a.result.changed) return !1;
1901
+ this.startSmoothEnd();
1902
+ }
1903
+ return n.modification.result.rect = null, n.offsetBy(this.targetOffset), n._doPhase({ interaction: n, event: e, phase: "inertiastart" }), n.offsetBy({ x: -this.targetOffset.x, y: -this.targetOffset.y }), n.modification.result.rect = null, this.active = !0, n.simulation = this, !0;
1904
+ } }, { key: "startInertia", value: function() {
1905
+ var e = this, n = this.interaction.coords.velocity.client, r = Rt(this.interaction), i = r.resistance, o = -Math.log(r.endSpeed / this.v0) / i;
1906
+ this.targetOffset = { x: (n.x - o) / i, y: (n.y - o) / i }, this.te = o, this.lambda_v0 = i / this.v0, this.one_ve_v0 = 1 - r.endSpeed / this.v0;
1907
+ var a = this.modification, s = this.modifierArg;
1908
+ s.pageCoords = { x: this.startCoords.x + this.targetOffset.x, y: this.startCoords.y + this.targetOffset.y }, a.result = a.setAll(s), a.result.changed && (this.isModified = !0, this.modifiedOffset = { x: this.targetOffset.x + a.result.delta.x, y: this.targetOffset.y + a.result.delta.y }), this.onNextFrame(function() {
1909
+ return e.inertiaTick();
1910
+ });
1911
+ } }, { key: "startSmoothEnd", value: function() {
1912
+ var e = this;
1913
+ this.smoothEnd = !0, this.isModified = !0, this.targetOffset = { x: this.modification.result.delta.x, y: this.modification.result.delta.y }, this.onNextFrame(function() {
1914
+ return e.smoothEndTick();
1915
+ });
1916
+ } }, { key: "onNextFrame", value: function(e) {
1917
+ var n = this;
1918
+ this.timeout = Ze.request(function() {
1919
+ n.active && e();
1920
+ });
1921
+ } }, { key: "inertiaTick", value: function() {
1922
+ var e, n, r, i, o, a, s, l = this, u = this.interaction, c = Rt(u).resistance, p = (u._now() - this.t0) / 1e3;
1923
+ if (p < this.te) {
1924
+ var g, w = 1 - (Math.exp(-c * p) - this.lambda_v0) / this.one_ve_v0;
1925
+ this.isModified ? (e = 0, n = 0, r = this.targetOffset.x, i = this.targetOffset.y, o = this.modifiedOffset.x, a = this.modifiedOffset.y, g = { x: Hn(s = w, e, r, o), y: Hn(s, n, i, a) }) : g = { x: this.targetOffset.x * w, y: this.targetOffset.y * w };
1926
+ var x = { x: g.x - this.currentOffset.x, y: g.y - this.currentOffset.y };
1927
+ this.currentOffset.x += x.x, this.currentOffset.y += x.y, u.offsetBy(x), u.move(), this.onNextFrame(function() {
1928
+ return l.inertiaTick();
1929
+ });
1930
+ } else u.offsetBy({ x: this.modifiedOffset.x - this.currentOffset.x, y: this.modifiedOffset.y - this.currentOffset.y }), this.end();
1931
+ } }, { key: "smoothEndTick", value: function() {
1932
+ var e = this, n = this.interaction, r = n._now() - this.t0, i = Rt(n).smoothEndDuration;
1933
+ if (r < i) {
1934
+ var o = { x: Wn(r, 0, this.targetOffset.x, i), y: Wn(r, 0, this.targetOffset.y, i) }, a = { x: o.x - this.currentOffset.x, y: o.y - this.currentOffset.y };
1935
+ this.currentOffset.x += a.x, this.currentOffset.y += a.y, n.offsetBy(a), n.move({ skipModifiers: this.modifierCount }), this.onNextFrame(function() {
1936
+ return e.smoothEndTick();
1937
+ });
1938
+ } else n.offsetBy({ x: this.targetOffset.x - this.currentOffset.x, y: this.targetOffset.y - this.currentOffset.y }), this.end();
1939
+ } }, { key: "resume", value: function(e) {
1940
+ var n = e.pointer, r = e.event, i = e.eventTarget, o = this.interaction;
1941
+ o.offsetBy({ x: -this.currentOffset.x, y: -this.currentOffset.y }), o.updatePointer(n, r, i, !0), o._doPhase({ interaction: o, event: r, phase: "resume" }), ut(o.coords.prev, o.coords.cur), this.stop();
1942
+ } }, { key: "end", value: function() {
1943
+ this.interaction.move(), this.interaction.end(), this.stop();
1944
+ } }, { key: "stop", value: function() {
1945
+ this.active = this.smoothEnd = !1, this.interaction.simulation = null, Ze.cancel(this.timeout);
1946
+ } }]), t;
1947
+ }();
1948
+ function Rt(t) {
1949
+ var e = t.interactable, n = t.prepared;
1950
+ return e && e.options && n.name && e.options[n.name].inertia;
1951
+ }
1952
+ var ni = { id: "inertia", before: ["modifiers", "actions"], install: function(t) {
1953
+ var e = t.defaults;
1954
+ t.usePlugin(Nn), t.usePlugin(Bn), t.actions.phases.inertiastart = !0, t.actions.phases.resume = !0, e.perAction.inertia = { enabled: !1, resistance: 10, minSpeed: 100, endSpeed: 10, allowResume: !0, smoothEndDuration: 300 };
1955
+ }, listeners: { "interactions:new": function(t) {
1956
+ var e = t.interaction;
1957
+ e.inertia = new ti(e);
1958
+ }, "interactions:before-action-end": function(t) {
1959
+ var e = t.interaction, n = t.event;
1960
+ return (!e._interacting || e.simulation || !e.inertia.start(n)) && null;
1961
+ }, "interactions:down": function(t) {
1962
+ var e = t.interaction, n = t.eventTarget, r = e.inertia;
1963
+ if (r.active) for (var i = n; h.element(i); ) {
1964
+ if (i === e.element) {
1965
+ r.resume(t);
1966
+ break;
1967
+ }
1968
+ i = de(i);
1969
+ }
1970
+ }, "interactions:stop": function(t) {
1971
+ var e = t.interaction.inertia;
1972
+ e.active && e.stop();
1973
+ }, "interactions:before-action-resume": function(t) {
1974
+ var e = t.interaction.modification;
1975
+ e.stop(t), e.start(t, t.interaction.coords.cur.page), e.applyToInteraction(t);
1976
+ }, "interactions:before-action-inertiastart": function(t) {
1977
+ return t.interaction.modification.setAndApply(t);
1978
+ }, "interactions:action-resume": _t, "interactions:action-inertiastart": _t, "interactions:after-action-inertiastart": function(t) {
1979
+ return t.interaction.modification.restoreInteractionCoords(t);
1980
+ }, "interactions:after-action-resume": function(t) {
1981
+ return t.interaction.modification.restoreInteractionCoords(t);
1982
+ } } };
1983
+ function Hn(t, e, n, r) {
1984
+ var i = 1 - t;
1985
+ return i * i * e + 2 * i * t * n + t * t * r;
1986
+ }
1987
+ function Wn(t, e, n, r) {
1988
+ return -n * (t /= r) * (t - 2) + e;
1989
+ }
1990
+ var ri = ni;
1991
+ function Yn(t, e) {
1992
+ for (var n = 0; n < e.length; n++) {
1993
+ var r = e[n];
1994
+ if (t.immediatePropagationStopped) break;
1995
+ r(t);
1996
+ }
1997
+ }
1998
+ var Xn = function() {
1999
+ function t(e) {
2000
+ v(this, t), this.options = void 0, this.types = {}, this.propagationStopped = !1, this.immediatePropagationStopped = !1, this.global = void 0, this.options = A({}, e || {});
2001
+ }
2002
+ return T(t, [{ key: "fire", value: function(e) {
2003
+ var n, r = this.global;
2004
+ (n = this.types[e.type]) && Yn(e, n), !e.propagationStopped && r && (n = r[e.type]) && Yn(e, n);
2005
+ } }, { key: "on", value: function(e, n) {
2006
+ var r = Fe(e, n);
2007
+ for (e in r) this.types[e] = pt(this.types[e] || [], r[e]);
2008
+ } }, { key: "off", value: function(e, n) {
2009
+ var r = Fe(e, n);
2010
+ for (e in r) {
2011
+ var i = this.types[e];
2012
+ if (i && i.length) for (var o = 0, a = r[e]; o < a.length; o++) {
2013
+ var s = a[o], l = i.indexOf(s);
2014
+ l !== -1 && i.splice(l, 1);
2015
+ }
2016
+ }
2017
+ } }, { key: "getRect", value: function(e) {
2018
+ return null;
2019
+ } }]), t;
2020
+ }(), ii = function() {
2021
+ function t(e) {
2022
+ v(this, t), this.currentTarget = void 0, this.originalEvent = void 0, this.type = void 0, this.originalEvent = e, it(this, e);
2023
+ }
2024
+ return T(t, [{ key: "preventOriginalDefault", value: function() {
2025
+ this.originalEvent.preventDefault();
2026
+ } }, { key: "stopPropagation", value: function() {
2027
+ this.originalEvent.stopPropagation();
2028
+ } }, { key: "stopImmediatePropagation", value: function() {
2029
+ this.originalEvent.stopImmediatePropagation();
2030
+ } }]), t;
2031
+ }();
2032
+ function Et(t) {
2033
+ return h.object(t) ? { capture: !!t.capture, passive: !!t.passive } : { capture: !!t, passive: !1 };
2034
+ }
2035
+ function At(t, e) {
2036
+ return t === e || (typeof t == "boolean" ? !!e.capture === t && !e.passive : !!t.capture == !!e.capture && !!t.passive == !!e.passive);
2037
+ }
2038
+ var oi = { id: "events", install: function(t) {
2039
+ var e, n = [], r = {}, i = [], o = { add: a, remove: s, addDelegate: function(c, p, g, w, x) {
2040
+ var S = Et(x);
2041
+ if (!r[g]) {
2042
+ r[g] = [];
2043
+ for (var P = 0; P < i.length; P++) {
2044
+ var M = i[P];
2045
+ a(M, g, l), a(M, g, u, !0);
2046
+ }
2047
+ }
2048
+ var B = r[g], X = xt(B, function(Z) {
2049
+ return Z.selector === c && Z.context === p;
2050
+ });
2051
+ X || (X = { selector: c, context: p, listeners: [] }, B.push(X)), X.listeners.push({ func: w, options: S });
2052
+ }, removeDelegate: function(c, p, g, w, x) {
2053
+ var S, P = Et(x), M = r[g], B = !1;
2054
+ if (M)
2055
+ for (S = M.length - 1; S >= 0; S--) {
2056
+ var X = M[S];
2057
+ if (X.selector === c && X.context === p) {
2058
+ for (var Z = X.listeners, $ = Z.length - 1; $ >= 0; $--) {
2059
+ var G = Z[$];
2060
+ if (G.func === w && At(G.options, P)) {
2061
+ Z.splice($, 1), Z.length || (M.splice(S, 1), s(p, g, l), s(p, g, u, !0)), B = !0;
2062
+ break;
2063
+ }
2064
+ }
2065
+ if (B) break;
2066
+ }
2067
+ }
2068
+ }, delegateListener: l, delegateUseCapture: u, delegatedEvents: r, documents: i, targets: n, supportsOptions: !1, supportsPassive: !1 };
2069
+ function a(c, p, g, w) {
2070
+ if (c.addEventListener) {
2071
+ var x = Et(w), S = xt(n, function(P) {
2072
+ return P.eventTarget === c;
2073
+ });
2074
+ S || (S = { eventTarget: c, events: {} }, n.push(S)), S.events[p] || (S.events[p] = []), xt(S.events[p], function(P) {
2075
+ return P.func === g && At(P.options, x);
2076
+ }) || (c.addEventListener(p, g, o.supportsOptions ? x : x.capture), S.events[p].push({ func: g, options: x }));
2077
+ }
2078
+ }
2079
+ function s(c, p, g, w) {
2080
+ if (c.addEventListener && c.removeEventListener) {
2081
+ var x = $e(n, function(Te) {
2082
+ return Te.eventTarget === c;
2083
+ }), S = n[x];
2084
+ if (S && S.events) if (p !== "all") {
2085
+ var P = !1, M = S.events[p];
2086
+ if (M) {
2087
+ if (g === "all") {
2088
+ for (var B = M.length - 1; B >= 0; B--) {
2089
+ var X = M[B];
2090
+ s(c, p, X.func, X.options);
2091
+ }
2092
+ return;
2093
+ }
2094
+ for (var Z = Et(w), $ = 0; $ < M.length; $++) {
2095
+ var G = M[$];
2096
+ if (G.func === g && At(G.options, Z)) {
2097
+ c.removeEventListener(p, g, o.supportsOptions ? Z : Z.capture), M.splice($, 1), M.length === 0 && (delete S.events[p], P = !0);
2098
+ break;
2099
+ }
2100
+ }
2101
+ }
2102
+ P && !Object.keys(S.events).length && n.splice(x, 1);
2103
+ } else for (p in S.events) S.events.hasOwnProperty(p) && s(c, p, "all");
2104
+ }
2105
+ }
2106
+ function l(c, p) {
2107
+ for (var g = Et(p), w = new ii(c), x = r[c.type], S = Ke(c)[0], P = S; h.element(P); ) {
2108
+ for (var M = 0; M < x.length; M++) {
2109
+ var B = x[M], X = B.selector, Z = B.context;
2110
+ if (K(P, X) && W(Z, S) && W(Z, P)) {
2111
+ var $ = B.listeners;
2112
+ w.currentTarget = P;
2113
+ for (var G = 0; G < $.length; G++) {
2114
+ var Te = $[G];
2115
+ At(Te.options, g) && Te.func(w);
2116
+ }
2117
+ }
2118
+ }
2119
+ P = de(P);
2120
+ }
2121
+ }
2122
+ function u(c) {
2123
+ return l(c, !0);
2124
+ }
2125
+ return (e = t.document) == null || e.createElement("div").addEventListener("test", null, { get capture() {
2126
+ return o.supportsOptions = !0;
2127
+ }, get passive() {
2128
+ return o.supportsPassive = !0;
2129
+ } }), t.events = o, o;
2130
+ } }, on = { methodOrder: ["simulationResume", "mouseOrPen", "hasPointer", "idle"], search: function(t) {
2131
+ for (var e = 0, n = on.methodOrder; e < n.length; e++) {
2132
+ var r = n[e], i = on[r](t);
2133
+ if (i) return i;
2134
+ }
2135
+ return null;
2136
+ }, simulationResume: function(t) {
2137
+ var e = t.pointerType, n = t.eventType, r = t.eventTarget, i = t.scope;
2138
+ if (!/down|start/i.test(n)) return null;
2139
+ for (var o = 0, a = i.interactions.list; o < a.length; o++) {
2140
+ var s = a[o], l = r;
2141
+ if (s.simulation && s.simulation.allowResume && s.pointerType === e) for (; l; ) {
2142
+ if (l === s.element) return s;
2143
+ l = de(l);
2144
+ }
2145
+ }
2146
+ return null;
2147
+ }, mouseOrPen: function(t) {
2148
+ var e, n = t.pointerId, r = t.pointerType, i = t.eventType, o = t.scope;
2149
+ if (r !== "mouse" && r !== "pen") return null;
2150
+ for (var a = 0, s = o.interactions.list; a < s.length; a++) {
2151
+ var l = s[a];
2152
+ if (l.pointerType === r) {
2153
+ if (l.simulation && !Vn(l, n)) continue;
2154
+ if (l.interacting()) return l;
2155
+ e || (e = l);
2156
+ }
2157
+ }
2158
+ if (e) return e;
2159
+ for (var u = 0, c = o.interactions.list; u < c.length; u++) {
2160
+ var p = c[u];
2161
+ if (!(p.pointerType !== r || /down/i.test(i) && p.simulation)) return p;
2162
+ }
2163
+ return null;
2164
+ }, hasPointer: function(t) {
2165
+ for (var e = t.pointerId, n = 0, r = t.scope.interactions.list; n < r.length; n++) {
2166
+ var i = r[n];
2167
+ if (Vn(i, e)) return i;
2168
+ }
2169
+ return null;
2170
+ }, idle: function(t) {
2171
+ for (var e = t.pointerType, n = 0, r = t.scope.interactions.list; n < r.length; n++) {
2172
+ var i = r[n];
2173
+ if (i.pointers.length === 1) {
2174
+ var o = i.interactable;
2175
+ if (o && (!o.options.gesture || !o.options.gesture.enabled)) continue;
2176
+ } else if (i.pointers.length >= 2) continue;
2177
+ if (!i.interacting() && e === i.pointerType) return i;
2178
+ }
2179
+ return null;
2180
+ } };
2181
+ function Vn(t, e) {
2182
+ return t.pointers.some(function(n) {
2183
+ return n.id === e;
2184
+ });
2185
+ }
2186
+ var ai = on, an = ["pointerDown", "pointerMove", "pointerUp", "updatePointer", "removePointer", "windowBlur"];
2187
+ function Gn(t, e) {
2188
+ return function(n) {
2189
+ var r = e.interactions.list, i = qe(n), o = Ke(n), a = o[0], s = o[1], l = [];
2190
+ if (/^touch/.test(n.type)) {
2191
+ e.prevTouchTime = e.now();
2192
+ for (var u = 0, c = n.changedTouches; u < c.length; u++) {
2193
+ var p = c[u], g = { pointer: p, pointerId: ne(p), pointerType: i, eventType: n.type, eventTarget: a, curEventTarget: s, scope: e }, w = Un(g);
2194
+ l.push([g.pointer, g.eventTarget, g.curEventTarget, w]);
2195
+ }
2196
+ } else {
2197
+ var x = !1;
2198
+ if (!ae.supportsPointerEvent && /mouse/.test(n.type)) {
2199
+ for (var S = 0; S < r.length && !x; S++) x = r[S].pointerType !== "mouse" && r[S].pointerIsDown;
2200
+ x = x || e.now() - e.prevTouchTime < 500 || n.timeStamp === 0;
2201
+ }
2202
+ if (!x) {
2203
+ var P = { pointer: n, pointerId: ne(n), pointerType: i, eventType: n.type, curEventTarget: s, eventTarget: a, scope: e }, M = Un(P);
2204
+ l.push([P.pointer, P.eventTarget, P.curEventTarget, M]);
2205
+ }
2206
+ }
2207
+ for (var B = 0; B < l.length; B++) {
2208
+ var X = l[B], Z = X[0], $ = X[1], G = X[2];
2209
+ X[3][t](Z, n, $, G);
2210
+ }
2211
+ };
2212
+ }
2213
+ function Un(t) {
2214
+ var e = t.pointerType, n = t.scope, r = { interaction: ai.search(t), searchDetails: t };
2215
+ return n.fire("interactions:find", r), r.interaction || n.interactions.new({ pointerType: e });
2216
+ }
2217
+ function sn(t, e) {
2218
+ var n = t.doc, r = t.scope, i = t.options, o = r.interactions.docEvents, a = r.events, s = a[e];
2219
+ for (var l in r.browser.isIOS && !i.events && (i.events = { passive: !1 }), a.delegatedEvents) s(n, l, a.delegateListener), s(n, l, a.delegateUseCapture, !0);
2220
+ for (var u = i && i.events, c = 0; c < o.length; c++) {
2221
+ var p = o[c];
2222
+ s(n, p.type, p.listener, u);
2223
+ }
2224
+ }
2225
+ var si = { id: "core/interactions", install: function(t) {
2226
+ for (var e = {}, n = 0; n < an.length; n++) {
2227
+ var r = an[n];
2228
+ e[r] = Gn(r, t);
2229
+ }
2230
+ var i, o = ae.pEventTypes;
2231
+ function a() {
2232
+ for (var s = 0, l = t.interactions.list; s < l.length; s++) {
2233
+ var u = l[s];
2234
+ if (u.pointerIsDown && u.pointerType === "touch" && !u._interacting) for (var c = function() {
2235
+ var w = g[p];
2236
+ t.documents.some(function(x) {
2237
+ return W(x.doc, w.downTarget);
2238
+ }) || u.removePointer(w.pointer, w.event);
2239
+ }, p = 0, g = u.pointers; p < g.length; p++) c();
2240
+ }
2241
+ }
2242
+ (i = ee.PointerEvent ? [{ type: o.down, listener: a }, { type: o.down, listener: e.pointerDown }, { type: o.move, listener: e.pointerMove }, { type: o.up, listener: e.pointerUp }, { type: o.cancel, listener: e.pointerUp }] : [{ type: "mousedown", listener: e.pointerDown }, { type: "mousemove", listener: e.pointerMove }, { type: "mouseup", listener: e.pointerUp }, { type: "touchstart", listener: a }, { type: "touchstart", listener: e.pointerDown }, { type: "touchmove", listener: e.pointerMove }, { type: "touchend", listener: e.pointerUp }, { type: "touchcancel", listener: e.pointerUp }]).push({ type: "blur", listener: function(s) {
2243
+ for (var l = 0, u = t.interactions.list; l < u.length; l++)
2244
+ u[l].documentBlur(s);
2245
+ } }), t.prevTouchTime = 0, t.Interaction = function(s) {
2246
+ q(u, s);
2247
+ var l = ie(u);
2248
+ function u() {
2249
+ return v(this, u), l.apply(this, arguments);
2250
+ }
2251
+ return T(u, [{ key: "pointerMoveTolerance", get: function() {
2252
+ return t.interactions.pointerMoveTolerance;
2253
+ }, set: function(c) {
2254
+ t.interactions.pointerMoveTolerance = c;
2255
+ } }, { key: "_now", value: function() {
2256
+ return t.now();
2257
+ } }]), u;
2258
+ }(Zr), t.interactions = { list: [], new: function(s) {
2259
+ s.scopeFire = function(u, c) {
2260
+ return t.fire(u, c);
2261
+ };
2262
+ var l = new t.Interaction(s);
2263
+ return t.interactions.list.push(l), l;
2264
+ }, listeners: e, docEvents: i, pointerMoveTolerance: 1 }, t.usePlugin(An);
2265
+ }, listeners: { "scope:add-document": function(t) {
2266
+ return sn(t, "add");
2267
+ }, "scope:remove-document": function(t) {
2268
+ return sn(t, "remove");
2269
+ }, "interactable:unset": function(t, e) {
2270
+ for (var n = t.interactable, r = e.interactions.list.length - 1; r >= 0; r--) {
2271
+ var i = e.interactions.list[r];
2272
+ i.interactable === n && (i.stop(), e.fire("interactions:destroy", { interaction: i }), i.destroy(), e.interactions.list.length > 2 && e.interactions.list.splice(r, 1));
2273
+ }
2274
+ } }, onDocSignal: sn, doOnInteractions: Gn, methodNames: an }, li = si, et = function(t) {
2275
+ return t[t.On = 0] = "On", t[t.Off = 1] = "Off", t;
2276
+ }(et || {}), ci = function() {
2277
+ function t(e, n, r, i) {
2278
+ v(this, t), this.target = void 0, this.options = void 0, this._actions = void 0, this.events = new Xn(), this._context = void 0, this._win = void 0, this._doc = void 0, this._scopeEvents = void 0, this._actions = n.actions, this.target = e, this._context = n.context || r, this._win = E(yt(e) ? this._context : e), this._doc = this._win.document, this._scopeEvents = i, this.set(n);
2279
+ }
2280
+ return T(t, [{ key: "_defaults", get: function() {
2281
+ return { base: {}, perAction: {}, actions: {} };
2282
+ } }, { key: "setOnEvents", value: function(e, n) {
2283
+ return h.func(n.onstart) && this.on("".concat(e, "start"), n.onstart), h.func(n.onmove) && this.on("".concat(e, "move"), n.onmove), h.func(n.onend) && this.on("".concat(e, "end"), n.onend), h.func(n.oninertiastart) && this.on("".concat(e, "inertiastart"), n.oninertiastart), this;
2284
+ } }, { key: "updatePerActionListeners", value: function(e, n, r) {
2285
+ var i, o = this, a = (i = this._actions.map[e]) == null ? void 0 : i.filterEventType, s = function(l) {
2286
+ return (a == null || a(l)) && Pt(l, o._actions);
2287
+ };
2288
+ (h.array(n) || h.object(n)) && this._onOff(et.Off, e, n, void 0, s), (h.array(r) || h.object(r)) && this._onOff(et.On, e, r, void 0, s);
2289
+ } }, { key: "setPerAction", value: function(e, n) {
2290
+ var r = this._defaults;
2291
+ for (var i in n) {
2292
+ var o = i, a = this.options[e], s = n[o];
2293
+ o === "listeners" && this.updatePerActionListeners(e, a.listeners, s), h.array(s) ? a[o] = ft(s) : h.plainObject(s) ? (a[o] = A(a[o] || {}, ht(s)), h.object(r.perAction[o]) && "enabled" in r.perAction[o] && (a[o].enabled = s.enabled !== !1)) : h.bool(s) && h.object(r.perAction[o]) ? a[o].enabled = s : a[o] = s;
2294
+ }
2295
+ } }, { key: "getRect", value: function(e) {
2296
+ return e = e || (h.element(this.target) ? this.target : null), h.string(this.target) && (e = e || this._context.querySelector(this.target)), Ae(e);
2297
+ } }, { key: "rectChecker", value: function(e) {
2298
+ var n = this;
2299
+ return h.func(e) ? (this.getRect = function(r) {
2300
+ var i = A({}, e.apply(n, r));
2301
+ return "width" in i || (i.width = i.right - i.left, i.height = i.bottom - i.top), i;
2302
+ }, this) : e === null ? (delete this.getRect, this) : this.getRect;
2303
+ } }, { key: "_backCompatOption", value: function(e, n) {
2304
+ if (yt(n) || h.object(n)) {
2305
+ for (var r in this.options[e] = n, this._actions.map) this.options[r][e] = n;
2306
+ return this;
2307
+ }
2308
+ return this.options[e];
2309
+ } }, { key: "origin", value: function(e) {
2310
+ return this._backCompatOption("origin", e);
2311
+ } }, { key: "deltaSource", value: function(e) {
2312
+ return e === "page" || e === "client" ? (this.options.deltaSource = e, this) : this.options.deltaSource;
2313
+ } }, { key: "getAllElements", value: function() {
2314
+ var e = this.target;
2315
+ return h.string(e) ? Array.from(this._context.querySelectorAll(e)) : h.func(e) && e.getAllElements ? e.getAllElements() : h.element(e) ? [e] : [];
2316
+ } }, { key: "context", value: function() {
2317
+ return this._context;
2318
+ } }, { key: "inContext", value: function(e) {
2319
+ return this._context === e.ownerDocument || W(this._context, e);
2320
+ } }, { key: "testIgnoreAllow", value: function(e, n, r) {
2321
+ return !this.testIgnore(e.ignoreFrom, n, r) && this.testAllow(e.allowFrom, n, r);
2322
+ } }, { key: "testAllow", value: function(e, n, r) {
2323
+ return !e || !!h.element(r) && (h.string(e) ? Oe(r, e, n) : !!h.element(e) && W(e, r));
2324
+ } }, { key: "testIgnore", value: function(e, n, r) {
2325
+ return !(!e || !h.element(r)) && (h.string(e) ? Oe(r, e, n) : !!h.element(e) && W(e, r));
2326
+ } }, { key: "fire", value: function(e) {
2327
+ return this.events.fire(e), this;
2328
+ } }, { key: "_onOff", value: function(e, n, r, i, o) {
2329
+ h.object(n) && !h.array(n) && (i = r, r = null);
2330
+ var a = Fe(n, r, o);
2331
+ for (var s in a) {
2332
+ s === "wheel" && (s = ae.wheelEvent);
2333
+ for (var l = 0, u = a[s]; l < u.length; l++) {
2334
+ var c = u[l];
2335
+ Pt(s, this._actions) ? this.events[e === et.On ? "on" : "off"](s, c) : h.string(this.target) ? this._scopeEvents[e === et.On ? "addDelegate" : "removeDelegate"](this.target, this._context, s, c, i) : this._scopeEvents[e === et.On ? "add" : "remove"](this.target, s, c, i);
2336
+ }
2337
+ }
2338
+ return this;
2339
+ } }, { key: "on", value: function(e, n, r) {
2340
+ return this._onOff(et.On, e, n, r);
2341
+ } }, { key: "off", value: function(e, n, r) {
2342
+ return this._onOff(et.Off, e, n, r);
2343
+ } }, { key: "set", value: function(e) {
2344
+ var n = this._defaults;
2345
+ for (var r in h.object(e) || (e = {}), this.options = ht(n.base), this._actions.methodDict) {
2346
+ var i = r, o = this._actions.methodDict[i];
2347
+ this.options[i] = {}, this.setPerAction(i, A(A({}, n.perAction), n.actions[i])), this[o](e[i]);
2348
+ }
2349
+ for (var a in e) a !== "getRect" ? h.func(this[a]) && this[a](e[a]) : this.rectChecker(e.getRect);
2350
+ return this;
2351
+ } }, { key: "unset", value: function() {
2352
+ if (h.string(this.target)) for (var e in this._scopeEvents.delegatedEvents) for (var n = this._scopeEvents.delegatedEvents[e], r = n.length - 1; r >= 0; r--) {
2353
+ var i = n[r], o = i.selector, a = i.context, s = i.listeners;
2354
+ o === this.target && a === this._context && n.splice(r, 1);
2355
+ for (var l = s.length - 1; l >= 0; l--) this._scopeEvents.removeDelegate(this.target, this._context, e, s[l][0], s[l][1]);
2356
+ }
2357
+ else this._scopeEvents.remove(this.target, "all");
2358
+ } }]), t;
2359
+ }(), ui = function() {
2360
+ function t(e) {
2361
+ var n = this;
2362
+ v(this, t), this.list = [], this.selectorMap = {}, this.scope = void 0, this.scope = e, e.addListeners({ "interactable:unset": function(r) {
2363
+ var i = r.interactable, o = i.target, a = h.string(o) ? n.selectorMap[o] : o[n.scope.id], s = $e(a, function(l) {
2364
+ return l === i;
2365
+ });
2366
+ a.splice(s, 1);
2367
+ } });
2368
+ }
2369
+ return T(t, [{ key: "new", value: function(e, n) {
2370
+ n = A(n || {}, { actions: this.scope.actions });
2371
+ var r = new this.scope.Interactable(e, n, this.scope.document, this.scope.events);
2372
+ return this.scope.addDocument(r._doc), this.list.push(r), h.string(e) ? (this.selectorMap[e] || (this.selectorMap[e] = []), this.selectorMap[e].push(r)) : (r.target[this.scope.id] || Object.defineProperty(e, this.scope.id, { value: [], configurable: !0 }), e[this.scope.id].push(r)), this.scope.fire("interactable:new", { target: e, options: n, interactable: r, win: this.scope._win }), r;
2373
+ } }, { key: "getExisting", value: function(e, n) {
2374
+ var r = n && n.context || this.scope.document, i = h.string(e), o = i ? this.selectorMap[e] : e[this.scope.id];
2375
+ if (o) return xt(o, function(a) {
2376
+ return a._context === r && (i || a.inContext(e));
2377
+ });
2378
+ } }, { key: "forEachMatch", value: function(e, n) {
2379
+ for (var r = 0, i = this.list; r < i.length; r++) {
2380
+ var o = i[r], a = void 0;
2381
+ if ((h.string(o.target) ? h.element(e) && K(e, o.target) : e === o.target) && o.inContext(e) && (a = n(o)), a !== void 0) return a;
2382
+ }
2383
+ } }]), t;
2384
+ }(), pi = function() {
2385
+ function t() {
2386
+ var e = this;
2387
+ v(this, t), this.id = "__interact_scope_".concat(Math.floor(100 * Math.random())), this.isInitialized = !1, this.listenerMaps = [], this.browser = ae, this.defaults = ht(jn), this.Eventable = Xn, this.actions = { map: {}, phases: { start: !0, move: !0, end: !0 }, methodDict: {}, phaselessTypes: {} }, this.interactStatic = function(r) {
2388
+ var i = function o(a, s) {
2389
+ var l = r.interactables.getExisting(a, s);
2390
+ return l || ((l = r.interactables.new(a, s)).events.global = o.globalEvents), l;
2391
+ };
2392
+ return i.getPointerAverage = L, i.getTouchBBox = ye, i.getTouchDistance = Ee, i.getTouchAngle = Ie, i.getElementRect = Ae, i.getElementClientRect = Xe, i.matchesSelector = K, i.closest = ze, i.globalEvents = {}, i.version = "1.10.27", i.scope = r, i.use = function(o, a) {
2393
+ return this.scope.usePlugin(o, a), this;
2394
+ }, i.isSet = function(o, a) {
2395
+ return !!this.scope.interactables.get(o, a && a.context);
2396
+ }, i.on = wt(function(o, a, s) {
2397
+ if (h.string(o) && o.search(" ") !== -1 && (o = o.trim().split(/ +/)), h.array(o)) {
2398
+ for (var l = 0, u = o; l < u.length; l++) {
2399
+ var c = u[l];
2400
+ this.on(c, a, s);
2401
+ }
2402
+ return this;
2403
+ }
2404
+ if (h.object(o)) {
2405
+ for (var p in o) this.on(p, o[p], a);
2406
+ return this;
2407
+ }
2408
+ return Pt(o, this.scope.actions) ? this.globalEvents[o] ? this.globalEvents[o].push(a) : this.globalEvents[o] = [a] : this.scope.events.add(this.scope.document, o, a, { options: s }), this;
2409
+ }, "The interact.on() method is being deprecated"), i.off = wt(function(o, a, s) {
2410
+ if (h.string(o) && o.search(" ") !== -1 && (o = o.trim().split(/ +/)), h.array(o)) {
2411
+ for (var l = 0, u = o; l < u.length; l++) {
2412
+ var c = u[l];
2413
+ this.off(c, a, s);
2414
+ }
2415
+ return this;
2416
+ }
2417
+ if (h.object(o)) {
2418
+ for (var p in o) this.off(p, o[p], a);
2419
+ return this;
2420
+ }
2421
+ var g;
2422
+ return Pt(o, this.scope.actions) ? o in this.globalEvents && (g = this.globalEvents[o].indexOf(a)) !== -1 && this.globalEvents[o].splice(g, 1) : this.scope.events.remove(this.scope.document, o, a, s), this;
2423
+ }, "The interact.off() method is being deprecated"), i.debug = function() {
2424
+ return this.scope;
2425
+ }, i.supportsTouch = function() {
2426
+ return ae.supportsTouch;
2427
+ }, i.supportsPointerEvent = function() {
2428
+ return ae.supportsPointerEvent;
2429
+ }, i.stop = function() {
2430
+ for (var o = 0, a = this.scope.interactions.list; o < a.length; o++) a[o].stop();
2431
+ return this;
2432
+ }, i.pointerMoveTolerance = function(o) {
2433
+ return h.number(o) ? (this.scope.interactions.pointerMoveTolerance = o, this) : this.scope.interactions.pointerMoveTolerance;
2434
+ }, i.addDocument = function(o, a) {
2435
+ this.scope.addDocument(o, a);
2436
+ }, i.removeDocument = function(o) {
2437
+ this.scope.removeDocument(o);
2438
+ }, i;
2439
+ }(this), this.InteractEvent = nn, this.Interactable = void 0, this.interactables = new ui(this), this._win = void 0, this.document = void 0, this.window = void 0, this.documents = [], this._plugins = { list: [], map: {} }, this.onWindowUnload = function(r) {
2440
+ return e.removeDocument(r.target);
2441
+ };
2442
+ var n = this;
2443
+ this.Interactable = function(r) {
2444
+ q(o, r);
2445
+ var i = ie(o);
2446
+ function o() {
2447
+ return v(this, o), i.apply(this, arguments);
2448
+ }
2449
+ return T(o, [{ key: "_defaults", get: function() {
2450
+ return n.defaults;
2451
+ } }, { key: "set", value: function(a) {
2452
+ return ge(V(o.prototype), "set", this).call(this, a), n.fire("interactable:set", { options: a, interactable: this }), this;
2453
+ } }, { key: "unset", value: function() {
2454
+ ge(V(o.prototype), "unset", this).call(this);
2455
+ var a = n.interactables.list.indexOf(this);
2456
+ a < 0 || (n.interactables.list.splice(a, 1), n.fire("interactable:unset", { interactable: this }));
2457
+ } }]), o;
2458
+ }(ci);
2459
+ }
2460
+ return T(t, [{ key: "addListeners", value: function(e, n) {
2461
+ this.listenerMaps.push({ id: n, map: e });
2462
+ } }, { key: "fire", value: function(e, n) {
2463
+ for (var r = 0, i = this.listenerMaps; r < i.length; r++) {
2464
+ var o = i[r].map[e];
2465
+ if (o && o(n, this, e) === !1) return !1;
2466
+ }
2467
+ } }, { key: "init", value: function(e) {
2468
+ return this.isInitialized ? this : function(n, r) {
2469
+ return n.isInitialized = !0, h.window(r) && C(r), ee.init(r), ae.init(r), Ze.init(r), n.window = r, n.document = r.document, n.usePlugin(li), n.usePlugin(oi), n;
2470
+ }(this, e);
2471
+ } }, { key: "pluginIsInstalled", value: function(e) {
2472
+ var n = e.id;
2473
+ return n ? !!this._plugins.map[n] : this._plugins.list.indexOf(e) !== -1;
2474
+ } }, { key: "usePlugin", value: function(e, n) {
2475
+ if (!this.isInitialized) return this;
2476
+ if (this.pluginIsInstalled(e)) return this;
2477
+ if (e.id && (this._plugins.map[e.id] = e), this._plugins.list.push(e), e.install && e.install(this, n), e.listeners && e.before) {
2478
+ for (var r = 0, i = this.listenerMaps.length, o = e.before.reduce(function(s, l) {
2479
+ return s[l] = !0, s[qn(l)] = !0, s;
2480
+ }, {}); r < i; r++) {
2481
+ var a = this.listenerMaps[r].id;
2482
+ if (a && (o[a] || o[qn(a)])) break;
2483
+ }
2484
+ this.listenerMaps.splice(r, 0, { id: e.id, map: e.listeners });
2485
+ } else e.listeners && this.listenerMaps.push({ id: e.id, map: e.listeners });
2486
+ return this;
2487
+ } }, { key: "addDocument", value: function(e, n) {
2488
+ if (this.getDocIndex(e) !== -1) return !1;
2489
+ var r = E(e);
2490
+ n = n ? A({}, n) : {}, this.documents.push({ doc: e, options: n }), this.events.documents.push(e), e !== this.document && this.events.add(r, "unload", this.onWindowUnload), this.fire("scope:add-document", { doc: e, window: r, scope: this, options: n });
2491
+ } }, { key: "removeDocument", value: function(e) {
2492
+ var n = this.getDocIndex(e), r = E(e), i = this.documents[n].options;
2493
+ this.events.remove(r, "unload", this.onWindowUnload), this.documents.splice(n, 1), this.events.documents.splice(n, 1), this.fire("scope:remove-document", { doc: e, window: r, scope: this, options: i });
2494
+ } }, { key: "getDocIndex", value: function(e) {
2495
+ for (var n = 0; n < this.documents.length; n++) if (this.documents[n].doc === e) return n;
2496
+ return -1;
2497
+ } }, { key: "getDocOptions", value: function(e) {
2498
+ var n = this.getDocIndex(e);
2499
+ return n === -1 ? null : this.documents[n].options;
2500
+ } }, { key: "now", value: function() {
2501
+ return (this.window.Date || Date).now();
2502
+ } }]), t;
2503
+ }();
2504
+ function qn(t) {
2505
+ return t && t.replace(/\/.*$/, "");
2506
+ }
2507
+ var Kn = new pi(), Se = Kn.interactStatic, fi = typeof globalThis < "u" ? globalThis : window;
2508
+ Kn.init(fi);
2509
+ var di = Object.freeze({ __proto__: null, edgeTarget: function() {
2510
+ }, elements: function() {
2511
+ }, grid: function(t) {
2512
+ var e = [["x", "y"], ["left", "top"], ["right", "bottom"], ["width", "height"]].filter(function(r) {
2513
+ var i = r[0], o = r[1];
2514
+ return i in t || o in t;
2515
+ }), n = function(r, i) {
2516
+ for (var o = t.range, a = t.limits, s = a === void 0 ? { left: -1 / 0, right: 1 / 0, top: -1 / 0, bottom: 1 / 0 } : a, l = t.offset, u = l === void 0 ? { x: 0, y: 0 } : l, c = { range: o, grid: t, x: null, y: null }, p = 0; p < e.length; p++) {
2517
+ var g = e[p], w = g[0], x = g[1], S = Math.round((r - u.x) / t[w]), P = Math.round((i - u.y) / t[x]);
2518
+ c[w] = Math.max(s.left, Math.min(s.right, S * t[w] + u.x)), c[x] = Math.max(s.top, Math.min(s.bottom, P * t[x] + u.y));
2519
+ }
2520
+ return c;
2521
+ };
2522
+ return n.grid = t, n.coordFields = e, n;
2523
+ } }), hi = { id: "snappers", install: function(t) {
2524
+ var e = t.interactStatic;
2525
+ e.snappers = A(e.snappers || {}, di), e.createSnapGrid = e.snappers.grid;
2526
+ } }, vi = hi, gi = { start: function(t) {
2527
+ var e = t.state, n = t.rect, r = t.edges, i = t.pageCoords, o = e.options, a = o.ratio, s = o.enabled, l = e.options, u = l.equalDelta, c = l.modifiers;
2528
+ a === "preserve" && (a = n.width / n.height), e.startCoords = A({}, i), e.startRect = A({}, n), e.ratio = a, e.equalDelta = u;
2529
+ var p = e.linkedEdges = { top: r.top || r.left && !r.bottom, left: r.left || r.top && !r.right, bottom: r.bottom || r.right && !r.top, right: r.right || r.bottom && !r.left };
2530
+ if (e.xIsPrimaryAxis = !(!r.left && !r.right), e.equalDelta) {
2531
+ var g = (p.left ? 1 : -1) * (p.top ? 1 : -1);
2532
+ e.edgeSign = { x: g, y: g };
2533
+ } else e.edgeSign = { x: p.left ? -1 : 1, y: p.top ? -1 : 1 };
2534
+ if (s !== !1 && A(r, p), c != null && c.length) {
2535
+ var w = new tn(t.interaction);
2536
+ w.copyFrom(t.interaction.modification), w.prepareStates(c), e.subModification = w, w.startAll(f({}, t));
2537
+ }
2538
+ }, set: function(t) {
2539
+ var e = t.state, n = t.rect, r = t.coords, i = e.linkedEdges, o = A({}, r), a = e.equalDelta ? mi : yi;
2540
+ if (A(t.edges, i), a(e, e.xIsPrimaryAxis, r, n), !e.subModification) return null;
2541
+ var s = A({}, n);
2542
+ nt(i, s, { x: r.x - o.x, y: r.y - o.y });
2543
+ var l = e.subModification.setAll(f(f({}, t), {}, { rect: s, edges: i, pageCoords: r, prevCoords: r, prevRect: s })), u = l.delta;
2544
+ return l.changed && (a(e, Math.abs(u.x) > Math.abs(u.y), l.coords, l.rect), A(r, l.coords)), l.eventProps;
2545
+ }, defaults: { ratio: "preserve", equalDelta: !1, modifiers: [], enabled: !1 } };
2546
+ function mi(t, e, n) {
2547
+ var r = t.startCoords, i = t.edgeSign;
2548
+ e ? n.y = r.y + (n.x - r.x) * i.y : n.x = r.x + (n.y - r.y) * i.x;
2549
+ }
2550
+ function yi(t, e, n, r) {
2551
+ var i = t.startRect, o = t.startCoords, a = t.ratio, s = t.edgeSign;
2552
+ if (e) {
2553
+ var l = r.width / a;
2554
+ n.y = o.y + (l - i.height) * s.y;
2555
+ } else {
2556
+ var u = r.height * a;
2557
+ n.x = o.x + (u - i.width) * s.x;
2558
+ }
2559
+ }
2560
+ var bi = Qe(gi, "aspectRatio"), Jn = function() {
2561
+ };
2562
+ Jn._defaults = {};
2563
+ var Bt = Jn;
2564
+ function at(t, e, n) {
2565
+ return h.func(t) ? Ge(t, e.interactable, e.element, [n.x, n.y, e]) : Ge(t, e.interactable, e.element);
2566
+ }
2567
+ var jt = { start: function(t) {
2568
+ var e = t.rect, n = t.startOffset, r = t.state, i = t.interaction, o = t.pageCoords, a = r.options, s = a.elementRect, l = A({ left: 0, top: 0, right: 0, bottom: 0 }, a.offset || {});
2569
+ if (e && s) {
2570
+ var u = at(a.restriction, i, o);
2571
+ if (u) {
2572
+ var c = u.right - u.left - e.width, p = u.bottom - u.top - e.height;
2573
+ c < 0 && (l.left += c, l.right += c), p < 0 && (l.top += p, l.bottom += p);
2574
+ }
2575
+ l.left += n.left - e.width * s.left, l.top += n.top - e.height * s.top, l.right += n.right - e.width * (1 - s.right), l.bottom += n.bottom - e.height * (1 - s.bottom);
2576
+ }
2577
+ r.offset = l;
2578
+ }, set: function(t) {
2579
+ var e = t.coords, n = t.interaction, r = t.state, i = r.options, o = r.offset, a = at(i.restriction, n, e);
2580
+ if (a) {
2581
+ var s = function(l) {
2582
+ return !l || "left" in l && "top" in l || ((l = A({}, l)).left = l.x || 0, l.top = l.y || 0, l.right = l.right || l.left + l.width, l.bottom = l.bottom || l.top + l.height), l;
2583
+ }(a);
2584
+ e.x = Math.max(Math.min(s.right - o.right, e.x), s.left + o.left), e.y = Math.max(Math.min(s.bottom - o.bottom, e.y), s.top + o.top);
2585
+ }
2586
+ }, defaults: { restriction: null, elementRect: null, offset: null, endOnly: !1, enabled: !1 } }, xi = Qe(jt, "restrict"), Zn = { top: 1 / 0, left: 1 / 0, bottom: -1 / 0, right: -1 / 0 }, Qn = { top: -1 / 0, left: -1 / 0, bottom: 1 / 0, right: 1 / 0 };
2587
+ function er(t, e) {
2588
+ for (var n = 0, r = ["top", "left", "bottom", "right"]; n < r.length; n++) {
2589
+ var i = r[n];
2590
+ i in t || (t[i] = e[i]);
2591
+ }
2592
+ return t;
2593
+ }
2594
+ var St = { noInner: Zn, noOuter: Qn, start: function(t) {
2595
+ var e, n = t.interaction, r = t.startOffset, i = t.state, o = i.options;
2596
+ o && (e = je(at(o.offset, n, n.coords.start.page))), e = e || { x: 0, y: 0 }, i.offset = { top: e.y + r.top, left: e.x + r.left, bottom: e.y - r.bottom, right: e.x - r.right };
2597
+ }, set: function(t) {
2598
+ var e = t.coords, n = t.edges, r = t.interaction, i = t.state, o = i.offset, a = i.options;
2599
+ if (n) {
2600
+ var s = A({}, e), l = at(a.inner, r, s) || {}, u = at(a.outer, r, s) || {};
2601
+ er(l, Zn), er(u, Qn), n.top ? e.y = Math.min(Math.max(u.top + o.top, s.y), l.top + o.top) : n.bottom && (e.y = Math.max(Math.min(u.bottom + o.bottom, s.y), l.bottom + o.bottom)), n.left ? e.x = Math.min(Math.max(u.left + o.left, s.x), l.left + o.left) : n.right && (e.x = Math.max(Math.min(u.right + o.right, s.x), l.right + o.right));
2602
+ }
2603
+ }, defaults: { inner: null, outer: null, offset: null, endOnly: !1, enabled: !1 } }, wi = Qe(St, "restrictEdges"), _i = A({ get elementRect() {
2604
+ return { top: 0, left: 0, bottom: 1, right: 1 };
2605
+ }, set elementRect(t) {
2606
+ } }, jt.defaults), Ei = Qe({ start: jt.start, set: jt.set, defaults: _i }, "restrictRect"), Si = { width: -1 / 0, height: -1 / 0 }, Ti = { width: 1 / 0, height: 1 / 0 }, ki = Qe({ start: function(t) {
2607
+ return St.start(t);
2608
+ }, set: function(t) {
2609
+ var e = t.interaction, n = t.state, r = t.rect, i = t.edges, o = n.options;
2610
+ if (i) {
2611
+ var a = ct(at(o.min, e, t.coords)) || Si, s = ct(at(o.max, e, t.coords)) || Ti;
2612
+ n.options = { endOnly: o.endOnly, inner: A({}, St.noInner), outer: A({}, St.noOuter) }, i.top ? (n.options.inner.top = r.bottom - a.height, n.options.outer.top = r.bottom - s.height) : i.bottom && (n.options.inner.bottom = r.top + a.height, n.options.outer.bottom = r.top + s.height), i.left ? (n.options.inner.left = r.right - a.width, n.options.outer.left = r.right - s.width) : i.right && (n.options.inner.right = r.left + a.width, n.options.outer.right = r.left + s.width), St.set(t), n.options = o;
2613
+ }
2614
+ }, defaults: { min: null, max: null, endOnly: !1, enabled: !1 } }, "restrictSize"), ln = { start: function(t) {
2615
+ var e, n = t.interaction, r = t.interactable, i = t.element, o = t.rect, a = t.state, s = t.startOffset, l = a.options, u = l.offsetWithOrigin ? function(g) {
2616
+ var w = g.interaction.element, x = je(Ge(g.state.options.origin, null, null, [w])), S = x || rt(g.interactable, w, g.interaction.prepared.name);
2617
+ return S;
2618
+ }(t) : { x: 0, y: 0 };
2619
+ if (l.offset === "startCoords") e = { x: n.coords.start.page.x, y: n.coords.start.page.y };
2620
+ else {
2621
+ var c = Ge(l.offset, r, i, [n]);
2622
+ (e = je(c) || { x: 0, y: 0 }).x += u.x, e.y += u.y;
2623
+ }
2624
+ var p = l.relativePoints;
2625
+ a.offsets = o && p && p.length ? p.map(function(g, w) {
2626
+ return { index: w, relativePoint: g, x: s.left - o.width * g.x + e.x, y: s.top - o.height * g.y + e.y };
2627
+ }) : [{ index: 0, relativePoint: null, x: e.x, y: e.y }];
2628
+ }, set: function(t) {
2629
+ var e = t.interaction, n = t.coords, r = t.state, i = r.options, o = r.offsets, a = rt(e.interactable, e.element, e.prepared.name), s = A({}, n), l = [];
2630
+ i.offsetWithOrigin || (s.x -= a.x, s.y -= a.y);
2631
+ for (var u = 0, c = o; u < c.length; u++) for (var p = c[u], g = s.x - p.x, w = s.y - p.y, x = 0, S = i.targets.length; x < S; x++) {
2632
+ var P = i.targets[x], M = void 0;
2633
+ (M = h.func(P) ? P(g, w, e._proxy, p, x) : P) && l.push({ x: (h.number(M.x) ? M.x : g) + p.x, y: (h.number(M.y) ? M.y : w) + p.y, range: h.number(M.range) ? M.range : i.range, source: P, index: x, offset: p });
2634
+ }
2635
+ for (var B = { target: null, inRange: !1, distance: 0, range: 0, delta: { x: 0, y: 0 } }, X = 0; X < l.length; X++) {
2636
+ var Z = l[X], $ = Z.range, G = Z.x - s.x, Te = Z.y - s.y, ce = Ue(G, Te), Pe = ce <= $;
2637
+ $ === 1 / 0 && B.inRange && B.range !== 1 / 0 && (Pe = !1), B.target && !(Pe ? B.inRange && $ !== 1 / 0 ? ce / $ < B.distance / B.range : $ === 1 / 0 && B.range !== 1 / 0 || ce < B.distance : !B.inRange && ce < B.distance) || (B.target = Z, B.distance = ce, B.range = $, B.inRange = Pe, B.delta.x = G, B.delta.y = Te);
2638
+ }
2639
+ return B.inRange && (n.x = B.target.x, n.y = B.target.y), r.closest = B, B;
2640
+ }, defaults: { range: 1 / 0, targets: null, offset: null, offsetWithOrigin: !0, origin: null, relativePoints: null, endOnly: !1, enabled: !1 } }, Di = Qe(ln, "snap"), Ft = { start: function(t) {
2641
+ var e = t.state, n = t.edges, r = e.options;
2642
+ if (!n) return null;
2643
+ t.state = { options: { targets: null, relativePoints: [{ x: n.left ? 0 : 1, y: n.top ? 0 : 1 }], offset: r.offset || "self", origin: { x: 0, y: 0 }, range: r.range } }, e.targetFields = e.targetFields || [["width", "height"], ["x", "y"]], ln.start(t), e.offsets = t.state.offsets, t.state = e;
2644
+ }, set: function(t) {
2645
+ var e = t.interaction, n = t.state, r = t.coords, i = n.options, o = n.offsets, a = { x: r.x - o[0].x, y: r.y - o[0].y };
2646
+ n.options = A({}, i), n.options.targets = [];
2647
+ for (var s = 0, l = i.targets || []; s < l.length; s++) {
2648
+ var u = l[s], c = void 0;
2649
+ if (c = h.func(u) ? u(a.x, a.y, e) : u) {
2650
+ for (var p = 0, g = n.targetFields; p < g.length; p++) {
2651
+ var w = g[p], x = w[0], S = w[1];
2652
+ if (x in c || S in c) {
2653
+ c.x = c[x], c.y = c[S];
2654
+ break;
2655
+ }
2656
+ }
2657
+ n.options.targets.push(c);
2658
+ }
2659
+ }
2660
+ var P = ln.set(t);
2661
+ return n.options = i, P;
2662
+ }, defaults: { range: 1 / 0, targets: null, offset: null, endOnly: !1, enabled: !1 } }, zi = Qe(Ft, "snapSize"), cn = { aspectRatio: bi, restrictEdges: wi, restrict: xi, restrictRect: Ei, restrictSize: ki, snapEdges: Qe({ start: function(t) {
2663
+ var e = t.edges;
2664
+ return e ? (t.state.targetFields = t.state.targetFields || [[e.left ? "left" : "right", e.top ? "top" : "bottom"]], Ft.start(t)) : null;
2665
+ }, set: Ft.set, defaults: A(ht(Ft.defaults), { targets: void 0, range: void 0, offset: { x: 0, y: 0 } }) }, "snapEdges"), snap: Di, snapSize: zi, spring: Bt, avoid: Bt, transform: Bt, rubberband: Bt }, Oi = { id: "modifiers", install: function(t) {
2666
+ var e = t.interactStatic;
2667
+ for (var n in t.usePlugin(Bn), t.usePlugin(vi), e.modifiers = cn, cn) {
2668
+ var r = cn[n], i = r._defaults, o = r._methods;
2669
+ i._methods = o, t.defaults.perAction[n] = i;
2670
+ }
2671
+ } }, Mi = Oi, tr = function(t) {
2672
+ q(n, t);
2673
+ var e = ie(n);
2674
+ function n(r, i, o, a, s, l) {
2675
+ var u;
2676
+ if (v(this, n), it(re(u = e.call(this, s)), o), o !== i && it(re(u), i), u.timeStamp = l, u.originalEvent = o, u.type = r, u.pointerId = ne(i), u.pointerType = qe(i), u.target = a, u.currentTarget = null, r === "tap") {
2677
+ var c = s.getPointerIndex(i);
2678
+ u.dt = u.timeStamp - s.pointers[c].downTime;
2679
+ var p = u.timeStamp - s.tapTime;
2680
+ u.double = !!s.prevTap && s.prevTap.type !== "doubletap" && s.prevTap.target === u.target && p < 500;
2681
+ } else r === "doubletap" && (u.dt = i.timeStamp - s.tapTime, u.double = !0);
2682
+ return u;
2683
+ }
2684
+ return T(n, [{ key: "_subtractOrigin", value: function(r) {
2685
+ var i = r.x, o = r.y;
2686
+ return this.pageX -= i, this.pageY -= o, this.clientX -= i, this.clientY -= o, this;
2687
+ } }, { key: "_addOrigin", value: function(r) {
2688
+ var i = r.x, o = r.y;
2689
+ return this.pageX += i, this.pageY += o, this.clientX += i, this.clientY += o, this;
2690
+ } }, { key: "preventDefault", value: function() {
2691
+ this.originalEvent.preventDefault();
2692
+ } }]), n;
2693
+ }(Je), Tt = { id: "pointer-events/base", before: ["inertia", "modifiers", "auto-start", "actions"], install: function(t) {
2694
+ t.pointerEvents = Tt, t.defaults.actions.pointerEvents = Tt.defaults, A(t.actions.phaselessTypes, Tt.types);
2695
+ }, listeners: { "interactions:new": function(t) {
2696
+ var e = t.interaction;
2697
+ e.prevTap = null, e.tapTime = 0;
2698
+ }, "interactions:update-pointer": function(t) {
2699
+ var e = t.down, n = t.pointerInfo;
2700
+ !e && n.hold || (n.hold = { duration: 1 / 0, timeout: null });
2701
+ }, "interactions:move": function(t, e) {
2702
+ var n = t.interaction, r = t.pointer, i = t.event, o = t.eventTarget;
2703
+ t.duplicate || n.pointerIsDown && !n.pointerWasMoved || (n.pointerIsDown && un(t), tt({ interaction: n, pointer: r, event: i, eventTarget: o, type: "move" }, e));
2704
+ }, "interactions:down": function(t, e) {
2705
+ (function(n, r) {
2706
+ for (var i = n.interaction, o = n.pointer, a = n.event, s = n.eventTarget, l = n.pointerIndex, u = i.pointers[l].hold, c = lt(s), p = { interaction: i, pointer: o, event: a, eventTarget: s, type: "hold", targets: [], path: c, node: null }, g = 0; g < c.length; g++) {
2707
+ var w = c[g];
2708
+ p.node = w, r.fire("pointerEvents:collect-targets", p);
2709
+ }
2710
+ if (p.targets.length) {
2711
+ for (var x = 1 / 0, S = 0, P = p.targets; S < P.length; S++) {
2712
+ var M = P[S].eventable.options.holdDuration;
2713
+ M < x && (x = M);
2714
+ }
2715
+ u.duration = x, u.timeout = setTimeout(function() {
2716
+ tt({ interaction: i, eventTarget: s, pointer: o, event: a, type: "hold" }, r);
2717
+ }, x);
2718
+ }
2719
+ })(t, e), tt(t, e);
2720
+ }, "interactions:up": function(t, e) {
2721
+ un(t), tt(t, e), function(n, r) {
2722
+ var i = n.interaction, o = n.pointer, a = n.event, s = n.eventTarget;
2723
+ i.pointerWasMoved || tt({ interaction: i, eventTarget: s, pointer: o, event: a, type: "tap" }, r);
2724
+ }(t, e);
2725
+ }, "interactions:cancel": function(t, e) {
2726
+ un(t), tt(t, e);
2727
+ } }, PointerEvent: tr, fire: tt, collectEventTargets: nr, defaults: { holdDuration: 600, ignoreFrom: null, allowFrom: null, origin: { x: 0, y: 0 } }, types: { down: !0, move: !0, up: !0, cancel: !0, tap: !0, doubletap: !0, hold: !0 } };
2728
+ function tt(t, e) {
2729
+ var n = t.interaction, r = t.pointer, i = t.event, o = t.eventTarget, a = t.type, s = t.targets, l = s === void 0 ? nr(t, e) : s, u = new tr(a, r, i, o, n, e.now());
2730
+ e.fire("pointerEvents:new", { pointerEvent: u });
2731
+ for (var c = { interaction: n, pointer: r, event: i, eventTarget: o, targets: l, type: a, pointerEvent: u }, p = 0; p < l.length; p++) {
2732
+ var g = l[p];
2733
+ for (var w in g.props || {}) u[w] = g.props[w];
2734
+ var x = rt(g.eventable, g.node);
2735
+ if (u._subtractOrigin(x), u.eventable = g.eventable, u.currentTarget = g.node, g.eventable.fire(u), u._addOrigin(x), u.immediatePropagationStopped || u.propagationStopped && p + 1 < l.length && l[p + 1].node !== u.currentTarget) break;
2736
+ }
2737
+ if (e.fire("pointerEvents:fired", c), a === "tap") {
2738
+ var S = u.double ? tt({ interaction: n, pointer: r, event: i, eventTarget: o, type: "doubletap" }, e) : u;
2739
+ n.prevTap = S, n.tapTime = S.timeStamp;
2740
+ }
2741
+ return u;
2742
+ }
2743
+ function nr(t, e) {
2744
+ var n = t.interaction, r = t.pointer, i = t.event, o = t.eventTarget, a = t.type, s = n.getPointerIndex(r), l = n.pointers[s];
2745
+ if (a === "tap" && (n.pointerWasMoved || !l || l.downTarget !== o)) return [];
2746
+ for (var u = lt(o), c = { interaction: n, pointer: r, event: i, eventTarget: o, type: a, path: u, targets: [], node: null }, p = 0; p < u.length; p++) {
2747
+ var g = u[p];
2748
+ c.node = g, e.fire("pointerEvents:collect-targets", c);
2749
+ }
2750
+ return a === "hold" && (c.targets = c.targets.filter(function(w) {
2751
+ var x, S;
2752
+ return w.eventable.options.holdDuration === ((x = n.pointers[s]) == null || (S = x.hold) == null ? void 0 : S.duration);
2753
+ })), c.targets;
2754
+ }
2755
+ function un(t) {
2756
+ var e = t.interaction, n = t.pointerIndex, r = e.pointers[n].hold;
2757
+ r && r.timeout && (clearTimeout(r.timeout), r.timeout = null);
2758
+ }
2759
+ var Ii = Object.freeze({ __proto__: null, default: Tt });
2760
+ function Pi(t) {
2761
+ var e = t.interaction;
2762
+ e.holdIntervalHandle && (clearInterval(e.holdIntervalHandle), e.holdIntervalHandle = null);
2763
+ }
2764
+ var Ci = { id: "pointer-events/holdRepeat", install: function(t) {
2765
+ t.usePlugin(Tt);
2766
+ var e = t.pointerEvents;
2767
+ e.defaults.holdRepeatInterval = 0, e.types.holdrepeat = t.actions.phaselessTypes.holdrepeat = !0;
2768
+ }, listeners: ["move", "up", "cancel", "endall"].reduce(function(t, e) {
2769
+ return t["pointerEvents:".concat(e)] = Pi, t;
2770
+ }, { "pointerEvents:new": function(t) {
2771
+ var e = t.pointerEvent;
2772
+ e.type === "hold" && (e.count = (e.count || 0) + 1);
2773
+ }, "pointerEvents:fired": function(t, e) {
2774
+ var n = t.interaction, r = t.pointerEvent, i = t.eventTarget, o = t.targets;
2775
+ if (r.type === "hold" && o.length) {
2776
+ var a = o[0].eventable.options.holdRepeatInterval;
2777
+ a <= 0 || (n.holdIntervalHandle = setTimeout(function() {
2778
+ e.pointerEvents.fire({ interaction: n, eventTarget: i, type: "hold", pointer: r, event: r }, e);
2779
+ }, a));
2780
+ }
2781
+ } }) }, Ri = Ci, Ai = { id: "pointer-events/interactableTargets", install: function(t) {
2782
+ var e = t.Interactable;
2783
+ e.prototype.pointerEvents = function(r) {
2784
+ return A(this.events.options, r), this;
2785
+ };
2786
+ var n = e.prototype._backCompatOption;
2787
+ e.prototype._backCompatOption = function(r, i) {
2788
+ var o = n.call(this, r, i);
2789
+ return o === this && (this.events.options[r] = i), o;
2790
+ };
2791
+ }, listeners: { "pointerEvents:collect-targets": function(t, e) {
2792
+ var n = t.targets, r = t.node, i = t.type, o = t.eventTarget;
2793
+ e.interactables.forEachMatch(r, function(a) {
2794
+ var s = a.events, l = s.options;
2795
+ s.types[i] && s.types[i].length && a.testIgnoreAllow(l, r, o) && n.push({ node: r, eventable: s, props: { interactable: a } });
2796
+ });
2797
+ }, "interactable:new": function(t) {
2798
+ var e = t.interactable;
2799
+ e.events.getRect = function(n) {
2800
+ return e.getRect(n);
2801
+ };
2802
+ }, "interactable:set": function(t, e) {
2803
+ var n = t.interactable, r = t.options;
2804
+ A(n.events.options, e.pointerEvents.defaults), A(n.events.options, r.pointerEvents || {});
2805
+ } } }, Bi = Ai, ji = { id: "pointer-events", install: function(t) {
2806
+ t.usePlugin(Ii), t.usePlugin(Ri), t.usePlugin(Bi);
2807
+ } }, Fi = ji, Li = { id: "reflow", install: function(t) {
2808
+ var e = t.Interactable;
2809
+ t.actions.phases.reflow = !0, e.prototype.reflow = function(n) {
2810
+ return function(r, i, o) {
2811
+ for (var a = r.getAllElements(), s = o.window.Promise, l = s ? [] : null, u = function() {
2812
+ var p = a[c], g = r.getRect(p);
2813
+ if (!g) return 1;
2814
+ var w, x = xt(o.interactions.list, function(M) {
2815
+ return M.interacting() && M.interactable === r && M.element === p && M.prepared.name === i.name;
2816
+ });
2817
+ if (x) x.move(), l && (w = x._reflowPromise || new s(function(M) {
2818
+ x._reflowResolve = M;
2819
+ }));
2820
+ else {
2821
+ var S = ct(g), P = /* @__PURE__ */ function(M) {
2822
+ return { coords: M, get page() {
2823
+ return this.coords.page;
2824
+ }, get client() {
2825
+ return this.coords.client;
2826
+ }, get timeStamp() {
2827
+ return this.coords.timeStamp;
2828
+ }, get pageX() {
2829
+ return this.coords.page.x;
2830
+ }, get pageY() {
2831
+ return this.coords.page.y;
2832
+ }, get clientX() {
2833
+ return this.coords.client.x;
2834
+ }, get clientY() {
2835
+ return this.coords.client.y;
2836
+ }, get pointerId() {
2837
+ return this.coords.pointerId;
2838
+ }, get target() {
2839
+ return this.coords.target;
2840
+ }, get type() {
2841
+ return this.coords.type;
2842
+ }, get pointerType() {
2843
+ return this.coords.pointerType;
2844
+ }, get buttons() {
2845
+ return this.coords.buttons;
2846
+ }, preventDefault: function() {
2847
+ } };
2848
+ }({ page: { x: S.x, y: S.y }, client: { x: S.x, y: S.y }, timeStamp: o.now() });
2849
+ w = function(M, B, X, Z, $) {
2850
+ var G = M.interactions.new({ pointerType: "reflow" }), Te = { interaction: G, event: $, pointer: $, eventTarget: X, phase: "reflow" };
2851
+ G.interactable = B, G.element = X, G.prevEvent = $, G.updatePointer($, $, X, !0), Le(G.coords.delta), Jt(G.prepared, Z), G._doPhase(Te);
2852
+ var ce = M.window, Pe = ce.Promise, Re = Pe ? new Pe(function(We) {
2853
+ G._reflowResolve = We;
2854
+ }) : void 0;
2855
+ return G._reflowPromise = Re, G.start(Z, B, X), G._interacting ? (G.move(Te), G.end($)) : (G.stop(), G._reflowResolve()), G.removePointer($, $), Re;
2856
+ }(o, r, p, i, P);
2857
+ }
2858
+ l && l.push(w);
2859
+ }, c = 0; c < a.length && !u(); c++) ;
2860
+ return l && s.all(l).then(function() {
2861
+ return r;
2862
+ });
2863
+ }(this, n, t);
2864
+ };
2865
+ }, listeners: { "interactions:stop": function(t, e) {
2866
+ var n = t.interaction;
2867
+ n.pointerType === "reflow" && (n._reflowResolve && n._reflowResolve(), function(r, i) {
2868
+ r.splice(r.indexOf(i), 1);
2869
+ }(e.interactions.list, n));
2870
+ } } }, $i = Li;
2871
+ if (Se.use(An), Se.use(Nn), Se.use(Fi), Se.use(ri), Se.use(Mi), Se.use(Xr), Se.use(Rr), Se.use(Br), Se.use($i), Se.default = Se, D(y) === "object" && y) try {
2872
+ y.exports = Se;
2873
+ } catch {
2874
+ }
2875
+ return Se.default = Se, Se;
2876
+ });
2877
+ }(zt, zt.exports)), zt.exports;
2878
+ }
2879
+ var Wo = /* @__PURE__ */ Ho();
2880
+ const vr = /* @__PURE__ */ to(Wo), gn = /* @__PURE__ */ mr({
2881
+ __name: "grid-item",
2882
+ props: {
2883
+ isDraggable: { type: Boolean, default: void 0 },
2884
+ isResizable: { type: Boolean, default: void 0 },
2885
+ isBounded: { type: Boolean, default: void 0 },
2886
+ static: { type: Boolean, default: !1 },
2887
+ minH: { default: 1 },
2888
+ minW: { default: 1 },
2889
+ maxH: { default: 1 / 0 },
2890
+ maxW: { default: 1 / 0 },
2891
+ x: {},
2892
+ y: {},
2893
+ w: {},
2894
+ h: {},
2895
+ i: {},
2896
+ dragIgnoreFrom: { default: "a, button" },
2897
+ dragAllowFrom: { default: void 0 },
2898
+ resizeIgnoreFrom: { default: "a, button" },
2899
+ preserveAspectRatio: { type: Boolean, default: !1 },
2900
+ dragOption: { default: () => ({}) },
2901
+ resizeOption: { default: () => ({}) }
2902
+ },
2903
+ emits: ["container-resized", "resize", "resized", "move", "moved"],
2904
+ setup(y, { expose: m, emit: b }) {
2905
+ const f = y, D = b, v = rr(_r), I = rr(Er);
2906
+ if (!v)
2907
+ throw new Error("[grid-layout-plus]: missing layout store, GridItem must under a GridLayout.");
2908
+ const T = Ni(null), d = Yt({
2909
+ cols: 1,
2910
+ containerWidth: 100,
2911
+ rowHeight: 30,
2912
+ margin: [10, 10],
2913
+ maxRows: 1 / 0,
2914
+ draggable: void 0,
2915
+ resizable: void 0,
2916
+ bounded: void 0,
2917
+ transformScale: 1,
2918
+ useCssTransforms: !0,
2919
+ useStyleCursor: !0,
2920
+ isDragging: !1,
2921
+ dragging: {
2922
+ top: -1,
2923
+ left: -1
2924
+ },
2925
+ isResizing: !1,
2926
+ resizing: {
2927
+ width: -1,
2928
+ height: -1
2929
+ },
2930
+ style: {},
2931
+ rtl: !1
2932
+ });
2933
+ let q = !1, V = !1, F = NaN, re = NaN, ie = NaN, ge = NaN, xe = -1, we = -1, _e = -1, R = -1, C = f.x, E = f.y, O = f.w, z = f.h;
2934
+ const h = me(), N = Yt({
2935
+ i: Hi(f, "i"),
2936
+ state: d,
2937
+ wrapper: h,
2938
+ calcXY: Ge
2939
+ });
2940
+ function U(_) {
2941
+ Fe(_);
2942
+ }
2943
+ function se() {
2944
+ bt();
2945
+ }
2946
+ function k(_) {
2947
+ Ce(f.isDraggable) && (d.draggable = _);
2948
+ }
2949
+ function j(_) {
2950
+ Ce(f.isResizable) && (d.resizable = _);
2951
+ }
2952
+ function Q(_) {
2953
+ Ce(f.isBounded) && (d.bounded = _);
2954
+ }
2955
+ function ee(_) {
2956
+ d.transformScale = _;
2957
+ }
2958
+ function oe(_) {
2959
+ d.rowHeight = _;
2960
+ }
2961
+ function ae(_) {
2962
+ d.maxRows = _;
2963
+ }
2964
+ function W() {
2965
+ d.rtl = dr() === "rtl", bt();
2966
+ }
2967
+ function ze(_) {
2968
+ d.cols = Math.floor(_);
2969
+ }
2970
+ v.increaseItem(N), yr(() => {
2971
+ d.rtl = dr() === "rtl";
2972
+ }), br(() => {
2973
+ v.responsive && v.lastBreakpoint ? d.cols = zr(v.lastBreakpoint, v.cols) : d.cols = v.colNum, d.rowHeight = v.rowHeight, d.containerWidth = v.width !== null ? v.width : 100, d.margin = v.margin !== void 0 ? v.margin.map(Number) : [10, 10], d.maxRows = v.maxRows, Ce(f.isDraggable) ? d.draggable = v.isDraggable : d.draggable = f.isDraggable, Ce(f.isResizable) ? d.resizable = v.isResizable : d.resizable = f.isResizable, Ce(f.isBounded) ? d.bounded = v.isBounded : d.bounded = f.isBounded, d.transformScale = v.transformScale, d.useCssTransforms = v.useCssTransforms, d.useStyleCursor = v.useStyleCursor, Wi(() => {
2974
+ C = f.x, E = f.y, z = f.h, O = f.w, ke(Ae);
2975
+ }), I.on("updateWidth", U), I.on("compact", se), I.on("setDraggable", k), I.on("setResizable", j), I.on("setBounded", Q), I.on("setTransformScale", ee), I.on("setRowHeight", oe), I.on("setMaxRows", ae), I.on("directionchange", W), I.on("setColNum", ze);
2976
+ }), xr(() => {
2977
+ I.off("updateWidth", U), I.off("compact", se), I.off("setDraggable", k), I.off("setResizable", j), I.off("setBounded", Q), I.off("setTransformScale", ee), I.off("setRowHeight", oe), I.off("setMaxRows", ae), I.off("directionchange", W), I.off("setColNum", ze), T.value && (T.value.unset(), T.value = null), v.decreaseItem(N);
2978
+ }), m({ state: d, wrapper: h });
2979
+ const de = typeof navigator < "u" ? navigator.userAgent.toLowerCase().includes("android") : !1, K = vt(() => d.resizable && !f.static), le = vt(() => v.isMirrored ? !d.rtl : d.rtl), Be = vt(() => (d.draggable || d.resizable) && !f.static), Oe = Ro("item"), Mt = vt(() => ({
2980
+ [Oe.b()]: !0,
2981
+ [Oe.bm("resizable")]: K.value,
2982
+ [Oe.bm("static")]: f.static,
2983
+ [Oe.bm("resizing")]: d.isResizing,
2984
+ [Oe.bm("dragging")]: d.isDragging,
2985
+ [Oe.bm("transform")]: d.useCssTransforms,
2986
+ [Oe.bm("rtl")]: le.value,
2987
+ [Oe.bm("no-touch")]: de && Be.value
2988
+ })), Xe = vt(() => [Oe.be("resizer"), le.value && Oe.bem("resizer", "rtl")].filter(Boolean));
2989
+ ue(
2990
+ () => f.isDraggable,
2991
+ (_) => {
2992
+ d.draggable = _;
2993
+ }
2994
+ ), ue(
2995
+ () => f.static,
2996
+ () => {
2997
+ ke(it), ke(Le);
2998
+ }
2999
+ ), ue(
3000
+ () => d.draggable,
3001
+ () => {
3002
+ ke(it);
3003
+ }
3004
+ ), ue(
3005
+ () => f.isResizable,
3006
+ (_) => {
3007
+ d.resizable = _;
3008
+ }
3009
+ ), ue(
3010
+ () => f.isBounded,
3011
+ (_) => {
3012
+ d.bounded = _;
3013
+ }
3014
+ ), ue(
3015
+ () => d.resizable,
3016
+ () => {
3017
+ ke(Le);
3018
+ }
3019
+ ), ue(
3020
+ () => d.rowHeight,
3021
+ () => {
3022
+ ke(Ae), ke(lt);
3023
+ }
3024
+ ), ue([() => d.cols, () => d.containerWidth], () => {
3025
+ ke(Le), ke(Ae), ke(lt);
3026
+ }), ue([() => f.minH, () => f.maxH, () => f.minW, () => f.maxW], () => {
3027
+ ke(Le);
3028
+ }), ue(le, () => {
3029
+ ke(Le), ke(Ae);
3030
+ }), ue([() => v.margin, () => v.margin[0], () => v.margin[1]], () => {
3031
+ const _ = v.margin;
3032
+ !_ || _[0] === d.margin[0] && _[1] === d.margin[1] || (d.margin = _.map(Number), ke(Ae), ke(lt));
3033
+ });
3034
+ function Ae() {
3035
+ f.x + f.w > d.cols ? (C = 0, O = f.w > d.cols ? d.cols : f.w) : (C = f.x, O = f.w);
3036
+ const _ = Ve(C, E, O, z);
3037
+ d.isDragging && (_.top = d.dragging.top, le.value ? _.right = d.dragging.left : _.left = d.dragging.left), d.isResizing && (_.width = d.resizing.width, _.height = d.resizing.height);
3038
+ let Y;
3039
+ d.useCssTransforms ? le.value ? Y = Mo(_.top, _.right, _.width, _.height) : Y = Oo(_.top, _.left, _.width, _.height) : le.value ? Y = Po(_.top, _.right, _.width, _.height) : Y = Io(_.top, _.left, _.width, _.height), d.style = Y;
3040
+ }
3041
+ function lt() {
3042
+ const _ = {};
3043
+ for (const Y of ["width", "height"]) {
3044
+ const te = d.style[Y].match(/^(\d+)px$/);
3045
+ if (!te)
3046
+ return;
3047
+ _[Y] = te[1];
3048
+ }
3049
+ D("container-resized", f.i, f.h, f.w, _.height, _.width);
3050
+ }
3051
+ function yt(_) {
3052
+ if (f.static) return;
3053
+ const Y = _.type;
3054
+ if (Y === "resizestart" && d.isResizing || Y !== "resizestart" && !d.isResizing)
3055
+ return;
3056
+ const te = pr(_);
3057
+ if (Ce(te)) return;
3058
+ const { x: ne, y: pe } = te, J = { width: 0, height: 0 };
3059
+ let L;
3060
+ switch (Y) {
3061
+ case "resizestart": {
3062
+ Le(), xe = O, we = z, L = Ve(C, E, O, z), J.width = L.width, J.height = L.height, d.resizing = J, d.isResizing = !0;
3063
+ break;
3064
+ }
3065
+ case "resizemove": {
3066
+ !_.edges.right && !_.edges.left && (ie = ne), !_.edges.top && !_.edges.bottom && (ge = pe);
3067
+ const ye = fr(ie, ge, ne, pe);
3068
+ le.value ? J.width = d.resizing.width - ye.deltaX / d.transformScale : J.width = d.resizing.width + ye.deltaX / d.transformScale, J.height = d.resizing.height + ye.deltaY / d.transformScale, d.resizing = J;
3069
+ break;
3070
+ }
3071
+ case "resizeend": {
3072
+ L = Ve(C, E, O, z), J.width = L.width, J.height = L.height, d.resizing = { width: -1, height: -1 }, d.isResizing = !1;
3073
+ break;
3074
+ }
3075
+ }
3076
+ L = rt(J.height, J.width), L.w < f.minW && (L.w = f.minW), L.w > f.maxW && (L.w = f.maxW), L.h < f.minH && (L.h = f.minH), L.h > f.maxH && (L.h = f.maxH), L.h < 1 && (L.h = 1), L.w < 1 && (L.w = 1), ie = ne, ge = pe, (O !== L.w || z !== L.h) && D("resize", f.i, L.h, L.w, J.height, J.width), _.type === "resizeend" && (xe !== O || we !== z) && D("resized", f.i, L.h, L.w, J.height, J.width), I.emit("resizeEvent", _.type, f.i, C, E, L.h, L.w);
3077
+ }
3078
+ function A(_) {
3079
+ if (f.static || d.isResizing) return;
3080
+ const Y = _.type;
3081
+ if (Y === "dragstart" && d.isDragging || Y !== "dragstart" && !d.isDragging)
3082
+ return;
3083
+ const te = pr(_);
3084
+ if (Ce(te)) return;
3085
+ const { x: ne, y: pe } = te, J = _.target;
3086
+ if (!J.offsetParent) return;
3087
+ const L = { top: 0, left: 0 };
3088
+ switch (Y) {
3089
+ case "dragstart": {
3090
+ _e = C, R = E;
3091
+ const Ee = J.offsetParent.getBoundingClientRect(), Ie = J.getBoundingClientRect(), qe = Ie.left / d.transformScale, Ke = Ee.left / d.transformScale, Je = Ie.right / d.transformScale, pt = Ee.right / d.transformScale, ft = Ie.top / d.transformScale, $e = Ee.top / d.transformScale;
3092
+ le.value ? L.left = (Je - pt) * -1 : L.left = qe - Ke, L.top = ft - $e, d.dragging = L, d.isDragging = !0;
3093
+ break;
3094
+ }
3095
+ case "dragmove": {
3096
+ const Ee = fr(F, re, ne, pe);
3097
+ if (le.value ? L.left = d.dragging.left - Ee.deltaX / d.transformScale : L.left = d.dragging.left + Ee.deltaX / d.transformScale, L.top = d.dragging.top + Ee.deltaY / d.transformScale, d.bounded) {
3098
+ const Ie = J.offsetParent.clientHeight - ct(f.h, d.rowHeight, d.margin[1]);
3099
+ L.top = nt(L.top, 0, Ie);
3100
+ const qe = je(), Ke = d.containerWidth - ct(f.w, qe, d.margin[0]);
3101
+ L.left = nt(L.left, 0, Ke);
3102
+ }
3103
+ d.dragging = L;
3104
+ break;
3105
+ }
3106
+ case "dragend": {
3107
+ const Ee = J.offsetParent.getBoundingClientRect(), Ie = J.getBoundingClientRect(), qe = Ie.left / d.transformScale, Ke = Ee.left / d.transformScale, Je = Ie.right / d.transformScale, pt = Ee.right / d.transformScale, ft = Ie.top / d.transformScale, $e = Ee.top / d.transformScale;
3108
+ le.value ? L.left = (Je - pt) * -1 : L.left = qe - Ke, L.top = ft - $e, d.dragging = { top: -1, left: -1 }, d.isDragging = !1;
3109
+ break;
3110
+ }
3111
+ }
3112
+ let ye;
3113
+ le.value, ye = Ge(L.top, L.left), F = ne, re = pe, (C !== ye.x || E !== ye.y) && D("move", f.i, ye.x, ye.y), _.type === "dragend" && (_e !== C || R !== E) && D("moved", f.i, ye.x, ye.y), I.emit("dragEvent", _.type, f.i, ye.x, ye.y, z, O);
3114
+ }
3115
+ function Ve(_, Y, te, ne) {
3116
+ const pe = je();
3117
+ let J;
3118
+ return le.value ? J = {
3119
+ right: Math.round(pe * _ + (_ + 1) * d.margin[0]),
3120
+ top: Math.round(d.rowHeight * Y + (Y + 1) * d.margin[1]),
3121
+ // 0 * Infinity === NaN, which causes problems with resize constraints;
3122
+ // Fix this if it occurs.
3123
+ // Note we do it here rather than later because Math.round(Infinity) causes depot
3124
+ width: te === 1 / 0 ? te : Math.round(pe * te + Math.max(0, te - 1) * d.margin[0]),
3125
+ height: ne === 1 / 0 ? ne : Math.round(d.rowHeight * ne + Math.max(0, ne - 1) * d.margin[1])
3126
+ } : J = {
3127
+ left: Math.round(pe * _ + (_ + 1) * d.margin[0]),
3128
+ top: Math.round(d.rowHeight * Y + (Y + 1) * d.margin[1]),
3129
+ // 0 * Infinity === NaN, which causes problems with resize constraints;
3130
+ // Fix this if it occurs.
3131
+ // Note we do it here rather than later because Math.round(Infinity) causes depot
3132
+ width: te === 1 / 0 ? te : Math.round(pe * te + Math.max(0, te - 1) * d.margin[0]),
3133
+ height: ne === 1 / 0 ? ne : Math.round(d.rowHeight * ne + Math.max(0, ne - 1) * d.margin[1])
3134
+ }, J;
3135
+ }
3136
+ function Ge(_, Y) {
3137
+ const te = je();
3138
+ let ne = Math.round((Y - d.margin[0]) / (te + d.margin[0])), pe = Math.round((_ - d.margin[1]) / (d.rowHeight + d.margin[1]));
3139
+ return ne = Math.max(Math.min(ne, d.cols - O), 0), pe = Math.max(Math.min(pe, d.maxRows - z), 0), { x: ne, y: pe };
3140
+ }
3141
+ function je() {
3142
+ return (d.containerWidth - d.margin[0] * (d.cols + 1)) / d.cols;
3143
+ }
3144
+ function ct(_, Y, te) {
3145
+ return Number.isFinite(_) ? Math.round(Y * _ + Math.max(0, _ - 1) * te) : _;
3146
+ }
3147
+ function nt(_, Y, te) {
3148
+ return Math.max(Math.min(_, te), Y);
3149
+ }
3150
+ function rt(_, Y, te = !1) {
3151
+ const ne = je();
3152
+ let pe = Math.round((Y + d.margin[0]) / (ne + d.margin[0])), J = 0;
3153
+ return te ? J = Math.ceil((_ + d.margin[1]) / (d.rowHeight + d.margin[1])) : J = Math.round((_ + d.margin[1]) / (d.rowHeight + d.margin[1])), pe = Math.max(Math.min(pe, d.cols - C), 0), J = Math.max(Math.min(J, d.maxRows - E), 0), { w: pe, h: J };
3154
+ }
3155
+ function Fe(_, Y) {
3156
+ d.containerWidth = _;
3157
+ }
3158
+ function bt() {
3159
+ Ae();
3160
+ }
3161
+ function Ue() {
3162
+ !T.value && h.value && (T.value = vr(h.value), d.useStyleCursor || T.value.styleCursor(!1));
3163
+ }
3164
+ const Xt = lr(A);
3165
+ function it() {
3166
+ if (Ue(), !!T.value)
3167
+ if (d.draggable && !f.static) {
3168
+ const _ = {
3169
+ ignoreFrom: f.dragIgnoreFrom,
3170
+ allowFrom: f.dragAllowFrom,
3171
+ ...f.dragOption
3172
+ };
3173
+ T.value.draggable(_), q || (q = !0, T.value.on("dragstart dragmove dragend", (Y) => {
3174
+ Y.type === "dragmove" ? Xt(Y) : A(Y);
3175
+ }));
3176
+ } else
3177
+ T.value.draggable({ enabled: !1 });
3178
+ }
3179
+ const ut = lr(yt);
3180
+ function Le() {
3181
+ if (Ue(), !!T.value)
3182
+ if (d.resizable && !f.static) {
3183
+ const _ = Ve(0, 0, f.maxW, f.maxH), Y = Ve(0, 0, f.minW, f.minH), te = {
3184
+ edges: {
3185
+ left: le.value ? `.${Xe.value[0]}` : !1,
3186
+ right: le.value ? !1 : `.${Xe.value[0]}`,
3187
+ bottom: `.${Xe.value[0]}`,
3188
+ top: !1
3189
+ },
3190
+ ignoreFrom: f.resizeIgnoreFrom,
3191
+ restrictSize: {
3192
+ min: {
3193
+ height: Y.height * d.transformScale,
3194
+ width: Y.width * d.transformScale
3195
+ },
3196
+ max: {
3197
+ height: _.height * d.transformScale,
3198
+ width: _.width * d.transformScale
3199
+ }
3200
+ },
3201
+ ...f.resizeOption
3202
+ };
3203
+ f.preserveAspectRatio && (te.modifiers = [vr.modifiers.aspectRatio({ ratio: "preserve" })]), T.value.resizable(te), V || (V = !0, T.value.on("resizestart resizemove resizeend", (ne) => {
3204
+ ne.type === "resizemove" ? ut(ne) : yt(ne);
3205
+ }));
3206
+ } else
3207
+ T.value.resizable({ enabled: !1 });
3208
+ }
3209
+ return (_, Y) => (fe(), be("section", {
3210
+ ref_key: "wrapper",
3211
+ ref: h,
3212
+ class: ir(Mt.value),
3213
+ style: mn(d.style)
3214
+ }, [
3215
+ dn(_.$slots, "default"),
3216
+ K.value ? (fe(), be("span", {
3217
+ key: 0,
3218
+ class: ir(Xe.value)
3219
+ }, null, 2)) : gt("", !0)
3220
+ ], 6));
3221
+ }
3222
+ }), Yo = /* @__PURE__ */ mr({
3223
+ __name: "grid-layout",
3224
+ props: {
3225
+ autoSize: { type: Boolean, default: !0 },
3226
+ colNum: { default: 12 },
3227
+ rowHeight: { default: 150 },
3228
+ maxRows: { default: 1 / 0 },
3229
+ margin: { default: () => [10, 10] },
3230
+ isDraggable: { type: Boolean, default: !0 },
3231
+ isResizable: { type: Boolean, default: !0 },
3232
+ isMirrored: { type: Boolean, default: !1 },
3233
+ isBounded: { type: Boolean, default: !1 },
3234
+ useCssTransforms: { type: Boolean, default: !0 },
3235
+ verticalCompact: { type: Boolean, default: !0 },
3236
+ restoreOnDrag: { type: Boolean, default: !1 },
3237
+ layout: {},
3238
+ responsive: { type: Boolean, default: !1 },
3239
+ responsiveLayouts: { default: () => ({}) },
3240
+ transformScale: { default: 1 },
3241
+ breakpoints: { default: () => ({ lg: 1200, md: 996, sm: 768, xs: 480, xxs: 0 }) },
3242
+ cols: { default: () => ({ lg: 12, md: 10, sm: 6, xs: 4, xxs: 2 }) },
3243
+ preventCollision: { type: Boolean, default: !1 },
3244
+ useStyleCursor: { type: Boolean, default: !0 }
3245
+ },
3246
+ emits: [
3247
+ "layout-before-mount",
3248
+ "layout-mounted",
3249
+ "layout-updated",
3250
+ "breakpoint-changed",
3251
+ "update:layout",
3252
+ "layout-ready"
3253
+ ],
3254
+ setup(y, { expose: m, emit: b }) {
3255
+ const f = y, D = b, v = Yt({
3256
+ width: -1,
3257
+ mergedStyle: {},
3258
+ lastLayoutLength: 0,
3259
+ isDragging: !1,
3260
+ placeholder: {
3261
+ x: 0,
3262
+ y: 0,
3263
+ w: 0,
3264
+ h: 0,
3265
+ i: ""
3266
+ },
3267
+ layouts: {},
3268
+ // array to store all layouts from different breakpoints
3269
+ lastBreakpoint: null,
3270
+ // store last active breakpoint
3271
+ originalLayout: null
3272
+ // store original Layout
3273
+ }), I = /* @__PURE__ */ new Map(), T = me(f.layout), d = me(), { observeResize: q, unobserveResize: V } = qi(), F = Ki();
3274
+ F.on("resizeEvent", re), F.on("dragEvent", ie), yr(() => {
3275
+ D("layout-before-mount", T.value);
3276
+ }), br(() => {
3277
+ D("layout-mounted", T.value), Ye(() => {
3278
+ Co(T.value), v.originalLayout = T.value, Ye(() => {
3279
+ U(), d.value && q(d.value, Ji(C, 16)), mt(T.value, f.verticalCompact), D("layout-updated", T.value), R(), C();
3280
+ });
3281
+ });
3282
+ }), xr(() => {
3283
+ F.clearAll(), d.value && V(d.value);
3284
+ });
3285
+ function re(k, j, Q, ee, oe, ae) {
3286
+ h(k, j, Q, ee, oe, ae);
3287
+ }
3288
+ function ie(k, j, Q, ee, oe, ae) {
3289
+ z(k, j, Q, ee, oe, ae);
3290
+ }
3291
+ ue(
3292
+ () => v.width,
3293
+ (k, j) => {
3294
+ Ye(() => {
3295
+ F.emit("updateWidth", k), j === -1 && Ye(() => {
3296
+ D("layout-ready", T.value);
3297
+ }), R();
3298
+ });
3299
+ }
3300
+ ), ue(
3301
+ () => [f.layout, f.layout.length],
3302
+ () => {
3303
+ T.value = f.layout, _e();
3304
+ }
3305
+ ), ue(
3306
+ () => f.colNum,
3307
+ (k) => {
3308
+ F.emit("setColNum", k);
3309
+ }
3310
+ ), ue(
3311
+ () => f.rowHeight,
3312
+ (k) => {
3313
+ F.emit("setRowHeight", k);
3314
+ }
3315
+ ), ue(
3316
+ () => f.isDraggable,
3317
+ (k) => {
3318
+ F.emit("setDraggable", k);
3319
+ }
3320
+ ), ue(
3321
+ () => f.isResizable,
3322
+ (k) => {
3323
+ F.emit("setResizable", k);
3324
+ }
3325
+ ), ue(
3326
+ () => f.isBounded,
3327
+ (k) => {
3328
+ F.emit("setBounded", k);
3329
+ }
3330
+ ), ue(
3331
+ () => f.transformScale,
3332
+ (k) => {
3333
+ F.emit("setTransformScale", k);
3334
+ }
3335
+ ), ue(
3336
+ () => f.responsive,
3337
+ (k) => {
3338
+ k || (D("update:layout", v.originalLayout), F.emit("setColNum", f.colNum)), C();
3339
+ }
3340
+ ), ue(
3341
+ () => f.maxRows,
3342
+ (k) => {
3343
+ F.emit("setMaxRows", k);
3344
+ }
3345
+ ), ue([() => f.margin, () => f.margin[1]], R), or(
3346
+ _r,
3347
+ Yt({
3348
+ ...ar(f),
3349
+ ...ar(v),
3350
+ increaseItem: ge,
3351
+ decreaseItem: xe
3352
+ })
3353
+ ), or(Er, F), m({ state: v, getItem: we, resizeEvent: h, dragEvent: z, layoutUpdate: _e });
3354
+ function ge(k) {
3355
+ I.set(k.i, k);
3356
+ }
3357
+ function xe(k) {
3358
+ I.delete(k.i);
3359
+ }
3360
+ function we(k) {
3361
+ return I.get(k);
3362
+ }
3363
+ function _e() {
3364
+ if (!Ce(T.value) && !Ce(v.originalLayout)) {
3365
+ if (T.value.length !== v.originalLayout.length) {
3366
+ const k = se(T.value, v.originalLayout);
3367
+ if (k.length > 0)
3368
+ if (T.value.length > v.originalLayout.length)
3369
+ v.originalLayout = v.originalLayout.concat(k);
3370
+ else {
3371
+ const j = new Set(k.map((Q) => Q.i));
3372
+ v.originalLayout = v.originalLayout.filter((Q) => !j.has(Q.i));
3373
+ }
3374
+ v.lastLayoutLength = T.value.length, U();
3375
+ }
3376
+ mt(T.value, f.verticalCompact), F.emit("updateWidth", v.width), R(), D("layout-updated", T.value);
3377
+ }
3378
+ }
3379
+ function R() {
3380
+ v.mergedStyle = {
3381
+ height: E()
3382
+ };
3383
+ }
3384
+ function C() {
3385
+ d.value && (v.width = d.value.offsetWidth), F.emit("resizeEvent");
3386
+ }
3387
+ function E() {
3388
+ if (!f.autoSize) return;
3389
+ const k = parseFloat(f.margin[1]);
3390
+ return To(T.value) * (f.rowHeight + k) + k + "px";
3391
+ }
3392
+ let O;
3393
+ function z(k, j, Q, ee, oe, ae) {
3394
+ let W = cr(T.value, j);
3395
+ Ce(W) && (W = { h: 0, w: 0, x: 0, y: 0, i: "" }), k === "dragstart" && !f.verticalCompact && (O = T.value.reduce(
3396
+ (ze, { i: de, x: K, y: le }) => ({
3397
+ ...ze,
3398
+ [de]: { x: K, y: le }
3399
+ }),
3400
+ {}
3401
+ )), k === "dragmove" || k === "dragstart" ? (v.placeholder.i = j, v.placeholder.x = W.x, v.placeholder.y = W.y, v.placeholder.w = ae, v.placeholder.h = oe, Ye(() => {
3402
+ v.isDragging = !0;
3403
+ }), F.emit("updateWidth", v.width)) : Ye(() => {
3404
+ v.isDragging = !1;
3405
+ }), T.value = vn(T.value, W, Q, ee, !0, f.preventCollision), f.restoreOnDrag ? (W.static = !0, mt(T.value, f.verticalCompact, O), W.static = !1) : mt(T.value, f.verticalCompact), F.emit("compact"), R(), k === "dragend" && (O = void 0, D("layout-updated", T.value));
3406
+ }
3407
+ function h(k, j, Q, ee, oe, ae) {
3408
+ let W = cr(T.value, j);
3409
+ Ce(W) && (W = { h: 0, w: 0, x: 0, y: 0, i: "" });
3410
+ let ze;
3411
+ if (f.preventCollision) {
3412
+ const de = Tr(T.value, { ...W, w: ae, h: oe }).filter(
3413
+ (K) => K.i !== W.i
3414
+ );
3415
+ if (ze = de.length > 0, ze) {
3416
+ let K = 1 / 0, le = 1 / 0;
3417
+ de.forEach((Be) => {
3418
+ Be.x > W.x && (K = Math.min(K, Be.x)), Be.y > W.y && (le = Math.min(le, Be.y));
3419
+ }), Number.isFinite(K) && (W.w = K - W.x), Number.isFinite(le) && (W.h = le - W.y);
3420
+ }
3421
+ }
3422
+ ze || (W.w = ae, W.h = oe), k === "resizestart" || k === "resizemove" ? (v.placeholder.i = j, v.placeholder.x = Q, v.placeholder.y = ee, v.placeholder.w = W.w, v.placeholder.h = W.h, Ye(() => {
3423
+ v.isDragging = !0;
3424
+ }), F.emit("updateWidth", v.width)) : k && Ye(() => {
3425
+ v.isDragging = !1;
3426
+ }), f.responsive && N(), mt(T.value, f.verticalCompact), F.emit("compact"), R(), k === "resizeend" && D("layout-updated", T.value);
3427
+ }
3428
+ function N() {
3429
+ const k = jo(f.breakpoints, v.width);
3430
+ if (k === v.lastBreakpoint)
3431
+ return;
3432
+ const j = zr(k, f.cols);
3433
+ !Ce(v.lastBreakpoint) && !v.layouts[v.lastBreakpoint] && (v.layouts[v.lastBreakpoint] = hn(T.value));
3434
+ const Q = Fo(
3435
+ v.originalLayout,
3436
+ v.layouts,
3437
+ f.breakpoints,
3438
+ k,
3439
+ v.lastBreakpoint,
3440
+ j,
3441
+ f.verticalCompact
3442
+ );
3443
+ v.layouts[k] = Q, v.lastBreakpoint !== k && D("breakpoint-changed", k, Q), T.value = Q, D("update:layout", Q), v.lastBreakpoint = k, F.emit("setColNum", j);
3444
+ }
3445
+ function U() {
3446
+ v.layouts = Object.assign({}, f.responsiveLayouts);
3447
+ }
3448
+ function se(k, j) {
3449
+ const Q = new Set(j.map((W) => W.i)), ee = new Set(k.map((W) => W.i)), oe = k.filter((W) => !Q.has(W.i)), ae = j.filter((W) => !ee.has(W.i));
3450
+ return oe.concat(ae);
3451
+ }
3452
+ return (k, j) => (fe(), be("div", {
3453
+ ref_key: "wrapper",
3454
+ ref: d,
3455
+ class: "vgl-layout",
3456
+ style: mn(v.mergedStyle)
3457
+ }, [
3458
+ k.$slots.default ? dn(k.$slots, "default", { key: 0 }) : (fe(!0), be(Nt, { key: 1 }, Ht(T.value, (Q) => (fe(), Wt(gn, Xi({
3459
+ key: Q.i,
3460
+ ref_for: !0
3461
+ }, Q), {
3462
+ default: Me(() => [
3463
+ dn(k.$slots, "item", { item: Q })
3464
+ ]),
3465
+ _: 2
3466
+ }, 1040))), 128)),
3467
+ Yi(he(gn, {
3468
+ class: "vgl-item--placeholder",
3469
+ x: v.placeholder.x,
3470
+ y: v.placeholder.y,
3471
+ w: v.placeholder.w,
3472
+ h: v.placeholder.h,
3473
+ i: v.placeholder.i
3474
+ }, null, 8, ["x", "y", "w", "h", "i"]), [
3475
+ [Vi, v.isDragging]
3476
+ ])
3477
+ ], 4));
3478
+ }
3479
+ }), Xo = { style: { display: "flex" } }, Vo = {
3480
+ __name: "index",
3481
+ setup(y) {
3482
+ const m = xn(yn), { itemData: b, activeItemIndex: f } = bn(m), D = me([]), v = me(null), I = me(null), T = me(12), d = me(4), q = me(15), V = me([]), F = (E) => {
3483
+ var N;
3484
+ if (!E) return;
3485
+ let O = null;
3486
+ const z = De(D.value);
3487
+ if (f.value >= 0 && (O = z == null ? void 0 : z[f.value]), O && O.comp === "Layout") {
3488
+ const { compData: U = [] } = O;
3489
+ ((N = U == null ? void 0 : U.find((k) => {
3490
+ const { key: j } = k;
3491
+ return j === "children";
3492
+ })) == null ? void 0 : N.contents).push({
3493
+ comp: E.comp,
3494
+ name: E.name,
3495
+ compData: []
3496
+ }), m.setItemData(z);
3497
+ return;
3498
+ }
3499
+ const h = De(D.value);
3500
+ h.push({
3501
+ comp: E.comp,
3502
+ name: E.name,
3503
+ compData: []
3504
+ }), m.setItemData(h), m.setItemGridData(V.value), console.log("栅格结构数据:", V.value);
3505
+ }, re = (E) => {
3506
+ E.preventDefault(), E.dataTransfer.dropEffect = "copy";
3507
+ }, ie = async (E) => {
3508
+ try {
3509
+ const O = E.dataTransfer.getData("application/json");
3510
+ if (!O) return;
3511
+ const z = JSON.parse(O), h = await ge(E), N = xe(z, h);
3512
+ await Ye(), we(N), F(JSON.parse(O || "")), _e();
3513
+ } catch (O) {
3514
+ console.error("Drop error:", O), _e();
3515
+ }
3516
+ }, ge = async (E) => v.value ? new Promise((O) => {
3517
+ requestAnimationFrame(() => {
3518
+ const z = v.value.getBoundingClientRect(), h = E.clientX - z.left, N = E.clientY, U = Math.floor(h / (z.width / T.value)), se = Math.floor(N / (z.width / T.value));
3519
+ O({
3520
+ x: Math.max(0, U),
3521
+ y: Math.max(0, se),
3522
+ w: T.value,
3523
+ h: q.value
3524
+ });
3525
+ });
3526
+ }) : { x: 0, y: 0 }, xe = (E, O) => {
3527
+ var h, N;
3528
+ const z = `item_${Date.now()}_${(N = (h = Math.random()) == null ? void 0 : h.toString(36)) == null ? void 0 : N.substring(2, 9)}`;
3529
+ return {
3530
+ i: z,
3531
+ id: z,
3532
+ x: O.x,
3533
+ y: O.y,
3534
+ w: O.w,
3535
+ h: O.h,
3536
+ component: {
3537
+ ...E,
3538
+ comp: E.comp,
3539
+ compData: E.compData,
3540
+ itemChildData: E.itemChildData
3541
+ },
3542
+ minW: 2,
3543
+ minH: 2
3544
+ };
3545
+ }, we = (E) => {
3546
+ V.value = [...V.value, E];
3547
+ }, _e = () => {
3548
+ document.querySelectorAll(".dragging").forEach((E) => {
3549
+ E.classList.remove("dragging");
3550
+ });
3551
+ }, R = (E) => {
3552
+ V.value = E == null ? void 0 : E.map((O, z) => ({
3553
+ x: z % 2 * 6,
3554
+ y: Math.floor(z / 2) * 7,
3555
+ w: T.value,
3556
+ h: q.value,
3557
+ minW: d.value,
3558
+ minH: q.value,
3559
+ i: z,
3560
+ id: O == null ? void 0 : O.id,
3561
+ component: E[z]
3562
+ })), m.setItemGridData(V.value);
3563
+ };
3564
+ ue(
3565
+ () => b.value,
3566
+ () => {
3567
+ var E;
3568
+ !b.value || ((E = b.value) == null ? void 0 : E.length) === 0 ? D.value = [] : D.value = De(b.value), R(D.value);
3569
+ },
3570
+ { deep: !0, immediate: !0 }
3571
+ );
3572
+ const C = (E) => wr(E);
3573
+ return (E, O) => (fe(), be("div", {
3574
+ ref_key: "containerRef",
3575
+ ref: v,
3576
+ style: { width: "100%", height: "100%", "margin-top": "10px" },
3577
+ onDragover: re,
3578
+ onDrop: ie
3579
+ }, [
3580
+ he(sr(Yo), {
3581
+ ref_key: "gridLayoutRef",
3582
+ ref: I,
3583
+ layout: V.value,
3584
+ "onUpdate:layout": O[0] || (O[0] = (z) => V.value = z),
3585
+ "row-height": q.value,
3586
+ "is-draggable": !0,
3587
+ "is-resizable": !0
3588
+ }, {
3589
+ default: Me(() => [
3590
+ (fe(!0), be(Nt, null, Ht(V.value, (z, h) => (fe(), Wt(sr(gn), {
3591
+ key: z.i,
3592
+ x: z.x,
3593
+ y: z.y,
3594
+ w: z.w,
3595
+ h: z.h,
3596
+ i: z.i
3597
+ }, {
3598
+ default: Me(() => {
3599
+ var N, U, se, k;
3600
+ return [
3601
+ ve("div", Xo, st((N = z == null ? void 0 : z.component) == null ? void 0 : N.name), 1),
3602
+ (fe(), Wt(gr(C((U = z == null ? void 0 : z.component) == null ? void 0 : U.comp)), {
3603
+ itemData: (se = z == null ? void 0 : z.component) == null ? void 0 : se.compData,
3604
+ childItemData: (k = z == null ? void 0 : z.component) == null ? void 0 : k.itemChildData,
3605
+ key: h
3606
+ }, null, 8, ["itemData", "childItemData"]))
3607
+ ];
3608
+ }),
3609
+ _: 2
3610
+ }, 1032, ["x", "y", "w", "h", "i"]))), 128))
3611
+ ]),
3612
+ _: 1
3613
+ }, 8, ["layout", "row-height"])
3614
+ ], 544));
3615
+ }
3616
+ }, ia = /* @__PURE__ */ wn(Vo, [["__scopeId", "data-v-1eedea10"]]);
3617
+ export {
3618
+ ia as a,
3619
+ ra as b,
3620
+ na as m
3621
+ };