@xtctwins/tctwins-bimx-engine 0.3.21 → 0.3.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +196 -196
- package/dist/{AnnotationTool-DCHJcLix.mjs → AnnotationTool-CtRhDcPK.mjs} +35 -35
- package/dist/BIMX_Viewer_Lib.es.js +6 -6
- package/dist/BIMX_Viewer_Lib.umd.js +214 -167
- package/dist/{CameraViewTool-CJfs6vWu.mjs → CameraViewTool-CtLUEw0Q.mjs} +38 -38
- package/dist/{CommentTool-mcXTV3bv.mjs → CommentTool-B8fvijhz.mjs} +192 -192
- package/dist/{HiddenTool-BXTqbPUK.mjs → HiddenTool-511eglcE.mjs} +13 -13
- package/dist/{InspectorTool-D6DtUWoh.mjs → InspectorTool-D9Yjs6eH.mjs} +13 -13
- package/dist/{MeasureTool-BZxE7H7U.mjs → MeasureTool-C5Ce0Nef.mjs} +125 -125
- package/dist/{MouseTool-Clt4JeIj.mjs → MouseTool-BJX4hgly.mjs} +8 -8
- package/dist/{NavigateTool-cQshheaw.mjs → NavigateTool-BxOX-2P9.mjs} +8 -8
- package/dist/{OperateTool-C86C-l1z.mjs → OperateTool-DdkSl849.mjs} +61 -58
- package/dist/{RoamTool-DueJxPwv.mjs → RoamTool-CzNcha7A.mjs} +27 -27
- package/dist/ScreenShotTool-_TQ3T0xw.mjs +429 -0
- package/dist/{SectionTool-CKrvJEQ9.mjs → SectionTool-DlUhDw_i.mjs} +70 -70
- package/dist/SettingTool-yhgi_CY0.mjs +1787 -0
- package/dist/StructureTree-CNKrxyeJ.mjs +1685 -0
- package/dist/{alert-D-agI6w6.mjs → alert-B0WoSDD3.mjs} +14 -14
- package/dist/{index-jngVSTsO.mjs → index-D7FcGpin.mjs} +56419 -53825
- package/dist/index.html +17 -17
- package/dist/{panel.vue_vue_type_style_index_0_lang-DfDOwKP2.mjs → panel.vue_vue_type_style_index_0_lang-BG2LZoNF.mjs} +1 -1
- package/dist/style.css +3 -3
- package/dist/{tallPanel-CNORaYkU.mjs → tallPanel-DpEzw_w-.mjs} +12 -12
- package/package.json +85 -85
- package/types/components/BCFComponents/BCFAddPanel.vue.d.ts +38 -10
- package/types/components/BCFComponents/BCFDetailPanel.vue.d.ts +37 -9
- package/types/components/BCFComponents/BCFDisplayList.vue.d.ts +5 -7
- package/types/components/BCFComponents/BCFFilter.vue.d.ts +5 -7
- package/types/components/BCFComponents/BCFTool.vue.d.ts +4 -7
- package/types/components/BCFComponents/addObjectOrAnno.vue.d.ts +5 -7
- package/types/components/BCFComponents/checkObjectPanel.vue.d.ts +5 -6
- package/types/components/BCFComponents/commentInput.vue.d.ts +36 -10
- package/types/components/BCFComponents/commentsView.vue.d.ts +36 -7
- package/types/components/BCFComponents/dialogPanel.vue.d.ts +5 -8
- package/types/components/BCFComponents/imageView.vue.d.ts +5 -7
- package/types/components/BCFComponents/imageZoomIn.vue.d.ts +5 -6
- package/types/components/BimViewerComponents/AnnotationTool.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/AppToolbar.vue.d.ts +18 -1
- package/types/components/BimViewerComponents/CameraViewTool.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/ClickEvent.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/CommentTool.vue.d.ts +32 -1
- package/types/components/BimViewerComponents/HiddenTool.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/MobileCommentsTool/add.vue.d.ts +6 -8
- package/types/components/BimViewerComponents/MobileCommentsTool/detail.vue.d.ts +4 -5
- package/types/components/BimViewerComponents/MobileCommentsTool/draw.vue.d.ts +2 -2
- package/types/components/BimViewerComponents/MobileCommentsTool/filter.vue.d.ts +270 -1
- package/types/components/BimViewerComponents/MobileCommentsTool/list.vue.d.ts +291 -7
- package/types/components/BimViewerComponents/MobileCommentsTool/zoomIn.vue.d.ts +5 -6
- package/types/components/BimViewerComponents/MouseTool.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/NavigateTool.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/PCCommentTool/pcdraw.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/RoamTool.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/SettingTool.vue.d.ts +4 -6
- package/types/components/BimViewerComponents/StructureTree.vue.d.ts +11642 -1
- package/types/components/BimViewerComponents/Toolbar.vue.d.ts +1 -1
- package/types/components/BimxViewerComp.vue.d.ts +7 -21
- package/types/components/MobileBCFComponents/MobileBCFAdd.vue.d.ts +37 -10
- package/types/components/MobileBCFComponents/MobileBCFDetail.vue.d.ts +37 -9
- package/types/components/MobileBCFComponents/MobileBCFDisplayList.vue.d.ts +291 -7
- package/types/components/MobileBCFComponents/MobileBCFFilter.vue.d.ts +270 -1
- package/types/components/MobileBCFComponents/MobileBCFTool.vue.d.ts +5 -8
- package/types/components/MobileBCFComponents/MobileCommentInput.vue.d.ts +38 -12
- package/types/components/MobileBCFComponents/MobileCommentsView.vue.d.ts +7 -9
- package/types/components/MobileBCFComponents/selectPanel.vue.d.ts +5 -7
- package/types/components/utilsComponents/alert.vue.d.ts +1 -1
- package/types/components/utilsComponents/closeButton.vue.d.ts +1 -1
- package/types/components/utilsComponents/closeButton_dark.vue.d.ts +1 -1
- package/types/components/utilsComponents/emptyPage.vue.d.ts +1 -1
- package/types/components/utilsComponents/loading.vue.d.ts +1 -1
- package/types/components/utilsComponents/panel.vue.d.ts +8 -2
- package/types/components/utilsComponents/prompt.vue.d.ts +1 -1
- package/types/components/utilsComponents/rectangleButton.vue.d.ts +3 -1
- package/types/components/utilsComponents/tallPanel.vue.d.ts +13 -3
- package/types/components/utilsComponents/tallPanel_noPos.vue.d.ts +13 -3
- package/types/pages/BimxViewerEntry.vue.d.ts +4 -66
- package/types/store/toolbars.d.ts +50 -50
- package/types/viewerManager/sectionManager.d.ts +25 -25
- package/dist/01.xtc +0 -0
- package/dist/02.xtc +0 -0
- package/dist/03.xtc +0 -0
- package/dist/ScreenShotTool-DDtQfqF5.mjs +0 -356
- package/dist/SettingTool-CWAOl-yl.mjs +0 -1508
- package/dist/StructureTree-BTqIDob7.mjs +0 -1582
- package/types/components/BCFComponents/BCFCommentNew.vue.d.ts +0 -22
- package/types/components/BimViewerComponents/emptyPage.vue.d.ts +0 -8
- package/types/components/BimViewerComponents/mobileToolbar.vue.d.ts +0 -10
- package/types/components/bimxViewer.vue.d.ts +0 -27
- package/types/pages/viewerEntry.vue.d.ts +0 -116
- package/types/tests/cmt.d.ts +0 -1
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { _ as
|
|
2
|
-
import {
|
|
3
|
-
import { _ as xt } from "./panel.vue_vue_type_style_index_0_lang-
|
|
4
|
-
import { defineComponent as Dt, ref as u, onMounted as Ne, computed as pe, onBeforeUnmount as At, watch as St, nextTick as
|
|
5
|
-
const
|
|
1
|
+
import { _ as bt } from "./alert-B0WoSDD3.mjs";
|
|
2
|
+
import { F as ft, G as yt, T as Fe, Y as j, I as Xe, H as h, W as ht, P as E, J as gt, Z as Mt, $ as kt, L as wt, a0 as q, M as Tt } from "./index-D7FcGpin.mjs";
|
|
3
|
+
import { _ as xt } from "./panel.vue_vue_type_style_index_0_lang-BG2LZoNF.mjs";
|
|
4
|
+
import { defineComponent as Dt, ref as u, onMounted as Ne, computed as pe, onBeforeUnmount as At, watch as St, nextTick as Pt, openBlock as r, createElementBlock as d, Fragment as S, unref as o, createBlock as We, withCtx as H, createElementVNode as l, renderList as L, normalizeClass as J, toDisplayString as v, normalizeStyle as be, createCommentVNode as ne, createVNode as p, withDirectives as je, vShow as qe } from "vue";
|
|
5
|
+
const Vt = {
|
|
6
6
|
key: 0,
|
|
7
7
|
class: "measure_panel_content"
|
|
8
|
-
}, Ct = { class: "measurement_type" }, Bt = ["onClick"], Et = ["src"],
|
|
8
|
+
}, Ct = { class: "measurement_type" }, Bt = ["onClick"], Et = ["src"], Lt = {
|
|
9
9
|
key: 1,
|
|
10
10
|
class: "measurement_img_empty"
|
|
11
|
-
},
|
|
11
|
+
}, It = { class: "measurement_data" }, Rt = {
|
|
12
12
|
key: 0,
|
|
13
13
|
class: "datum_bar"
|
|
14
14
|
}, $t = { class: "footer" }, Ut = {
|
|
15
15
|
key: 1,
|
|
16
16
|
class: "setMeasurePanel"
|
|
17
|
-
},
|
|
17
|
+
}, Ht = { class: "set_content_par" }, Ot = { class: "set_content_" }, zt = {
|
|
18
18
|
class: "set_content scale",
|
|
19
19
|
style: { display: "none" }
|
|
20
|
-
},
|
|
20
|
+
}, Yt = { class: "set_content unit" }, Ft = { class: "set_content precision" }, Xt = { class: "footer" }, Nt = {
|
|
21
21
|
key: 1,
|
|
22
22
|
class: "mobile_measure_panel"
|
|
23
|
-
},
|
|
23
|
+
}, Wt = { class: "mobile_panel_bar" }, jt = ["src"], qt = { class: "mouse_btn" }, Jt = ["src"], Zt = { class: "measure-list" }, Kt = ["onClick"], Qt = { class: "measure-icon" }, Gt = ["src"], el = { class: "measure-name" }, tl = { class: "measure-icon" }, ll = ["src"], sl = {
|
|
24
24
|
class: "measure-name",
|
|
25
25
|
style: { color: "#df1c1c" }
|
|
26
26
|
}, al = {
|
|
@@ -29,17 +29,17 @@ const Pt = {
|
|
|
29
29
|
}, ol = { class: "mobile_set_close_btn" }, nl = { class: "mobile_set_title" }, il = { class: "mobile_set_row" }, ul = { class: "mobile_set_row" }, cl = {
|
|
30
30
|
key: 0,
|
|
31
31
|
class: "mobile_set_datum"
|
|
32
|
-
}, rl = { class: "mobile_set_actions" }, dl = ["src"], vl = ["src"], Je = 5,
|
|
32
|
+
}, rl = { class: "mobile_set_actions" }, dl = ["src"], vl = ["src"], Je = 5, Ze = 6, ml = /* @__PURE__ */ Dt({
|
|
33
33
|
__name: "MeasureTool",
|
|
34
34
|
props: ["componentId"],
|
|
35
35
|
emits: ["closePanel", "emitHandler"],
|
|
36
|
-
setup(
|
|
37
|
-
const i =
|
|
36
|
+
setup(Ke, { emit: Qe }) {
|
|
37
|
+
const i = ft(), I = yt(), Ge = Ke, ie = u(0);
|
|
38
38
|
Ne(() => {
|
|
39
|
-
|
|
39
|
+
I.setReadyById(Ge.componentId), Fe.currentTheme == "blue" ? ie.value = 224 : Fe.currentTheme == "light-gray" && (ie.value = 202);
|
|
40
40
|
});
|
|
41
|
-
let a,
|
|
42
|
-
const
|
|
41
|
+
let a, O, z, m;
|
|
42
|
+
const b = u(1), g = u(""), fe = u(), ue = u(), ye = u(), ce = u(), he = u(), Z = u(), K = u(), Q = u(), re = u(""), de = u(""), Y = u(1), k = u("m"), P = u(3), w = u(!1), ge = [{ value: "m" }, { value: "cm" }, { value: "mm" }], f = u(!1), Me = [
|
|
43
43
|
{ label: "0", value: 0 },
|
|
44
44
|
{ label: "0.0", value: 1 },
|
|
45
45
|
{ label: "0.00", value: 2 },
|
|
@@ -77,7 +77,7 @@ const Pt = {
|
|
|
77
77
|
]
|
|
78
78
|
}, T = pe(() => {
|
|
79
79
|
var e;
|
|
80
|
-
return ((e =
|
|
80
|
+
return ((e = j.find((t) => t.id === b.value)) == null ? void 0 : e.code) || "pointDistance";
|
|
81
81
|
}), R = u(!0), M = u("");
|
|
82
82
|
let $ = null;
|
|
83
83
|
const G = (e) => {
|
|
@@ -91,19 +91,19 @@ const Pt = {
|
|
|
91
91
|
}, st = pe(
|
|
92
92
|
() => (et[T.value] || []).map((e) => {
|
|
93
93
|
let t = "";
|
|
94
|
-
e.key === "text" ? t = re.value || "~" : e.key === "type" ? t = de.value || "-" : e.key === "dx" ? t =
|
|
94
|
+
e.key === "text" ? t = re.value || "~" : e.key === "type" ? t = de.value || "-" : e.key === "dx" ? t = Z.value ?? "" : e.key === "dy" ? t = K.value ?? "" : e.key === "dz" && (t = Q.value ?? "");
|
|
95
95
|
const n = a && a.getModeColor ? a.getModeColor(T.value) : "", c = e.key === "text" && n ? n : e.color;
|
|
96
96
|
return { label: e.label, key: `${e.key}_${e.label}`, color: c, value: t };
|
|
97
97
|
})
|
|
98
|
-
), ke =
|
|
98
|
+
), ke = Qe, we = (e) => {
|
|
99
99
|
ke("emitHandler", e);
|
|
100
100
|
}, Te = () => {
|
|
101
|
-
a = window.bimViewer.measureProTool,
|
|
102
|
-
const e =
|
|
103
|
-
e && (
|
|
104
|
-
M.value = "", B(), h("isMobile") && (
|
|
101
|
+
a = window.bimViewer.measureProTool, z = window.bimViewer.measureAngleTool, O = window.bimViewer.measureDistanceTool, m = window.bimViewer.eventTrigger, k.value = a.unit, Y.value = a.scale, m.on("measureUnitChanged", Be);
|
|
102
|
+
const e = j.find((t) => t.code === q.NormalizeMeasureMode(q.viewerState.measureType));
|
|
103
|
+
e && (b.value = e.id), q.SaveViewerState({ measure: T.value }), m.on("newDistanceMeasure", () => {
|
|
104
|
+
M.value = "", B(), h("isMobile") && (f.value = !1);
|
|
105
105
|
}), m.on("newAngleMeasure", () => {
|
|
106
|
-
M.value = "", B(), h("isMobile") && (
|
|
106
|
+
M.value = "", B(), h("isMobile") && (f.value = !1);
|
|
107
107
|
}), m.on("proMeasureRejected", (t) => {
|
|
108
108
|
G(t && t.reasonText ? t.reasonText : "");
|
|
109
109
|
}), m.on("proMeasureDatumPicked", () => {
|
|
@@ -113,24 +113,24 @@ const Pt = {
|
|
|
113
113
|
}), m.on("proMeasureDatumPickCancel", () => {
|
|
114
114
|
x.value = !1;
|
|
115
115
|
}), m.on("createAngleMeasure", (t) => {
|
|
116
|
-
he.value = t.id, ce.value = t.result, D(t.id), h("isMobile") && (
|
|
116
|
+
he.value = t.id, ce.value = t.result, D(t.id), h("isMobile") && (f.value = !0), V("createAngleMeasure", { newMeasure: t });
|
|
117
117
|
}), m.on("createDistanceMeasure", (t) => {
|
|
118
|
-
|
|
118
|
+
fe.value = t.id, ye.value = t.id, ue.value = t.result, Z.value = t.xResult ? t.xResult : 0, K.value = t.yResult ? t.yResult : 0, Q.value = t.zResult ? t.zResult : 0, D(t.id), h("isMobile") && (f.value = !0), V("createAngleMeasure", { newMeasure: t });
|
|
119
119
|
}), m.on("clickDistanceMeasure", (t) => {
|
|
120
|
-
|
|
120
|
+
fe.value = t.id, ye.value = t.id, Pe(t.id), a.getModeByMeasurementId(t.id) || (ue.value = O.getMeasureResultByID(t.id)), D(t.id), h("isMobile") && (f.value = !0), V("clickDistanceMeasure", { id: t.id });
|
|
121
121
|
}), m.on("clickAngleMeasure", (t) => {
|
|
122
|
-
he.value = t.id,
|
|
123
|
-
}), m.on("DistanceMeasureDestroyed", (t) =>
|
|
122
|
+
he.value = t.id, Pe(t.id), a.getModeByMeasurementId(t.id) || (ce.value = z.getMeasureResultByID(t.id)), D(t.id), h("isMobile") && (f.value = !0), V("clickAngleMeasure", { id: t.id });
|
|
123
|
+
}), m.on("DistanceMeasureDestroyed", (t) => Ve(t.id)), m.on("AngleMeasureDestroyed", (t) => Ve(t.id)), Ce(!1), Ee() && I.isToolActive(3) && me(!0);
|
|
124
124
|
};
|
|
125
|
-
|
|
126
|
-
$ && clearTimeout($), m && m.off("measureUnitChanged", Be), ve(),
|
|
125
|
+
Xe.on("BimViewer", Te), At(() => {
|
|
126
|
+
$ && clearTimeout($), m && m.off("measureUnitChanged", Be), ve(), Xe.off("BimViewer", Te);
|
|
127
127
|
}), St(
|
|
128
|
-
() =>
|
|
128
|
+
() => I.isToolActive(2),
|
|
129
129
|
(e) => {
|
|
130
130
|
ct(e), e && (R.value = !0), Ee() && me(!!e);
|
|
131
131
|
}
|
|
132
132
|
);
|
|
133
|
-
const
|
|
133
|
+
const V = (e, t) => {
|
|
134
134
|
we({
|
|
135
135
|
isTool: !0,
|
|
136
136
|
event_name: e,
|
|
@@ -140,11 +140,11 @@ const Pt = {
|
|
|
140
140
|
}, at = () => {
|
|
141
141
|
ee(), window.bimViewer.SetMeasureProAllDisactive(), ke("closePanel"), w.value === !0 && C();
|
|
142
142
|
}, xe = (e) => {
|
|
143
|
-
if (
|
|
143
|
+
if (b.value === e.id)
|
|
144
144
|
return;
|
|
145
|
-
|
|
145
|
+
b.value = e.id, q.SaveViewerState({ measure: e.code }), M.value = "", ee(), it(), De(e), R.value = !0;
|
|
146
146
|
const t = a && a.getMeasurementsSummaryByMode ? a.getMeasurementsSummaryByMode(e.code) : [];
|
|
147
|
-
t.length ? D(t[t.length - 1].id) : B(), h("isMobile") && (
|
|
147
|
+
t.length ? D(t[t.length - 1].id) : B(), h("isMobile") && (f.value = !1);
|
|
148
148
|
}, De = (e) => {
|
|
149
149
|
const t = e.code;
|
|
150
150
|
window.bimViewer.SetMeasureProActive(e.code, !0), we({
|
|
@@ -172,43 +172,43 @@ const Pt = {
|
|
|
172
172
|
}, ee = () => {
|
|
173
173
|
x.value = !1, a && a.cancelMeasureDatumPick && a.cancelMeasureDatumPick();
|
|
174
174
|
}, ot = () => {
|
|
175
|
-
B(), a && a.clearAll(),
|
|
175
|
+
B(), a && a.clearAll(), O.clear(), z.clear(), V("destroyAllMeasure", { msg: "删除全部测量" }), f.value = !1;
|
|
176
176
|
}, nt = () => {
|
|
177
177
|
const e = g.value;
|
|
178
178
|
if (!e) return;
|
|
179
179
|
const t = T.value === "pointAngle" || T.value === "edgeAngle";
|
|
180
|
-
ut(e),
|
|
180
|
+
ut(e), V(t ? "destroyMeasurementAngle" : "destroyMeasureDistance", { id: e }), B(), f.value = !1;
|
|
181
181
|
}, C = () => {
|
|
182
182
|
w.value = !w.value;
|
|
183
183
|
}, Se = () => {
|
|
184
|
-
C(), Ce(), g.value && D(g.value),
|
|
184
|
+
C(), Ce(), g.value && D(g.value), V("updateMeasureSet", {
|
|
185
185
|
measurePrefer: {
|
|
186
|
-
distance_precision:
|
|
186
|
+
distance_precision: P.value,
|
|
187
187
|
distance_unit: k.value,
|
|
188
|
-
distance_scale:
|
|
188
|
+
distance_scale: Y.value
|
|
189
189
|
}
|
|
190
190
|
});
|
|
191
191
|
}, B = () => {
|
|
192
|
-
re.value = "", de.value = "", ue.value = "", ce.value = "",
|
|
192
|
+
re.value = "", de.value = "", ue.value = "", ce.value = "", Z.value = "", K.value = "", Q.value = "", g.value = "";
|
|
193
193
|
}, D = (e) => {
|
|
194
194
|
if (!e || !a || !a.getMeasurementSummary) return;
|
|
195
195
|
g.value = e;
|
|
196
196
|
const t = a.getModeByMeasurementId(e);
|
|
197
197
|
if (t) {
|
|
198
|
-
const c =
|
|
198
|
+
const c = j.find((_) => _.code === t);
|
|
199
199
|
if (!c) {
|
|
200
200
|
B();
|
|
201
201
|
return;
|
|
202
202
|
}
|
|
203
|
-
c.id !==
|
|
203
|
+
c.id !== b.value && (b.value = c.id, q.SaveViewerState({ measure: c.code })), a.getActiveByMode(t) || De(c);
|
|
204
204
|
}
|
|
205
205
|
const n = a.getMeasurementSummary(e);
|
|
206
|
-
n && (re.value = n.text || (n.value ? n.value.toFixed(
|
|
207
|
-
},
|
|
206
|
+
n && (re.value = n.text || (n.value ? n.value.toFixed(P.value) : ""), de.value = n.description || n.relationLabel || "", Z.value = n.xResult ?? "", K.value = n.yResult ?? "", Q.value = n.zResult ?? "");
|
|
207
|
+
}, Pe = (e) => {
|
|
208
208
|
!e || !a || !a.selectMeasurementById || a.selectMeasurementById(e);
|
|
209
209
|
}, it = () => {
|
|
210
210
|
!a || !a.clearSelectedMeasurement || a.clearSelectedMeasurement();
|
|
211
|
-
},
|
|
211
|
+
}, Ve = (e) => {
|
|
212
212
|
!e || e !== g.value || B();
|
|
213
213
|
}, ut = (e) => {
|
|
214
214
|
if (e) {
|
|
@@ -216,34 +216,34 @@ const Pt = {
|
|
|
216
216
|
a.destroyMeasurementById(e);
|
|
217
217
|
return;
|
|
218
218
|
}
|
|
219
|
-
|
|
219
|
+
O.destroyMeasurementById(e), z.destroyMeasurementById(e);
|
|
220
220
|
}
|
|
221
221
|
}, Ce = (e = !0) => {
|
|
222
|
-
a && (e && (a.unit = k.value), a.scale =
|
|
222
|
+
a && (e && (a.unit = k.value), a.scale = Y.value, a.precision = P.value);
|
|
223
223
|
}, Be = (e) => {
|
|
224
224
|
k.value = e.unit, g.value && D(g.value);
|
|
225
225
|
}, ct = (e) => {
|
|
226
|
-
a && a.setAllVisible(e),
|
|
226
|
+
a && a.setAllVisible(e), O.setAllVisible(e), z.setAllVisible(e);
|
|
227
227
|
};
|
|
228
228
|
Ne(() => {
|
|
229
229
|
document.getElementById("top_bar");
|
|
230
230
|
});
|
|
231
231
|
const U = u(!1);
|
|
232
|
-
let
|
|
233
|
-
const se = u(290), ae = u(300), Ee = () => !!h("isMobile"),
|
|
232
|
+
let F = !1, te = 0, le = 0;
|
|
233
|
+
const se = u(290), ae = u(300), Ee = () => !!h("isMobile"), X = () => document.getElementById("measure_mouseGroup"), Le = () => {
|
|
234
234
|
var e, t, n, c;
|
|
235
235
|
return ((c = (n = (t = (e = window.bimViewer) == null ? void 0 : e.viewer) == null ? void 0 : t.scene) == null ? void 0 : n.canvas) == null ? void 0 : c.canvas) || null;
|
|
236
|
-
},
|
|
237
|
-
const e =
|
|
236
|
+
}, Ie = () => {
|
|
237
|
+
const e = X();
|
|
238
238
|
if (!e)
|
|
239
|
-
return [se.value + Je, ae.value +
|
|
239
|
+
return [se.value + Je, ae.value + Ze];
|
|
240
240
|
const t = e.getBoundingClientRect();
|
|
241
|
-
return [t.left + Je, t.top +
|
|
241
|
+
return [t.left + Je, t.top + Ze];
|
|
242
242
|
}, N = (e, t) => {
|
|
243
|
-
const n =
|
|
243
|
+
const n = Le();
|
|
244
244
|
if (!n)
|
|
245
245
|
return;
|
|
246
|
-
const [c, _] =
|
|
246
|
+
const [c, _] = Ie(), y = {
|
|
247
247
|
bubbles: !0,
|
|
248
248
|
cancelable: !0,
|
|
249
249
|
composed: !0,
|
|
@@ -267,7 +267,7 @@ const Pt = {
|
|
|
267
267
|
}, Re = () => {
|
|
268
268
|
N("pointermove", 0);
|
|
269
269
|
}, rt = () => {
|
|
270
|
-
const e =
|
|
270
|
+
const e = X(), [t, n] = Ie(), c = e ? e.style.visibility : "";
|
|
271
271
|
e && (e.style.visibility = "hidden");
|
|
272
272
|
const _ = document.elementFromPoint ? document.elementFromPoint(t, n) : null;
|
|
273
273
|
return e && (e.style.visibility = c), _;
|
|
@@ -277,7 +277,7 @@ const Pt = {
|
|
|
277
277
|
t.dispatchEvent(new MouseEvent("click", { bubbles: !0, cancelable: !0, view: window }));
|
|
278
278
|
return;
|
|
279
279
|
}
|
|
280
|
-
const n =
|
|
280
|
+
const n = Le();
|
|
281
281
|
if (e && e !== n && !(n && n.contains(e)))
|
|
282
282
|
return;
|
|
283
283
|
N("pointermove", 0);
|
|
@@ -291,51 +291,51 @@ const Pt = {
|
|
|
291
291
|
const e = !U.value;
|
|
292
292
|
e || (ee(), dt()), me(e);
|
|
293
293
|
}, mt = () => {
|
|
294
|
-
const e =
|
|
294
|
+
const e = X();
|
|
295
295
|
if (!e)
|
|
296
296
|
return;
|
|
297
|
-
const n = (e.offsetParent || document.body).getBoundingClientRect(), c = e.getBoundingClientRect(), _ = n.width || window.innerWidth, y = n.height || window.innerHeight, A = c.width || 40,
|
|
298
|
-
se.value = Math.max(0, Math.min(_e, _ - A)), ae.value = Math.max(0, Math.min(oe, y -
|
|
297
|
+
const n = (e.offsetParent || document.body).getBoundingClientRect(), c = e.getBoundingClientRect(), _ = n.width || window.innerWidth, y = n.height || window.innerHeight, A = c.width || 40, W = c.height || 84, _e = _ * 0.62 - A / 2, oe = y * 0.5 - W / 2;
|
|
298
|
+
se.value = Math.max(0, Math.min(_e, _ - A)), ae.value = Math.max(0, Math.min(oe, y - W));
|
|
299
299
|
}, Ue = (e) => {
|
|
300
|
-
e.touches.length == 1 && (
|
|
301
|
-
},
|
|
302
|
-
if (!
|
|
300
|
+
e.touches.length == 1 && (F = !0, te = e.touches[0].clientX, le = e.touches[0].clientY);
|
|
301
|
+
}, He = (e) => {
|
|
302
|
+
if (!F || e.touches.length != 1)
|
|
303
303
|
return;
|
|
304
304
|
const t = e.touches[0].clientX, n = e.touches[0].clientY;
|
|
305
305
|
se.value += t - te, ae.value += n - le, te = t, le = n, Re();
|
|
306
|
-
},
|
|
307
|
-
|
|
306
|
+
}, Oe = () => {
|
|
307
|
+
F = !1;
|
|
308
308
|
}, _t = () => {
|
|
309
|
-
const e =
|
|
310
|
-
e && (ve(), e.addEventListener("touchstart", Ue), e.addEventListener("touchmove",
|
|
309
|
+
const e = X();
|
|
310
|
+
e && (ve(), e.addEventListener("touchstart", Ue), e.addEventListener("touchmove", He), e.addEventListener("touchend", Oe), e.addEventListener("click", $e), F = !1, te = 0, le = 0);
|
|
311
311
|
}, ve = () => {
|
|
312
|
-
const e =
|
|
313
|
-
e == null || e.removeEventListener("touchstart", Ue), e == null || e.removeEventListener("touchmove",
|
|
312
|
+
const e = X();
|
|
313
|
+
e == null || e.removeEventListener("touchstart", Ue), e == null || e.removeEventListener("touchmove", He), e == null || e.removeEventListener("touchend", Oe), e == null || e.removeEventListener("click", $e);
|
|
314
314
|
}, me = (e) => {
|
|
315
315
|
if (U.value !== e) {
|
|
316
316
|
if (U.value = e, !e) {
|
|
317
|
-
ve(),
|
|
317
|
+
ve(), F = !1, M.value = "";
|
|
318
318
|
return;
|
|
319
319
|
}
|
|
320
|
-
|
|
320
|
+
Pt(() => {
|
|
321
321
|
mt(), _t(), Re();
|
|
322
322
|
});
|
|
323
323
|
}
|
|
324
324
|
};
|
|
325
325
|
return (e, t) => {
|
|
326
|
-
var oe,
|
|
327
|
-
const n = ht, c = gt, _ =
|
|
326
|
+
var oe, ze, Ye;
|
|
327
|
+
const n = ht, c = gt, _ = kt, y = Mt, A = xt, W = wt, _e = bt;
|
|
328
328
|
return r(), d(S, null, [
|
|
329
329
|
o(h)("isMobile") ? (r(), d("div", Nt, [
|
|
330
|
-
l("div",
|
|
330
|
+
l("div", Wt, [
|
|
331
331
|
l("div", {
|
|
332
332
|
class: J(["mobile_set_btn", { mobile_set_btn_active: w.value }]),
|
|
333
333
|
onClick: C
|
|
334
334
|
}, [
|
|
335
335
|
l("img", {
|
|
336
|
-
src: `${o(E)}/industry-viewer/action-bar/${(oe = o(
|
|
336
|
+
src: `${o(E)}/industry-viewer/action-bar/${(oe = o(I).getToolById(11)) == null ? void 0 : oe.img}.svg`,
|
|
337
337
|
alt: ""
|
|
338
|
-
}, null, 8,
|
|
338
|
+
}, null, 8, jt)
|
|
339
339
|
], 2),
|
|
340
340
|
l("div", qt, [
|
|
341
341
|
l("div", {
|
|
@@ -343,66 +343,66 @@ const Pt = {
|
|
|
343
343
|
onClick: vt
|
|
344
344
|
}, [
|
|
345
345
|
l("img", {
|
|
346
|
-
src: `${o(E)}/industry-viewer/action-bar/${U.value ? (
|
|
346
|
+
src: `${o(E)}/industry-viewer/action-bar/${U.value ? (ze = o(I).getToolById(16)) == null ? void 0 : ze.imgActive : (Ye = o(I).getToolById(16)) == null ? void 0 : Ye.img}.svg`
|
|
347
347
|
}, null, 8, Jt),
|
|
348
348
|
l("span", {
|
|
349
|
-
style:
|
|
349
|
+
style: be({ color: U.value ? "#1457F7" : "#262626" })
|
|
350
350
|
}, v(o(i)("toolbar.virtualMouse")), 5)
|
|
351
351
|
])
|
|
352
352
|
])
|
|
353
353
|
]),
|
|
354
|
-
l("div",
|
|
355
|
-
(r(!0), d(S, null,
|
|
354
|
+
l("div", Zt, [
|
|
355
|
+
(r(!0), d(S, null, L(o(j), (s) => (r(), d("div", {
|
|
356
356
|
key: s.id,
|
|
357
357
|
class: J(["measure-item", {
|
|
358
|
-
"measure-item-active":
|
|
358
|
+
"measure-item-active": b.value === s.id
|
|
359
359
|
}]),
|
|
360
360
|
onClick: (pt) => xe(s)
|
|
361
361
|
}, [
|
|
362
|
-
l("div",
|
|
362
|
+
l("div", Qt, [
|
|
363
363
|
l("img", {
|
|
364
|
-
src: o(E)
|
|
364
|
+
src: `${o(E)}/bim-viewer/measure-bar/bimkk-mobile-measure-${b.value === s.id ? s.svgActive : s.svg}.svg`,
|
|
365
365
|
alt: ""
|
|
366
366
|
}, null, 8, Gt),
|
|
367
367
|
l("div", el, v(o(i)(s.label || s.name)), 1)
|
|
368
368
|
])
|
|
369
|
-
], 10,
|
|
370
|
-
|
|
369
|
+
], 10, Kt))), 128)),
|
|
370
|
+
f.value ? (r(), d("div", {
|
|
371
371
|
key: 0,
|
|
372
372
|
class: "measure-item",
|
|
373
373
|
onClick: nt
|
|
374
374
|
}, [
|
|
375
375
|
l("div", tl, [
|
|
376
376
|
l("img", {
|
|
377
|
-
src: o(E)
|
|
377
|
+
src: `${o(E)}/bim-viewer/delete.svg`,
|
|
378
378
|
alt: ""
|
|
379
379
|
}, null, 8, ll),
|
|
380
380
|
l("div", sl, v(o(i)("common.delete")), 1)
|
|
381
381
|
])
|
|
382
382
|
])) : ne("", !0)
|
|
383
383
|
])
|
|
384
|
-
])) : (r(),
|
|
384
|
+
])) : (r(), We(A, {
|
|
385
385
|
key: 0,
|
|
386
386
|
class: "measure_panel",
|
|
387
387
|
width: ie.value,
|
|
388
388
|
panelTitle: w.value ? o(i)("measure.settings") : o(i)("measure.title"),
|
|
389
389
|
"click-handle": at
|
|
390
390
|
}, {
|
|
391
|
-
default:
|
|
391
|
+
default: H(() => [
|
|
392
392
|
w.value ? (r(), d("div", Ut, [
|
|
393
|
-
l("div",
|
|
394
|
-
l("div",
|
|
395
|
-
l("div",
|
|
393
|
+
l("div", Ht, [
|
|
394
|
+
l("div", Ot, [
|
|
395
|
+
l("div", zt, [
|
|
396
396
|
l("span", null, v(o(i)("measure.scaleLabel")), 1),
|
|
397
397
|
t[5] || (t[5] = l("span", null, "1:", -1)),
|
|
398
398
|
p(c, {
|
|
399
|
-
modelValue:
|
|
400
|
-
"onUpdate:modelValue": t[0] || (t[0] = (s) =>
|
|
399
|
+
modelValue: Y.value,
|
|
400
|
+
"onUpdate:modelValue": t[0] || (t[0] = (s) => Y.value = s),
|
|
401
401
|
style: { width: "122px", height: "28px" },
|
|
402
402
|
placeholder: "1"
|
|
403
403
|
}, null, 8, ["modelValue"])
|
|
404
404
|
]),
|
|
405
|
-
l("div",
|
|
405
|
+
l("div", Yt, [
|
|
406
406
|
l("span", null, v(o(i)("measure.unitLabel")), 1),
|
|
407
407
|
p(y, {
|
|
408
408
|
modelValue: k.value,
|
|
@@ -410,8 +410,8 @@ const Pt = {
|
|
|
410
410
|
placeholder: o(i)("measure.unitPlaceholder"),
|
|
411
411
|
style: { width: "136px", height: "28px" }
|
|
412
412
|
}, {
|
|
413
|
-
default:
|
|
414
|
-
(r(), d(S, null,
|
|
413
|
+
default: H(() => [
|
|
414
|
+
(r(), d(S, null, L(ge, (s) => p(_, {
|
|
415
415
|
key: s.value,
|
|
416
416
|
value: s.value
|
|
417
417
|
}, null, 8, ["value"])), 64))
|
|
@@ -419,16 +419,16 @@ const Pt = {
|
|
|
419
419
|
_: 1
|
|
420
420
|
}, 8, ["modelValue", "placeholder"])
|
|
421
421
|
]),
|
|
422
|
-
l("div",
|
|
422
|
+
l("div", Ft, [
|
|
423
423
|
l("span", null, v(o(i)("measure.precisionLabel")), 1),
|
|
424
424
|
p(y, {
|
|
425
|
-
modelValue:
|
|
426
|
-
"onUpdate:modelValue": t[2] || (t[2] = (s) =>
|
|
425
|
+
modelValue: P.value,
|
|
426
|
+
"onUpdate:modelValue": t[2] || (t[2] = (s) => P.value = s),
|
|
427
427
|
placeholder: o(i)("measure.precisionPlaceholder"),
|
|
428
428
|
style: { width: "136px", height: "28px" }
|
|
429
429
|
}, {
|
|
430
|
-
default:
|
|
431
|
-
(r(), d(S, null,
|
|
430
|
+
default: H(() => [
|
|
431
|
+
(r(), d(S, null, L(Me, (s) => p(_, {
|
|
432
432
|
key: s.value,
|
|
433
433
|
label: s.label,
|
|
434
434
|
value: s.value
|
|
@@ -439,7 +439,7 @@ const Pt = {
|
|
|
439
439
|
])
|
|
440
440
|
])
|
|
441
441
|
]),
|
|
442
|
-
l("div",
|
|
442
|
+
l("div", Xt, [
|
|
443
443
|
l("div", {
|
|
444
444
|
class: "measure_footer_button measure_footer_button_cancel",
|
|
445
445
|
onClick: C
|
|
@@ -449,39 +449,39 @@ const Pt = {
|
|
|
449
449
|
onClick: Se
|
|
450
450
|
}, v(o(i)("common.save")), 1)
|
|
451
451
|
])
|
|
452
|
-
])) : (r(), d("div",
|
|
452
|
+
])) : (r(), d("div", Vt, [
|
|
453
453
|
l("div", Ct, [
|
|
454
|
-
(r(!0), d(S, null,
|
|
454
|
+
(r(!0), d(S, null, L(o(j), (s) => (r(), We(n, {
|
|
455
455
|
key: s.id,
|
|
456
456
|
content: o(i)(s.label),
|
|
457
457
|
placement: "top",
|
|
458
458
|
effect: "light",
|
|
459
459
|
"hide-after": 50
|
|
460
460
|
}, {
|
|
461
|
-
default:
|
|
461
|
+
default: H(() => [
|
|
462
462
|
l("div", {
|
|
463
|
-
class: J(["measurement_box", { measurement_box_active:
|
|
463
|
+
class: J(["measurement_box", { measurement_box_active: b.value === s.id }]),
|
|
464
464
|
onClick: (pt) => xe(s)
|
|
465
465
|
}, [
|
|
466
466
|
s.img || s.imgActive ? (r(), d("img", {
|
|
467
467
|
key: 0,
|
|
468
468
|
class: "measurement_img",
|
|
469
|
-
src: o(E)
|
|
469
|
+
src: `${o(E)}/bim-viewer/action-bars/pmeasure-${b.value === s.id ? s.imgActive : s.img}.svg`,
|
|
470
470
|
alt: ""
|
|
471
|
-
}, null, 8, Et)) : (r(), d("span",
|
|
471
|
+
}, null, 8, Et)) : (r(), d("span", Lt))
|
|
472
472
|
], 10, Bt)
|
|
473
473
|
]),
|
|
474
474
|
_: 2
|
|
475
475
|
}, 1032, ["content"]))), 128))
|
|
476
476
|
]),
|
|
477
|
-
l("div",
|
|
478
|
-
(r(!0), d(S, null,
|
|
477
|
+
l("div", It, [
|
|
478
|
+
(r(!0), d(S, null, L(st.value, (s) => (r(), d("div", {
|
|
479
479
|
key: s.key,
|
|
480
480
|
class: "data_box"
|
|
481
481
|
}, [
|
|
482
482
|
l("div", null, v(o(i)(s.label)), 1),
|
|
483
483
|
l("div", {
|
|
484
|
-
style:
|
|
484
|
+
style: be({ color: s.color })
|
|
485
485
|
}, v(s.value), 5)
|
|
486
486
|
]))), 128))
|
|
487
487
|
]),
|
|
@@ -501,7 +501,7 @@ const Pt = {
|
|
|
501
501
|
}, 8, ["width", "panelTitle"])),
|
|
502
502
|
w.value && o(h)("isMobile") ? (r(), d("div", al, [
|
|
503
503
|
l("div", ol, [
|
|
504
|
-
p(
|
|
504
|
+
p(W, {
|
|
505
505
|
width: 0.34,
|
|
506
506
|
"size-type": "rem",
|
|
507
507
|
"click-handle": C
|
|
@@ -517,8 +517,8 @@ const Pt = {
|
|
|
517
517
|
placeholder: o(i)("measure.unitPlaceholder"),
|
|
518
518
|
style: { width: "136px", height: "28px" }
|
|
519
519
|
}, {
|
|
520
|
-
default:
|
|
521
|
-
(r(), d(S, null,
|
|
520
|
+
default: H(() => [
|
|
521
|
+
(r(), d(S, null, L(ge, (s) => p(_, {
|
|
522
522
|
key: s.value,
|
|
523
523
|
value: s.value
|
|
524
524
|
}, null, 8, ["value"])), 64))
|
|
@@ -529,14 +529,14 @@ const Pt = {
|
|
|
529
529
|
l("div", ul, [
|
|
530
530
|
l("span", null, v(o(i)("measure.precisionLabel")), 1),
|
|
531
531
|
p(y, {
|
|
532
|
-
modelValue:
|
|
533
|
-
"onUpdate:modelValue": t[4] || (t[4] = (s) =>
|
|
532
|
+
modelValue: P.value,
|
|
533
|
+
"onUpdate:modelValue": t[4] || (t[4] = (s) => P.value = s),
|
|
534
534
|
teleported: !1,
|
|
535
535
|
placeholder: o(i)("measure.precisionPlaceholder"),
|
|
536
536
|
style: { width: "136px", height: "28px" }
|
|
537
537
|
}, {
|
|
538
|
-
default:
|
|
539
|
-
(r(), d(S, null,
|
|
538
|
+
default: H(() => [
|
|
539
|
+
(r(), d(S, null, L(Me, (s) => p(_, {
|
|
540
540
|
key: s.value,
|
|
541
541
|
label: s.label,
|
|
542
542
|
value: s.value
|
|
@@ -562,16 +562,16 @@ const Pt = {
|
|
|
562
562
|
}, v(o(i)("common.save")), 1)
|
|
563
563
|
])
|
|
564
564
|
])) : ne("", !0),
|
|
565
|
-
|
|
565
|
+
je(p(_e, {
|
|
566
566
|
title: tt.value,
|
|
567
567
|
"click-handle": lt
|
|
568
568
|
}, null, 8, ["title"]), [
|
|
569
569
|
[qe, R.value]
|
|
570
570
|
]),
|
|
571
|
-
|
|
571
|
+
je(l("div", {
|
|
572
572
|
id: "measure_mouseGroup",
|
|
573
573
|
class: "mouse_group",
|
|
574
|
-
style:
|
|
574
|
+
style: be({ left: `${se.value}px`, top: `${ae.value}px` })
|
|
575
575
|
}, [
|
|
576
576
|
l("img", {
|
|
577
577
|
id: "mouse_icon",
|
|
@@ -589,7 +589,7 @@ const Pt = {
|
|
|
589
589
|
], 64);
|
|
590
590
|
};
|
|
591
591
|
}
|
|
592
|
-
}), yl = /* @__PURE__ */ Tt(ml, [["__scopeId", "data-v-
|
|
592
|
+
}), yl = /* @__PURE__ */ Tt(ml, [["__scopeId", "data-v-b7b27337"]]);
|
|
593
593
|
export {
|
|
594
594
|
yl as default
|
|
595
595
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { defineComponent as Y, onMounted as x, onBeforeUnmount as A, ref as _, watch as C, openBlock as M, createElementBlock as $, withDirectives as F, createElementVNode as g, normalizeStyle as D, unref as L, vShow as N } from "vue";
|
|
2
|
-
import {
|
|
3
|
-
const
|
|
2
|
+
import { G as P, I as s, P as k, a0 as V } from "./index-D7FcGpin.mjs";
|
|
3
|
+
const R = { class: "mouse_tool" }, U = ["src"], z = ["src"], J = /* @__PURE__ */ Y({
|
|
4
4
|
__name: "MouseTool",
|
|
5
5
|
props: ["componentId"],
|
|
6
6
|
setup(O) {
|
|
7
|
-
const p =
|
|
7
|
+
const p = P(), y = O;
|
|
8
8
|
x(() => {
|
|
9
9
|
p.setReadyById(y.componentId), document.getElementById("top_bar");
|
|
10
10
|
});
|
|
@@ -48,7 +48,7 @@ const U = { class: "mouse_tool" }, q = ["src"], z = ["src"], J = /* @__PURE__ */
|
|
|
48
48
|
const u = t.viewer.scene.pick({
|
|
49
49
|
canvasPos: h
|
|
50
50
|
});
|
|
51
|
-
u ? (o = !0, n !== u.entity.id && (n = u.entity.id, t.setAllObjectsSelected(!1), t.setEntitySelected(u.entity))) : (o = !1, n = "", t.setAllObjectsSelected(!1)),
|
|
51
|
+
u ? (o = !0, n !== u.entity.id && (n = u.entity.id, t.setAllObjectsSelected(!1), t.setEntitySelected(u.entity))) : (o = !1, n = "", t.setAllObjectsSelected(!1)), V.entityState.selectedObjectIds.length > 0 && t.setObjectsSelected(V.entityState.selectedObjectIds, !0), r = f, a = B;
|
|
52
52
|
}
|
|
53
53
|
}, j = () => {
|
|
54
54
|
const e = document.getElementById("mouseGroup");
|
|
@@ -57,7 +57,7 @@ const U = { class: "mouse_tool" }, q = ["src"], z = ["src"], J = /* @__PURE__ */
|
|
|
57
57
|
const e = document.getElementById("mouseGroup");
|
|
58
58
|
e == null || e.removeEventListener("touchstart", S), e == null || e.removeEventListener("touchmove", b), e == null || e.removeEventListener("click", I);
|
|
59
59
|
};
|
|
60
|
-
return (e, f) => (M(), $("div",
|
|
60
|
+
return (e, f) => (M(), $("div", R, [
|
|
61
61
|
F(g("div", {
|
|
62
62
|
id: "mouseGroup",
|
|
63
63
|
class: "mouse_group",
|
|
@@ -66,12 +66,12 @@ const U = { class: "mouse_tool" }, q = ["src"], z = ["src"], J = /* @__PURE__ */
|
|
|
66
66
|
g("img", {
|
|
67
67
|
id: "mouse_icon",
|
|
68
68
|
class: "mouse_icon",
|
|
69
|
-
src: `${L(
|
|
70
|
-
}, null, 8,
|
|
69
|
+
src: `${L(k)}/industry-viewer/mouse-icon.svg`
|
|
70
|
+
}, null, 8, U),
|
|
71
71
|
g("img", {
|
|
72
72
|
id: "mouse_img",
|
|
73
73
|
class: "mouse_img",
|
|
74
|
-
src: `${L(
|
|
74
|
+
src: `${L(k)}/industry-viewer/mouse-active-large.svg`
|
|
75
75
|
}, null, 8, z)
|
|
76
76
|
], 4), [
|
|
77
77
|
[N, !l.value]
|