@xtctwins/tctwins-bimx-engine 0.3.9 → 0.3.11

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 (41) hide show
  1. package/dist/{AnnotationTool-BN1cQJZT.mjs → AnnotationTool-BnLd0s38.mjs} +2 -2
  2. package/dist/AnnotationTool-Bp8DGFFA.mjs +167 -0
  3. package/dist/BIMX_Viewer_Lib.es.js +1 -1
  4. package/dist/BIMX_Viewer_Lib.umd.js +119 -119
  5. package/dist/{CameraViewTool-DoHrCSBa.mjs → CameraViewTool-BGmwAori.mjs} +1 -1
  6. package/dist/CameraViewTool-BwVnc0ua.mjs +164 -0
  7. package/dist/{CommentTool-DzpiIRq5.mjs → CommentTool-B9TgO52t.mjs} +1 -1
  8. package/dist/CommentTool-C7NLPxMd.mjs +1529 -0
  9. package/dist/{HiddenTool-DKl-Td4d.mjs → HiddenTool-CNMJqZzC.mjs} +1 -1
  10. package/dist/HiddenTool-i1AESn4-.mjs +57 -0
  11. package/dist/{InspectorTool-ButMlfJZ.mjs → InspectorTool-CiyN_aCB.mjs} +29 -28
  12. package/dist/InspectorTool-D4gr7uiQ.mjs +679 -0
  13. package/dist/{MeasureTool-HA7KurNk.mjs → MeasureTool-BNBUx-1X.mjs} +2 -2
  14. package/dist/MeasureTool-Cxnp9MVY.mjs +323 -0
  15. package/dist/{MouseTool-Cx7FUkja.mjs → MouseTool-B07SstRZ.mjs} +1 -1
  16. package/dist/MouseTool-DVqNDADf.mjs +84 -0
  17. package/dist/{NavigateTool-CHspxjfw.mjs → NavigateTool-B8qIl9xy.mjs} +1 -1
  18. package/dist/NavigateTool-DKTSPVCL.mjs +52 -0
  19. package/dist/{RoamTool-CvErAJ4s.mjs → RoamTool-3sDI1Ouu.mjs} +1 -1
  20. package/dist/RoamTool-CazuxheL.mjs +287 -0
  21. package/dist/{ScreenShotTool-BKFYnVZ5.mjs → ScreenShotTool-CjsT2-Va.mjs} +2 -2
  22. package/dist/ScreenShotTool-fYVxpPrW.mjs +430 -0
  23. package/dist/{SectionTool-Dc_qndpy.mjs → SectionTool-Bpk5jewK.mjs} +4 -4
  24. package/dist/SectionTool-DMSGkjYm.mjs +331 -0
  25. package/dist/{SettingTool-BYVwI27m.mjs → SettingTool-BuSm2JB6.mjs} +3 -3
  26. package/dist/SettingTool-IBRpWdfo.mjs +695 -0
  27. package/dist/{StructureTree-CNrEg0TP.mjs → StructureTree-B183vT5b.mjs} +3 -3
  28. package/dist/StructureTree-D9z28tm4.mjs +1686 -0
  29. package/dist/{alert-BE0cXifr.mjs → alert-DN7oOiZl.mjs} +1 -1
  30. package/dist/alert-DwTFq4bp.mjs +47 -0
  31. package/dist/{el-slider-D_kA0TiT.mjs → el-slider-C9_q447A.mjs} +1 -1
  32. package/dist/el-slider-dslleM3g.mjs +1059 -0
  33. package/dist/index-BzB8rqmg.mjs +131961 -0
  34. package/dist/{index-s9bhlFsR.mjs → index-DfRswjrC.mjs} +19136 -18956
  35. package/dist/{panel.vue_vue_type_style_index_0_lang-D0m8xJuR.mjs → panel.vue_vue_type_style_index_0_lang-DOsptET6.mjs} +1 -1
  36. package/dist/panel.vue_vue_type_style_index_0_lang-E8w23EhV.mjs +61 -0
  37. package/dist/style.css +1 -1
  38. package/dist/{tallPanel-C_lzWM4i.mjs → tallPanel-D0Zgkc3n.mjs} +1 -1
  39. package/dist/tallPanel-Dp1ZbCTR.mjs +84 -0
  40. package/package.json +3 -2
  41. package/types/viewerManager/load/loadModel.d.ts +23 -0
@@ -1,4 +1,4 @@
1
- import { G as Y, H as z, I as x, V as A, P as y, M as G } from "./index-s9bhlFsR.mjs";
1
+ import { G as Y, H as z, I as x, V as A, P as y, M as G } from "./index-BzB8rqmg.mjs";
2
2
  import { defineComponent as O, ref as l, watch as k, onMounted as W, onBeforeUnmount as j, openBlock as u, createElementBlock as g, normalizeClass as T, createElementVNode as t, createBlock as q, withCtx as F, unref as B, withDirectives as I, vModelText as N, createCommentVNode as J } from "vue";
3
3
  const K = { class: "cameraView_tool_btn" }, Q = ["src"], Z = {
4
4
  key: 1,
@@ -0,0 +1,164 @@
1
+ import { G as Y, H as z, I as x, V as A, P as y, M as G } from "./index-DfRswjrC.mjs";
2
+ import { defineComponent as O, ref as l, watch as k, onMounted as W, onBeforeUnmount as j, openBlock as u, createElementBlock as g, normalizeClass as T, createElementVNode as t, createBlock as q, withCtx as F, unref as B, withDirectives as I, vModelText as N, createCommentVNode as J } from "vue";
3
+ const K = { class: "cameraView_tool_btn" }, Q = ["src"], Z = {
4
+ key: 1,
5
+ class: "cameraView_tool_btn"
6
+ }, ee = ["src"], te = { class: "dialog-container" }, oe = { class: "dialog-header" }, ae = { class: "dialog-content" }, se = { class: "preview-shot" }, ne = ["src"], le = { class: "form-group" }, ie = { class: "form-group" }, ce = { class: "dialog-footer" }, re = /* @__PURE__ */ O({
7
+ __name: "CameraViewTool",
8
+ props: ["componentId", "instruction"],
9
+ emits: ["emitHandler"],
10
+ setup(E, { emit: S }) {
11
+ const V = Y();
12
+ let v;
13
+ const w = l(!z("isMobile")), p = E;
14
+ k(
15
+ () => V.isToolActive(p.componentId),
16
+ (o) => {
17
+ }
18
+ ), k(
19
+ () => p.instruction,
20
+ (o) => {
21
+ if (o && o.instruct_name == "setCameraView") {
22
+ const e = o.content.cameraView;
23
+ v.flyToNewView({ ...e, duration: 1 });
24
+ }
25
+ },
26
+ { deep: !0 }
27
+ ), W(() => {
28
+ V.setReadyById(p.componentId);
29
+ });
30
+ const _ = () => {
31
+ v = window.bimViewer, window.bimViewer.eventTrigger;
32
+ };
33
+ x.on("BimViewer", _);
34
+ const H = (o, e) => {
35
+ const a = document.getElementById("myCanvas"), s = document.createElement("a");
36
+ s.download = "screenshot.png";
37
+ const d = document.createElement("canvas"), i = d.getContext("2d");
38
+ if (a && i) {
39
+ d.width = o, d.height = e;
40
+ const D = o / a.width, L = e / a.height, b = Math.max(D, L), C = a.width * b, h = a.height * b, P = (o - C) / 2, X = (e - h) / 2;
41
+ return i.clearRect(0, 0, o, e), i.fillStyle = "transparent", i.fillRect(0, 0, o, e), i.drawImage(a, 0, 0, a.width, a.height, P, X, C, h), d.toDataURL("image/png");
42
+ } else
43
+ return "";
44
+ }, M = S, R = (o) => {
45
+ M("emitHandler", o);
46
+ }, c = l(""), r = l(""), n = l(!1), m = l(""), f = l(), U = () => {
47
+ n.value = !0, f.value = v.getCameraView(), m.value = H(220, 124);
48
+ }, $ = () => {
49
+ R({
50
+ isTool: !0,
51
+ event_target: "CameraViewTool",
52
+ event_name: "newCameraView",
53
+ content: {
54
+ cameraView: f.value,
55
+ title: c.value,
56
+ description: r.value,
57
+ img_data: m.value
58
+ }
59
+ }), n.value = !1, c.value = "", r.value = "", f.value = null, m.value = "";
60
+ };
61
+ return j(() => {
62
+ x.off("BimViewer", _);
63
+ }), (o, e) => {
64
+ const a = A;
65
+ return u(), g("div", {
66
+ class: T(["cameraView_component", { is_mobile: !w.value }])
67
+ }, [
68
+ t("div", {
69
+ class: "new_btn",
70
+ onClick: U
71
+ }, [
72
+ w.value ? (u(), q(a, {
73
+ key: 0,
74
+ content: "添加视角",
75
+ placement: "top",
76
+ effect: "light"
77
+ }, {
78
+ default: F(() => [
79
+ t("div", K, [
80
+ t("img", {
81
+ class: "img",
82
+ src: `${B(y)}/bim-viewer/cameraView/cameraViewNew.svg`,
83
+ alt: ""
84
+ }, null, 8, Q)
85
+ ])
86
+ ]),
87
+ _: 1
88
+ })) : (u(), g("div", Z, [
89
+ t("img", {
90
+ class: "img",
91
+ src: `${B(y)}/bim-viewer/cameraView/cameraViewNew.svg`,
92
+ alt: ""
93
+ }, null, 8, ee)
94
+ ]))
95
+ ]),
96
+ n.value ? (u(), g("div", {
97
+ key: 0,
98
+ class: T(["newViewDialog", { mobile_dialog: !w.value }])
99
+ }, [
100
+ t("div", {
101
+ class: "dialog-overlay",
102
+ onClick: e[0] || (e[0] = (s) => n.value = !1)
103
+ }),
104
+ t("div", te, [
105
+ t("div", oe, [
106
+ e[6] || (e[6] = t("span", { class: "dialog-title" }, "添加视角", -1)),
107
+ t("button", {
108
+ class: "dialog-close",
109
+ onClick: e[1] || (e[1] = (s) => n.value = !1)
110
+ }, [...e[5] || (e[5] = [
111
+ t("span", null, "✕", -1)
112
+ ])])
113
+ ]),
114
+ t("div", ae, [
115
+ t("div", se, [
116
+ t("img", {
117
+ src: m.value,
118
+ alt: "视角预览"
119
+ }, null, 8, ne)
120
+ ]),
121
+ t("div", le, [
122
+ e[7] || (e[7] = t("label", { class: "form-label" }, "视角名称", -1)),
123
+ I(t("input", {
124
+ "onUpdate:modelValue": e[2] || (e[2] = (s) => c.value = s),
125
+ type: "text",
126
+ class: "form-input",
127
+ placeholder: "请输入视角名称",
128
+ maxlength: "50"
129
+ }, null, 512), [
130
+ [N, c.value]
131
+ ])
132
+ ]),
133
+ t("div", ie, [
134
+ e[8] || (e[8] = t("label", { class: "form-label" }, "视角描述", -1)),
135
+ I(t("textarea", {
136
+ "onUpdate:modelValue": e[3] || (e[3] = (s) => r.value = s),
137
+ class: "form-textarea",
138
+ placeholder: "请输入视角描述",
139
+ maxlength: "200",
140
+ rows: "4"
141
+ }, null, 512), [
142
+ [N, r.value]
143
+ ])
144
+ ])
145
+ ]),
146
+ t("div", ce, [
147
+ t("button", {
148
+ class: "btn btn-secondary",
149
+ onClick: e[4] || (e[4] = (s) => n.value = !1)
150
+ }, "取 消"),
151
+ t("button", {
152
+ class: "btn btn-primary",
153
+ onClick: $
154
+ }, "确 定")
155
+ ])
156
+ ])
157
+ ], 2)) : J("", !0)
158
+ ], 2);
159
+ };
160
+ }
161
+ }), ue = /* @__PURE__ */ G(re, [["__scopeId", "data-v-2c9174bb"]]);
162
+ export {
163
+ ue as default
164
+ };
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as ne, ref as o, openBlock as n, createElementBlock as c, createElementVNode as e, unref as s, toDisplayString as a, withModifiers as Z, Fragment as G, renderList as q, createCommentVNode as A, createVNode as X, withCtx as ce, toRefs as Pe, onMounted as me, watch as re, normalizeStyle as ee, createTextVNode as de, createBlock as oe, withDirectives as ye, vShow as we, onBeforeUnmount as fe, normalizeClass as ue } from "vue";
2
- import { P, M as ie, $ as be, F as ae, K as pe, a0 as Ie, a1 as xe, a2 as Te, a3 as De, a4 as ge, a5 as ve, a6 as _e, H as j, J as ke, a7 as $e, Z as Be, a8 as Me, a9 as ze, aa as Ee, W as Oe, X as Re, I as K, G as Ce } from "./index-s9bhlFsR.mjs";
2
+ import { P, M as ie, $ as be, F as ae, K as pe, a0 as Ie, a1 as xe, a2 as Te, a3 as De, a4 as ge, a5 as ve, a6 as _e, H as j, J as ke, a7 as $e, Z as Be, a8 as Me, a9 as ze, aa as Ee, W as Oe, X as Re, I as K, G as Ce } from "./index-DfRswjrC.mjs";
3
3
  import { C as Se, F as Ne, L as Fe, T as Ue } from "./const-DOnRsYpZ.mjs";
4
4
  import { T as Ae } from "./timer-DoTiGoWP.mjs";
5
5
  const He = { class: "prompt_wrapper" }, We = { class: "prompt_box" }, Ye = ["src"], Je = { class: "text" }, Ze = /* @__PURE__ */ ne({