@xtctwins/tctwins-bimx-engine 0.2.55 → 0.3.1

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 (104) hide show
  1. package/dist/{alert-C0MgdbKf.mjs → Alert-CSiEPFGt.mjs} +5 -5
  2. package/dist/{AnnotationTool-CPBZcbp_.mjs → AnnotationTool-CKzHkqWM.mjs} +80 -80
  3. package/dist/BIMX_Viewer_Lib.es.js +1 -1
  4. package/dist/BIMX_Viewer_Lib.umd.js +224 -169
  5. package/dist/{CommentTool-ChVib2Wg.mjs → CommentTool-5HhGDqpg.mjs} +575 -555
  6. package/dist/{HiddenTool-CilrXe5l.mjs → HiddenTool-BGFoHMWC.mjs} +9 -9
  7. package/dist/{InspectorTool-BXArGZHO.mjs → InspectorTool-DD3w7k07.mjs} +27 -27
  8. package/dist/{MeasureTool-DtUiP4t1.mjs → MeasureTool-COR8QLDf.mjs} +118 -94
  9. package/dist/{MouseTool-2Nxz447f.mjs → MouseTool-OxODcO4X.mjs} +27 -24
  10. package/dist/{NavigateTool-COsSnxyD.mjs → NavigateTool-Bw6GFzsg.mjs} +5 -5
  11. package/dist/{panel.vue_vue_type_style_index_0_lang-CN9vybau.mjs → Panel.vue_vue_type_style_index_0_lang-DgM_qGLO.mjs} +4 -4
  12. package/dist/{RoamTool-CjRywSYn.mjs → RoamTool-X-b0hsmJ.mjs} +7 -7
  13. package/dist/ScreenShotTool-0xSJZBBw.mjs +430 -0
  14. package/dist/SectionTool-BqI2Qnk5.mjs +343 -0
  15. package/dist/SettingTool-CGkRGfZH.mjs +747 -0
  16. package/dist/StructureTree-CWAXoI0r.mjs +1662 -0
  17. package/dist/{tallPanel-Ddd7gAie.mjs → TallPanel-CR5vNQ4c.mjs} +8 -8
  18. package/dist/bimTools-D3TraX9d.mjs +75 -0
  19. package/dist/el-slider-CBVU9_og.mjs +1040 -0
  20. package/dist/{index-DTeJ8S3e.mjs → index-CwRGVhoT.mjs} +44953 -46755
  21. package/dist/style.css +1 -1
  22. package/package.json +4 -3
  23. package/types/components/bcf/AddObjectOrAnno.vue.d.ts +16 -0
  24. package/types/components/bcf/BCFAddPanel.vue.d.ts +55 -0
  25. package/types/components/bcf/BCFDetailPanel.vue.d.ts +59 -0
  26. package/types/components/bcf/BCFDisplayList.vue.d.ts +18 -0
  27. package/types/components/bcf/BCFFilter.vue.d.ts +14 -0
  28. package/types/components/bcf/BCFTool.vue.d.ts +15 -0
  29. package/types/components/bcf/CheckObjectPanel.vue.d.ts +11 -0
  30. package/types/components/bcf/CommentInput.vue.d.ts +51 -0
  31. package/types/components/bcf/CommentsView.vue.d.ts +48 -0
  32. package/types/components/bcf/DialogPanel.vue.d.ts +15 -0
  33. package/types/components/bcf/ImageView.vue.d.ts +17 -0
  34. package/types/components/bcf/ImageZoomIn.vue.d.ts +9 -0
  35. package/types/components/bcf/MobileBCFAdd.vue.d.ts +56 -0
  36. package/types/components/bcf/MobileBCFDetail.vue.d.ts +55 -0
  37. package/types/components/bcf/MobileBCFDisplayList.vue.d.ts +498 -0
  38. package/types/components/bcf/MobileBCFFilter.vue.d.ts +475 -0
  39. package/types/components/bcf/MobileBCFTool.vue.d.ts +17 -0
  40. package/types/components/bcf/MobileCommentInput.vue.d.ts +54 -0
  41. package/types/components/bcf/MobileCommentsView.vue.d.ts +17 -0
  42. package/types/components/bcf/SelectPanel.vue.d.ts +12 -0
  43. package/types/components/comment/mobile/MobileCommentAdd.vue.d.ts +14 -0
  44. package/types/components/comment/mobile/MobileDetail.vue.d.ts +11 -0
  45. package/types/components/comment/mobile/MobileDraw.vue.d.ts +17 -0
  46. package/types/components/comment/mobile/MobileFilter.vue.d.ts +475 -0
  47. package/types/components/comment/mobile/MobileList.vue.d.ts +497 -0
  48. package/types/components/comment/mobile/MobileZoomIn.vue.d.ts +9 -0
  49. package/types/components/comment/pc/PcDraw.vue.d.ts +14 -0
  50. package/types/components/shared/Alert.vue.d.ts +32 -0
  51. package/types/components/shared/CloseButton.vue.d.ts +50 -0
  52. package/types/components/shared/CloseButtonDark.vue.d.ts +32 -0
  53. package/types/components/shared/EmptyPage.vue.d.ts +6 -0
  54. package/types/components/shared/Loading.vue.d.ts +2 -0
  55. package/types/components/shared/Panel.vue.d.ts +47 -0
  56. package/types/components/shared/Prompt.vue.d.ts +8 -0
  57. package/types/components/shared/RectangleButton.vue.d.ts +106 -0
  58. package/types/components/shared/TallPanel.vue.d.ts +69 -0
  59. package/types/components/shared/TallPanelNoPos.vue.d.ts +82 -0
  60. package/types/components/tools/AnnotationTool.vue.d.ts +14 -0
  61. package/types/components/tools/AppToolbar.vue.d.ts +27 -0
  62. package/types/components/tools/ClickEvent.vue.d.ts +6 -0
  63. package/types/components/tools/CommentTool.vue.d.ts +45 -0
  64. package/types/components/tools/HiddenTool.vue.d.ts +12 -0
  65. package/types/components/tools/InspectorTool.vue.d.ts +14 -0
  66. package/types/components/tools/MeasureTool.vue.d.ts +14 -0
  67. package/types/components/tools/MouseTool.vue.d.ts +6 -0
  68. package/types/components/tools/NavigateTool.vue.d.ts +10 -0
  69. package/types/components/tools/RoamTool.vue.d.ts +12 -0
  70. package/types/components/tools/ScreenShotTool.vue.d.ts +10 -0
  71. package/types/components/tools/SectionTool.vue.d.ts +14 -0
  72. package/types/components/tools/SettingTool.vue.d.ts +13 -0
  73. package/types/components/tools/StructureTree.vue.d.ts +11645 -0
  74. package/types/components/tools/Toolbar.vue.d.ts +10 -0
  75. package/types/composables/useBimViewerEvent.d.ts +44 -0
  76. package/types/composables/useEmitHandler.d.ts +2 -0
  77. package/types/composables/useToolActive.d.ts +1 -0
  78. package/types/composables/useToolReady.d.ts +1 -0
  79. package/types/i18n/index.d.ts +5 -1
  80. package/types/i18n/locales/en-US.d.ts +1 -0
  81. package/types/i18n/locales/zh-CN.d.ts +1 -0
  82. package/types/store/bcfReflect.d.ts +13 -81
  83. package/types/store/const/app.d.ts +66 -0
  84. package/types/store/const/bimTools.d.ts +81 -0
  85. package/types/store/const/project.d.ts +48 -0
  86. package/types/store/const/theme.d.ts +16 -0
  87. package/types/store/const/toolbar.d.ts +26 -0
  88. package/types/store/const.d.ts +11 -228
  89. package/types/store/toolbars.d.ts +22 -0
  90. package/types/store/userInfoStore.d.ts +1 -1
  91. package/types/stores/viewerStore.d.ts +112 -0
  92. package/types/types/bcf.d.ts +83 -0
  93. package/types/types/events.d.ts +88 -0
  94. package/types/utils/OSSHelper.d.ts +27 -0
  95. package/types/utils/cacheInfo.d.ts +26 -3
  96. package/types/utils/dbscan.d.ts +1 -0
  97. package/types/utils/eventBus.d.ts +1 -83
  98. package/types/viewerManager/viewerManager.d.ts +53 -3
  99. package/dist/ScreenShotTool-g1dzvqn2.mjs +0 -500
  100. package/dist/SectionTool-DlnlE6Pv.mjs +0 -331
  101. package/dist/SettingTool-y_hp2XrJ.mjs +0 -815
  102. package/dist/StructureTree-CtJ4Yf5_.mjs +0 -1846
  103. package/dist/const-DOnRsYpZ.mjs +0 -389
  104. package/dist/el-input-number-BjEspzGk.mjs +0 -1169
@@ -1,35 +1,38 @@
1
- import { defineComponent as Y, onMounted as x, onBeforeUnmount as A, ref as _, watch as C, createElementBlock as M, openBlock as $, withDirectives as D, createElementVNode as g, normalizeStyle as F, unref as L, vShow as N } from "vue";
2
- import { B as R, D as s, O as V, V as k } from "./index-DTeJ8S3e.mjs";
3
- const U = { class: "mouse_tool" }, z = ["src"], P = ["src"], J = /* @__PURE__ */ Y({
1
+ import { defineComponent as Y, onMounted as x, onBeforeUnmount as A, ref as _, watch as C, openBlock as M, createElementBlock as $, withDirectives as D, createElementVNode as p, normalizeStyle as F, unref as V, vShow as N } from "vue";
2
+ import { B as R, D as s, O as L, Q as U, V as k } from "./index-CwRGVhoT.mjs";
3
+ const z = { class: "mouse_tool" }, P = ["src"], Q = ["src"], J = /* @__PURE__ */ Y({
4
4
  __name: "MouseTool",
5
5
  props: ["componentId"],
6
6
  setup(O) {
7
- const p = R(), y = O;
7
+ const y = R(), w = O;
8
8
  x(() => {
9
- p.setReadyById(y.componentId), document.getElementById("top_bar");
9
+ y.setReadyById(w.componentId), document.getElementById("top_bar");
10
10
  });
11
11
  let t;
12
- const w = () => {
13
- t = window.bimViewer, t.eventTrigger.on("pickedNothing", () => {
14
- l.value = !1;
12
+ const E = () => {
13
+ t = window.bimViewer, U({
14
+ event: "pickedNothing",
15
+ handler: () => {
16
+ l.value = !1;
17
+ }
15
18
  }), t.viewer.cameraControl.on("touchmoveCanvas", () => {
16
19
  o = !1, n = "";
17
20
  });
18
21
  };
19
- s.on("BimViewer", w);
20
- const E = () => {
22
+ s.on("BimViewer", E);
23
+ const g = () => {
21
24
  l.value = !1, o = !1;
22
- }, T = () => {
25
+ }, j = () => {
23
26
  };
24
- s.on("unFocus", E), s.on("multiSelect", T), A(() => {
25
- s.off("BimViewer", w), s.off("unFocus", E);
27
+ s.on("unFocus", g), s.on("multiSelect", j), A(() => {
28
+ s.off("BimViewer", E), s.off("unFocus", g);
26
29
  });
27
30
  const c = _(290), i = _(300), l = _(!1);
28
31
  let d = !1, o = !1, r = 0, a = 0, m = 0, v = 0;
29
32
  C(
30
- () => p.isToolActive(y.componentId),
33
+ () => y.isToolActive(w.componentId),
31
34
  (e) => {
32
- e ? j() : (o = !1, d = !1, r = 0, a = 0, m = 0, v = 0, X());
35
+ e ? T() : (o = !1, d = !1, r = 0, a = 0, m = 0, v = 0, X());
33
36
  }
34
37
  );
35
38
  let n = "";
@@ -50,29 +53,29 @@ const U = { class: "mouse_tool" }, z = ["src"], P = ["src"], J = /* @__PURE__ */
50
53
  });
51
54
  u ? (o = !0, n !== u.entity.id && (n = u.entity.id, t.setAllObjectsSelected(!1), t.setEntitySelected(u.entity))) : (o = !1, n = "", t.setAllObjectsSelected(!1)), k.entityState.selectedObjectIds.length > 0 && t.setObjectsSelected(k.entityState.selectedObjectIds, !0), r = f, a = b;
52
55
  }
53
- }, j = () => {
56
+ }, T = () => {
54
57
  const e = document.getElementById("mouseGroup");
55
58
  e == null || e.addEventListener("touchstart", S), e == null || e.addEventListener("touchmove", I), e == null || e.addEventListener("click", B), c.value = 290, i.value = 300;
56
59
  }, X = () => {
57
60
  const e = document.getElementById("mouseGroup");
58
61
  e == null || e.removeEventListener("touchstart", S), e == null || e.removeEventListener("touchmove", I), e == null || e.removeEventListener("click", B);
59
62
  };
60
- return (e, f) => ($(), M("div", U, [
61
- D(g("div", {
63
+ return (e, f) => (M(), $("div", z, [
64
+ D(p("div", {
62
65
  id: "mouseGroup",
63
66
  class: "mouse_group",
64
67
  style: F({ left: `${c.value}px`, top: `${i.value}px` })
65
68
  }, [
66
- g("img", {
69
+ p("img", {
67
70
  id: "mouse_icon",
68
71
  class: "mouse_icon",
69
- src: `${L(V)}/industry-viewer/mouse-icon.svg`
70
- }, null, 8, z),
71
- g("img", {
72
+ src: `${V(L)}/industry-viewer/mouse-icon.svg`
73
+ }, null, 8, P),
74
+ p("img", {
72
75
  id: "mouse_img",
73
76
  class: "mouse_img",
74
- src: `${L(V)}/industry-viewer/mouse-active-large.svg`
75
- }, null, 8, P)
77
+ src: `${V(L)}/industry-viewer/mouse-active-large.svg`
78
+ }, null, 8, Q)
76
79
  ], 4), [
77
80
  [N, !l.value]
78
81
  ])
@@ -1,6 +1,6 @@
1
- import { defineComponent as b, onMounted as p, ref as w, createElementBlock as n, openBlock as i, createElementVNode as s, Fragment as g, renderList as f, unref as a, normalizeClass as h, toDisplayString as B } from "vue";
2
- import { A as I, B as N, O as S } from "./index-DTeJ8S3e.mjs";
3
- import { N as T } from "./const-DOnRsYpZ.mjs";
1
+ import { defineComponent as b, onMounted as p, ref as w, openBlock as n, createElementBlock as i, createElementVNode as s, Fragment as g, renderList as f, unref as a, normalizeClass as h, toDisplayString as B } from "vue";
2
+ import { A as I, B as N, O as S } from "./index-CwRGVhoT.mjs";
3
+ import { N as T } from "./bimTools-D3TraX9d.mjs";
4
4
  const k = { class: "best-view-box" }, A = { class: "best-view-list" }, V = ["onClick"], x = { class: "best-view-icon" }, y = ["src"], C = { class: "best-view-name" }, R = /* @__PURE__ */ b({
5
5
  __name: "NavigateTool",
6
6
  props: ["componentId"],
@@ -26,9 +26,9 @@ const k = { class: "best-view-box" }, A = { class: "best-view-list" }, V = ["onC
26
26
  }
27
27
  });
28
28
  };
29
- return (t, E) => (i(), n("div", k, [
29
+ return (t, E) => (n(), i("div", k, [
30
30
  s("div", A, [
31
- (i(!0), n(g, null, f(a(T), (e) => (i(), n("div", {
31
+ (n(!0), i(g, null, f(a(T), (e) => (n(), i("div", {
32
32
  key: e.id,
33
33
  class: h(["best-view-item", {
34
34
  "best-view-item-active": o.value === e.id
@@ -1,8 +1,8 @@
1
- import { H as r, T as o } from "./index-DTeJ8S3e.mjs";
2
- import { defineComponent as c, ref as u, onMounted as p, createBlock as m, openBlock as h, unref as l, withCtx as _, createElementVNode as e, normalizeStyle as g, toDisplayString as f, createVNode as w, renderSlot as k } from "vue";
1
+ import { H as r, T as o } from "./index-CwRGVhoT.mjs";
2
+ import { defineComponent as c, ref as u, onMounted as p, openBlock as m, createBlock as h, unref as l, withCtx as _, createElementVNode as e, normalizeStyle as g, toDisplayString as f, createVNode as w, renderSlot as k } from "vue";
3
3
  import { ElDialog as v } from "element-plus";
4
4
  const y = { class: "panel_top" }, T = { class: "panel_title" }, V = { class: "panel_close" }, S = { class: "panel_content" }, C = /* @__PURE__ */ c({
5
- __name: "panel",
5
+ __name: "Panel",
6
6
  props: {
7
7
  panelTitle: {
8
8
  type: String,
@@ -23,7 +23,7 @@ const y = { class: "panel_top" }, T = { class: "panel_title" }, V = { class: "pa
23
23
  return p(() => {
24
24
  }), (i, a) => {
25
25
  const d = r;
26
- return h(), m(l(v), {
26
+ return m(), h(l(v), {
27
27
  class: "panel_dialog",
28
28
  modelValue: n.value,
29
29
  "onUpdate:modelValue": a[0] || (a[0] = (s) => n.value = s),
@@ -1,5 +1,5 @@
1
- import { defineComponent as H, ref as u, onMounted as j, onBeforeUnmount as q, watch as z, createElementBlock as h, openBlock as b, createCommentVNode as L, unref as r, createElementVNode as e, toDisplayString as m } from "vue";
2
- import { B as J, A as K, C as c, M as S, D as M, O as l, P as V, I as Q } from "./index-DTeJ8S3e.mjs";
1
+ import { defineComponent as H, ref as u, onMounted as j, onBeforeUnmount as q, watch as z, openBlock as h, createElementBlock as b, unref as r, createElementVNode as e, toDisplayString as m, createCommentVNode as L } from "vue";
2
+ import { B as J, A as K, C as c, M as S, D as M, O as l, P as V, I as Q } from "./index-CwRGVhoT.mjs";
3
3
  const W = { class: "roam_container_wrapper" }, Y = {
4
4
  key: 0,
5
5
  class: "roam_container"
@@ -150,8 +150,8 @@ const W = { class: "roam_container_wrapper" }, Y = {
150
150
  }
151
151
  });
152
152
  };
153
- return (t, o) => (b(), h("div", W, [
154
- !r(c)("isMobile") && g.value ? (b(), h("div", Y, [
153
+ return (t, o) => (h(), b("div", W, [
154
+ !r(c)("isMobile") && g.value ? (h(), b("div", Y, [
155
155
  e("div", Z, m(r(v)("roam.courseTitle")), 1),
156
156
  e("img", {
157
157
  class: "container_img",
@@ -169,7 +169,7 @@ const W = { class: "roam_container_wrapper" }, Y = {
169
169
  }, m(r(v)("roam.gotIt")), 1)
170
170
  ])
171
171
  ])) : L("", !0),
172
- r(c)("isMobile") ? L("", !0) : (b(), h("div", te, [
172
+ r(c)("isMobile") ? L("", !0) : (h(), b("div", te, [
173
173
  e("div", se, [
174
174
  e("div", ne, [
175
175
  e("div", re, m(r(v)("roam.speedLabel")), 1),
@@ -204,7 +204,7 @@ const W = { class: "roam_container_wrapper" }, Y = {
204
204
  ])
205
205
  ])
206
206
  ])),
207
- r(c)("isMobile") ? (b(), h("div", ue, [
207
+ r(c)("isMobile") ? (h(), b("div", ue, [
208
208
  e("div", me, [
209
209
  e("div", ce, [
210
210
  e("div", ve, [
@@ -281,7 +281,7 @@ const W = { class: "roam_container_wrapper" }, Y = {
281
281
  ])) : L("", !0)
282
282
  ]));
283
283
  }
284
- }), Oe = /* @__PURE__ */ Q(xe, [["__scopeId", "data-v-566257e2"]]);
284
+ }), Oe = /* @__PURE__ */ Q(xe, [["__scopeId", "data-v-3c440223"]]);
285
285
  export {
286
286
  Oe as default
287
287
  };
@@ -0,0 +1,430 @@
1
+ import { _ as _e } from "./Panel.vue_vue_type_style_index_0_lang-DgM_qGLO.mjs";
2
+ import { a7 as U, l as K, a8 as q, d as G, a9 as Y, b as N, aa as W, ab as he, f as H, n as X, a as Se, ac as Ve, ad as Ee, u as $, ae as Re, af as ke, ag as Be, y as Ce, N as Ie, ah as Pe, ai as J, w as xe, A as we, B as Ne, F as ze } from "./index-CwRGVhoT.mjs";
3
+ import { ref as B, inject as Te, computed as h, defineComponent as z, openBlock as R, createElementBlock as C, normalizeClass as E, unref as e, createElementVNode as y, withDirectives as Q, withModifiers as x, isRef as Z, vModelRadio as ee, renderSlot as A, createTextVNode as w, toDisplayString as I, nextTick as te, normalizeStyle as Le, onMounted as ae, provide as Ue, reactive as $e, toRefs as Ae, watch as oe, Fragment as le, renderList as se, createBlock as ne, resolveDynamicComponent as De, mergeProps as Fe, withCtx as T, createVNode as P, createCommentVNode as Oe } from "vue";
4
+ import { a as L } from "./bimTools-D3TraX9d.mjs";
5
+ const ie = N({
6
+ /**
7
+ * @description binding value
8
+ */
9
+ modelValue: {
10
+ type: [
11
+ String,
12
+ Number,
13
+ Boolean
14
+ ],
15
+ default: void 0
16
+ },
17
+ /**
18
+ * @description size of the Radio
19
+ */
20
+ size: W,
21
+ /**
22
+ * @description whether Radio is disabled
23
+ */
24
+ disabled: {
25
+ type: Boolean,
26
+ default: void 0
27
+ },
28
+ /**
29
+ * @description the label of Radio
30
+ */
31
+ label: {
32
+ type: [
33
+ String,
34
+ Number,
35
+ Boolean
36
+ ],
37
+ default: void 0
38
+ },
39
+ /**
40
+ * @description the value of Radio
41
+ */
42
+ value: {
43
+ type: [
44
+ String,
45
+ Number,
46
+ Boolean
47
+ ],
48
+ default: void 0
49
+ },
50
+ /**
51
+ * @description native `name` attribute
52
+ */
53
+ name: {
54
+ type: String,
55
+ default: void 0
56
+ }
57
+ }), Me = N({
58
+ ...ie,
59
+ /**
60
+ * @description whether to add a border around Radio
61
+ */
62
+ border: Boolean
63
+ }), re = {
64
+ [Y]: (o) => K(o) || q(o) || G(o),
65
+ [U]: (o) => K(o) || q(o) || G(o)
66
+ }, de = Symbol("radioGroupKey"), je = N({ ...ie }), ue = {
67
+ label: "label",
68
+ value: "value",
69
+ disabled: "disabled"
70
+ }, Ke = N({
71
+ /**
72
+ * @description native `id` attribute
73
+ */
74
+ id: {
75
+ type: String,
76
+ default: void 0
77
+ },
78
+ /**
79
+ * @description the size of radio buttons or bordered radios
80
+ */
81
+ size: W,
82
+ /**
83
+ * @description whether the nesting radios are disabled
84
+ */
85
+ disabled: {
86
+ type: Boolean,
87
+ default: void 0
88
+ },
89
+ /**
90
+ * @description binding value
91
+ */
92
+ modelValue: {
93
+ type: [
94
+ String,
95
+ Number,
96
+ Boolean
97
+ ],
98
+ default: void 0
99
+ },
100
+ /**
101
+ * @description border and background color when button is active
102
+ */
103
+ fill: {
104
+ type: String,
105
+ default: ""
106
+ },
107
+ /**
108
+ * @description font color when button is active
109
+ */
110
+ textColor: {
111
+ type: String,
112
+ default: ""
113
+ },
114
+ /**
115
+ * @description native `name` attribute
116
+ */
117
+ name: {
118
+ type: String,
119
+ default: void 0
120
+ },
121
+ /**
122
+ * @description whether to trigger form validation
123
+ */
124
+ validateEvent: {
125
+ type: Boolean,
126
+ default: !0
127
+ },
128
+ options: { type: H(Array) },
129
+ props: {
130
+ type: H(Object),
131
+ default: () => ue
132
+ },
133
+ type: {
134
+ type: String,
135
+ values: ["radio", "button"],
136
+ default: "radio"
137
+ },
138
+ ...he(["ariaLabel"])
139
+ }), qe = re, ce = (o, S) => {
140
+ const l = B(), r = Te(de, void 0), s = h(() => !!r), f = h(() => X(o.value) ? o.label : o.value), c = h({
141
+ get() {
142
+ return s.value ? r.modelValue : o.modelValue;
143
+ },
144
+ set(g) {
145
+ s.value ? r.changeEvent(g) : S && S("update:modelValue", g), l.value.checked = o.modelValue === f.value;
146
+ }
147
+ }), i = Se(h(() => r == null ? void 0 : r.size)), n = Ve(h(() => r == null ? void 0 : r.disabled)), b = B(!1), v = h(() => n.value || s.value && c.value !== f.value ? -1 : 0);
148
+ return Ee({
149
+ from: "label act as value",
150
+ replacement: "value",
151
+ version: "3.0.0",
152
+ scope: "el-radio",
153
+ ref: "https://element-plus.org/en-US/component/radio.html"
154
+ }, h(() => s.value && X(o.value))), {
155
+ radioRef: l,
156
+ isGroup: s,
157
+ radioGroup: r,
158
+ focus: b,
159
+ size: i,
160
+ disabled: n,
161
+ tabIndex: v,
162
+ modelValue: c,
163
+ actualValue: f
164
+ };
165
+ }, Ge = [
166
+ "value",
167
+ "name",
168
+ "disabled",
169
+ "checked"
170
+ ];
171
+ var He = /* @__PURE__ */ z({
172
+ name: "ElRadio",
173
+ __name: "radio",
174
+ props: Me,
175
+ emits: re,
176
+ setup(o, { emit: S }) {
177
+ const l = o, r = S, s = $("radio"), { radioRef: f, radioGroup: c, focus: i, size: n, disabled: b, modelValue: v, actualValue: g } = ce(l, r);
178
+ function d() {
179
+ te(() => r(U, v.value));
180
+ }
181
+ return (k, a) => {
182
+ var t;
183
+ return R(), C("label", { class: E([
184
+ e(s).b(),
185
+ e(s).is("disabled", e(b)),
186
+ e(s).is("focus", e(i)),
187
+ e(s).is("bordered", o.border),
188
+ e(s).is("checked", e(v) === e(g)),
189
+ e(s).m(e(n))
190
+ ]) }, [y("span", { class: E([
191
+ e(s).e("input"),
192
+ e(s).is("disabled", e(b)),
193
+ e(s).is("checked", e(v) === e(g))
194
+ ]) }, [Q(y("input", {
195
+ ref_key: "radioRef",
196
+ ref: f,
197
+ "onUpdate:modelValue": a[0] || (a[0] = (m) => Z(v) ? v.value = m : null),
198
+ class: E(e(s).e("original")),
199
+ value: e(g),
200
+ name: o.name || ((t = e(c)) == null ? void 0 : t.name),
201
+ disabled: e(b),
202
+ checked: e(v) === e(g),
203
+ type: "radio",
204
+ onFocus: a[1] || (a[1] = (m) => i.value = !0),
205
+ onBlur: a[2] || (a[2] = (m) => i.value = !1),
206
+ onChange: d,
207
+ onClick: a[3] || (a[3] = x(() => {
208
+ }, ["stop"]))
209
+ }, null, 42, Ge), [[ee, e(v)]]), y("span", { class: E(e(s).e("inner")) }, null, 2)], 2), y("span", {
210
+ class: E(e(s).e("label")),
211
+ onKeydown: a[4] || (a[4] = x(() => {
212
+ }, ["stop"]))
213
+ }, [A(k.$slots, "default", {}, () => [w(I(o.label), 1)])], 34)], 2);
214
+ };
215
+ }
216
+ }), me = He;
217
+ const Xe = [
218
+ "value",
219
+ "name",
220
+ "disabled"
221
+ ];
222
+ var Ye = /* @__PURE__ */ z({
223
+ name: "ElRadioButton",
224
+ __name: "radio-button",
225
+ props: je,
226
+ setup(o) {
227
+ const S = o, l = $("radio"), { radioRef: r, focus: s, size: f, disabled: c, modelValue: i, radioGroup: n, actualValue: b } = ce(S), v = h(() => ({
228
+ backgroundColor: (n == null ? void 0 : n.fill) || "",
229
+ borderColor: (n == null ? void 0 : n.fill) || "",
230
+ boxShadow: n != null && n.fill ? `-1px 0 0 0 ${n.fill}` : "",
231
+ color: (n == null ? void 0 : n.textColor) || ""
232
+ }));
233
+ return (g, d) => {
234
+ var k;
235
+ return R(), C("label", { class: E([
236
+ e(l).b("button"),
237
+ e(l).is("active", e(i) === e(b)),
238
+ e(l).is("disabled", e(c)),
239
+ e(l).is("focus", e(s)),
240
+ e(l).bm("button", e(f))
241
+ ]) }, [Q(y("input", {
242
+ ref_key: "radioRef",
243
+ ref: r,
244
+ "onUpdate:modelValue": d[0] || (d[0] = (a) => Z(i) ? i.value = a : null),
245
+ class: E(e(l).be("button", "original-radio")),
246
+ value: e(b),
247
+ type: "radio",
248
+ name: o.name || ((k = e(n)) == null ? void 0 : k.name),
249
+ disabled: e(c),
250
+ onFocus: d[1] || (d[1] = (a) => s.value = !0),
251
+ onBlur: d[2] || (d[2] = (a) => s.value = !1),
252
+ onClick: d[3] || (d[3] = x(() => {
253
+ }, ["stop"]))
254
+ }, null, 42, Xe), [[ee, e(i)]]), y("span", {
255
+ class: E(e(l).be("button", "inner")),
256
+ style: Le(e(i) === e(b) ? v.value : {}),
257
+ onKeydown: d[4] || (d[4] = x(() => {
258
+ }, ["stop"]))
259
+ }, [A(g.$slots, "default", {}, () => [w(I(o.label), 1)])], 38)], 2);
260
+ };
261
+ }
262
+ }), D = Ye;
263
+ const We = [
264
+ "id",
265
+ "aria-label",
266
+ "aria-labelledby"
267
+ ];
268
+ var Je = /* @__PURE__ */ z({
269
+ name: "ElRadioGroup",
270
+ __name: "radio-group",
271
+ props: Ke,
272
+ emits: qe,
273
+ setup(o, { emit: S }) {
274
+ const l = o, r = S, s = $("radio"), f = Re(), c = B(), { formItem: i } = ke(), { inputId: n, isLabeledByFormItem: b } = Be(l, { formItemContext: i }), v = (t) => {
275
+ r(Y, t), te(() => r(U, t));
276
+ };
277
+ ae(() => {
278
+ const t = c.value.querySelectorAll("[type=radio]"), m = t[0];
279
+ !Array.from(t).some((u) => u.checked) && m && (m.tabIndex = 0);
280
+ });
281
+ const g = h(() => l.name || f.value), d = h(() => ({
282
+ ...ue,
283
+ ...l.props
284
+ })), k = (t) => {
285
+ const { label: m, value: u, disabled: _ } = d.value, V = {
286
+ label: t[m],
287
+ value: t[u],
288
+ disabled: t[_]
289
+ };
290
+ return {
291
+ ...Pe(t, [
292
+ m,
293
+ u,
294
+ _
295
+ ]),
296
+ ...V
297
+ };
298
+ }, a = h(() => l.type === "button" ? D : me);
299
+ return Ue(de, $e({
300
+ ...Ae(l),
301
+ changeEvent: v,
302
+ name: g
303
+ })), oe(() => l.modelValue, (t, m) => {
304
+ l.validateEvent && !Ce(t, m) && (i == null || i.validate("change").catch(Ie));
305
+ }), (t, m) => (R(), C("div", {
306
+ id: e(n),
307
+ ref_key: "radioGroupRef",
308
+ ref: c,
309
+ class: E(e(s).b("group")),
310
+ role: "radiogroup",
311
+ "aria-label": e(b) ? void 0 : o.ariaLabel || "radio-group",
312
+ "aria-labelledby": e(b) ? e(i).labelId : void 0
313
+ }, [A(t.$slots, "default", {}, () => [(R(!0), C(le, null, se(o.options, (u, _) => (R(), ne(De(a.value), Fe({ key: _ }, { ref_for: !0 }, k(u)), null, 16))), 128))])], 10, We));
314
+ }
315
+ }), pe = Je;
316
+ const Qe = xe(me, {
317
+ RadioButton: D,
318
+ RadioGroup: pe
319
+ }), Ze = J(pe);
320
+ J(D);
321
+ const et = { class: "wrapper" }, tt = { class: "screen_thumbnail" }, at = ["src"], ot = { class: "validity-period" }, lt = {
322
+ key: 0,
323
+ class: "custom"
324
+ }, st = { class: "footer" }, ut = /* @__PURE__ */ z({
325
+ __name: "ScreenShotTool",
326
+ props: ["componentId"],
327
+ emits: ["closePanel"],
328
+ setup(o, { emit: S }) {
329
+ const l = we(), r = Ne(), s = o, f = B(0), c = B(), i = B(), n = B(), b = S;
330
+ ae(() => {
331
+ c.value = 1280, i.value = 720, r.setReadyById(s.componentId);
332
+ }), oe(
333
+ () => r.isToolActive(s.componentId),
334
+ (a) => {
335
+ a && d(220, 124, !1);
336
+ }
337
+ );
338
+ const v = (a) => {
339
+ f.value = a, a !== 3 && (c.value = L[a].width, i.value = L[a].height);
340
+ }, g = () => {
341
+ b("closePanel");
342
+ }, d = (a, t, m) => {
343
+ const u = document.getElementById("myCanvas"), _ = document.createElement("a");
344
+ _.download = "screenshot.png";
345
+ const V = document.createElement("canvas"), p = V.getContext("2d");
346
+ if (u && p) {
347
+ V.width = a, V.height = t;
348
+ const ve = a / u.width, fe = t / u.height, F = Math.max(ve, fe), O = u.width * F, M = u.height * F, be = (a - O) / 2, ge = (t - M) / 2;
349
+ p.clearRect(0, 0, a, t), p.fillStyle = "transparent", p.fillRect(0, 0, a, t), p.drawImage(u, 0, 0, u.width, u.height, be, ge, O, M), m ? V.toBlob(function(ye) {
350
+ const j = URL.createObjectURL(ye);
351
+ _.href = j, _.click(), URL.revokeObjectURL(j);
352
+ }) : n.value = V.toDataURL("image/png");
353
+ }
354
+ }, k = () => {
355
+ d(c.value, i.value, !0);
356
+ };
357
+ return (a, t) => {
358
+ const m = Qe, u = Ze, _ = ze, V = _e;
359
+ return R(), ne(V, {
360
+ class: "screen_container",
361
+ width: 240,
362
+ panelTitle: e(l)("screenshot.title"),
363
+ "click-handle": g
364
+ }, {
365
+ default: T(() => [
366
+ y("div", et, [
367
+ y("div", tt, [
368
+ y("img", {
369
+ class: "thumbnail_img",
370
+ src: n.value,
371
+ alt: ""
372
+ }, null, 8, at)
373
+ ]),
374
+ P(u, {
375
+ modelValue: f.value,
376
+ "onUpdate:modelValue": t[0] || (t[0] = (p) => f.value = p),
377
+ onChange: v
378
+ }, {
379
+ default: T(() => [
380
+ y("div", ot, [
381
+ (R(!0), C(le, null, se(e(L), (p) => (R(), C("div", {
382
+ key: p.id,
383
+ class: "period_box"
384
+ }, [
385
+ P(m, {
386
+ value: p.id
387
+ }, {
388
+ default: T(() => [
389
+ w(I(p.name || e(l)(p.label ?? "")), 1)
390
+ ]),
391
+ _: 2
392
+ }, 1032, ["value"])
393
+ ]))), 128))
394
+ ])
395
+ ]),
396
+ _: 1
397
+ }, 8, ["modelValue"]),
398
+ f.value === 3 ? (R(), C("div", lt, [
399
+ P(_, {
400
+ modelValue: c.value,
401
+ "onUpdate:modelValue": t[1] || (t[1] = (p) => c.value = p),
402
+ placeholder: e(l)("screenshot.widthPlaceholder")
403
+ }, null, 8, ["modelValue", "placeholder"]),
404
+ t[3] || (t[3] = w(" x ", -1)),
405
+ P(_, {
406
+ modelValue: i.value,
407
+ "onUpdate:modelValue": t[2] || (t[2] = (p) => i.value = p),
408
+ placeholder: e(l)("screenshot.heightPlaceholder")
409
+ }, null, 8, ["modelValue", "placeholder"])
410
+ ])) : Oe("", !0),
411
+ y("div", st, [
412
+ y("div", {
413
+ class: "btn1",
414
+ onClick: g
415
+ }, I(e(l)("common.cancel")), 1),
416
+ y("div", {
417
+ class: "btn2",
418
+ onClick: k
419
+ }, I(e(l)("common.save")), 1)
420
+ ])
421
+ ])
422
+ ]),
423
+ _: 1
424
+ }, 8, ["panelTitle"]);
425
+ };
426
+ }
427
+ });
428
+ export {
429
+ ut as default
430
+ };