@xtctwins/tctwins-industry-engine 0.0.12 → 0.1.0
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 -3
- package/dist/01.xtc +0 -0
- package/dist/02.xtc +0 -0
- package/dist/03.xtc +0 -0
- package/dist/AnnotationTool-DfcSXn-d.mjs +166 -0
- package/dist/CameraViewTool-C91GKumm.mjs +164 -0
- package/dist/CommentTool-CR1yMDYP.mjs +1528 -0
- package/dist/HiddenTool-iCXaAMtS.mjs +56 -0
- package/dist/Industry_Viewer_Lib.es.js +10 -5
- package/dist/Industry_Viewer_Lib.umd.js +264 -237
- package/dist/InspectorTool-MyLTC7qp.mjs +679 -0
- package/dist/MeasureTool-BpomWCXl.mjs +593 -0
- package/dist/MouseTool-COWvA8Jk.mjs +84 -0
- package/dist/NavigateTool-DeMrrYoS.mjs +51 -0
- package/dist/OperateTool-DSZCJVkD.mjs +185 -0
- package/dist/RoamTool-0E0ls2Cx.mjs +287 -0
- package/dist/ScreenShotTool-viitj9zy.mjs +429 -0
- package/dist/SectionTool-Bz1c26fa.mjs +241 -0
- package/dist/SettingTool-BlsqUNQM.mjs +1745 -0
- package/dist/StructureTree-Dke0hMRC.mjs +1685 -0
- package/dist/alert-CgfjcpRo.mjs +52 -0
- package/dist/index-COQ8NdId.mjs +138714 -0
- package/dist/index.html +17 -0
- package/dist/{panel.vue_vue_type_style_index_0_lang-CCuIP-Pp.mjs → panel.vue_vue_type_style_index_0_lang-B-dNXuRK.mjs} +3 -3
- package/dist/style.css +3 -1
- package/dist/{tallPanel-CqKqC6yK.mjs → tallPanel-B-5hSZt6.mjs} +24 -24
- package/dist/timer-DoTiGoWP.mjs +30 -0
- package/package.json +85 -66
- package/types/App.vue.d.ts +3 -1
- package/types/components/BCFComponents/BCFAddPanel.vue.d.ts +1 -1
- package/types/components/BCFComponents/BCFDetailPanel.vue.d.ts +1 -1
- package/types/components/BCFComponents/BCFFilter.vue.d.ts +2 -2
- package/types/components/BCFComponents/commentInput.vue.d.ts +1 -1
- package/types/components/BCFComponents/commentsView.vue.d.ts +6 -6
- package/types/components/BCFComponents/imageView.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/AnnotationTool.vue.d.ts +1 -1
- package/types/components/BimViewerComponents/CameraViewTool.vue.d.ts +12 -0
- package/types/components/BimViewerComponents/CommentTool.vue.d.ts +34 -1
- package/types/components/BimViewerComponents/MobileCommentsTool/add.vue.d.ts +14 -0
- package/types/components/BimViewerComponents/MobileCommentsTool/detail.vue.d.ts +11 -0
- package/types/components/BimViewerComponents/MobileCommentsTool/draw.vue.d.ts +17 -0
- package/types/components/BimViewerComponents/MobileCommentsTool/filter.vue.d.ts +275 -0
- package/types/components/BimViewerComponents/MobileCommentsTool/list.vue.d.ts +297 -0
- package/types/components/BimViewerComponents/MobileCommentsTool/zoomIn.vue.d.ts +9 -0
- package/types/components/BimViewerComponents/OperateTool.vue.d.ts +12 -0
- package/types/components/BimViewerComponents/PCCommentTool/pcdraw.vue.d.ts +14 -0
- package/types/components/BimViewerComponents/SectionModeBar.vue.d.ts +2 -0
- package/types/components/BimViewerComponents/StructureTree.vue.d.ts +8035 -419
- package/types/components/{industryViewer.vue.d.ts → BimxViewerComp.vue.d.ts} +7 -0
- package/types/components/IndustryViewerComp.vue.d.ts +25 -0
- package/types/components/MobileBCFComponents/MobileBCFAdd.vue.d.ts +1 -1
- package/types/components/MobileBCFComponents/MobileBCFDetail.vue.d.ts +1 -1
- package/types/components/MobileBCFComponents/MobileBCFDisplayList.vue.d.ts +100 -308
- package/types/components/MobileBCFComponents/MobileBCFFilter.vue.d.ts +100 -308
- package/types/components/MobileBCFComponents/MobileBCFTool.vue.d.ts +2 -0
- package/types/components/MobileBCFComponents/MobileCommentInput.vue.d.ts +4 -4
- package/types/components/utilsComponents/alert.vue.d.ts +9 -0
- package/types/components/utilsComponents/prompt.vue.d.ts +8 -0
- package/types/components/utilsComponents/rectangleButton.vue.d.ts +1 -1
- package/types/i18n/index.d.ts +1767 -0
- package/types/i18n/locales/en-US.d.ts +439 -0
- package/types/i18n/locales/zh-CN.d.ts +439 -0
- package/types/i18n/types.d.ts +144 -0
- package/types/index.d.ts +8 -5
- package/types/pages/{viewerEntry.vue.d.ts → BimxViewerEntry.vue.d.ts} +20 -8
- package/types/pages/IndustryViewerEntry.vue.d.ts +71 -0
- package/types/services/request/api.d.ts +3 -0
- package/types/services/request/index.d.ts +14 -0
- package/types/services/request/types.d.ts +12 -0
- package/types/store/bcfReflect.d.ts +8 -7
- package/types/store/const.d.ts +32 -3
- package/types/store/initConfigs.d.ts +3 -3
- package/types/store/localeStore.d.ts +12 -0
- package/types/store/propertyReflect.d.ts +1 -1
- package/types/store/toolbars.d.ts +596 -75
- package/types/store/userInfoStore.d.ts +32 -0
- package/types/tests/bcf.d.ts +8 -0
- package/types/utils/OSSHelper.d.ts +3 -0
- package/types/utils/eventBus.d.ts +23 -5
- package/types/utils/roles.d.ts +1 -1
- package/types/utils/splitType.d.ts +1 -0
- package/types/viewerManager/initial/viewerInitial.d.ts +14 -1
- package/types/viewerManager/load/loadModel.d.ts +137 -1
- package/types/viewerManager/sectionManager.d.ts +524 -0
- package/types/viewerManager/viewerManager.d.ts +19 -1
- package/dist/AnnotationTool-f7CrC7Dr.mjs +0 -131
- package/dist/BCFTool-CdN6SGDL.mjs +0 -25118
- package/dist/CommentTool-Cfht7mQS.mjs +0 -168
- package/dist/InspectorTool-M_oBYVQA.mjs +0 -674
- package/dist/MeasureTool-CxWeQFgY.mjs +0 -167
- package/dist/MouseTool-BHbi-fg3.mjs +0 -84
- package/dist/NavigateTool-BdUVi4Be.mjs +0 -52
- package/dist/RoamTool-Uuxa-94w.mjs +0 -212
- package/dist/ScreenShotTool-CZUm8l2Z.mjs +0 -445
- package/dist/SectionTool-DZToybAI.mjs +0 -217
- package/dist/SettingTool-CYM0qsUs.mjs +0 -770
- package/dist/StructureTree-DeXxENMk.mjs +0 -1824
- package/dist/XRayTool-Bug-FcKJ.mjs +0 -57
- package/dist/alert-DGyQ9rEq.mjs +0 -46
- package/dist/const-DeViLYl5.mjs +0 -266
- package/dist/el-checkbox-ClYe-8uK.mjs +0 -544
- package/dist/el-input-number-Df5HOHuh.mjs +0 -1028
- package/dist/index-BNrMlQLr.mjs +0 -101871
- /package/types/components/BimViewerComponents/{mobileToolbar.vue.d.ts → AppToolbar.vue.d.ts} +0 -0
- /package/types/components/BimViewerComponents/{XRayTool.vue.d.ts → HiddenTool.vue.d.ts} +0 -0
|
@@ -1,544 +0,0 @@
|
|
|
1
|
-
import { inject as L, computed as p, getCurrentInstance as J, watch as ee, nextTick as le, ref as G, toRaw as W, defineComponent as U, useSlots as ae, createBlock as z, openBlock as S, resolveDynamicComponent as F, unref as c, normalizeClass as V, withCtx as te, createElementVNode as I, createElementBlock as B, createCommentVNode as P, withDirectives as ne, mergeProps as M, isRef as oe, withModifiers as ue, vModelCheckbox as se, renderSlot as R, Fragment as ie, createTextVNode as re, toDisplayString as ce, normalizeStyle as Ve, provide as Le, toRefs as Ee, renderList as Be } from "vue";
|
|
2
|
-
import { j as X, L as Y, d as $, S as de, P as be, U as N, au as _e, i as O, Q as ve, X as j, n as me, M as T, e as _, l as A, k as Ie, x as fe, a as Z, Y as he, R as w, _ as K, u as q, b as Ne, t as D, av as we, Z as De, w as Ge, $ as pe } from "./index-BNrMlQLr.mjs";
|
|
3
|
-
const ke = {
|
|
4
|
-
modelValue: {
|
|
5
|
-
type: [Number, String, Boolean],
|
|
6
|
-
default: void 0
|
|
7
|
-
},
|
|
8
|
-
label: {
|
|
9
|
-
type: [String, Boolean, Number, Object],
|
|
10
|
-
default: void 0
|
|
11
|
-
},
|
|
12
|
-
value: {
|
|
13
|
-
type: [String, Boolean, Number, Object],
|
|
14
|
-
default: void 0
|
|
15
|
-
},
|
|
16
|
-
indeterminate: Boolean,
|
|
17
|
-
disabled: {
|
|
18
|
-
type: Boolean,
|
|
19
|
-
default: void 0
|
|
20
|
-
},
|
|
21
|
-
checked: Boolean,
|
|
22
|
-
name: {
|
|
23
|
-
type: String,
|
|
24
|
-
default: void 0
|
|
25
|
-
},
|
|
26
|
-
trueValue: {
|
|
27
|
-
type: [String, Number],
|
|
28
|
-
default: void 0
|
|
29
|
-
},
|
|
30
|
-
falseValue: {
|
|
31
|
-
type: [String, Number],
|
|
32
|
-
default: void 0
|
|
33
|
-
},
|
|
34
|
-
trueLabel: {
|
|
35
|
-
type: [String, Number],
|
|
36
|
-
default: void 0
|
|
37
|
-
},
|
|
38
|
-
falseLabel: {
|
|
39
|
-
type: [String, Number],
|
|
40
|
-
default: void 0
|
|
41
|
-
},
|
|
42
|
-
id: {
|
|
43
|
-
type: String,
|
|
44
|
-
default: void 0
|
|
45
|
-
},
|
|
46
|
-
border: Boolean,
|
|
47
|
-
size: be,
|
|
48
|
-
tabindex: [String, Number],
|
|
49
|
-
validateEvent: {
|
|
50
|
-
type: Boolean,
|
|
51
|
-
default: !0
|
|
52
|
-
},
|
|
53
|
-
ariaLabel: String,
|
|
54
|
-
...de(["ariaControls"])
|
|
55
|
-
}, xe = {
|
|
56
|
-
[N]: (e) => X(e) || Y(e) || $(e),
|
|
57
|
-
change: (e) => X(e) || Y(e) || $(e)
|
|
58
|
-
}, E = Symbol("checkboxGroupContextKey"), ze = ({
|
|
59
|
-
model: e,
|
|
60
|
-
isChecked: t
|
|
61
|
-
}) => {
|
|
62
|
-
const r = L(E, void 0), a = L(_e, void 0), m = p(() => {
|
|
63
|
-
var d, o;
|
|
64
|
-
const h = (d = r == null ? void 0 : r.max) == null ? void 0 : d.value, v = (o = r == null ? void 0 : r.min) == null ? void 0 : o.value;
|
|
65
|
-
return !O(h) && e.value.length >= h && !t.value || !O(v) && e.value.length <= v && t.value;
|
|
66
|
-
});
|
|
67
|
-
return {
|
|
68
|
-
isDisabled: ve(
|
|
69
|
-
p(() => {
|
|
70
|
-
var d, o;
|
|
71
|
-
return r === void 0 ? (d = a == null ? void 0 : a.disabled) != null ? d : m.value : ((o = r.disabled) == null ? void 0 : o.value) || m.value;
|
|
72
|
-
})
|
|
73
|
-
),
|
|
74
|
-
isLimitDisabled: m
|
|
75
|
-
};
|
|
76
|
-
}, Fe = (e, {
|
|
77
|
-
model: t,
|
|
78
|
-
isLimitExceeded: r,
|
|
79
|
-
hasOwnLabel: a,
|
|
80
|
-
isDisabled: m,
|
|
81
|
-
isLabeledByFormItem: f
|
|
82
|
-
}) => {
|
|
83
|
-
const d = L(E, void 0), { formItem: o } = j(), { emit: h } = J();
|
|
84
|
-
function v(n) {
|
|
85
|
-
var l, u, b, i;
|
|
86
|
-
return [!0, e.trueValue, e.trueLabel].includes(n) ? (u = (l = e.trueValue) != null ? l : e.trueLabel) != null ? u : !0 : (i = (b = e.falseValue) != null ? b : e.falseLabel) != null ? i : !1;
|
|
87
|
-
}
|
|
88
|
-
function s(n, l) {
|
|
89
|
-
h(T, v(n), l);
|
|
90
|
-
}
|
|
91
|
-
function g(n) {
|
|
92
|
-
if (r.value)
|
|
93
|
-
return;
|
|
94
|
-
const l = n.target;
|
|
95
|
-
h(T, v(l.checked), n);
|
|
96
|
-
}
|
|
97
|
-
async function x(n) {
|
|
98
|
-
r.value || !a.value && !m.value && f.value && (n.composedPath().some(
|
|
99
|
-
(b) => b.tagName === "LABEL"
|
|
100
|
-
) || (t.value = v(
|
|
101
|
-
[!1, e.falseValue, e.falseLabel].includes(t.value)
|
|
102
|
-
), await le(), s(t.value, n)));
|
|
103
|
-
}
|
|
104
|
-
const y = p(
|
|
105
|
-
() => (d == null ? void 0 : d.validateEvent) || e.validateEvent
|
|
106
|
-
);
|
|
107
|
-
return ee(
|
|
108
|
-
() => e.modelValue,
|
|
109
|
-
() => {
|
|
110
|
-
y.value && (o == null || o.validate("change").catch((n) => me(n)));
|
|
111
|
-
}
|
|
112
|
-
), {
|
|
113
|
-
handleChange: g,
|
|
114
|
-
onClickRoot: x
|
|
115
|
-
};
|
|
116
|
-
}, Pe = (e) => {
|
|
117
|
-
const t = G(!1), { emit: r } = J(), a = L(E, void 0), m = p(() => O(a) === !1), f = G(!1), d = p({
|
|
118
|
-
get() {
|
|
119
|
-
var o, h;
|
|
120
|
-
return m.value ? (o = a == null ? void 0 : a.modelValue) == null ? void 0 : o.value : (h = e.modelValue) != null ? h : t.value;
|
|
121
|
-
},
|
|
122
|
-
set(o) {
|
|
123
|
-
var h, v;
|
|
124
|
-
m.value && _(o) ? (f.value = ((h = a == null ? void 0 : a.max) == null ? void 0 : h.value) !== void 0 && o.length > (a == null ? void 0 : a.max.value) && o.length > d.value.length, f.value === !1 && ((v = a == null ? void 0 : a.changeEvent) == null || v.call(a, o))) : (r(N, o), t.value = o);
|
|
125
|
-
}
|
|
126
|
-
});
|
|
127
|
-
return {
|
|
128
|
-
model: d,
|
|
129
|
-
isGroup: m,
|
|
130
|
-
isLimitExceeded: f
|
|
131
|
-
};
|
|
132
|
-
}, $e = (e, t, { model: r }) => {
|
|
133
|
-
const a = L(E, void 0), m = G(!1), f = p(() => A(e.value) ? e.label : e.value), d = p(() => {
|
|
134
|
-
const s = r.value;
|
|
135
|
-
return $(s) ? s : _(s) ? Ie(f.value) ? s.map(W).some((g) => fe(g, f.value)) : s.map(W).includes(f.value) : s != null ? s === e.trueValue || s === e.trueLabel : !!s;
|
|
136
|
-
}), o = Z(
|
|
137
|
-
p(() => {
|
|
138
|
-
var s;
|
|
139
|
-
return (s = a == null ? void 0 : a.size) == null ? void 0 : s.value;
|
|
140
|
-
}),
|
|
141
|
-
{
|
|
142
|
-
prop: !0
|
|
143
|
-
}
|
|
144
|
-
), h = Z(p(() => {
|
|
145
|
-
var s;
|
|
146
|
-
return (s = a == null ? void 0 : a.size) == null ? void 0 : s.value;
|
|
147
|
-
})), v = p(() => !!t.default || !A(f.value));
|
|
148
|
-
return {
|
|
149
|
-
checkboxButtonSize: o,
|
|
150
|
-
isChecked: d,
|
|
151
|
-
isFocused: m,
|
|
152
|
-
checkboxSize: h,
|
|
153
|
-
hasOwnLabel: v,
|
|
154
|
-
actualValue: f
|
|
155
|
-
};
|
|
156
|
-
}, ge = (e, t) => {
|
|
157
|
-
const { formItem: r } = j(), { model: a, isGroup: m, isLimitExceeded: f } = Pe(e), {
|
|
158
|
-
isFocused: d,
|
|
159
|
-
isChecked: o,
|
|
160
|
-
checkboxButtonSize: h,
|
|
161
|
-
checkboxSize: v,
|
|
162
|
-
hasOwnLabel: s,
|
|
163
|
-
actualValue: g
|
|
164
|
-
} = $e(e, t, { model: a }), { isDisabled: x } = ze({ model: a, isChecked: o }), { inputId: y, isLabeledByFormItem: n } = he(e, {
|
|
165
|
-
formItemContext: r,
|
|
166
|
-
disableIdGeneration: s,
|
|
167
|
-
disableIdManagement: m
|
|
168
|
-
}), { handleChange: l, onClickRoot: u } = Fe(e, {
|
|
169
|
-
model: a,
|
|
170
|
-
isLimitExceeded: f,
|
|
171
|
-
hasOwnLabel: s,
|
|
172
|
-
isDisabled: x,
|
|
173
|
-
isLabeledByFormItem: n
|
|
174
|
-
});
|
|
175
|
-
return (() => {
|
|
176
|
-
function i() {
|
|
177
|
-
var k, C;
|
|
178
|
-
_(a.value) && !a.value.includes(g.value) ? a.value.push(g.value) : a.value = (C = (k = e.trueValue) != null ? k : e.trueLabel) != null ? C : !0;
|
|
179
|
-
}
|
|
180
|
-
e.checked && i();
|
|
181
|
-
})(), w(
|
|
182
|
-
{
|
|
183
|
-
from: "label act as value",
|
|
184
|
-
replacement: "value",
|
|
185
|
-
version: "3.0.0",
|
|
186
|
-
scope: "el-checkbox",
|
|
187
|
-
ref: "https://element-plus.org/en-US/component/checkbox.html"
|
|
188
|
-
},
|
|
189
|
-
p(() => m.value && A(e.value))
|
|
190
|
-
), w(
|
|
191
|
-
{
|
|
192
|
-
from: "true-label",
|
|
193
|
-
replacement: "true-value",
|
|
194
|
-
version: "3.0.0",
|
|
195
|
-
scope: "el-checkbox",
|
|
196
|
-
ref: "https://element-plus.org/en-US/component/checkbox.html"
|
|
197
|
-
},
|
|
198
|
-
p(() => !!e.trueLabel)
|
|
199
|
-
), w(
|
|
200
|
-
{
|
|
201
|
-
from: "false-label",
|
|
202
|
-
replacement: "false-value",
|
|
203
|
-
version: "3.0.0",
|
|
204
|
-
scope: "el-checkbox",
|
|
205
|
-
ref: "https://element-plus.org/en-US/component/checkbox.html"
|
|
206
|
-
},
|
|
207
|
-
p(() => !!e.falseLabel)
|
|
208
|
-
), {
|
|
209
|
-
inputId: y,
|
|
210
|
-
isLabeledByFormItem: n,
|
|
211
|
-
isChecked: o,
|
|
212
|
-
isDisabled: x,
|
|
213
|
-
isFocused: d,
|
|
214
|
-
checkboxButtonSize: h,
|
|
215
|
-
checkboxSize: v,
|
|
216
|
-
hasOwnLabel: s,
|
|
217
|
-
model: a,
|
|
218
|
-
actualValue: g,
|
|
219
|
-
handleChange: l,
|
|
220
|
-
onClickRoot: u
|
|
221
|
-
};
|
|
222
|
-
}, Oe = ["id", "indeterminate", "name", "tabindex", "disabled"], Te = U({
|
|
223
|
-
name: "ElCheckbox",
|
|
224
|
-
__name: "checkbox",
|
|
225
|
-
props: ke,
|
|
226
|
-
emits: xe,
|
|
227
|
-
setup(e) {
|
|
228
|
-
const t = e, r = ae(), {
|
|
229
|
-
inputId: a,
|
|
230
|
-
isLabeledByFormItem: m,
|
|
231
|
-
isChecked: f,
|
|
232
|
-
isDisabled: d,
|
|
233
|
-
isFocused: o,
|
|
234
|
-
checkboxSize: h,
|
|
235
|
-
hasOwnLabel: v,
|
|
236
|
-
model: s,
|
|
237
|
-
actualValue: g,
|
|
238
|
-
handleChange: x,
|
|
239
|
-
onClickRoot: y
|
|
240
|
-
} = ge(t, r), n = p(() => {
|
|
241
|
-
var i, k, C, Q;
|
|
242
|
-
return t.trueValue || t.falseValue || t.trueLabel || t.falseLabel ? {
|
|
243
|
-
"true-value": (k = (i = t.trueValue) != null ? i : t.trueLabel) != null ? k : !0,
|
|
244
|
-
"false-value": (Q = (C = t.falseValue) != null ? C : t.falseLabel) != null ? Q : !1
|
|
245
|
-
} : {
|
|
246
|
-
value: g.value
|
|
247
|
-
};
|
|
248
|
-
}), l = q("checkbox"), u = p(() => [
|
|
249
|
-
l.b(),
|
|
250
|
-
l.m(h.value),
|
|
251
|
-
l.is("disabled", d.value),
|
|
252
|
-
l.is("bordered", t.border),
|
|
253
|
-
l.is("checked", f.value)
|
|
254
|
-
]), b = p(() => [
|
|
255
|
-
l.e("input"),
|
|
256
|
-
l.is("disabled", d.value),
|
|
257
|
-
l.is("checked", f.value),
|
|
258
|
-
l.is("indeterminate", t.indeterminate),
|
|
259
|
-
l.is("focus", o.value)
|
|
260
|
-
]);
|
|
261
|
-
return (i, k) => (S(), z(F(!c(v) && c(m) ? "span" : "label"), {
|
|
262
|
-
for: !c(v) && c(m) ? null : c(a),
|
|
263
|
-
class: V(u.value),
|
|
264
|
-
"aria-controls": i.indeterminate ? i.ariaControls : null,
|
|
265
|
-
"aria-checked": i.indeterminate ? "mixed" : void 0,
|
|
266
|
-
"aria-label": i.ariaLabel,
|
|
267
|
-
onClick: c(y)
|
|
268
|
-
}, {
|
|
269
|
-
default: te(() => [
|
|
270
|
-
I(
|
|
271
|
-
"span",
|
|
272
|
-
{
|
|
273
|
-
class: V(b.value)
|
|
274
|
-
},
|
|
275
|
-
[
|
|
276
|
-
ne(I("input", M({
|
|
277
|
-
id: c(a),
|
|
278
|
-
"onUpdate:modelValue": k[0] || (k[0] = (C) => oe(s) ? s.value = C : null),
|
|
279
|
-
class: c(l).e("original"),
|
|
280
|
-
type: "checkbox",
|
|
281
|
-
indeterminate: i.indeterminate,
|
|
282
|
-
name: i.name,
|
|
283
|
-
tabindex: i.tabindex,
|
|
284
|
-
disabled: c(d)
|
|
285
|
-
}, n.value, {
|
|
286
|
-
onChange: k[1] || (k[1] = (...C) => c(x) && c(x)(...C)),
|
|
287
|
-
onFocus: k[2] || (k[2] = (C) => o.value = !0),
|
|
288
|
-
onBlur: k[3] || (k[3] = (C) => o.value = !1),
|
|
289
|
-
onClick: k[4] || (k[4] = ue(() => {
|
|
290
|
-
}, ["stop"]))
|
|
291
|
-
}), null, 16, Oe), [
|
|
292
|
-
[se, c(s)]
|
|
293
|
-
]),
|
|
294
|
-
I(
|
|
295
|
-
"span",
|
|
296
|
-
{
|
|
297
|
-
class: V(c(l).e("inner"))
|
|
298
|
-
},
|
|
299
|
-
null,
|
|
300
|
-
2
|
|
301
|
-
)
|
|
302
|
-
],
|
|
303
|
-
2
|
|
304
|
-
),
|
|
305
|
-
c(v) ? (S(), B(
|
|
306
|
-
"span",
|
|
307
|
-
{
|
|
308
|
-
key: 0,
|
|
309
|
-
class: V(c(l).e("label"))
|
|
310
|
-
},
|
|
311
|
-
[
|
|
312
|
-
R(i.$slots, "default"),
|
|
313
|
-
i.$slots.default ? P("v-if", !0) : (S(), B(
|
|
314
|
-
ie,
|
|
315
|
-
{ key: 0 },
|
|
316
|
-
[
|
|
317
|
-
re(
|
|
318
|
-
ce(i.label),
|
|
319
|
-
1
|
|
320
|
-
)
|
|
321
|
-
],
|
|
322
|
-
64
|
|
323
|
-
))
|
|
324
|
-
],
|
|
325
|
-
2
|
|
326
|
-
)) : P("v-if", !0)
|
|
327
|
-
]),
|
|
328
|
-
_: 3
|
|
329
|
-
}, 8, ["for", "class", "aria-controls", "aria-checked", "aria-label", "onClick"]));
|
|
330
|
-
}
|
|
331
|
-
});
|
|
332
|
-
var Ce = /* @__PURE__ */ K(Te, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/checkbox/src/checkbox.vue"]]);
|
|
333
|
-
const Ae = ["name", "tabindex", "disabled"], Ue = U({
|
|
334
|
-
name: "ElCheckboxButton",
|
|
335
|
-
__name: "checkbox-button",
|
|
336
|
-
props: ke,
|
|
337
|
-
emits: xe,
|
|
338
|
-
setup(e) {
|
|
339
|
-
const t = e, r = ae(), {
|
|
340
|
-
isFocused: a,
|
|
341
|
-
isChecked: m,
|
|
342
|
-
isDisabled: f,
|
|
343
|
-
checkboxButtonSize: d,
|
|
344
|
-
model: o,
|
|
345
|
-
actualValue: h,
|
|
346
|
-
handleChange: v
|
|
347
|
-
} = ge(t, r), s = p(() => {
|
|
348
|
-
var l, u, b, i;
|
|
349
|
-
return t.trueValue || t.falseValue || t.trueLabel || t.falseLabel ? {
|
|
350
|
-
"true-value": (u = (l = t.trueValue) != null ? l : t.trueLabel) != null ? u : !0,
|
|
351
|
-
"false-value": (i = (b = t.falseValue) != null ? b : t.falseLabel) != null ? i : !1
|
|
352
|
-
} : {
|
|
353
|
-
value: h.value
|
|
354
|
-
};
|
|
355
|
-
}), g = L(E, void 0), x = q("checkbox"), y = p(() => {
|
|
356
|
-
var l, u, b, i;
|
|
357
|
-
const k = (u = (l = g == null ? void 0 : g.fill) == null ? void 0 : l.value) != null ? u : "";
|
|
358
|
-
return {
|
|
359
|
-
backgroundColor: k,
|
|
360
|
-
borderColor: k,
|
|
361
|
-
color: (i = (b = g == null ? void 0 : g.textColor) == null ? void 0 : b.value) != null ? i : "",
|
|
362
|
-
boxShadow: k ? `-1px 0 0 0 ${k}` : void 0
|
|
363
|
-
};
|
|
364
|
-
}), n = p(() => [
|
|
365
|
-
x.b("button"),
|
|
366
|
-
x.bm("button", d.value),
|
|
367
|
-
x.is("disabled", f.value),
|
|
368
|
-
x.is("checked", m.value),
|
|
369
|
-
x.is("focus", a.value)
|
|
370
|
-
]);
|
|
371
|
-
return (l, u) => (S(), B(
|
|
372
|
-
"label",
|
|
373
|
-
{
|
|
374
|
-
class: V(n.value)
|
|
375
|
-
},
|
|
376
|
-
[
|
|
377
|
-
ne(I("input", M({
|
|
378
|
-
"onUpdate:modelValue": u[0] || (u[0] = (b) => oe(o) ? o.value = b : null),
|
|
379
|
-
class: c(x).be("button", "original"),
|
|
380
|
-
type: "checkbox",
|
|
381
|
-
name: l.name,
|
|
382
|
-
tabindex: l.tabindex,
|
|
383
|
-
disabled: c(f)
|
|
384
|
-
}, s.value, {
|
|
385
|
-
onChange: u[1] || (u[1] = (...b) => c(v) && c(v)(...b)),
|
|
386
|
-
onFocus: u[2] || (u[2] = (b) => a.value = !0),
|
|
387
|
-
onBlur: u[3] || (u[3] = (b) => a.value = !1),
|
|
388
|
-
onClick: u[4] || (u[4] = ue(() => {
|
|
389
|
-
}, ["stop"]))
|
|
390
|
-
}), null, 16, Ae), [
|
|
391
|
-
[se, c(o)]
|
|
392
|
-
]),
|
|
393
|
-
l.$slots.default || l.label ? (S(), B(
|
|
394
|
-
"span",
|
|
395
|
-
{
|
|
396
|
-
key: 0,
|
|
397
|
-
class: V(c(x).be("button", "inner")),
|
|
398
|
-
style: Ve(c(m) ? y.value : void 0)
|
|
399
|
-
},
|
|
400
|
-
[
|
|
401
|
-
R(l.$slots, "default", {}, () => [
|
|
402
|
-
re(
|
|
403
|
-
ce(l.label),
|
|
404
|
-
1
|
|
405
|
-
)
|
|
406
|
-
])
|
|
407
|
-
],
|
|
408
|
-
6
|
|
409
|
-
)) : P("v-if", !0)
|
|
410
|
-
],
|
|
411
|
-
2
|
|
412
|
-
));
|
|
413
|
-
}
|
|
414
|
-
});
|
|
415
|
-
var H = /* @__PURE__ */ K(Ue, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/checkbox/src/checkbox-button.vue"]]);
|
|
416
|
-
const Me = Ne({
|
|
417
|
-
modelValue: {
|
|
418
|
-
type: D(Array),
|
|
419
|
-
default: () => []
|
|
420
|
-
},
|
|
421
|
-
disabled: {
|
|
422
|
-
type: Boolean,
|
|
423
|
-
default: void 0
|
|
424
|
-
},
|
|
425
|
-
min: Number,
|
|
426
|
-
max: Number,
|
|
427
|
-
size: be,
|
|
428
|
-
fill: String,
|
|
429
|
-
textColor: String,
|
|
430
|
-
tag: {
|
|
431
|
-
type: String,
|
|
432
|
-
default: "div"
|
|
433
|
-
},
|
|
434
|
-
validateEvent: {
|
|
435
|
-
type: Boolean,
|
|
436
|
-
default: !0
|
|
437
|
-
},
|
|
438
|
-
options: {
|
|
439
|
-
type: D(Array)
|
|
440
|
-
},
|
|
441
|
-
props: {
|
|
442
|
-
type: D(Object),
|
|
443
|
-
default: () => ye
|
|
444
|
-
},
|
|
445
|
-
type: {
|
|
446
|
-
type: String,
|
|
447
|
-
values: ["checkbox", "button"],
|
|
448
|
-
default: "checkbox"
|
|
449
|
-
},
|
|
450
|
-
...de(["ariaLabel"])
|
|
451
|
-
}), Re = {
|
|
452
|
-
[N]: (e) => _(e),
|
|
453
|
-
change: (e) => _(e)
|
|
454
|
-
}, ye = {
|
|
455
|
-
label: "label",
|
|
456
|
-
value: "value",
|
|
457
|
-
disabled: "disabled"
|
|
458
|
-
}, je = U({
|
|
459
|
-
name: "ElCheckboxGroup",
|
|
460
|
-
__name: "checkbox-group",
|
|
461
|
-
props: Me,
|
|
462
|
-
emits: Re,
|
|
463
|
-
setup(e, { emit: t }) {
|
|
464
|
-
const r = e, a = t, m = q("checkbox"), f = ve(), { formItem: d } = j(), { inputId: o, isLabeledByFormItem: h } = he(r, {
|
|
465
|
-
formItemContext: d
|
|
466
|
-
}), v = async (n) => {
|
|
467
|
-
a(N, n), await le(), a(T, n);
|
|
468
|
-
}, s = p({
|
|
469
|
-
get() {
|
|
470
|
-
return r.modelValue;
|
|
471
|
-
},
|
|
472
|
-
set(n) {
|
|
473
|
-
v(n);
|
|
474
|
-
}
|
|
475
|
-
}), g = p(() => ({
|
|
476
|
-
...ye,
|
|
477
|
-
...r.props
|
|
478
|
-
})), x = (n) => {
|
|
479
|
-
const { label: l, value: u, disabled: b } = g.value, i = {
|
|
480
|
-
label: n[l],
|
|
481
|
-
value: n[u],
|
|
482
|
-
disabled: n[b]
|
|
483
|
-
};
|
|
484
|
-
return { ...De(n, [l, u, b]), ...i };
|
|
485
|
-
}, y = p(
|
|
486
|
-
() => r.type === "button" ? H : Ce
|
|
487
|
-
);
|
|
488
|
-
return Le(E, {
|
|
489
|
-
...we(Ee(r), [
|
|
490
|
-
"size",
|
|
491
|
-
"min",
|
|
492
|
-
"max",
|
|
493
|
-
"validateEvent",
|
|
494
|
-
"fill",
|
|
495
|
-
"textColor"
|
|
496
|
-
]),
|
|
497
|
-
disabled: f,
|
|
498
|
-
modelValue: s,
|
|
499
|
-
changeEvent: v
|
|
500
|
-
}), ee(
|
|
501
|
-
() => r.modelValue,
|
|
502
|
-
(n, l) => {
|
|
503
|
-
r.validateEvent && !fe(n, l) && (d == null || d.validate("change").catch((u) => me(u)));
|
|
504
|
-
}
|
|
505
|
-
), (n, l) => {
|
|
506
|
-
var u;
|
|
507
|
-
return S(), z(F(n.tag), {
|
|
508
|
-
id: c(o),
|
|
509
|
-
class: V(c(m).b("group")),
|
|
510
|
-
role: "group",
|
|
511
|
-
"aria-label": c(h) ? void 0 : n.ariaLabel || "checkbox-group",
|
|
512
|
-
"aria-labelledby": c(h) ? (u = c(d)) == null ? void 0 : u.labelId : void 0
|
|
513
|
-
}, {
|
|
514
|
-
default: te(() => [
|
|
515
|
-
R(n.$slots, "default", {}, () => [
|
|
516
|
-
(S(!0), B(
|
|
517
|
-
ie,
|
|
518
|
-
null,
|
|
519
|
-
Be(n.options, (b, i) => (S(), z(
|
|
520
|
-
F(y.value),
|
|
521
|
-
M({ key: i }, { ref_for: !0 }, x(b)),
|
|
522
|
-
null,
|
|
523
|
-
16
|
|
524
|
-
))),
|
|
525
|
-
128
|
|
526
|
-
))
|
|
527
|
-
])
|
|
528
|
-
]),
|
|
529
|
-
_: 3
|
|
530
|
-
}, 8, ["id", "class", "aria-label", "aria-labelledby"]);
|
|
531
|
-
};
|
|
532
|
-
}
|
|
533
|
-
});
|
|
534
|
-
var Se = /* @__PURE__ */ K(je, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/checkbox/src/checkbox-group.vue"]]);
|
|
535
|
-
const He = Ge(Ce, {
|
|
536
|
-
CheckboxButton: H,
|
|
537
|
-
CheckboxGroup: Se
|
|
538
|
-
});
|
|
539
|
-
pe(H);
|
|
540
|
-
const Qe = pe(Se);
|
|
541
|
-
export {
|
|
542
|
-
He as E,
|
|
543
|
-
Qe as a
|
|
544
|
-
};
|