@xtctwins/tctwins-industry-engine 0.0.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.
- package/README.md +5 -0
- package/dist/AnnotationTool-p1JXCwLS.mjs +129 -0
- package/dist/BCFTool-Cssf2dIk.mjs +25118 -0
- package/dist/CommentTool-Bug4iFC9.mjs +167 -0
- package/dist/Industry_Viewer_Lib.es.js +12 -0
- package/dist/Industry_Viewer_Lib.umd.js +633 -0
- package/dist/InspectorTool-BJzXtOU-.mjs +674 -0
- package/dist/MeasureTool-Dkrz8dS6.mjs +168 -0
- package/dist/MouseTool-Cvc5G90V.mjs +80 -0
- package/dist/NavigateTool-DwEEE5nd.mjs +52 -0
- package/dist/RoamTool-dChjfNvn.mjs +212 -0
- package/dist/ScreenShotTool-CPrA7pEa.mjs +357 -0
- package/dist/SectionTool-Du-V6U-J.mjs +217 -0
- package/dist/SettingTool-X6AjiptI.mjs +691 -0
- package/dist/StructureTree-CHhrQiDL.mjs +1591 -0
- package/dist/XRayTool-Ci1SR92x.mjs +57 -0
- package/dist/alert-BzjOjWCu.mjs +46 -0
- package/dist/const-DeViLYl5.mjs +266 -0
- package/dist/el-checkbox-DeNYO9VE.mjs +460 -0
- package/dist/el-input-number-CsUyeV_5.mjs +858 -0
- package/dist/index-CBO0Vhj8.mjs +99354 -0
- package/dist/index.html +17 -0
- package/dist/panel.vue_vue_type_style_index_0_lang-CUi6naB0.mjs +61 -0
- package/dist/style.css +1 -0
- package/dist/tallPanel-D226sbKd.mjs +84 -0
- package/package.json +65 -0
- package/types/App.vue.d.ts +2 -0
- package/types/components/BCFComponents/BCFAddPanel.vue.d.ts +55 -0
- package/types/components/BCFComponents/BCFDetailPanel.vue.d.ts +59 -0
- package/types/components/BCFComponents/BCFDisplayList.vue.d.ts +18 -0
- package/types/components/BCFComponents/BCFFilter.vue.d.ts +14 -0
- package/types/components/BCFComponents/BCFTool.vue.d.ts +15 -0
- package/types/components/BCFComponents/addObjectOrAnno.vue.d.ts +16 -0
- package/types/components/BCFComponents/checkObjectPanel.vue.d.ts +11 -0
- package/types/components/BCFComponents/commentInput.vue.d.ts +51 -0
- package/types/components/BCFComponents/commentsView.vue.d.ts +48 -0
- package/types/components/BCFComponents/dialogPanel.vue.d.ts +15 -0
- package/types/components/BCFComponents/imageView.vue.d.ts +17 -0
- package/types/components/BCFComponents/imageZoomIn.vue.d.ts +9 -0
- package/types/components/BimViewerComponents/AnnotationTool.vue.d.ts +14 -0
- package/types/components/BimViewerComponents/ClickEvent.vue.d.ts +6 -0
- package/types/components/BimViewerComponents/CommentTool.vue.d.ts +12 -0
- package/types/components/BimViewerComponents/InspectorTool.vue.d.ts +12 -0
- package/types/components/BimViewerComponents/MeasureTool.vue.d.ts +12 -0
- package/types/components/BimViewerComponents/MouseTool.vue.d.ts +6 -0
- package/types/components/BimViewerComponents/NavigateTool.vue.d.ts +10 -0
- package/types/components/BimViewerComponents/RoamTool.vue.d.ts +12 -0
- package/types/components/BimViewerComponents/ScreenShotTool.vue.d.ts +10 -0
- package/types/components/BimViewerComponents/SectionTool.vue.d.ts +10 -0
- package/types/components/BimViewerComponents/SettingTool.vue.d.ts +13 -0
- package/types/components/BimViewerComponents/StructureTree.vue.d.ts +3053 -0
- package/types/components/BimViewerComponents/Toolbar.vue.d.ts +10 -0
- package/types/components/BimViewerComponents/XRayTool.vue.d.ts +12 -0
- package/types/components/BimViewerComponents/mobileToolbar.vue.d.ts +27 -0
- package/types/components/MobileBCFComponents/MobileBCFAdd.vue.d.ts +56 -0
- package/types/components/MobileBCFComponents/MobileBCFDetail.vue.d.ts +55 -0
- package/types/components/MobileBCFComponents/MobileBCFDisplayList.vue.d.ts +278 -0
- package/types/components/MobileBCFComponents/MobileBCFFilter.vue.d.ts +255 -0
- package/types/components/MobileBCFComponents/MobileBCFTool.vue.d.ts +15 -0
- package/types/components/MobileBCFComponents/MobileCommentInput.vue.d.ts +54 -0
- package/types/components/MobileBCFComponents/MobileCommentsView.vue.d.ts +17 -0
- package/types/components/MobileBCFComponents/selectPanel.vue.d.ts +12 -0
- package/types/components/index.d.ts +3 -0
- package/types/components/industryViewer.vue.d.ts +18 -0
- package/types/components/utilsComponents/alert.vue.d.ts +32 -0
- package/types/components/utilsComponents/closeButton.vue.d.ts +50 -0
- package/types/components/utilsComponents/closeButton_dark.vue.d.ts +32 -0
- package/types/components/utilsComponents/emptyPage.vue.d.ts +6 -0
- package/types/components/utilsComponents/loading.vue.d.ts +2 -0
- package/types/components/utilsComponents/panel.vue.d.ts +47 -0
- package/types/components/utilsComponents/rectangleButton.vue.d.ts +106 -0
- package/types/components/utilsComponents/tallPanel.vue.d.ts +69 -0
- package/types/components/utilsComponents/tallPanel_noPos.vue.d.ts +82 -0
- package/types/index.d.ts +31 -0
- package/types/main.d.ts +1 -0
- package/types/pages/viewerEntry.vue.d.ts +59 -0
- package/types/services/request/config.d.ts +8 -0
- package/types/store/bcfManager.d.ts +11 -0
- package/types/store/bcfReflect.d.ts +88 -0
- package/types/store/const.d.ts +211 -0
- package/types/store/initConfigs.d.ts +58 -0
- package/types/store/propertyReflect.d.ts +1 -0
- package/types/store/themeManager.d.ts +8 -0
- package/types/store/toolbars.d.ts +392 -0
- package/types/utils/OSSHelper.d.ts +4 -0
- package/types/utils/cacheInfo.d.ts +20 -0
- package/types/utils/dateFormat.d.ts +2 -0
- package/types/utils/dpscan.d.ts +1 -0
- package/types/utils/eventBus.d.ts +86 -0
- package/types/utils/roles.d.ts +1 -0
- package/types/utils/splitType.d.ts +3 -0
- package/types/utils/timer.d.ts +9 -0
- package/types/viewerManager/initial/viewerInitial.d.ts +7 -0
- package/types/viewerManager/load/loadModel.d.ts +1 -0
- package/types/viewerManager/viewerManager.d.ts +12 -0
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
import { defineComponent as ge, ref as s, onMounted as U, onBeforeUnmount as _e, watch as Me, openBlock as I, createElementBlock as A, Fragment as F, createElementVNode as t, renderList as fe, unref as a, normalizeClass as he, toDisplayString as ye, createCommentVNode as we, normalizeStyle as O, withDirectives as Te, vShow as pe } from "vue";
|
|
2
|
+
import { p as Be, T as q, t as P, O as h, V as W, q as g, z as be } from "./index-CBO0Vhj8.mjs";
|
|
3
|
+
import { M as L } from "./const-DeViLYl5.mjs";
|
|
4
|
+
const Ie = { class: "mobile_measure_panel" }, Ae = { class: "measure-list" }, Ee = ["onClick"], De = { class: "measure-icon" }, Re = ["src"], Ve = { class: "measure-name" }, Se = { class: "measure-icon" }, ke = ["src"], Le = { class: "mouse_btn" }, xe = ["src"], Ce = ["src"], $e = ["src"], ze = /* @__PURE__ */ ge({
|
|
5
|
+
__name: "MeasureTool",
|
|
6
|
+
props: ["componentId"],
|
|
7
|
+
emits: ["closePanel", "emitHandler"],
|
|
8
|
+
setup(j, { emit: J }) {
|
|
9
|
+
const y = Be(), K = j, x = s(0);
|
|
10
|
+
U(() => {
|
|
11
|
+
y.setReadyById(K.componentId), q.currentTheme == "blue" ? x.value = 224 : q.currentTheme == "light-gray" && (x.value = 202);
|
|
12
|
+
});
|
|
13
|
+
let u, w, T, i;
|
|
14
|
+
const n = s(1), C = s(), E = s(), _ = s(), D = s(), R = s(), Q = s(), Z = s(), G = s(), ee = s(1), se = s("m"), te = s(3), l = s(!1), oe = J, $ = (e) => {
|
|
15
|
+
oe("emitHandler", e);
|
|
16
|
+
}, z = () => {
|
|
17
|
+
T = window.bimViewer, W.SaveViewerState({ measure: "distance" }), w = window.bimViewer.measureAngleTool, u = window.bimViewer.measureDistanceTool, i = window.bimViewer.eventTrigger, g("isMobile") && (i.on("newAngleMeasure", (e) => {
|
|
18
|
+
l.value = !1;
|
|
19
|
+
}), i.on("newDistanceMeasure", (e) => {
|
|
20
|
+
l.value = !1;
|
|
21
|
+
})), i.on("createAngleMeasure", (e) => {
|
|
22
|
+
R.value = e.id, D.value = e.result, g("isMobile") && (l.value = !0), m("createAngleMeasure", { newMeasure: e });
|
|
23
|
+
}), i.on("createDistanceMeasure", (e) => {
|
|
24
|
+
C.value = e.id, _.value = e.id, E.value = e.result, Q.value = e.xResult ? e.xResult : 0, Z.value = e.yResult ? e.yResult : 0, G.value = e.zResult ? e.zResult : 0, g("isMobile") && (l.value = !0), m("createAngleMeasure", { newMeasure: e });
|
|
25
|
+
}), i.on("clickDistanceMeasure", (e) => {
|
|
26
|
+
n.value == 2 && V(L[0]), C.value = e.id, ie(e.id), g("isMobile") && (l.value = !0), m("clickDistanceMeasure", { id: e.id });
|
|
27
|
+
}), i.on("clickAngleMeasure", (e) => {
|
|
28
|
+
n.value == 1 && V(L[1]), ae(e.id), g("isMobile") && (l.value = !0), m("clickAngleMeasure", { id: e.id });
|
|
29
|
+
}), u.precision = te.value, u.unit = se.value, u.scale = ee.value;
|
|
30
|
+
};
|
|
31
|
+
P.on("BimViewer", z), _e(() => {
|
|
32
|
+
P.off("BimViewer", z);
|
|
33
|
+
}), Me(
|
|
34
|
+
() => y.isToolActive(3),
|
|
35
|
+
(e) => {
|
|
36
|
+
ce(e);
|
|
37
|
+
}
|
|
38
|
+
);
|
|
39
|
+
const m = (e, o) => {
|
|
40
|
+
$({
|
|
41
|
+
isTool: !0,
|
|
42
|
+
event_name: e,
|
|
43
|
+
event_target: "MeasureTool",
|
|
44
|
+
content: o
|
|
45
|
+
});
|
|
46
|
+
}, V = (e) => {
|
|
47
|
+
n.value !== e.id && (n.value = e.id, W.SaveViewerState({ measure: e.code }), le(e), g("isMobile") && (l.value = !1));
|
|
48
|
+
}, le = (e) => {
|
|
49
|
+
let o = e.code;
|
|
50
|
+
window.bimViewer.measureTool.setActiveByType(o, !0), $({
|
|
51
|
+
isTool: !0,
|
|
52
|
+
event_name: "",
|
|
53
|
+
event_target: "MeasureTool",
|
|
54
|
+
content: {
|
|
55
|
+
measureTool: o
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
}, ne = () => {
|
|
59
|
+
E.value = "", D.value = "", n.value === 1 ? (re(_.value), m("destroyMeasureDistance", { id: _.value })) : n.value === 2 && (ue(R.value), m("destroyMeasurementAngle", { id: _.value })), l.value = !1;
|
|
60
|
+
}, ae = (e) => {
|
|
61
|
+
R.value = e, D.value = w.getMeasureResultByID(e);
|
|
62
|
+
}, ue = (e) => w.destroyMeasurementById(e), ie = (e) => {
|
|
63
|
+
_.value = e, E.value = u.getMeasureResultByID(e);
|
|
64
|
+
}, re = (e) => u.destroyMeasurementById(e), ce = (e) => {
|
|
65
|
+
u.setAllVisible(e), w.setAllVisible(e);
|
|
66
|
+
};
|
|
67
|
+
let N;
|
|
68
|
+
U(() => {
|
|
69
|
+
N = document.getElementById("top_bar");
|
|
70
|
+
});
|
|
71
|
+
const d = s(!1);
|
|
72
|
+
let p = !1, B = 0, b = 0, S = 0, k = 0;
|
|
73
|
+
const r = s(260), c = s(500), ve = () => {
|
|
74
|
+
d.value = !d.value, d.value ? me() : de();
|
|
75
|
+
}, X = (e) => {
|
|
76
|
+
p ? T.measureTool.currentTool.onSimulateMousedown([r.value, c.value]) : e.touches.length == 1 && (B = e.touches[0].clientX, b = e.touches[0].clientY, p = !0);
|
|
77
|
+
}, Y = (e) => {
|
|
78
|
+
if (e.touches.length == 1) {
|
|
79
|
+
const o = e.touches[0].clientX, M = e.touches[0].clientY;
|
|
80
|
+
S = o - B, k = M - b, r.value += S, c.value += k;
|
|
81
|
+
let f = new Int16Array(2);
|
|
82
|
+
f[0] = r.value + 5, f[1] = c.value + N.offsetHeight + 6, B = o, b = M, T.measureTool.currentTool.onSimulateMousemove([r.value, c.value]);
|
|
83
|
+
}
|
|
84
|
+
}, H = (e) => {
|
|
85
|
+
p && T.measureTool.currentTool.onSimulateMouseup([r.value, c.value]);
|
|
86
|
+
}, me = () => {
|
|
87
|
+
const e = document.getElementById("measure_mouseGroup");
|
|
88
|
+
e == null || e.addEventListener("touchstart", X), e == null || e.addEventListener("touchmove", Y), e == null || e.addEventListener("touchend", H), r.value = 260, c.value = 500, B = 0, b = 0, S = 0, k = 0, p = !1;
|
|
89
|
+
}, de = () => {
|
|
90
|
+
const e = document.getElementById("measure_mouseGroup");
|
|
91
|
+
e == null || e.removeEventListener("touchstart", X), e == null || e.removeEventListener("touchmove", Y), e == null || e.removeEventListener("touchend", H);
|
|
92
|
+
};
|
|
93
|
+
return (e, o) => {
|
|
94
|
+
var M, f;
|
|
95
|
+
return I(), A(F, null, [
|
|
96
|
+
t("div", Ie, [
|
|
97
|
+
t("div", Ae, [
|
|
98
|
+
(I(!0), A(F, null, fe(a(L), (v) => (I(), A("div", {
|
|
99
|
+
key: v.id,
|
|
100
|
+
class: he(["measure-item", {
|
|
101
|
+
"measure-item-active": n.value === v.id
|
|
102
|
+
}]),
|
|
103
|
+
onClick: (Ne) => V(v)
|
|
104
|
+
}, [
|
|
105
|
+
t("div", De, [
|
|
106
|
+
t("img", {
|
|
107
|
+
src: a(h) + `/industry-viewer/measure-bar/${n.value === v.id ? v.svgActive : v.svg}.svg`,
|
|
108
|
+
alt: ""
|
|
109
|
+
}, null, 8, Re),
|
|
110
|
+
t("div", Ve, ye(v.name), 1)
|
|
111
|
+
])
|
|
112
|
+
], 10, Ee))), 128)),
|
|
113
|
+
l.value ? (I(), A("div", {
|
|
114
|
+
key: 0,
|
|
115
|
+
class: "measure-item",
|
|
116
|
+
onClick: ne
|
|
117
|
+
}, [
|
|
118
|
+
t("div", Se, [
|
|
119
|
+
t("img", {
|
|
120
|
+
src: a(h) + "/industry-viewer/delete.svg",
|
|
121
|
+
alt: ""
|
|
122
|
+
}, null, 8, ke),
|
|
123
|
+
o[0] || (o[0] = t("div", {
|
|
124
|
+
class: "measure-name",
|
|
125
|
+
style: { color: "#df1c1c" }
|
|
126
|
+
}, " 删除 ", -1))
|
|
127
|
+
])
|
|
128
|
+
])) : we("", !0)
|
|
129
|
+
]),
|
|
130
|
+
t("div", Le, [
|
|
131
|
+
t("div", {
|
|
132
|
+
class: "mouse",
|
|
133
|
+
onClick: ve
|
|
134
|
+
}, [
|
|
135
|
+
t("img", {
|
|
136
|
+
src: `${a(h)}/industry-viewer/action-bar/${d.value ? (M = a(y).getToolById(15)) == null ? void 0 : M.imgActive : (f = a(y).getToolById(15)) == null ? void 0 : f.img}.svg`
|
|
137
|
+
}, null, 8, xe),
|
|
138
|
+
t("span", {
|
|
139
|
+
style: O({ color: d.value ? "#1457F7" : "#262626" })
|
|
140
|
+
}, "虚拟鼠标", 4)
|
|
141
|
+
])
|
|
142
|
+
])
|
|
143
|
+
]),
|
|
144
|
+
Te(t("div", {
|
|
145
|
+
id: "measure_mouseGroup",
|
|
146
|
+
class: "mouse_group",
|
|
147
|
+
style: O({ left: `${r.value}px`, top: `${c.value}px` })
|
|
148
|
+
}, [
|
|
149
|
+
t("img", {
|
|
150
|
+
id: "mouse_icon",
|
|
151
|
+
class: "mouse_icon",
|
|
152
|
+
src: `${a(h)}/industry-viewer/mouse-icon.svg`
|
|
153
|
+
}, null, 8, Ce),
|
|
154
|
+
t("img", {
|
|
155
|
+
id: "mouse_img",
|
|
156
|
+
class: "mouse_img",
|
|
157
|
+
src: `${a(h)}/industry-viewer/mouse-active-large.svg`
|
|
158
|
+
}, null, 8, $e)
|
|
159
|
+
], 4), [
|
|
160
|
+
[pe, d.value]
|
|
161
|
+
])
|
|
162
|
+
], 64);
|
|
163
|
+
};
|
|
164
|
+
}
|
|
165
|
+
}), Ue = /* @__PURE__ */ be(ze, [["__scopeId", "data-v-075f91d3"]]);
|
|
166
|
+
export {
|
|
167
|
+
Ue as default
|
|
168
|
+
};
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { defineComponent as x, onMounted as A, onBeforeUnmount as O, ref as _, watch as $, openBlock as F, createElementBlock as M, withDirectives as j, createElementVNode as p, normalizeStyle as C, unref as k, vShow as N } from "vue";
|
|
2
|
+
import { p as R, t as o, O as V } from "./index-CBO0Vhj8.mjs";
|
|
3
|
+
const U = { class: "mouse_tool" }, z = ["src"], D = ["src"], q = /* @__PURE__ */ x({
|
|
4
|
+
__name: "MouseTool",
|
|
5
|
+
props: ["componentId"],
|
|
6
|
+
setup(T) {
|
|
7
|
+
const g = R(), y = T;
|
|
8
|
+
let E;
|
|
9
|
+
A(() => {
|
|
10
|
+
g.setReadyById(y.componentId), E = document.getElementById("top_bar");
|
|
11
|
+
});
|
|
12
|
+
let t;
|
|
13
|
+
const w = () => {
|
|
14
|
+
t = window.bimViewer, t.eventTrigger.on("pickedNothing", () => {
|
|
15
|
+
s.value = !1;
|
|
16
|
+
});
|
|
17
|
+
};
|
|
18
|
+
o.on("BimViewer", w);
|
|
19
|
+
const B = () => {
|
|
20
|
+
s.value = !1;
|
|
21
|
+
};
|
|
22
|
+
o.on("unFocus", B), O(() => {
|
|
23
|
+
o.off("BimViewer", w), o.off("unFocus", B);
|
|
24
|
+
});
|
|
25
|
+
const a = _(260), u = _(500), s = _(!1);
|
|
26
|
+
let d = !1, n = !1, c = 0, i = 0, m = 0, v = 0;
|
|
27
|
+
$(
|
|
28
|
+
() => g.isToolActive(y.componentId),
|
|
29
|
+
(e) => {
|
|
30
|
+
e ? X() : (n = !1, d = !1, c = 0, i = 0, m = 0, v = 0, Y());
|
|
31
|
+
}
|
|
32
|
+
);
|
|
33
|
+
let l = "";
|
|
34
|
+
const S = (e) => {
|
|
35
|
+
n || e.touches.length == 1 && (d = !0, c = e.touches[0].clientX, i = e.touches[0].clientY);
|
|
36
|
+
}, I = (e) => {
|
|
37
|
+
n && (s.value = !0, o.emit("focusEntity", l));
|
|
38
|
+
}, L = (e) => {
|
|
39
|
+
if (d && e.touches.length == 1) {
|
|
40
|
+
const f = e.touches[0].clientX, b = e.touches[0].clientY;
|
|
41
|
+
m = f - c, v = b - i, a.value += m, u.value += v;
|
|
42
|
+
let h = new Int16Array(2);
|
|
43
|
+
h[0] = a.value + 5, h[1] = u.value + E.offsetHeight + 6;
|
|
44
|
+
const r = t.viewer.scene.pick({
|
|
45
|
+
canvasPos: h
|
|
46
|
+
});
|
|
47
|
+
r ? (n = !0, l !== r.entity.id && (l = r.entity.id, t.setAllObjectsSelected(!1), t.setEntitySelected(r.entity))) : (l = "", t.setAllObjectsSelected(!1)), c = f, i = b;
|
|
48
|
+
}
|
|
49
|
+
}, X = () => {
|
|
50
|
+
const e = document.getElementById("mouseGroup");
|
|
51
|
+
e == null || e.addEventListener("touchstart", S), e == null || e.addEventListener("touchmove", L), e == null || e.addEventListener("click", I);
|
|
52
|
+
}, Y = () => {
|
|
53
|
+
const e = document.getElementById("mouseGroup");
|
|
54
|
+
e == null || e.removeEventListener("touchstart", S), e == null || e.removeEventListener("touchmove", L), e == null || e.removeEventListener("click", I);
|
|
55
|
+
};
|
|
56
|
+
return (e, f) => (F(), M("div", U, [
|
|
57
|
+
j(p("div", {
|
|
58
|
+
id: "mouseGroup",
|
|
59
|
+
class: "mouse_group",
|
|
60
|
+
style: C({ left: `${a.value}px`, top: `${u.value}px` })
|
|
61
|
+
}, [
|
|
62
|
+
p("img", {
|
|
63
|
+
id: "mouse_icon",
|
|
64
|
+
class: "mouse_icon",
|
|
65
|
+
src: `${k(V)}/industry-viewer/mouse-icon.svg`
|
|
66
|
+
}, null, 8, z),
|
|
67
|
+
p("img", {
|
|
68
|
+
id: "mouse_img",
|
|
69
|
+
class: "mouse_img",
|
|
70
|
+
src: `${k(V)}/industry-viewer/mouse-active-large.svg`
|
|
71
|
+
}, null, 8, D)
|
|
72
|
+
], 4), [
|
|
73
|
+
[N, !s.value]
|
|
74
|
+
])
|
|
75
|
+
]));
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
export {
|
|
79
|
+
q as default
|
|
80
|
+
};
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { defineComponent as u, onMounted as p, ref as b, openBlock as i, createElementBlock as n, createElementVNode as s, Fragment as w, renderList as g, unref as r, normalizeClass as f, toDisplayString as h } from "vue";
|
|
2
|
+
import { N } from "./const-DeViLYl5.mjs";
|
|
3
|
+
import { p as S, O as T } from "./index-CBO0Vhj8.mjs";
|
|
4
|
+
const k = { class: "best-view-box" }, I = { class: "best-view-list" }, V = ["onClick"], y = { class: "best-view-icon" }, A = ["src"], B = { class: "best-view-name" }, D = /* @__PURE__ */ u({
|
|
5
|
+
__name: "NavigateTool",
|
|
6
|
+
props: ["componentId"],
|
|
7
|
+
emits: ["emitHandler"],
|
|
8
|
+
setup(a, { emit: c }) {
|
|
9
|
+
const l = S(), d = a;
|
|
10
|
+
p(() => {
|
|
11
|
+
l.setReadyById(d.componentId);
|
|
12
|
+
});
|
|
13
|
+
const v = c, m = (e) => {
|
|
14
|
+
v("emitHandler", e);
|
|
15
|
+
}, o = b(), _ = (e) => {
|
|
16
|
+
if (e.id === o.value) {
|
|
17
|
+
o.value = "";
|
|
18
|
+
return;
|
|
19
|
+
}
|
|
20
|
+
o.value = e.id, window.bimViewer.setDirection(e.dir_num), m({
|
|
21
|
+
isTool: !0,
|
|
22
|
+
event_target: "NavigateTool",
|
|
23
|
+
event_name: "changeNav",
|
|
24
|
+
content: {
|
|
25
|
+
direction: e.dir_num
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
};
|
|
29
|
+
return (e, C) => (i(), n("div", k, [
|
|
30
|
+
s("div", I, [
|
|
31
|
+
(i(!0), n(w, null, g(r(N), (t) => (i(), n("div", {
|
|
32
|
+
key: t.id,
|
|
33
|
+
class: f(["best-view-item", {
|
|
34
|
+
"best-view-item-active": o.value === t.id
|
|
35
|
+
}]),
|
|
36
|
+
onClick: (E) => _(t)
|
|
37
|
+
}, [
|
|
38
|
+
s("div", y, [
|
|
39
|
+
s("img", {
|
|
40
|
+
src: r(T) + `/bim-viewer/best-view/${o.value === t.id ? t.imgActive : t.img}.svg`,
|
|
41
|
+
alt: ""
|
|
42
|
+
}, null, 8, A),
|
|
43
|
+
s("div", B, h(t.name), 1)
|
|
44
|
+
])
|
|
45
|
+
], 10, V))), 128))
|
|
46
|
+
])
|
|
47
|
+
]));
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
export {
|
|
51
|
+
D as default
|
|
52
|
+
};
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
import { defineComponent as k, ref as u, onMounted as F, onBeforeUnmount as N, watch as P, openBlock as x, createElementBlock as O, createElementVNode as o, unref as d, toDisplayString as G } from "vue";
|
|
2
|
+
import { p as Y, q as v, I as B, t as f, O as l, C as I, z as H } from "./index-CBO0Vhj8.mjs";
|
|
3
|
+
const A = { class: "roam_container_wrapper" }, $ = { class: "mobile_roam-box" }, q = { class: "roam-left" }, z = { class: "roam-left-box" }, X = {
|
|
4
|
+
id: "roamMoveForward",
|
|
5
|
+
class: "roam-left-item"
|
|
6
|
+
}, j = ["src"], J = { class: "roam-left-box" }, K = {
|
|
7
|
+
id: "roamMoveBackward",
|
|
8
|
+
class: "roam-left-item roam-left-bottom"
|
|
9
|
+
}, Q = ["src"], W = { class: "speed_panel roam-left" }, Z = { class: "roam-left-item" }, ee = { class: "up_down_img" }, oe = ["src"], te = { class: "speed_text" }, ne = { class: "up_down_img" }, re = ["src"], se = { class: "roam-right" }, ae = {
|
|
10
|
+
id: "roamMoveUp",
|
|
11
|
+
class: "roam-right-up"
|
|
12
|
+
}, ie = ["src"], de = { class: "roam-right-center" }, le = {
|
|
13
|
+
id: "roamMoveLeft",
|
|
14
|
+
class: "center-left"
|
|
15
|
+
}, me = ["src"], ue = { class: "center-center" }, ce = ["src"], ve = {
|
|
16
|
+
id: "roamMoveRight",
|
|
17
|
+
class: "center-right"
|
|
18
|
+
}, fe = ["src"], we = {
|
|
19
|
+
id: "roamMoveDown",
|
|
20
|
+
class: "roam-right-down"
|
|
21
|
+
}, _e = ["src"], ge = /* @__PURE__ */ k({
|
|
22
|
+
__name: "RoamTool",
|
|
23
|
+
props: ["componentId"],
|
|
24
|
+
emits: ["closePanel", "emitHandler"],
|
|
25
|
+
setup(L, { emit: y }) {
|
|
26
|
+
const _ = Y(), w = u("1"), g = u(!1), c = u(!0), h = L, D = y, r = u(!1), p = (e) => {
|
|
27
|
+
D("emitHandler", e);
|
|
28
|
+
}, n = u(v("isMobile"));
|
|
29
|
+
F(() => {
|
|
30
|
+
(v("isMobile") || B.showRoam === !1) && (c.value = !1), setTimeout(() => {
|
|
31
|
+
R(), S(), T(), U(), V(), C();
|
|
32
|
+
}, 1e3), _.setReadyById(h.componentId);
|
|
33
|
+
});
|
|
34
|
+
const b = () => {
|
|
35
|
+
let e = window.bimViewer.eventTrigger;
|
|
36
|
+
e.on("personModeSpeedUp", (t) => {
|
|
37
|
+
w.value = t.toString();
|
|
38
|
+
}), e.on("personModeSpeedDown", (t) => {
|
|
39
|
+
w.value = t.toString();
|
|
40
|
+
});
|
|
41
|
+
};
|
|
42
|
+
f.on("BimViewer", b), N(() => {
|
|
43
|
+
f.off("BimViewer", b);
|
|
44
|
+
});
|
|
45
|
+
const M = (e) => {
|
|
46
|
+
e ? window.bimViewer.firstPersonMode.speedUp() : window.bimViewer.firstPersonMode.speedDown();
|
|
47
|
+
};
|
|
48
|
+
I.INDUSTRY_CONFIGS.RoamTool || (f.on("INDUSTRY_CONFIGS", () => {
|
|
49
|
+
B.showRoam == !1 && (c.value = !1);
|
|
50
|
+
}), I.INDUSTRY_CONFIGS.RoamTool = !0), P(
|
|
51
|
+
() => _.isToolActive(h.componentId),
|
|
52
|
+
(e) => {
|
|
53
|
+
E(!!e);
|
|
54
|
+
}
|
|
55
|
+
);
|
|
56
|
+
const E = (e) => {
|
|
57
|
+
v("isMobile") ? r.value = e : (v("hideTool") || f.emit("hideToolbar", e), e ? c.value && (g.value = !0) : g.value = !1);
|
|
58
|
+
}, R = () => {
|
|
59
|
+
var e, t, s;
|
|
60
|
+
(e = document.getElementById("roamMoveUp")) == null || e.addEventListener(n.value ? "touchstart" : "mousedown", (i) => {
|
|
61
|
+
r.value && (n.value && i.preventDefault(), window.bimViewer.firstPersonMode.goUp = !0, m("goUp"));
|
|
62
|
+
}), (t = document.getElementById("roamMoveUp")) == null || t.addEventListener(n.value ? "touchend" : "mouseup", () => {
|
|
63
|
+
r.value && a();
|
|
64
|
+
}), (s = document.getElementById("roamMoveUp")) == null || s.addEventListener(n.value ? "touchcancel" : "mouseup", () => {
|
|
65
|
+
r.value && a();
|
|
66
|
+
});
|
|
67
|
+
}, S = () => {
|
|
68
|
+
var e, t, s;
|
|
69
|
+
(e = document.getElementById("roamMoveDown")) == null || e.addEventListener(n.value ? "touchstart" : "mousedown", (i) => {
|
|
70
|
+
r.value && (n.value && i.preventDefault(), window.bimViewer.firstPersonMode.goDown = !0, m("goDown"));
|
|
71
|
+
}), (t = document.getElementById("roamMoveDown")) == null || t.addEventListener(n.value ? "touchend" : "mouseup", () => {
|
|
72
|
+
r.value && a();
|
|
73
|
+
}), (s = document.getElementById("roamMoveDown")) == null || s.addEventListener(n.value ? "touchcancel" : "mouseup", () => {
|
|
74
|
+
r.value && a();
|
|
75
|
+
});
|
|
76
|
+
}, T = () => {
|
|
77
|
+
var e, t, s;
|
|
78
|
+
(e = document.getElementById("roamMoveLeft")) == null || e.addEventListener(n.value ? "touchstart" : "mousedown", (i) => {
|
|
79
|
+
r.value && (n.value && i.preventDefault(), window.bimViewer.firstPersonMode.goLeft = !0, m("goLeft"));
|
|
80
|
+
}), (t = document.getElementById("roamMoveLeft")) == null || t.addEventListener(n.value ? "touchend" : "mouseup", () => {
|
|
81
|
+
r.value && a();
|
|
82
|
+
}), (s = document.getElementById("roamMoveLeft")) == null || s.addEventListener(n.value ? "touchcancel" : "mouseup", () => {
|
|
83
|
+
r.value && a();
|
|
84
|
+
});
|
|
85
|
+
}, U = () => {
|
|
86
|
+
var e, t, s;
|
|
87
|
+
(e = document.getElementById("roamMoveRight")) == null || e.addEventListener(n.value ? "touchstart" : "mousedown", (i) => {
|
|
88
|
+
r.value && (n.value && i.preventDefault(), window.bimViewer.firstPersonMode.goRight = !0, m("goDown"));
|
|
89
|
+
}), (t = document.getElementById("roamMoveRight")) == null || t.addEventListener(n.value ? "touchend" : "mouseup", () => {
|
|
90
|
+
r.value && a();
|
|
91
|
+
}), (s = document.getElementById("roamMoveRight")) == null || s.addEventListener(n.value ? "touchcancel" : "mouseup", () => {
|
|
92
|
+
r.value && a();
|
|
93
|
+
});
|
|
94
|
+
}, V = () => {
|
|
95
|
+
var e, t, s;
|
|
96
|
+
(e = document.getElementById("roamMoveForward")) == null || e.addEventListener(n.value ? "touchstart" : "mousedown", (i) => {
|
|
97
|
+
r.value && (n.value && i.preventDefault(), window.bimViewer.firstPersonMode.goForward = !0, m("goForward"));
|
|
98
|
+
}), (t = document.getElementById("roamMoveForward")) == null || t.addEventListener(n.value ? "touchend" : "mouseup", () => {
|
|
99
|
+
r.value && a();
|
|
100
|
+
}), (s = document.getElementById("roamMoveForward")) == null || s.addEventListener(n.value ? "touchcancel" : "mouseup", () => {
|
|
101
|
+
r.value && a();
|
|
102
|
+
});
|
|
103
|
+
}, C = () => {
|
|
104
|
+
var e, t, s;
|
|
105
|
+
(e = document.getElementById("roamMoveBackward")) == null || e.addEventListener(n.value ? "touchstart" : "mousedown", (i) => {
|
|
106
|
+
r.value && (n.value && i.preventDefault(), window.bimViewer.firstPersonMode.goBackward = !0, m("goBackward"));
|
|
107
|
+
}), (t = document.getElementById("roamMoveBackward")) == null || t.addEventListener(n.value ? "touchend" : "mouseup", () => {
|
|
108
|
+
r.value && a();
|
|
109
|
+
}), (s = document.getElementById("roamMoveBackward")) == null || s.addEventListener(n.value ? "touchcancel" : "mouseup", () => {
|
|
110
|
+
r.value && a();
|
|
111
|
+
});
|
|
112
|
+
}, m = (e) => {
|
|
113
|
+
p({
|
|
114
|
+
isTool: !0,
|
|
115
|
+
event_target: "RoamTool",
|
|
116
|
+
event_name: "",
|
|
117
|
+
content: {
|
|
118
|
+
roam: e
|
|
119
|
+
}
|
|
120
|
+
});
|
|
121
|
+
}, a = () => {
|
|
122
|
+
window.bimViewer.firstPersonMode.setdirectionChangeCancel(), p({
|
|
123
|
+
isTool: !0,
|
|
124
|
+
event_target: "RoamTool",
|
|
125
|
+
event_name: "",
|
|
126
|
+
content: {
|
|
127
|
+
roam: "stop"
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
};
|
|
131
|
+
return (e, t) => (x(), O("div", A, [
|
|
132
|
+
o("div", $, [
|
|
133
|
+
o("div", q, [
|
|
134
|
+
o("div", z, [
|
|
135
|
+
o("div", X, [
|
|
136
|
+
o("img", {
|
|
137
|
+
src: d(l) + "/bim-viewer/roam-bar/up.svg",
|
|
138
|
+
alt: ""
|
|
139
|
+
}, null, 8, j)
|
|
140
|
+
])
|
|
141
|
+
]),
|
|
142
|
+
o("div", J, [
|
|
143
|
+
o("div", K, [
|
|
144
|
+
o("img", {
|
|
145
|
+
src: d(l) + "/bim-viewer/roam-bar/down.svg",
|
|
146
|
+
alt: ""
|
|
147
|
+
}, null, 8, Q)
|
|
148
|
+
])
|
|
149
|
+
])
|
|
150
|
+
]),
|
|
151
|
+
o("div", W, [
|
|
152
|
+
o("div", Z, [
|
|
153
|
+
o("div", ee, [
|
|
154
|
+
o("img", {
|
|
155
|
+
src: d(l) + "/bim-viewer/roam-bar/plus.svg",
|
|
156
|
+
onClick: t[0] || (t[0] = (s) => M(!0)),
|
|
157
|
+
alt: ""
|
|
158
|
+
}, null, 8, oe)
|
|
159
|
+
]),
|
|
160
|
+
o("div", te, [
|
|
161
|
+
o("span", null, G(w.value) + "X", 1)
|
|
162
|
+
]),
|
|
163
|
+
o("div", ne, [
|
|
164
|
+
o("img", {
|
|
165
|
+
src: d(l) + "/bim-viewer/roam-bar/minus.svg",
|
|
166
|
+
onClick: t[1] || (t[1] = (s) => M(!1)),
|
|
167
|
+
alt: ""
|
|
168
|
+
}, null, 8, re)
|
|
169
|
+
])
|
|
170
|
+
])
|
|
171
|
+
]),
|
|
172
|
+
o("div", se, [
|
|
173
|
+
o("div", ae, [
|
|
174
|
+
o("img", {
|
|
175
|
+
src: d(l) + "/bim-viewer/roam-bar/top.svg",
|
|
176
|
+
alt: ""
|
|
177
|
+
}, null, 8, ie)
|
|
178
|
+
]),
|
|
179
|
+
o("div", de, [
|
|
180
|
+
o("div", le, [
|
|
181
|
+
o("img", {
|
|
182
|
+
src: d(l) + "/bim-viewer/roam-bar/left.svg",
|
|
183
|
+
alt: ""
|
|
184
|
+
}, null, 8, me)
|
|
185
|
+
]),
|
|
186
|
+
o("div", ue, [
|
|
187
|
+
o("img", {
|
|
188
|
+
src: d(l) + "/bim-viewer/roam-bar/center.svg",
|
|
189
|
+
alt: ""
|
|
190
|
+
}, null, 8, ce)
|
|
191
|
+
]),
|
|
192
|
+
o("div", ve, [
|
|
193
|
+
o("img", {
|
|
194
|
+
src: d(l) + "/bim-viewer/roam-bar/right.svg",
|
|
195
|
+
alt: ""
|
|
196
|
+
}, null, 8, fe)
|
|
197
|
+
])
|
|
198
|
+
]),
|
|
199
|
+
o("div", we, [
|
|
200
|
+
o("img", {
|
|
201
|
+
src: d(l) + "/bim-viewer/roam-bar/bottom.svg",
|
|
202
|
+
alt: ""
|
|
203
|
+
}, null, 8, _e)
|
|
204
|
+
])
|
|
205
|
+
])
|
|
206
|
+
])
|
|
207
|
+
]));
|
|
208
|
+
}
|
|
209
|
+
}), be = /* @__PURE__ */ H(ge, [["__scopeId", "data-v-d6d1c4c6"]]);
|
|
210
|
+
export {
|
|
211
|
+
be as default
|
|
212
|
+
};
|