@farris/ui-vue 1.0.1 → 1.0.2
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/accordion/package.json +1 -1
- package/avatar/package.json +1 -1
- package/button/package.json +1 -1
- package/button-edit/package.json +1 -1
- package/calculator/package.json +1 -1
- package/calendar/package.json +1 -1
- package/capsule/package.json +1 -1
- package/checkbox/package.json +1 -1
- package/color-picker/package.json +1 -1
- package/combo-list/index.esm.js +808 -802
- package/combo-list/index.umd.js +1 -1
- package/combo-list/package.json +1 -1
- package/combo-list/style.css +1 -1
- package/component/package.json +1 -1
- package/condition/index.esm.js +2656 -2650
- package/condition/index.umd.js +1 -1
- package/condition/package.json +1 -1
- package/condition/style.css +1 -1
- package/content-container/package.json +1 -1
- package/data-grid/index.esm.js +2298 -2292
- package/data-grid/index.umd.js +1 -1
- package/data-grid/package.json +1 -1
- package/data-grid/style.css +1 -1
- package/date-picker/package.json +1 -1
- package/designer-canvas/index.esm.js +2632 -2626
- package/designer-canvas/index.umd.js +1 -1
- package/designer-canvas/package.json +1 -1
- package/designer-canvas/style.css +1 -1
- package/discussion-editor/package.json +1 -1
- package/discussion-list/package.json +1 -1
- package/dropdown/package.json +1 -1
- package/dynamic-form/index.esm.js +2656 -2650
- package/dynamic-form/index.umd.js +1 -1
- package/dynamic-form/package.json +1 -1
- package/dynamic-form/style.css +1 -1
- package/dynamic-resolver/package.json +1 -1
- package/dynamic-view/index.esm.js +1735 -1729
- package/dynamic-view/index.umd.js +1 -1
- package/dynamic-view/package.json +1 -1
- package/dynamic-view/style.css +1 -1
- package/farris.all.esm.js +3064 -3058
- package/farris.all.umd.js +5 -5
- package/filter-bar/package.json +1 -1
- package/image-cropper/package.json +1 -1
- package/input-group/package.json +1 -1
- package/list-nav/package.json +1 -1
- package/list-view/package.json +1 -1
- package/loading/package.json +1 -1
- package/locale/package.json +1 -1
- package/message-box/package.json +1 -1
- package/modal/package.json +1 -1
- package/nav/package.json +1 -1
- package/notify/package.json +1 -1
- package/order/index.esm.js +759 -753
- package/order/index.umd.js +1 -1
- package/order/package.json +1 -1
- package/order/style.css +1 -1
- package/package.json +1 -1
- package/page-footer/package.json +1 -1
- package/page-header/package.json +1 -1
- package/pagination/package.json +1 -1
- package/popover/package.json +1 -1
- package/propress/package.json +1 -1
- package/radio-group/package.json +1 -1
- package/rate/package.json +1 -1
- package/response-toolbar/package.json +1 -1
- package/search-box/package.json +1 -1
- package/section/package.json +1 -1
- package/splitter/package.json +1 -1
- package/step/package.json +1 -1
- package/style.css +1 -1
- package/switch/package.json +1 -1
- package/tabs/package.json +1 -1
- package/tags/package.json +1 -1
- package/text/package.json +1 -1
- package/time-picker/package.json +1 -1
- package/tooltip/package.json +1 -1
- package/transfer/package.json +1 -1
- package/tree-view/package.json +1 -1
- package/types/combo-list/src/components/list-container.props.d.ts +3 -1
- package/types/combo-list/src/composition/types.d.ts +1 -0
- package/uploader/package.json +1 -1
- package/verify-detail/package.json +1 -1
package/order/index.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref as
|
|
1
|
+
import { ref as o, computed as I, watch as W, defineComponent as z, createVNode as d, withDirectives as Q, vModelCheckbox as Fe, Fragment as te, withModifiers as Oe, vModelText as Pe, Teleport as se, createApp as Ve, onUnmounted as ce, nextTick as K, vShow as re, onMounted as de, mergeProps as Me } from "vue";
|
|
2
2
|
const Le = {
|
|
3
3
|
dataSource: { type: Array, default: [] },
|
|
4
4
|
items: { type: Array, default: [] }
|
|
@@ -20,100 +20,100 @@ const Le = {
|
|
|
20
20
|
keepOrder: { type: Boolean, default: !1 },
|
|
21
21
|
disableField: { type: String, default: "disabled" }
|
|
22
22
|
};
|
|
23
|
-
function je(e, t,
|
|
24
|
-
const i =
|
|
25
|
-
|
|
26
|
-
const { isDragging:
|
|
27
|
-
function
|
|
23
|
+
function je(e, t, a, l, n) {
|
|
24
|
+
const i = o(e.idField), u = o(e.disableField), r = o(e.draggable), h = o(e.itemClass), f = o(e.multiSelect), v = o(e.multiSelectMode);
|
|
25
|
+
o(!0);
|
|
26
|
+
const { isDragging: s } = a, { activeIndex: c, focusedItemId: p, hoverIndex: g } = l, { clearSelection: y, selectedItems: w, toggleSelectItem: B } = n;
|
|
27
|
+
function S(C, j) {
|
|
28
28
|
const M = {
|
|
29
29
|
"f-list-view-group-item": !0,
|
|
30
|
-
"f-list-view-draggable-item":
|
|
30
|
+
"f-list-view-draggable-item": r.value,
|
|
31
31
|
"f-un-click": !!C.unClick,
|
|
32
32
|
"f-un-select": !!C[u.value],
|
|
33
|
-
"f-listview-active": C.__fv_index__ ===
|
|
34
|
-
"f-listview-hover": !
|
|
33
|
+
"f-listview-active": C.__fv_index__ === c.value,
|
|
34
|
+
"f-listview-hover": !s.value && j === g.value,
|
|
35
35
|
moving: !!C.moving
|
|
36
36
|
};
|
|
37
|
-
return
|
|
37
|
+
return h.value.split(" ").reduce((X, R) => (X[R] = !0, X), M), M;
|
|
38
38
|
}
|
|
39
|
-
function
|
|
39
|
+
function b(C, j) {
|
|
40
40
|
return C[i.value] || "";
|
|
41
41
|
}
|
|
42
|
-
const
|
|
42
|
+
const x = I(() => !f.value);
|
|
43
43
|
function O(C, j) {
|
|
44
|
-
C.unClick || C[u.value] || (
|
|
44
|
+
C.unClick || C[u.value] || (x.value && (p.value = C[i.value]), B(C, j));
|
|
45
45
|
}
|
|
46
|
-
const F = I(() =>
|
|
46
|
+
const F = I(() => f.value && v.value === "OnCheckClearByClick"), E = I(() => !f.value || f.value && (v.value === "OnCheckAndClick" || v.value === "OnClick"));
|
|
47
47
|
function L(C, j, M) {
|
|
48
48
|
if (j.unClick || j[u.value]) {
|
|
49
49
|
C.preventDefault(), C.stopPropagation();
|
|
50
50
|
return;
|
|
51
51
|
}
|
|
52
|
-
|
|
52
|
+
p.value = j[i.value], c.value = M, F.value && y(), E.value && B(j, M), t.emit("clickItem", { data: w.value, index: M });
|
|
53
53
|
}
|
|
54
54
|
return {
|
|
55
|
-
getKey:
|
|
56
|
-
listViewItemClass:
|
|
55
|
+
getKey: b,
|
|
56
|
+
listViewItemClass: S,
|
|
57
57
|
onCheckItem: O,
|
|
58
58
|
onClickItem: L
|
|
59
59
|
};
|
|
60
60
|
}
|
|
61
|
-
function De(e, t,
|
|
62
|
-
const l =
|
|
63
|
-
|
|
64
|
-
const { getSelectionItems: i } =
|
|
65
|
-
W(() => e.selectionValues, (
|
|
66
|
-
u.value =
|
|
61
|
+
function De(e, t, a) {
|
|
62
|
+
const l = o(e.idField), n = o(e.multiSelect);
|
|
63
|
+
o(e.multiSelectMode);
|
|
64
|
+
const { getSelectionItems: i } = a, u = o(i(e.selectionValues));
|
|
65
|
+
W(() => e.selectionValues, (c) => {
|
|
66
|
+
u.value = o(i(c)).value;
|
|
67
67
|
});
|
|
68
|
-
const
|
|
69
|
-
function
|
|
70
|
-
return
|
|
68
|
+
const r = I(() => !n.value);
|
|
69
|
+
function h(c) {
|
|
70
|
+
return c[l.value] || "";
|
|
71
71
|
}
|
|
72
|
-
function c
|
|
73
|
-
return u.value.findIndex((
|
|
72
|
+
function f(c) {
|
|
73
|
+
return u.value.findIndex((g) => h(g) === h(c));
|
|
74
74
|
}
|
|
75
|
-
function
|
|
76
|
-
u.value.forEach((
|
|
77
|
-
|
|
75
|
+
function v() {
|
|
76
|
+
u.value.forEach((c) => {
|
|
77
|
+
c.checked = !1;
|
|
78
78
|
}), u.value = [];
|
|
79
79
|
}
|
|
80
|
-
function
|
|
81
|
-
|
|
82
|
-
const
|
|
83
|
-
|
|
80
|
+
function s(c, p) {
|
|
81
|
+
r.value && v();
|
|
82
|
+
const g = f(c);
|
|
83
|
+
g > -1 ? (u.value.splice(g, 1), c.checked = !1) : (u.value.push(c), c.checked = !0), t.emit("selectionChange", u.value);
|
|
84
84
|
}
|
|
85
|
-
return { clearSelection:
|
|
85
|
+
return { clearSelection: v, findIndexInSelectedItems: f, selectedItems: u, toggleSelectItem: s };
|
|
86
86
|
}
|
|
87
87
|
function Ae(e, t) {
|
|
88
|
-
function
|
|
88
|
+
function a(i) {
|
|
89
89
|
const u = [];
|
|
90
|
-
let
|
|
91
|
-
for (;
|
|
92
|
-
u.push(
|
|
90
|
+
let r = i.nextNode();
|
|
91
|
+
for (; r; )
|
|
92
|
+
u.push(r), r = i.nextNode();
|
|
93
93
|
return u;
|
|
94
94
|
}
|
|
95
95
|
function l(i, u) {
|
|
96
|
-
const
|
|
97
|
-
return
|
|
98
|
-
const
|
|
99
|
-
let
|
|
100
|
-
for (;
|
|
101
|
-
const y =
|
|
96
|
+
const r = document.createTreeWalker(i, NodeFilter.SHOW_TEXT);
|
|
97
|
+
return a(r).map((s) => ({ textNode: s, text: (s.textContent || "").toLocaleLowerCase() })).map(({ textNode: s, text: c }) => {
|
|
98
|
+
const p = [];
|
|
99
|
+
let g = 0;
|
|
100
|
+
for (; g < c.length; ) {
|
|
101
|
+
const y = c.indexOf(u, g);
|
|
102
102
|
if (y === -1)
|
|
103
103
|
break;
|
|
104
|
-
|
|
104
|
+
p.push(y), g = y + u.length;
|
|
105
105
|
}
|
|
106
|
-
return
|
|
107
|
-
const
|
|
108
|
-
return
|
|
106
|
+
return p.map((y) => {
|
|
107
|
+
const w = new Range();
|
|
108
|
+
return w.setStart(s, y), w.setEnd(s, y + u.length), w;
|
|
109
109
|
});
|
|
110
110
|
}).flat();
|
|
111
111
|
}
|
|
112
112
|
function n(i) {
|
|
113
113
|
if (!CSS.highlights || (CSS.highlights.clear(), !i || !t))
|
|
114
114
|
return;
|
|
115
|
-
const u = l(t.value, i.toLocaleLowerCase()),
|
|
116
|
-
CSS.highlights.set("search-result",
|
|
115
|
+
const u = l(t.value, i.toLocaleLowerCase()), r = new Highlight(...u);
|
|
116
|
+
CSS.highlights.set("search-result", r);
|
|
117
117
|
}
|
|
118
118
|
return { search: n };
|
|
119
119
|
}
|
|
@@ -130,138 +130,138 @@ const Ee = {
|
|
|
130
130
|
props: Ee,
|
|
131
131
|
emits: ["change", "update:modelValue"],
|
|
132
132
|
setup(e, t) {
|
|
133
|
-
const
|
|
133
|
+
const a = o(e.checked), l = o(e.disabled), n = o(e.id);
|
|
134
134
|
function i(u) {
|
|
135
|
-
u.stopPropagation(), u.preventDefault(), l.value || (
|
|
135
|
+
u.stopPropagation(), u.preventDefault(), l.value || (a.value = !a.value, t.emit("change", {
|
|
136
136
|
originalEvent: u,
|
|
137
|
-
checked:
|
|
137
|
+
checked: a.value
|
|
138
138
|
}));
|
|
139
139
|
}
|
|
140
140
|
return W(() => e.checked, (u) => {
|
|
141
|
-
|
|
142
|
-
}), () =>
|
|
141
|
+
a.value = u;
|
|
142
|
+
}), () => d("div", {
|
|
143
143
|
class: "custom-control custom-checkbox custom-control-inline listview-checkbox"
|
|
144
|
-
}, [Q(
|
|
144
|
+
}, [Q(d("input", {
|
|
145
145
|
id: n.value,
|
|
146
146
|
title: n.value,
|
|
147
147
|
type: "checkbox",
|
|
148
148
|
class: "custom-control-input",
|
|
149
|
-
"onUpdate:modelValue": (u) =>
|
|
149
|
+
"onUpdate:modelValue": (u) => a.value = u,
|
|
150
150
|
onChange: (u) => console.log(u)
|
|
151
|
-
}, null), [[Fe,
|
|
151
|
+
}, null), [[Fe, a.value]]), d("label", {
|
|
152
152
|
for: n.value,
|
|
153
153
|
class: "custom-control-label",
|
|
154
154
|
onClick: (u) => i(u)
|
|
155
155
|
}, null)]);
|
|
156
156
|
}
|
|
157
157
|
});
|
|
158
|
-
function ae(e, t,
|
|
159
|
-
const
|
|
160
|
-
onMouseenterItem:
|
|
161
|
-
onMouseoverItem:
|
|
162
|
-
onMouseoutItem:
|
|
158
|
+
function ae(e, t, a, l, n, i, u, r) {
|
|
159
|
+
const h = o(e.size), f = o(e.textField), v = o(e.multiSelect), s = o(e.disableField), {
|
|
160
|
+
onMouseenterItem: c,
|
|
161
|
+
onMouseoverItem: p,
|
|
162
|
+
onMouseoutItem: g
|
|
163
163
|
} = n, {
|
|
164
164
|
getKey: y,
|
|
165
|
-
listViewItemClass:
|
|
165
|
+
listViewItemClass: w,
|
|
166
166
|
onCheckItem: B,
|
|
167
|
-
onClickItem:
|
|
168
|
-
} = i,
|
|
169
|
-
margin:
|
|
167
|
+
onClickItem: S
|
|
168
|
+
} = i, b = I(() => ({
|
|
169
|
+
margin: h.value === "small" ? "0.25rem 0" : "10px 0"
|
|
170
170
|
}));
|
|
171
|
-
function
|
|
172
|
-
return O.checked = u.findIndexInSelectedItems(O) > -1,
|
|
173
|
-
class:
|
|
171
|
+
function x(O, F, E) {
|
|
172
|
+
return O.checked = u.findIndexInSelectedItems(O) > -1, d("li", {
|
|
173
|
+
class: w(O, F),
|
|
174
174
|
id: y(O, F),
|
|
175
175
|
key: y(O, F),
|
|
176
|
-
onClick: (L) =>
|
|
177
|
-
onMouseenter: (L) =>
|
|
178
|
-
onMouseover: (L) =>
|
|
179
|
-
onMouseout: (L) =>
|
|
180
|
-
}, [
|
|
176
|
+
onClick: (L) => S(L, O, F),
|
|
177
|
+
onMouseenter: (L) => c(L, O, F),
|
|
178
|
+
onMouseover: (L) => p(L, O, F),
|
|
179
|
+
onMouseout: (L) => g(L, O, F)
|
|
180
|
+
}, [v.value && d("div", {
|
|
181
181
|
class: "f-list-select",
|
|
182
182
|
onClick: (L) => L.stopPropagation()
|
|
183
|
-
}, [
|
|
183
|
+
}, [d(ne, {
|
|
184
184
|
id: "list-" + y(O, F),
|
|
185
|
-
disabled: O[
|
|
185
|
+
disabled: O[s.value] || O.unClick,
|
|
186
186
|
checked: O.checked,
|
|
187
187
|
onChange: (L) => B(O, F)
|
|
188
|
-
}, null)]),
|
|
188
|
+
}, null)]), d("div", {
|
|
189
189
|
class: "f-list-content"
|
|
190
|
-
}, [
|
|
191
|
-
style:
|
|
192
|
-
}, [O[
|
|
190
|
+
}, [d("div", {
|
|
191
|
+
style: b.value
|
|
192
|
+
}, [O[f.value]])])]);
|
|
193
193
|
}
|
|
194
194
|
return {
|
|
195
|
-
renderItem:
|
|
195
|
+
renderItem: x
|
|
196
196
|
};
|
|
197
197
|
}
|
|
198
|
-
function He(e, t,
|
|
199
|
-
const
|
|
200
|
-
onMouseenterItem:
|
|
201
|
-
onMouseoverItem:
|
|
202
|
-
onMouseoutItem:
|
|
198
|
+
function He(e, t, a, l, n, i, u, r) {
|
|
199
|
+
const h = o(e.multiSelect), f = o(e.disableField), {
|
|
200
|
+
onMouseenterItem: v,
|
|
201
|
+
onMouseoverItem: s,
|
|
202
|
+
onMouseoutItem: c
|
|
203
203
|
} = n, {
|
|
204
|
-
getKey:
|
|
205
|
-
listViewItemClass:
|
|
204
|
+
getKey: p,
|
|
205
|
+
listViewItemClass: g,
|
|
206
206
|
onCheckItem: y,
|
|
207
|
-
onClickItem:
|
|
207
|
+
onClickItem: w
|
|
208
208
|
} = i;
|
|
209
|
-
function B(
|
|
210
|
-
return t.slots.content ?
|
|
211
|
-
item:
|
|
212
|
-
index:
|
|
209
|
+
function B(b, x, O) {
|
|
210
|
+
return t.slots.content ? d(te, null, [t.slots.content && t.slots.content({
|
|
211
|
+
item: b,
|
|
212
|
+
index: x,
|
|
213
213
|
selectedItem: O
|
|
214
|
-
})]) :
|
|
214
|
+
})]) : d("div", {
|
|
215
215
|
style: "margin: 10px 0;"
|
|
216
|
-
}, [
|
|
217
|
-
}
|
|
218
|
-
function
|
|
219
|
-
return
|
|
220
|
-
class:
|
|
221
|
-
id: b
|
|
222
|
-
key: b
|
|
223
|
-
onClick: (F) =>
|
|
224
|
-
onMouseenter: (F) =>
|
|
225
|
-
onMouseover: (F) =>
|
|
226
|
-
onMouseout: (F) =>
|
|
227
|
-
}, [
|
|
216
|
+
}, [b.name]);
|
|
217
|
+
}
|
|
218
|
+
function S(b, x, O) {
|
|
219
|
+
return d("li", {
|
|
220
|
+
class: g(b, x),
|
|
221
|
+
id: p(b, x),
|
|
222
|
+
key: p(b, x),
|
|
223
|
+
onClick: (F) => w(F, b, x),
|
|
224
|
+
onMouseenter: (F) => v(F, b, x),
|
|
225
|
+
onMouseover: (F) => s(F, b, x),
|
|
226
|
+
onMouseout: (F) => c(F, b, x)
|
|
227
|
+
}, [h.value && d("div", {
|
|
228
228
|
class: "f-list-select",
|
|
229
229
|
onClick: (F) => F.stopPropagation()
|
|
230
|
-
}, [
|
|
231
|
-
id: "list-" + b
|
|
232
|
-
disabled:
|
|
233
|
-
checked:
|
|
234
|
-
onChange: (F) => y(
|
|
235
|
-
}, null)]),
|
|
230
|
+
}, [d(ne, {
|
|
231
|
+
id: "list-" + p(b, x),
|
|
232
|
+
disabled: b[f.value] || b.unClick,
|
|
233
|
+
checked: b.checked,
|
|
234
|
+
onChange: (F) => y(b, x)
|
|
235
|
+
}, null)]), d("div", {
|
|
236
236
|
class: "f-list-content"
|
|
237
|
-
}, [B(
|
|
237
|
+
}, [B(b, x, O)])]);
|
|
238
238
|
}
|
|
239
239
|
return {
|
|
240
|
-
renderItem:
|
|
240
|
+
renderItem: S
|
|
241
241
|
};
|
|
242
242
|
}
|
|
243
|
-
function We(e, t,
|
|
244
|
-
const
|
|
245
|
-
onMouseenterItem:
|
|
246
|
-
onMouseoverItem:
|
|
247
|
-
onMouseoutItem:
|
|
243
|
+
function We(e, t, a, l, n, i, u, r) {
|
|
244
|
+
const h = o(e.multiSelect), f = o(e.disableField), {
|
|
245
|
+
onMouseenterItem: v,
|
|
246
|
+
onMouseoverItem: s,
|
|
247
|
+
onMouseoutItem: c
|
|
248
248
|
} = n, {
|
|
249
|
-
getKey:
|
|
250
|
-
listViewItemClass:
|
|
249
|
+
getKey: p,
|
|
250
|
+
listViewItemClass: g,
|
|
251
251
|
onCheckItem: y,
|
|
252
|
-
onClickItem:
|
|
252
|
+
onClickItem: w
|
|
253
253
|
} = i, {
|
|
254
254
|
dragstart: B,
|
|
255
|
-
dragenter:
|
|
256
|
-
dragover:
|
|
257
|
-
dragend:
|
|
255
|
+
dragenter: S,
|
|
256
|
+
dragover: b,
|
|
257
|
+
dragend: x
|
|
258
258
|
} = l, {
|
|
259
259
|
removeItem: O
|
|
260
|
-
} =
|
|
261
|
-
margin:
|
|
260
|
+
} = r, F = I(() => ({
|
|
261
|
+
margin: h.value ? "10px 0" : "10px 0px 10px 14px"
|
|
262
262
|
}));
|
|
263
263
|
function E(M) {
|
|
264
|
-
return
|
|
264
|
+
return d("div", {
|
|
265
265
|
style: F.value
|
|
266
266
|
}, [M.name]);
|
|
267
267
|
}
|
|
@@ -270,39 +270,39 @@ function We(e, t, o, l, n, i, u, s) {
|
|
|
270
270
|
}
|
|
271
271
|
const C = L();
|
|
272
272
|
function j(M, D, X) {
|
|
273
|
-
return
|
|
274
|
-
class:
|
|
275
|
-
id:
|
|
276
|
-
key:
|
|
277
|
-
onClick: (R) =>
|
|
278
|
-
onMouseenter: (R) =>
|
|
279
|
-
onMouseover: (R) =>
|
|
280
|
-
onMouseout: (R) =>
|
|
273
|
+
return d("li", {
|
|
274
|
+
class: g(M, D),
|
|
275
|
+
id: p(M, D),
|
|
276
|
+
key: p(M, D),
|
|
277
|
+
onClick: (R) => w(R, M, D),
|
|
278
|
+
onMouseenter: (R) => v(R, M, D),
|
|
279
|
+
onMouseover: (R) => s(R, M, D),
|
|
280
|
+
onMouseout: (R) => c(R, M, D),
|
|
281
281
|
draggable: "true",
|
|
282
282
|
onDragstart: (R) => B(R, M, D),
|
|
283
|
-
onDragenter: (R) =>
|
|
284
|
-
onDragend: (R) =>
|
|
285
|
-
onDragover: (R) =>
|
|
286
|
-
}, [
|
|
283
|
+
onDragenter: (R) => S(R, D),
|
|
284
|
+
onDragend: (R) => x(R, M),
|
|
285
|
+
onDragover: (R) => b(R, D)
|
|
286
|
+
}, [h.value && d("div", {
|
|
287
287
|
class: "f-list-select",
|
|
288
288
|
onClick: (R) => R.stopPropagation()
|
|
289
|
-
}, [
|
|
290
|
-
id: "list-" +
|
|
291
|
-
disabled: M[
|
|
289
|
+
}, [d(ne, {
|
|
290
|
+
id: "list-" + p(M, D),
|
|
291
|
+
disabled: M[f.value] || M.unClick,
|
|
292
292
|
checked: M.checked,
|
|
293
293
|
onChange: (R) => y(M, D)
|
|
294
|
-
}, null)]),
|
|
294
|
+
}, null)]), d("div", {
|
|
295
295
|
class: "f-list-content"
|
|
296
|
-
}, [C(M)]),
|
|
296
|
+
}, [C(M)]), d("div", {
|
|
297
297
|
class: "f-list-remove",
|
|
298
298
|
onClick: (R) => O(D)
|
|
299
|
-
}, [
|
|
299
|
+
}, [d("div", {
|
|
300
300
|
class: "f-list-remove-icon"
|
|
301
|
-
}, [
|
|
301
|
+
}, [d("i", {
|
|
302
302
|
class: "f-icon f-icon-remove_face"
|
|
303
|
-
}, null)])]),
|
|
303
|
+
}, null)])]), d("div", {
|
|
304
304
|
class: "f-list-handle"
|
|
305
|
-
}, [
|
|
305
|
+
}, [d("div", null, [d("i", {
|
|
306
306
|
class: "f-icon f-icon-drag-vertical"
|
|
307
307
|
}, null)])])]);
|
|
308
308
|
}
|
|
@@ -310,9 +310,9 @@ function We(e, t, o, l, n, i, u, s) {
|
|
|
310
310
|
renderItem: j
|
|
311
311
|
};
|
|
312
312
|
}
|
|
313
|
-
function _e(e, t,
|
|
313
|
+
function _e(e, t, a) {
|
|
314
314
|
function l() {
|
|
315
|
-
return t.slots.header &&
|
|
315
|
+
return t.slots.header && d("div", {
|
|
316
316
|
class: "f-list-view-header"
|
|
317
317
|
}, [t.slots.header()]);
|
|
318
318
|
}
|
|
@@ -320,119 +320,119 @@ function _e(e, t, o) {
|
|
|
320
320
|
renderHeader: l
|
|
321
321
|
};
|
|
322
322
|
}
|
|
323
|
-
function le(e, t,
|
|
324
|
-
const l =
|
|
325
|
-
function
|
|
323
|
+
function le(e, t, a) {
|
|
324
|
+
const l = o(e.headerClass), n = o(e.placeholder), i = o(""), u = I(() => !i.value), r = I(() => !!i.value);
|
|
325
|
+
function h(c) {
|
|
326
326
|
i.value = "";
|
|
327
327
|
}
|
|
328
|
-
W(i, (
|
|
329
|
-
|
|
328
|
+
W(i, (c) => {
|
|
329
|
+
a.search(c);
|
|
330
330
|
});
|
|
331
|
-
const
|
|
332
|
-
const
|
|
331
|
+
const f = I(() => {
|
|
332
|
+
const c = {
|
|
333
333
|
"form-group": !0,
|
|
334
334
|
"farris-form-group": !0
|
|
335
335
|
};
|
|
336
|
-
return l.value && l.value.split(" ").reduce((
|
|
336
|
+
return l.value && l.value.split(" ").reduce((g, y) => (g[y] = !0, g), c), c;
|
|
337
337
|
});
|
|
338
|
-
function
|
|
338
|
+
function v(c) {
|
|
339
339
|
}
|
|
340
|
-
function
|
|
341
|
-
return
|
|
340
|
+
function s() {
|
|
341
|
+
return d("div", {
|
|
342
342
|
class: "f-list-view-header",
|
|
343
|
-
onClick: Oe(
|
|
344
|
-
}, [
|
|
345
|
-
class:
|
|
346
|
-
}, [
|
|
343
|
+
onClick: Oe(v, ["prevent", "stop"])
|
|
344
|
+
}, [d("div", {
|
|
345
|
+
class: f.value
|
|
346
|
+
}, [d("div", {
|
|
347
347
|
class: "farris-input-wrap"
|
|
348
|
-
}, [
|
|
348
|
+
}, [d("div", {
|
|
349
349
|
class: "f-cmp-inputgroup"
|
|
350
|
-
}, [
|
|
350
|
+
}, [d("div", {
|
|
351
351
|
class: "input-group f-state-editable"
|
|
352
|
-
}, [Q(
|
|
352
|
+
}, [Q(d("input", {
|
|
353
353
|
class: "form-control f-utils-fill text-left",
|
|
354
|
-
"onUpdate:modelValue": (
|
|
354
|
+
"onUpdate:modelValue": (c) => i.value = c,
|
|
355
355
|
name: "input-group-value",
|
|
356
356
|
type: "text",
|
|
357
357
|
placeholder: n.value,
|
|
358
358
|
autocomplete: "off"
|
|
359
|
-
}, null), [[Pe, i.value]]),
|
|
359
|
+
}, null), [[Pe, i.value]]), d("div", {
|
|
360
360
|
class: "input-group-append"
|
|
361
|
-
}, [
|
|
361
|
+
}, [r.value && d("span", {
|
|
362
362
|
class: "input-group-text input-group-clear",
|
|
363
|
-
onClick: (
|
|
364
|
-
}, [
|
|
363
|
+
onClick: (c) => h()
|
|
364
|
+
}, [d("i", {
|
|
365
365
|
class: "f-icon f-icon-close-circle"
|
|
366
|
-
}, null)]), u.value &&
|
|
366
|
+
}, null)]), u.value && d("span", {
|
|
367
367
|
class: "input-group-text"
|
|
368
|
-
}, [
|
|
368
|
+
}, [d("span", {
|
|
369
369
|
class: "f-icon f-icon-search"
|
|
370
370
|
}, null)])])])])])])]);
|
|
371
371
|
}
|
|
372
372
|
return {
|
|
373
|
-
renderHeader:
|
|
373
|
+
renderHeader: s
|
|
374
374
|
};
|
|
375
375
|
}
|
|
376
376
|
function $e(e, t) {
|
|
377
|
-
const
|
|
377
|
+
const a = o(e.idField), l = o(e.data), n = o(e.data), i = o(e.keepOrder);
|
|
378
378
|
function u() {
|
|
379
|
-
const
|
|
380
|
-
return n.value =
|
|
379
|
+
const f = l.value.map((v, s) => typeof v != "object" ? { __fv_index__: s, name: v } : (v.__fv_index__ = s, v));
|
|
380
|
+
return n.value = f, f;
|
|
381
381
|
}
|
|
382
|
-
const
|
|
382
|
+
const r = o(u());
|
|
383
383
|
W(
|
|
384
384
|
() => e.data,
|
|
385
|
-
(
|
|
385
|
+
(f) => {
|
|
386
386
|
if (i.value) {
|
|
387
|
-
const
|
|
388
|
-
l.value = [...
|
|
387
|
+
const v = f.reduce((g, y) => (g.set(y.id, !0), g), /* @__PURE__ */ new Map()), s = l.value.reduce((g, y) => (g.set(y.id, !0), g), /* @__PURE__ */ new Map()), c = r.value.filter((g) => v.has(g.id)), p = f.filter((g) => !s.has(g.id));
|
|
388
|
+
l.value = [...c, ...p];
|
|
389
389
|
} else
|
|
390
|
-
l.value =
|
|
391
|
-
|
|
390
|
+
l.value = f;
|
|
391
|
+
r.value = u();
|
|
392
392
|
}
|
|
393
393
|
);
|
|
394
|
-
function
|
|
395
|
-
return
|
|
396
|
-
const
|
|
397
|
-
return
|
|
398
|
-
}).filter((
|
|
394
|
+
function h(f) {
|
|
395
|
+
return f.map((s) => {
|
|
396
|
+
const c = n.value.findIndex((p) => p[a.value] === s);
|
|
397
|
+
return c > -1 ? n.value[c] : null;
|
|
398
|
+
}).filter((s) => s != null);
|
|
399
399
|
}
|
|
400
400
|
return {
|
|
401
|
-
dataView:
|
|
402
|
-
getSelectionItems:
|
|
401
|
+
dataView: r,
|
|
402
|
+
getSelectionItems: h
|
|
403
403
|
};
|
|
404
404
|
}
|
|
405
|
-
function Ne(e, t,
|
|
406
|
-
const n =
|
|
407
|
-
function
|
|
408
|
-
B.stopPropagation(),
|
|
409
|
-
u.value =
|
|
405
|
+
function Ne(e, t, a, l) {
|
|
406
|
+
const n = o(e.idField), { dataView: i } = a, u = o(-1), r = o(!1), { activeIndex: h, focusedItemId: f, hoverIndex: v, resumeHover: s, suspendHover: c } = l;
|
|
407
|
+
function p(B, S, b) {
|
|
408
|
+
B.stopPropagation(), c(), S && setTimeout(() => {
|
|
409
|
+
u.value = b, r.value = !0, S.moving = !0;
|
|
410
410
|
});
|
|
411
411
|
}
|
|
412
|
-
function
|
|
413
|
-
if (B.preventDefault(), u.value !==
|
|
414
|
-
const
|
|
415
|
-
|
|
412
|
+
function g(B, S) {
|
|
413
|
+
if (B.preventDefault(), u.value !== S) {
|
|
414
|
+
const b = i.value[u.value], x = i.value;
|
|
415
|
+
x.splice(u.value, 1), x.splice(S, 0, b), u.value = S;
|
|
416
416
|
}
|
|
417
417
|
}
|
|
418
|
-
function y(B,
|
|
418
|
+
function y(B, S) {
|
|
419
419
|
B.preventDefault(), B.dataTransfer && (B.dataTransfer.dropEffect = "move");
|
|
420
420
|
}
|
|
421
|
-
function
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
}),
|
|
421
|
+
function w(B, S) {
|
|
422
|
+
S && (S.moving = !1), i.value.forEach((b, x) => {
|
|
423
|
+
b.__fv_index__ = x;
|
|
424
|
+
}), r.value = !1, s(), v.value = S.__fv_index__, h.value = S.__fv_index__, f.value = S[n.value], t.emit("change", i.value);
|
|
425
425
|
}
|
|
426
426
|
return {
|
|
427
|
-
dragstart:
|
|
428
|
-
dragenter:
|
|
427
|
+
dragstart: p,
|
|
428
|
+
dragenter: g,
|
|
429
429
|
dragover: y,
|
|
430
|
-
dragend:
|
|
431
|
-
isDragging:
|
|
430
|
+
dragend: w,
|
|
431
|
+
isDragging: r
|
|
432
432
|
};
|
|
433
433
|
}
|
|
434
|
-
function ze(e, t,
|
|
435
|
-
const { dataView: l } =
|
|
434
|
+
function ze(e, t, a) {
|
|
435
|
+
const { dataView: l } = a;
|
|
436
436
|
function n(i) {
|
|
437
437
|
if (i > -1 && i < l.value.length) {
|
|
438
438
|
const u = l.value.splice(i, 1);
|
|
@@ -442,31 +442,31 @@ function ze(e, t, o) {
|
|
|
442
442
|
return { removeItem: n };
|
|
443
443
|
}
|
|
444
444
|
function Xe() {
|
|
445
|
-
const e =
|
|
446
|
-
function n(
|
|
447
|
-
|
|
445
|
+
const e = o(-1), t = o(""), a = o(-1), l = o(!1);
|
|
446
|
+
function n(f, v, s) {
|
|
447
|
+
a.value = s;
|
|
448
448
|
}
|
|
449
|
-
function i(
|
|
450
|
-
l.value || (
|
|
449
|
+
function i(f, v, s) {
|
|
450
|
+
l.value || (a.value = s);
|
|
451
451
|
}
|
|
452
|
-
function u(
|
|
453
|
-
|
|
452
|
+
function u(f, v, s) {
|
|
453
|
+
a.value = -1;
|
|
454
454
|
}
|
|
455
|
-
function
|
|
455
|
+
function r() {
|
|
456
456
|
l.value = !0;
|
|
457
457
|
}
|
|
458
|
-
function
|
|
458
|
+
function h() {
|
|
459
459
|
l.value = !1;
|
|
460
460
|
}
|
|
461
461
|
return {
|
|
462
462
|
activeIndex: e,
|
|
463
463
|
focusedItemId: t,
|
|
464
|
-
hoverIndex:
|
|
464
|
+
hoverIndex: a,
|
|
465
465
|
onMouseenterItem: n,
|
|
466
466
|
onMouseoverItem: i,
|
|
467
467
|
onMouseoutItem: u,
|
|
468
|
-
resumeHover:
|
|
469
|
-
suspendHover:
|
|
468
|
+
resumeHover: h,
|
|
469
|
+
suspendHover: r
|
|
470
470
|
};
|
|
471
471
|
}
|
|
472
472
|
const fe = /* @__PURE__ */ z({
|
|
@@ -474,35 +474,35 @@ const fe = /* @__PURE__ */ z({
|
|
|
474
474
|
props: Re,
|
|
475
475
|
emits: ["checkValuesChange", "clickItem", "selectionChange", "removeItem", "change"],
|
|
476
476
|
setup(e, t) {
|
|
477
|
-
const
|
|
478
|
-
|
|
479
|
-
const
|
|
480
|
-
dataView:
|
|
481
|
-
} =
|
|
477
|
+
const a = o(), l = o(e.view), n = o(e.header), i = o(e.multiSelect), u = o(e.view === "CardView"), r = o(!0), h = o({}), f = o("暂无数据");
|
|
478
|
+
o(!0), o(!1), o("id");
|
|
479
|
+
const v = $e(e), {
|
|
480
|
+
dataView: s
|
|
481
|
+
} = v, c = I(() => {
|
|
482
482
|
const P = {
|
|
483
483
|
"f-list-view": !0,
|
|
484
484
|
"f-list-view-multiple": i.value
|
|
485
485
|
};
|
|
486
486
|
return e.size !== "default" && (P[`${e.size}-item`] = !0), P;
|
|
487
|
-
}),
|
|
487
|
+
}), p = I(() => ({
|
|
488
488
|
"f-list-view-group": !0,
|
|
489
489
|
"d-flex": u.value,
|
|
490
490
|
"flex-wrap": u.value
|
|
491
|
-
})),
|
|
491
|
+
})), g = I(() => !!s.value && s.value.length > 0), y = Xe(), w = De(e, t, v), B = Ne(e, t, v, y), S = ze(e, t, v), b = je(e, t, B, y, w), x = Ae(e, a), O = I(() => s.value.length === 0), F = I(() => O.value && !t.slots.empty), E = I(() => !!t.slots.footer || r.value);
|
|
492
492
|
function L() {
|
|
493
493
|
return l.value === "SingleView" ? ae : l.value === "DraggableView" ? We : l.value === "ContentView" && t.slots.content ? He : ae;
|
|
494
494
|
}
|
|
495
495
|
const C = L(), {
|
|
496
496
|
renderItem: j
|
|
497
|
-
} = C(e, t,
|
|
497
|
+
} = C(e, t, v, B, y, b, w, S);
|
|
498
498
|
function M() {
|
|
499
499
|
return n.value === "SearchBar" ? le : n.value === "ContentHeader" ? _e : le;
|
|
500
500
|
}
|
|
501
501
|
const D = M(), {
|
|
502
502
|
renderHeader: X
|
|
503
|
-
} = D(e, t,
|
|
503
|
+
} = D(e, t, x);
|
|
504
504
|
function R(P) {
|
|
505
|
-
|
|
505
|
+
x.search(P);
|
|
506
506
|
}
|
|
507
507
|
t.expose({
|
|
508
508
|
search: R
|
|
@@ -510,20 +510,20 @@ const fe = /* @__PURE__ */ z({
|
|
|
510
510
|
function V(P) {
|
|
511
511
|
i.value && (P.preventDefault(), P.stopPropagation());
|
|
512
512
|
}
|
|
513
|
-
return () =>
|
|
514
|
-
class:
|
|
513
|
+
return () => d("div", {
|
|
514
|
+
class: c.value,
|
|
515
515
|
onClick: V
|
|
516
|
-
}, [X(),
|
|
517
|
-
ref:
|
|
516
|
+
}, [X(), d("div", {
|
|
517
|
+
ref: a,
|
|
518
518
|
class: "f-list-view-content"
|
|
519
|
-
}, [
|
|
520
|
-
class:
|
|
519
|
+
}, [d("ul", {
|
|
520
|
+
class: p.value,
|
|
521
521
|
style: "list-style: none;"
|
|
522
|
-
}, [
|
|
522
|
+
}, [g.value && s.value.map((P, A) => j(P, A, h)), F.value && d("div", {
|
|
523
523
|
class: "f-list-view-emptydata"
|
|
524
|
-
}, [
|
|
524
|
+
}, [d("p", {
|
|
525
525
|
class: "f-empty-title"
|
|
526
|
-
}, [
|
|
526
|
+
}, [f.value])]), t.slots.empty && t.slots.empty()])]), E.value && d("div", {
|
|
527
527
|
class: "f-list-view-footer"
|
|
528
528
|
}, [t.slots.footer && t.slots.footer()])]);
|
|
529
529
|
}
|
|
@@ -550,11 +550,11 @@ const fe = /* @__PURE__ */ z({
|
|
|
550
550
|
icon: { type: String }
|
|
551
551
|
};
|
|
552
552
|
function Ge(e, t) {
|
|
553
|
-
function
|
|
553
|
+
function a(l) {
|
|
554
554
|
l.stopPropagation(), e.disabled || t.emit("click", l);
|
|
555
555
|
}
|
|
556
556
|
return {
|
|
557
|
-
onClickButton:
|
|
557
|
+
onClickButton: a
|
|
558
558
|
};
|
|
559
559
|
}
|
|
560
560
|
const Ue = /* @__PURE__ */ z({
|
|
@@ -563,21 +563,21 @@ const Ue = /* @__PURE__ */ z({
|
|
|
563
563
|
emits: ["click"],
|
|
564
564
|
setup(e, t) {
|
|
565
565
|
const {
|
|
566
|
-
onClickButton:
|
|
567
|
-
} = Ge(e, t), l =
|
|
568
|
-
|
|
566
|
+
onClickButton: a
|
|
567
|
+
} = Ge(e, t), l = o(e.size), n = o(e.type), i = o(e.disabled);
|
|
568
|
+
o(e.icon);
|
|
569
569
|
const u = I(() => {
|
|
570
|
-
const
|
|
570
|
+
const r = {
|
|
571
571
|
btn: !0,
|
|
572
572
|
"btn-lg": l.value === "large",
|
|
573
573
|
"btn-sm": l.value !== "large"
|
|
574
574
|
};
|
|
575
|
-
return n.value && (
|
|
575
|
+
return n.value && (r[`btn-${n.value}`] = !0), r;
|
|
576
576
|
});
|
|
577
|
-
return I(() => ({})), () =>
|
|
577
|
+
return I(() => ({})), () => d("button", {
|
|
578
578
|
class: u.value,
|
|
579
579
|
disabled: i.value,
|
|
580
|
-
onClick: (
|
|
580
|
+
onClick: (r) => a(r)
|
|
581
581
|
}, [t.slots.default && t.slots.default()]);
|
|
582
582
|
}
|
|
583
583
|
}), Ke = {};
|
|
@@ -586,8 +586,8 @@ function ve(e) {
|
|
|
586
586
|
return Object.keys(t).reduce((l, n) => (l[n] = t[n].type === "object" && t[n].properties ? ve(t[n]) : t[n].default, l), {});
|
|
587
587
|
}
|
|
588
588
|
function Je(e, t) {
|
|
589
|
-
const
|
|
590
|
-
return Object.keys(e).reduce((l, n) => (l[n] = e[n], l),
|
|
589
|
+
const a = ve(t);
|
|
590
|
+
return Object.keys(e).reduce((l, n) => (l[n] = e[n], l), a), a;
|
|
591
591
|
}
|
|
592
592
|
function Qe(e, t) {
|
|
593
593
|
return Object.keys(e).filter((l) => e[l] != null).reduce((l, n) => {
|
|
@@ -604,13 +604,13 @@ function Qe(e, t) {
|
|
|
604
604
|
return l;
|
|
605
605
|
}, {});
|
|
606
606
|
}
|
|
607
|
-
function Ye(e, t,
|
|
607
|
+
function Ye(e, t, a = /* @__PURE__ */ new Map()) {
|
|
608
608
|
const l = Je(e, t);
|
|
609
|
-
return Qe(l,
|
|
609
|
+
return Qe(l, a);
|
|
610
610
|
}
|
|
611
|
-
function pe(e, t,
|
|
611
|
+
function pe(e, t, a = /* @__PURE__ */ new Map()) {
|
|
612
612
|
return Ke[t.title] = t, (l) => {
|
|
613
|
-
const n = Ye(l, t,
|
|
613
|
+
const n = Ye(l, t, a), i = Object.keys(e).reduce((u, r) => (u[r] = e[r].default, u), {});
|
|
614
614
|
return Object.assign(i, n);
|
|
615
615
|
};
|
|
616
616
|
}
|
|
@@ -864,35 +864,40 @@ const st = {
|
|
|
864
864
|
selectedValues: { type: String, default: "" },
|
|
865
865
|
separator: { type: String, default: "," },
|
|
866
866
|
textField: { type: String, default: "name" },
|
|
867
|
-
width: { type: Number
|
|
867
|
+
width: { type: Number },
|
|
868
|
+
height: { type: Number },
|
|
868
869
|
valueField: { type: String, default: "id" }
|
|
869
870
|
}, ct = /* @__PURE__ */ z({
|
|
870
871
|
name: "FComboListContainer",
|
|
871
872
|
props: st,
|
|
872
873
|
emits: ["selectionChange"],
|
|
873
874
|
setup(e, t) {
|
|
874
|
-
const
|
|
875
|
+
const a = o(e.dataSource), l = o([]), n = o(e.separator), i = o(e.width), u = o(e.height), r = o(e.selectedValues.split(n.value));
|
|
875
876
|
W(e.dataSource, () => {
|
|
876
|
-
|
|
877
|
+
a.value = e.dataSource;
|
|
878
|
+
});
|
|
879
|
+
const h = I(() => e.enableSearch ? "SearchBar" : "ContentHeader"), f = I(() => {
|
|
880
|
+
const s = {};
|
|
881
|
+
return i.value !== void 0 && (s.width = `${i.value}px`), u.value !== void 0 && (s.height = `${u.value}px`), s;
|
|
877
882
|
});
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
l.value = p.map((c) => Object.assign({}, c)), i.value = p.map((c) => c[e.idField]), t.emit("selectionChange", l.value);
|
|
883
|
+
function v(s) {
|
|
884
|
+
l.value = s.map((c) => Object.assign({}, c)), r.value = s.map((c) => c[e.idField]), t.emit("selectionChange", l.value);
|
|
881
885
|
}
|
|
882
|
-
return () =>
|
|
883
|
-
class: "f-combo-list-container"
|
|
884
|
-
|
|
886
|
+
return () => d("div", {
|
|
887
|
+
class: "f-combo-list-container",
|
|
888
|
+
style: f.value
|
|
889
|
+
}, [d(fe, {
|
|
885
890
|
size: "small",
|
|
886
891
|
itemClass: "f-combo-list-item",
|
|
887
|
-
header:
|
|
892
|
+
header: h.value,
|
|
888
893
|
headerClass: "f-combo-list-search-box",
|
|
889
|
-
data:
|
|
894
|
+
data: a.value,
|
|
890
895
|
idField: e.idField,
|
|
891
896
|
textField: e.textField,
|
|
892
897
|
multiSelect: e.multiSelect,
|
|
893
898
|
multiSelectMode: "OnCheckAndClick",
|
|
894
|
-
"selection-values":
|
|
895
|
-
onSelectionChange:
|
|
899
|
+
"selection-values": r.value,
|
|
900
|
+
onSelectionChange: v
|
|
896
901
|
}, null)]);
|
|
897
902
|
}
|
|
898
903
|
}), rt = /* @__PURE__ */ new Map([
|
|
@@ -1193,41 +1198,41 @@ const bt = {
|
|
|
1193
1198
|
props: bt,
|
|
1194
1199
|
emits: ["click"],
|
|
1195
1200
|
setup(e, t) {
|
|
1196
|
-
const
|
|
1197
|
-
function n(
|
|
1198
|
-
t.emit("click"),
|
|
1201
|
+
const a = o(e.popupContentPosition), l = o(e.host);
|
|
1202
|
+
function n(r) {
|
|
1203
|
+
t.emit("click"), r.preventDefault(), r.stopPropagation();
|
|
1199
1204
|
}
|
|
1200
1205
|
const i = I(() => {
|
|
1201
|
-
const
|
|
1202
|
-
if (
|
|
1203
|
-
const
|
|
1204
|
-
left:
|
|
1205
|
-
top:
|
|
1206
|
-
height:
|
|
1207
|
-
} =
|
|
1206
|
+
const r = l.value;
|
|
1207
|
+
if (r) {
|
|
1208
|
+
const h = r.getBoundingClientRect(), {
|
|
1209
|
+
left: f,
|
|
1210
|
+
top: v,
|
|
1211
|
+
height: s
|
|
1212
|
+
} = h;
|
|
1208
1213
|
return {
|
|
1209
|
-
left:
|
|
1210
|
-
top:
|
|
1214
|
+
left: f,
|
|
1215
|
+
top: v + s
|
|
1211
1216
|
};
|
|
1212
1217
|
}
|
|
1213
|
-
return
|
|
1218
|
+
return a.value;
|
|
1214
1219
|
}), u = I(() => ({
|
|
1215
1220
|
position: "relative",
|
|
1216
1221
|
left: `${i.value.left}px`,
|
|
1217
1222
|
top: `${i.value.top}px`
|
|
1218
1223
|
}));
|
|
1219
|
-
return () =>
|
|
1224
|
+
return () => d(se, {
|
|
1220
1225
|
to: "body"
|
|
1221
1226
|
}, {
|
|
1222
1227
|
default: () => {
|
|
1223
|
-
var
|
|
1224
|
-
return [
|
|
1228
|
+
var r, h;
|
|
1229
|
+
return [d("div", {
|
|
1225
1230
|
class: "overlay-container",
|
|
1226
1231
|
style: "pointer-events: auto;",
|
|
1227
|
-
onClick: (
|
|
1228
|
-
}, [
|
|
1232
|
+
onClick: (f) => n(f)
|
|
1233
|
+
}, [d("div", {
|
|
1229
1234
|
style: u.value
|
|
1230
|
-
}, [(
|
|
1235
|
+
}, [(h = (r = t.slots).default) == null ? void 0 : h.call(r)])])];
|
|
1231
1236
|
}
|
|
1232
1237
|
});
|
|
1233
1238
|
}
|
|
@@ -1241,18 +1246,18 @@ function wt(e) {
|
|
|
1241
1246
|
function St(e) {
|
|
1242
1247
|
const t = document.createElement("div");
|
|
1243
1248
|
t.style.display = "contents";
|
|
1244
|
-
let
|
|
1249
|
+
let a;
|
|
1245
1250
|
const l = e.onClickCallback || (() => {
|
|
1246
1251
|
}), n = () => {
|
|
1247
|
-
l(),
|
|
1252
|
+
l(), a && a.unmount();
|
|
1248
1253
|
};
|
|
1249
|
-
return
|
|
1254
|
+
return a = Ve({
|
|
1250
1255
|
setup() {
|
|
1251
1256
|
ce(() => {
|
|
1252
1257
|
document.body.removeChild(t);
|
|
1253
1258
|
});
|
|
1254
1259
|
const i = wt(e);
|
|
1255
|
-
return () =>
|
|
1260
|
+
return () => d(Ct, {
|
|
1256
1261
|
"popup-content-position": e.popupPosition,
|
|
1257
1262
|
host: e.host,
|
|
1258
1263
|
onClick: n
|
|
@@ -1260,125 +1265,125 @@ function St(e) {
|
|
|
1260
1265
|
default: () => [i && i()]
|
|
1261
1266
|
});
|
|
1262
1267
|
}
|
|
1263
|
-
}), document.body.appendChild(t),
|
|
1268
|
+
}), document.body.appendChild(t), a.mount(t), a;
|
|
1264
1269
|
}
|
|
1265
1270
|
class Tt {
|
|
1266
1271
|
static show(t) {
|
|
1267
1272
|
return St(t);
|
|
1268
1273
|
}
|
|
1269
1274
|
}
|
|
1270
|
-
function Bt(e, t,
|
|
1271
|
-
const n =
|
|
1275
|
+
function Bt(e, t, a, l) {
|
|
1276
|
+
const n = o(e.buttonBehavior), i = o(e.popupOnInput), u = I(() => ({
|
|
1272
1277
|
"input-group-append": !0,
|
|
1273
1278
|
"append-force-show": e.showButtonWhenDisabled && (e.readonly || e.disable)
|
|
1274
|
-
})),
|
|
1275
|
-
async function
|
|
1276
|
-
if (
|
|
1277
|
-
const
|
|
1279
|
+
})), r = I(() => e.showButtonWhenDisabled || (!e.editable || !e.readonly) && !e.disable);
|
|
1280
|
+
async function h(c) {
|
|
1281
|
+
if (r.value) {
|
|
1282
|
+
const p = !!t.slots.default;
|
|
1278
1283
|
n.value === "Overlay" && Tt.show({
|
|
1279
|
-
host:
|
|
1284
|
+
host: a.value,
|
|
1280
1285
|
render: () => {
|
|
1281
1286
|
if (t.slots.default)
|
|
1282
1287
|
return t.slots.default();
|
|
1283
1288
|
}
|
|
1284
|
-
}),
|
|
1289
|
+
}), p && n.value === "Popup" && l.togglePopup(), p && i.value && l.hidePopup(), t.emit("clickButton", { origin: c, value: e.modelValue });
|
|
1285
1290
|
}
|
|
1286
|
-
|
|
1291
|
+
c.stopPropagation();
|
|
1287
1292
|
}
|
|
1288
|
-
function c
|
|
1289
|
-
t.emit("mouseEnterIcon",
|
|
1293
|
+
function f(c) {
|
|
1294
|
+
t.emit("mouseEnterIcon", c);
|
|
1290
1295
|
}
|
|
1291
|
-
function
|
|
1292
|
-
t.emit("mouseLeaveIcon",
|
|
1296
|
+
function v(c) {
|
|
1297
|
+
t.emit("mouseLeaveIcon", c);
|
|
1293
1298
|
}
|
|
1294
|
-
function
|
|
1299
|
+
function s() {
|
|
1295
1300
|
t.emit("mouseOverButton");
|
|
1296
1301
|
}
|
|
1297
1302
|
return {
|
|
1298
1303
|
buttonClass: u,
|
|
1299
|
-
onClickButton:
|
|
1300
|
-
onMouseEnterButton:
|
|
1301
|
-
onMouseLeaveButton:
|
|
1302
|
-
onMouseOverButton:
|
|
1304
|
+
onClickButton: h,
|
|
1305
|
+
onMouseEnterButton: f,
|
|
1306
|
+
onMouseLeaveButton: v,
|
|
1307
|
+
onMouseOverButton: s
|
|
1303
1308
|
};
|
|
1304
1309
|
}
|
|
1305
|
-
function It(e, t,
|
|
1306
|
-
const u =
|
|
1307
|
-
function
|
|
1308
|
-
u.value =
|
|
1310
|
+
function It(e, t, a, l, n, i) {
|
|
1311
|
+
const u = o(!1), r = I(() => e.enableClear && !e.readonly && !e.disable), { changeTextBoxValue: h } = i;
|
|
1312
|
+
function f(p) {
|
|
1313
|
+
u.value = p;
|
|
1309
1314
|
}
|
|
1310
1315
|
W(n, () => {
|
|
1311
|
-
l.value ?
|
|
1316
|
+
l.value ? f(!!n.value) : f(!1);
|
|
1312
1317
|
});
|
|
1313
|
-
function
|
|
1314
|
-
const
|
|
1315
|
-
|
|
1316
|
-
}
|
|
1317
|
-
function
|
|
1318
|
-
if (
|
|
1319
|
-
if (!
|
|
1320
|
-
|
|
1318
|
+
function v(p) {
|
|
1319
|
+
const g = !e.readonly && !e.disable && e.editable, y = !e.editable;
|
|
1320
|
+
p.stopPropagation(), (g || y) && (h("", !1), f(!u.value), t.emit("clear"));
|
|
1321
|
+
}
|
|
1322
|
+
function s(p) {
|
|
1323
|
+
if (r.value) {
|
|
1324
|
+
if (!a.value) {
|
|
1325
|
+
f(!1);
|
|
1321
1326
|
return;
|
|
1322
1327
|
}
|
|
1323
|
-
(!e.editable || !e.readonly) && !e.disable &&
|
|
1328
|
+
(!e.editable || !e.readonly) && !e.disable && f(!0);
|
|
1324
1329
|
}
|
|
1325
1330
|
}
|
|
1326
|
-
function
|
|
1327
|
-
|
|
1331
|
+
function c(p) {
|
|
1332
|
+
r.value && f(!1);
|
|
1328
1333
|
}
|
|
1329
1334
|
return {
|
|
1330
|
-
enableClearButton:
|
|
1335
|
+
enableClearButton: r,
|
|
1331
1336
|
showClearButton: u,
|
|
1332
|
-
onClearValue:
|
|
1333
|
-
onMouseEnterTextBox:
|
|
1334
|
-
onMouseLeaveTextBox:
|
|
1337
|
+
onClearValue: v,
|
|
1338
|
+
onMouseEnterTextBox: s,
|
|
1339
|
+
onMouseLeaveTextBox: c
|
|
1335
1340
|
};
|
|
1336
1341
|
}
|
|
1337
|
-
function kt(e, t,
|
|
1338
|
-
const i =
|
|
1339
|
-
let
|
|
1340
|
-
const
|
|
1342
|
+
function kt(e, t, a, l, n) {
|
|
1343
|
+
const i = o(e.popupOnInput), u = o(e.popupOnFocus), { shouldPopupContent: r } = n, h = I(() => e.enableTitle ? a.value : ""), f = I(() => (e.disable || e.readonly) && !e.forcePlaceholder ? "" : e.placeholder), v = I(() => e.readonly || !e.editable);
|
|
1344
|
+
let s = !1;
|
|
1345
|
+
const c = I(() => !e.disable && s), p = I(() => ({
|
|
1341
1346
|
"text-left": e.textAlign === "left",
|
|
1342
1347
|
"text-center": e.textAlign === "center",
|
|
1343
1348
|
"text-right": e.textAlign === "right",
|
|
1344
1349
|
"form-control": !0,
|
|
1345
1350
|
"f-utils-fill": !0
|
|
1346
|
-
})),
|
|
1351
|
+
})), g = I(() => ({
|
|
1347
1352
|
"input-group": !0,
|
|
1348
1353
|
"f-state-disable": e.disable,
|
|
1349
1354
|
"f-state-editable": e.editable && !e.disable && !e.readonly,
|
|
1350
1355
|
"f-state-readonly": e.readonly && !e.disable,
|
|
1351
|
-
"f-state-focus":
|
|
1356
|
+
"f-state-focus": c.value
|
|
1352
1357
|
}));
|
|
1353
1358
|
function y(C, j = !0) {
|
|
1354
|
-
|
|
1359
|
+
a.value !== C && (a.value = C, j && t.emit("change", C), t.emit("update:modelValue", C));
|
|
1355
1360
|
}
|
|
1356
|
-
function
|
|
1357
|
-
|
|
1361
|
+
function w(C) {
|
|
1362
|
+
r.value = !1, y(C, !0);
|
|
1358
1363
|
}
|
|
1359
1364
|
W(
|
|
1360
1365
|
() => e.modelValue,
|
|
1361
1366
|
(C) => {
|
|
1362
|
-
|
|
1367
|
+
a.value = C, t.emit("change", C);
|
|
1363
1368
|
}
|
|
1364
1369
|
);
|
|
1365
1370
|
function B(C) {
|
|
1366
|
-
|
|
1371
|
+
s = !1, t.emit("blur", C), C.stopPropagation();
|
|
1367
1372
|
}
|
|
1368
|
-
function
|
|
1373
|
+
function S(C) {
|
|
1369
1374
|
t.emit("click", C);
|
|
1370
1375
|
}
|
|
1371
|
-
function
|
|
1376
|
+
function b(C) {
|
|
1372
1377
|
if (e.disable) {
|
|
1373
|
-
|
|
1378
|
+
s = !0;
|
|
1374
1379
|
return;
|
|
1375
1380
|
}
|
|
1376
|
-
|
|
1381
|
+
s = !0, v.value || (t.emit("focus", C), u.value && !r.value && n.popup());
|
|
1377
1382
|
}
|
|
1378
|
-
function
|
|
1383
|
+
function x(C) {
|
|
1379
1384
|
t.emit("input", C.target.value);
|
|
1380
1385
|
const j = C.target.value;
|
|
1381
|
-
l.value = j,
|
|
1386
|
+
l.value = j, a.value !== j && y(j, !1), i.value && !r.value && n.popup();
|
|
1382
1387
|
}
|
|
1383
1388
|
function O(C) {
|
|
1384
1389
|
C.target.tagName !== "INPUT" && C.preventDefault(), C.stopPropagation();
|
|
@@ -1394,57 +1399,57 @@ function kt(e, t, o, l, n) {
|
|
|
1394
1399
|
C.stopPropagation(), y(j);
|
|
1395
1400
|
}
|
|
1396
1401
|
return {
|
|
1397
|
-
hasFocusedTextBox:
|
|
1398
|
-
isTextBoxReadonly:
|
|
1399
|
-
textBoxClass:
|
|
1400
|
-
textBoxPlaceholder:
|
|
1401
|
-
textBoxTitle:
|
|
1402
|
-
inputGroupClass:
|
|
1402
|
+
hasFocusedTextBox: c,
|
|
1403
|
+
isTextBoxReadonly: v,
|
|
1404
|
+
textBoxClass: p,
|
|
1405
|
+
textBoxPlaceholder: f,
|
|
1406
|
+
textBoxTitle: h,
|
|
1407
|
+
inputGroupClass: g,
|
|
1403
1408
|
changeTextBoxValue: y,
|
|
1404
|
-
commitValue:
|
|
1409
|
+
commitValue: w,
|
|
1405
1410
|
onBlurTextBox: B,
|
|
1406
|
-
onClickTextBox:
|
|
1407
|
-
onFocusTextBox:
|
|
1408
|
-
onInput:
|
|
1411
|
+
onClickTextBox: S,
|
|
1412
|
+
onFocusTextBox: b,
|
|
1413
|
+
onInput: x,
|
|
1409
1414
|
onKeyDownTextBox: F,
|
|
1410
1415
|
onKeyUpTextBox: E,
|
|
1411
1416
|
onMouseDownTextBox: O,
|
|
1412
1417
|
onTextBoxValueChange: L
|
|
1413
1418
|
};
|
|
1414
1419
|
}
|
|
1415
|
-
function xt(e, t,
|
|
1416
|
-
const l =
|
|
1420
|
+
function xt(e, t, a) {
|
|
1421
|
+
const l = o(), n = o(!1);
|
|
1417
1422
|
function i() {
|
|
1418
|
-
const
|
|
1419
|
-
|
|
1423
|
+
const f = l.value;
|
|
1424
|
+
f && f.show(a.value);
|
|
1420
1425
|
}
|
|
1421
1426
|
async function u() {
|
|
1422
1427
|
!!t.slots.default && (n.value = !n.value, await K(), i());
|
|
1423
1428
|
}
|
|
1424
|
-
async function
|
|
1429
|
+
async function r() {
|
|
1425
1430
|
!!t.slots.default && (n.value = !0, await K(), i());
|
|
1426
1431
|
}
|
|
1427
|
-
function
|
|
1432
|
+
function h() {
|
|
1428
1433
|
n.value = !1;
|
|
1429
1434
|
}
|
|
1430
|
-
return { hidePopup:
|
|
1435
|
+
return { hidePopup: h, popup: r, shouldPopupContent: n, togglePopup: u, popoverRef: l };
|
|
1431
1436
|
}
|
|
1432
|
-
function Ft(e, t,
|
|
1437
|
+
function Ft(e, t, a) {
|
|
1433
1438
|
const {
|
|
1434
1439
|
isTextBoxReadonly: l,
|
|
1435
1440
|
textBoxClass: n,
|
|
1436
1441
|
textBoxPlaceholder: i,
|
|
1437
1442
|
textBoxTitle: u,
|
|
1438
|
-
onBlurTextBox:
|
|
1439
|
-
onClickTextBox:
|
|
1440
|
-
onFocusTextBox:
|
|
1441
|
-
onInput:
|
|
1442
|
-
onKeyDownTextBox:
|
|
1443
|
-
onKeyUpTextBox:
|
|
1444
|
-
onMouseDownTextBox:
|
|
1445
|
-
onTextBoxValueChange:
|
|
1446
|
-
} =
|
|
1447
|
-
return () =>
|
|
1443
|
+
onBlurTextBox: r,
|
|
1444
|
+
onClickTextBox: h,
|
|
1445
|
+
onFocusTextBox: f,
|
|
1446
|
+
onInput: v,
|
|
1447
|
+
onKeyDownTextBox: s,
|
|
1448
|
+
onKeyUpTextBox: c,
|
|
1449
|
+
onMouseDownTextBox: p,
|
|
1450
|
+
onTextBoxValueChange: g
|
|
1451
|
+
} = a;
|
|
1452
|
+
return () => d("input", {
|
|
1448
1453
|
name: "input-group-value",
|
|
1449
1454
|
autocomplete: e.autoComplete ? "on" : "off",
|
|
1450
1455
|
class: n.value,
|
|
@@ -1457,14 +1462,14 @@ function Ft(e, t, o) {
|
|
|
1457
1462
|
title: u.value,
|
|
1458
1463
|
type: e.inputType,
|
|
1459
1464
|
value: t.value,
|
|
1460
|
-
onBlur:
|
|
1461
|
-
onChange:
|
|
1462
|
-
onClick:
|
|
1463
|
-
onFocus:
|
|
1464
|
-
onInput:
|
|
1465
|
-
onKeydown:
|
|
1466
|
-
onKeyup:
|
|
1467
|
-
onMousedown:
|
|
1465
|
+
onBlur: r,
|
|
1466
|
+
onChange: g,
|
|
1467
|
+
onClick: h,
|
|
1468
|
+
onFocus: f,
|
|
1469
|
+
onInput: v,
|
|
1470
|
+
onKeydown: s,
|
|
1471
|
+
onKeyup: c,
|
|
1472
|
+
onMousedown: p
|
|
1468
1473
|
}, null);
|
|
1469
1474
|
}
|
|
1470
1475
|
const Ot = {
|
|
@@ -1485,30 +1490,30 @@ const Ot = {
|
|
|
1485
1490
|
wrapText: { Type: Boolean, default: !1 },
|
|
1486
1491
|
draggable: { Type: Boolean, default: !1 }
|
|
1487
1492
|
};
|
|
1488
|
-
function Pt(e, t,
|
|
1489
|
-
const n =
|
|
1490
|
-
function u(
|
|
1491
|
-
|
|
1492
|
-
n.value =
|
|
1493
|
+
function Pt(e, t, a, l) {
|
|
1494
|
+
const n = o(-1), i = o(!1);
|
|
1495
|
+
function u(v, s, c) {
|
|
1496
|
+
v.stopPropagation(), s && setTimeout(() => {
|
|
1497
|
+
n.value = c, i.value = !0, s.moving = !0;
|
|
1493
1498
|
});
|
|
1494
1499
|
}
|
|
1495
|
-
function
|
|
1496
|
-
if (
|
|
1497
|
-
const
|
|
1498
|
-
|
|
1500
|
+
function r(v, s) {
|
|
1501
|
+
if (v.preventDefault(), n.value !== s) {
|
|
1502
|
+
const c = l.value[n.value], p = l.value;
|
|
1503
|
+
p.splice(n.value, 1), p.splice(s, 0, c), n.value = s;
|
|
1499
1504
|
}
|
|
1500
1505
|
}
|
|
1501
|
-
function
|
|
1502
|
-
|
|
1506
|
+
function h(v, s) {
|
|
1507
|
+
v.preventDefault(), v.dataTransfer && (v.dataTransfer.dropEffect = "move");
|
|
1503
1508
|
}
|
|
1504
|
-
function
|
|
1505
|
-
|
|
1509
|
+
function f(v, s) {
|
|
1510
|
+
s && (s.moving = !1), a.value = l.value.filter((c) => c.type === "Tag").map((c) => c.payload), i.value = !1, t.emit("change", a.value);
|
|
1506
1511
|
}
|
|
1507
1512
|
return {
|
|
1508
1513
|
dragstart: u,
|
|
1509
|
-
dragenter:
|
|
1510
|
-
dragover:
|
|
1511
|
-
dragend:
|
|
1514
|
+
dragenter: r,
|
|
1515
|
+
dragover: h,
|
|
1516
|
+
dragend: f,
|
|
1512
1517
|
isDragging: i
|
|
1513
1518
|
};
|
|
1514
1519
|
}
|
|
@@ -1517,68 +1522,68 @@ const Vt = /* @__PURE__ */ z({
|
|
|
1517
1522
|
props: Ot,
|
|
1518
1523
|
emits: ["remove", "selectionChange", "change"],
|
|
1519
1524
|
setup(e, t) {
|
|
1520
|
-
const
|
|
1521
|
-
|
|
1522
|
-
const y =
|
|
1523
|
-
function
|
|
1524
|
-
const
|
|
1525
|
+
const a = o(e.selectable), l = o(e.customClass), n = o(e.data), i = o(e.tagType), u = o(e.tagStyle), r = o(e.showColor), h = o(e.activeTag), f = o(e.customStyle), v = o(e.showClose), s = o(e.showAddButton), c = o(e.showInput), p = o(e.addButtonText), g = o(e.enableAddButton);
|
|
1526
|
+
o(e.placeholder), o(""), o();
|
|
1527
|
+
const y = o(), w = o(e.wrapText), B = o();
|
|
1528
|
+
function S() {
|
|
1529
|
+
const m = n.value.map((T) => ({
|
|
1525
1530
|
type: "Tag",
|
|
1526
|
-
payload:
|
|
1531
|
+
payload: T
|
|
1527
1532
|
}));
|
|
1528
|
-
return
|
|
1533
|
+
return s.value && m.push({
|
|
1529
1534
|
type: "AddButton"
|
|
1530
|
-
}),
|
|
1535
|
+
}), m;
|
|
1531
1536
|
}
|
|
1532
|
-
const
|
|
1533
|
-
function
|
|
1534
|
-
n.value =
|
|
1537
|
+
const b = o(S());
|
|
1538
|
+
function x(m) {
|
|
1539
|
+
n.value = m, b.value = S();
|
|
1535
1540
|
}
|
|
1536
|
-
const O = I(() =>
|
|
1541
|
+
const O = I(() => b.value.findIndex((m) => m.type === "Input")), F = Pt(e, t, n, b), {
|
|
1537
1542
|
dragstart: E,
|
|
1538
1543
|
dragenter: L,
|
|
1539
1544
|
dragover: C,
|
|
1540
1545
|
dragend: j
|
|
1541
1546
|
} = F;
|
|
1542
|
-
W(() => e.data, (
|
|
1547
|
+
W(() => e.data, (m) => x(m));
|
|
1543
1548
|
const M = I(() => {
|
|
1544
|
-
const
|
|
1549
|
+
const m = {
|
|
1545
1550
|
"farris-tags": !0,
|
|
1546
|
-
"farris-tags-checkable":
|
|
1547
|
-
"farris-tags-nowrap": !
|
|
1551
|
+
"farris-tags-checkable": a.value,
|
|
1552
|
+
"farris-tags-nowrap": !w.value
|
|
1548
1553
|
};
|
|
1549
|
-
return l.value.split(" ").reduce((
|
|
1554
|
+
return l.value.split(" ").reduce((T, k) => (T[k] = !0, T), m), m;
|
|
1550
1555
|
});
|
|
1551
|
-
function D(
|
|
1552
|
-
const
|
|
1556
|
+
function D(m) {
|
|
1557
|
+
const T = {
|
|
1553
1558
|
"farris-tag-item": !0,
|
|
1554
|
-
"farris-tag-item-checked":
|
|
1555
|
-
"farris-tag-item-checkable":
|
|
1556
|
-
"farris-tag-item-has-color":
|
|
1557
|
-
"farris-tag-item-actived":
|
|
1559
|
+
"farris-tag-item-checked": a.value && m.checked,
|
|
1560
|
+
"farris-tag-item-checkable": a.value,
|
|
1561
|
+
"farris-tag-item-has-color": r.value,
|
|
1562
|
+
"farris-tag-item-actived": h.value === m.name
|
|
1558
1563
|
};
|
|
1559
1564
|
if (i.value) {
|
|
1560
1565
|
const k = `farris-tag-item-${i.value}`;
|
|
1561
|
-
|
|
1566
|
+
T[k] = !0;
|
|
1562
1567
|
}
|
|
1563
|
-
return
|
|
1568
|
+
return T;
|
|
1564
1569
|
}
|
|
1565
1570
|
const X = I(() => {
|
|
1566
|
-
const
|
|
1567
|
-
return
|
|
1571
|
+
const m = {};
|
|
1572
|
+
return f.value && f.value.split(";").reduce((T, k) => {
|
|
1568
1573
|
const H = k.split(":");
|
|
1569
|
-
return
|
|
1570
|
-
},
|
|
1574
|
+
return T[H[0]] = H[1], T;
|
|
1575
|
+
}, m), m;
|
|
1571
1576
|
});
|
|
1572
|
-
function R(
|
|
1573
|
-
|
|
1574
|
-
k.checked = !
|
|
1575
|
-
}), t.emit("change", n.value), t.emit("selectionChange",
|
|
1577
|
+
function R(m, T) {
|
|
1578
|
+
a.value && T.selectable && (T.checked = !T.checked, h.value = T.checked ? T.name : "", T.checked && n.value.filter((k) => k.name !== T.name).forEach((k) => {
|
|
1579
|
+
k.checked = !T.checked;
|
|
1580
|
+
}), t.emit("change", n.value), t.emit("selectionChange", T));
|
|
1576
1581
|
}
|
|
1577
|
-
function V(
|
|
1582
|
+
function V(m, T) {
|
|
1578
1583
|
let k;
|
|
1579
|
-
switch (
|
|
1584
|
+
switch (m.key) {
|
|
1580
1585
|
case "Backspace":
|
|
1581
|
-
n.value = n.value.filter((H) => H.name !==
|
|
1586
|
+
n.value = n.value.filter((H) => H.name !== T.name), t.emit("change", n.value);
|
|
1582
1587
|
break;
|
|
1583
1588
|
case "ArrowLeft":
|
|
1584
1589
|
k = Math.max(y.value.scrollLeft + 20, 0), y.value.scrollLeft = k;
|
|
@@ -1587,66 +1592,66 @@ const Vt = /* @__PURE__ */ z({
|
|
|
1587
1592
|
k = Math.max(y.value.scrollLeft - 20, 0), y.value.scrollLeft = k;
|
|
1588
1593
|
}
|
|
1589
1594
|
}
|
|
1590
|
-
function P(
|
|
1591
|
-
const k = n.value.findIndex((H) => H.name ===
|
|
1595
|
+
function P(m, T) {
|
|
1596
|
+
const k = n.value.findIndex((H) => H.name === T.name);
|
|
1592
1597
|
if (k > -1) {
|
|
1593
1598
|
const [H] = n.value.splice(k, 1);
|
|
1594
|
-
|
|
1599
|
+
b.value = S(), t.emit("change", n.value), t.emit("remove", n.value, H, k);
|
|
1595
1600
|
}
|
|
1596
|
-
|
|
1601
|
+
m.stopPropagation();
|
|
1597
1602
|
}
|
|
1598
1603
|
const A = I(() => ({
|
|
1599
1604
|
"farris-tag-item": !0,
|
|
1600
1605
|
"farris-tag-add-button": !0,
|
|
1601
|
-
"farris-tag-add-button-disabled": !
|
|
1606
|
+
"farris-tag-add-button-disabled": !g.value
|
|
1602
1607
|
}));
|
|
1603
|
-
function $(
|
|
1608
|
+
function $(m) {
|
|
1604
1609
|
}
|
|
1605
1610
|
function _() {
|
|
1606
|
-
return
|
|
1611
|
+
return d("li", {
|
|
1607
1612
|
class: A.value,
|
|
1608
|
-
onClick: (
|
|
1609
|
-
}, [
|
|
1613
|
+
onClick: (m) => void 0
|
|
1614
|
+
}, [d("span", {
|
|
1610
1615
|
class: "f-icon f-icon-amplification"
|
|
1611
|
-
}, null),
|
|
1616
|
+
}, null), d("span", {
|
|
1612
1617
|
class: "farris-tag-add-text"
|
|
1613
|
-
}, [
|
|
1618
|
+
}, [p.value])]);
|
|
1614
1619
|
}
|
|
1615
|
-
function N(
|
|
1616
|
-
if (
|
|
1617
|
-
const
|
|
1618
|
-
if (
|
|
1619
|
-
const [k] = n.value.splice(
|
|
1620
|
-
|
|
1620
|
+
function N(m) {
|
|
1621
|
+
if (m && !m.innerText) {
|
|
1622
|
+
const T = O.value;
|
|
1623
|
+
if (T > 0) {
|
|
1624
|
+
const [k] = n.value.splice(T - 1, 1);
|
|
1625
|
+
b.value.splice(T - 1, 1), t.emit("remove", n.value, k, T - 1);
|
|
1621
1626
|
}
|
|
1622
1627
|
}
|
|
1623
1628
|
}
|
|
1624
|
-
function U(
|
|
1625
|
-
|
|
1626
|
-
name:
|
|
1629
|
+
function U(m, T, k) {
|
|
1630
|
+
m > -1 && (n.value.splice(m, 0, {
|
|
1631
|
+
name: T,
|
|
1627
1632
|
value: k,
|
|
1628
|
-
selectable:
|
|
1629
|
-
}),
|
|
1633
|
+
selectable: a.value
|
|
1634
|
+
}), b.value = S(), t.emit("change", n.value));
|
|
1630
1635
|
}
|
|
1631
|
-
function J(
|
|
1632
|
-
if (
|
|
1633
|
-
const
|
|
1634
|
-
U(k,
|
|
1636
|
+
function J(m) {
|
|
1637
|
+
if (m && m.innerText) {
|
|
1638
|
+
const T = m.innerText, k = O.value;
|
|
1639
|
+
U(k, T, T), m.innerText = "";
|
|
1635
1640
|
}
|
|
1636
1641
|
}
|
|
1637
|
-
function Y(
|
|
1638
|
-
const
|
|
1639
|
-
|
|
1642
|
+
function Y(m) {
|
|
1643
|
+
const T = m.target;
|
|
1644
|
+
T && (T.innerText ? J(T) : t.emit("change", n.value));
|
|
1640
1645
|
}
|
|
1641
|
-
function ye(
|
|
1642
|
-
|
|
1646
|
+
function ye(m) {
|
|
1647
|
+
m.key === "Enter" && J(m.target), m.key === "Backspace" && (N(m.target), K(() => {
|
|
1643
1648
|
B.value && B.value.focus();
|
|
1644
1649
|
}));
|
|
1645
1650
|
}
|
|
1646
1651
|
function be() {
|
|
1647
|
-
return
|
|
1652
|
+
return d("li", {
|
|
1648
1653
|
class: "farris-tag-input-box"
|
|
1649
|
-
}, [
|
|
1654
|
+
}, [d("div", {
|
|
1650
1655
|
ref: B,
|
|
1651
1656
|
class: "form-control",
|
|
1652
1657
|
contenteditable: "true",
|
|
@@ -1654,35 +1659,35 @@ const Vt = /* @__PURE__ */ z({
|
|
|
1654
1659
|
onBlur: Y
|
|
1655
1660
|
}, null)]);
|
|
1656
1661
|
}
|
|
1657
|
-
function Ce(
|
|
1658
|
-
return
|
|
1659
|
-
class: D(
|
|
1662
|
+
function Ce(m, T) {
|
|
1663
|
+
return d("li", {
|
|
1664
|
+
class: D(m),
|
|
1660
1665
|
style: X.value,
|
|
1661
1666
|
tabindex: 0,
|
|
1662
|
-
id:
|
|
1663
|
-
key:
|
|
1664
|
-
onClick: (k) => R(k,
|
|
1665
|
-
onKeydown: (k) => V(k,
|
|
1667
|
+
id: m.name,
|
|
1668
|
+
key: m.name,
|
|
1669
|
+
onClick: (k) => R(k, m),
|
|
1670
|
+
onKeydown: (k) => V(k, m),
|
|
1666
1671
|
draggable: "true",
|
|
1667
|
-
onDragstart: (k) => E(k,
|
|
1668
|
-
onDragenter: (k) => L(k,
|
|
1669
|
-
onDragend: (k) => j(k,
|
|
1670
|
-
onDragover: (k) => C(k,
|
|
1671
|
-
}, [
|
|
1672
|
-
title:
|
|
1672
|
+
onDragstart: (k) => E(k, m, T),
|
|
1673
|
+
onDragenter: (k) => L(k, T),
|
|
1674
|
+
onDragend: (k) => j(k, m),
|
|
1675
|
+
onDragover: (k) => C(k, T)
|
|
1676
|
+
}, [d("div", {
|
|
1677
|
+
title: m.name,
|
|
1673
1678
|
class: "tag-box"
|
|
1674
|
-
}, [
|
|
1679
|
+
}, [m.name]), v.value && d("span", {
|
|
1675
1680
|
class: "tag-delete"
|
|
1676
|
-
}, [
|
|
1681
|
+
}, [d("i", {
|
|
1677
1682
|
class: "f-icon f-icon-close",
|
|
1678
|
-
onClick: (k) => P(k,
|
|
1683
|
+
onClick: (k) => P(k, m)
|
|
1679
1684
|
}, null)])]);
|
|
1680
1685
|
}
|
|
1681
1686
|
function we() {
|
|
1682
|
-
return
|
|
1683
|
-
switch (
|
|
1687
|
+
return b.value.map((m, T) => {
|
|
1688
|
+
switch (m.type) {
|
|
1684
1689
|
case "Tag":
|
|
1685
|
-
return Ce(
|
|
1690
|
+
return Ce(m.payload, T);
|
|
1686
1691
|
case "AddButton":
|
|
1687
1692
|
return _();
|
|
1688
1693
|
case "Input":
|
|
@@ -1694,67 +1699,67 @@ const Vt = /* @__PURE__ */ z({
|
|
|
1694
1699
|
"farris-tags-item-container": !0,
|
|
1695
1700
|
"farris-tag-item-capsule": u.value === "capsule"
|
|
1696
1701
|
}));
|
|
1697
|
-
function Te(
|
|
1698
|
-
const
|
|
1699
|
-
y.value.scrollLeft =
|
|
1702
|
+
function Te(m) {
|
|
1703
|
+
const T = Math.max(y.value.scrollLeft - m.deltaX, 0);
|
|
1704
|
+
y.value.scrollLeft = T;
|
|
1700
1705
|
}
|
|
1701
|
-
function Be(
|
|
1702
|
-
const
|
|
1703
|
-
if (
|
|
1704
|
-
const H = Array.from(
|
|
1706
|
+
function Be(m) {
|
|
1707
|
+
const T = y.value, k = n.value.length - 1;
|
|
1708
|
+
if (T) {
|
|
1709
|
+
const H = Array.from(T.children).filter((q) => q.className.indexOf("farris-tag-item") > -1).findIndex((q) => {
|
|
1705
1710
|
const G = q.getBoundingClientRect(), Z = window.getComputedStyle(q), oe = parseInt(Z["margin-left"], 10) + G.width + parseInt(Z["margin-right"], 10);
|
|
1706
|
-
return G.left + oe >
|
|
1711
|
+
return G.left + oe > m;
|
|
1707
1712
|
});
|
|
1708
1713
|
if (H > -1)
|
|
1709
1714
|
return H;
|
|
1710
1715
|
}
|
|
1711
1716
|
return k;
|
|
1712
1717
|
}
|
|
1713
|
-
function Ie(
|
|
1714
|
-
if (
|
|
1715
|
-
const k = Be(
|
|
1718
|
+
function Ie(m) {
|
|
1719
|
+
if (c.value) {
|
|
1720
|
+
const k = Be(m.clientX) + 1, q = b.value.filter((G) => G.type !== "Input");
|
|
1716
1721
|
q.splice(k, 0, {
|
|
1717
1722
|
type: "Input"
|
|
1718
|
-
}),
|
|
1723
|
+
}), b.value = q, K(() => {
|
|
1719
1724
|
B.value && B.value.focus();
|
|
1720
1725
|
});
|
|
1721
1726
|
}
|
|
1722
1727
|
}
|
|
1723
|
-
function ke(
|
|
1728
|
+
function ke(m) {
|
|
1724
1729
|
var k;
|
|
1725
|
-
|
|
1726
|
-
const
|
|
1727
|
-
if (
|
|
1728
|
-
const H =
|
|
1730
|
+
m.preventDefault(), m.stopPropagation();
|
|
1731
|
+
const T = (k = m.dataTransfer) == null ? void 0 : k.getData("Text");
|
|
1732
|
+
if (T) {
|
|
1733
|
+
const H = T.split(":"), q = H[0], G = H[1];
|
|
1729
1734
|
[...n.value].findIndex((ee) => (console.log(`${ee.value} === ${G} is ${ee.value === G}`), ee.value === G)) > -1 || U(n.value.length, q, G);
|
|
1730
1735
|
}
|
|
1731
1736
|
}
|
|
1732
|
-
function xe(
|
|
1733
|
-
|
|
1737
|
+
function xe(m) {
|
|
1738
|
+
m.preventDefault();
|
|
1734
1739
|
}
|
|
1735
|
-
return () =>
|
|
1740
|
+
return () => d("div", {
|
|
1736
1741
|
class: M.value,
|
|
1737
1742
|
onClick: Ie,
|
|
1738
1743
|
onDrop: ke,
|
|
1739
1744
|
onDragover: xe
|
|
1740
|
-
}, [
|
|
1745
|
+
}, [d("ul", {
|
|
1741
1746
|
ref: y,
|
|
1742
1747
|
class: Se.value,
|
|
1743
|
-
onWheel: (
|
|
1748
|
+
onWheel: (m) => Te(m)
|
|
1744
1749
|
}, [we()])]);
|
|
1745
1750
|
}
|
|
1746
1751
|
});
|
|
1747
|
-
function Mt(e, t,
|
|
1748
|
-
const l =
|
|
1752
|
+
function Mt(e, t, a) {
|
|
1753
|
+
const l = o(e.separator), {
|
|
1749
1754
|
changeTextBoxValue: n
|
|
1750
|
-
} =
|
|
1751
|
-
name:
|
|
1755
|
+
} = a, i = I(() => t.value ? t.value.split(l.value).map((r) => ({
|
|
1756
|
+
name: r,
|
|
1752
1757
|
selectable: !0
|
|
1753
1758
|
})) : []);
|
|
1754
|
-
function u(
|
|
1755
|
-
n(
|
|
1759
|
+
function u(r) {
|
|
1760
|
+
n(r.map((h) => h.name).join(l.value), !0);
|
|
1756
1761
|
}
|
|
1757
|
-
return () =>
|
|
1762
|
+
return () => d(Vt, {
|
|
1758
1763
|
class: "form-control",
|
|
1759
1764
|
data: i.value,
|
|
1760
1765
|
showClose: !0,
|
|
@@ -1762,25 +1767,25 @@ function Mt(e, t, o) {
|
|
|
1762
1767
|
onChange: u
|
|
1763
1768
|
}, null);
|
|
1764
1769
|
}
|
|
1765
|
-
function Lt(e, t,
|
|
1770
|
+
function Lt(e, t, a) {
|
|
1766
1771
|
const {
|
|
1767
1772
|
buttonClass: l,
|
|
1768
1773
|
onClickButton: n,
|
|
1769
1774
|
onMouseEnterButton: i,
|
|
1770
1775
|
onMouseLeaveButton: u
|
|
1771
1776
|
} = t, {
|
|
1772
|
-
enableClearButton:
|
|
1773
|
-
showClearButton:
|
|
1774
|
-
onClearValue:
|
|
1775
|
-
} =
|
|
1776
|
-
return () =>
|
|
1777
|
+
enableClearButton: r,
|
|
1778
|
+
showClearButton: h,
|
|
1779
|
+
onClearValue: f
|
|
1780
|
+
} = a;
|
|
1781
|
+
return () => d("div", {
|
|
1777
1782
|
class: l.value
|
|
1778
|
-
}, [
|
|
1783
|
+
}, [r.value && Q(d("span", {
|
|
1779
1784
|
class: "input-group-text input-group-clear",
|
|
1780
|
-
onClick:
|
|
1781
|
-
}, [
|
|
1785
|
+
onClick: f
|
|
1786
|
+
}, [d("i", {
|
|
1782
1787
|
class: "f-icon modal_close"
|
|
1783
|
-
}, null)]), [[re,
|
|
1788
|
+
}, null)]), [[re, h.value]]), e.buttonContent && d("span", {
|
|
1784
1789
|
class: "input-group-text input-group-append-button",
|
|
1785
1790
|
innerHTML: e.buttonContent,
|
|
1786
1791
|
onClick: n,
|
|
@@ -1805,33 +1810,33 @@ const Rt = {
|
|
|
1805
1810
|
},
|
|
1806
1811
|
visible: { type: Boolean, default: !1 },
|
|
1807
1812
|
class: { type: String },
|
|
1808
|
-
offsetX: { type: Object, default:
|
|
1813
|
+
offsetX: { type: Object, default: o(0) },
|
|
1809
1814
|
zIndex: { type: Number, default: -1 },
|
|
1810
1815
|
keepWidthWithReference: { type: Boolean, default: !1 },
|
|
1811
1816
|
fitContent: { type: Boolean, default: !1 },
|
|
1812
1817
|
minWidth: { type: Number, default: -1 }
|
|
1813
1818
|
};
|
|
1814
1819
|
function jt(e) {
|
|
1815
|
-
const t = e.host ? e.host : "body",
|
|
1816
|
-
return { host: t, hostLeft: l, hostTop:
|
|
1820
|
+
const t = e.host ? e.host : "body", a = I(() => t === "body" ? 0 : t ? t.getBoundingClientRect().top : 0), l = I(() => t === "body" ? 0 : t ? t.getBoundingClientRect().left : 0), n = I(() => t === "body" ? document.body.getBoundingClientRect().width : t ? t.getBoundingClientRect().width - (e.rightBoundary ? e.rightBoundary.getBoundingClientRect().width : 0) : document.body.getBoundingClientRect().width);
|
|
1821
|
+
return { host: t, hostLeft: l, hostTop: a, hostWidth: n };
|
|
1817
1822
|
}
|
|
1818
|
-
function Dt(e, t,
|
|
1823
|
+
function Dt(e, t, a, l) {
|
|
1819
1824
|
var R;
|
|
1820
|
-
const n =
|
|
1825
|
+
const n = o(0), i = o(((R = e.offsetX) == null ? void 0 : R.value) || 0), u = o(-1), r = o(-1), h = o(-1), f = o(e.placement), v = o(0), s = o(0), c = o(0), p = o(document.documentElement.scrollLeft), g = o(document.documentElement.scrollTop), { hostLeft: y, hostTop: w, hostWidth: B } = l;
|
|
1821
1826
|
W(e.offsetX, (V) => {
|
|
1822
1827
|
n.value = V - i.value;
|
|
1823
1828
|
});
|
|
1824
|
-
const
|
|
1829
|
+
const S = I(() => {
|
|
1825
1830
|
const V = {
|
|
1826
|
-
left: `${
|
|
1827
|
-
top: `${
|
|
1831
|
+
left: `${s.value}px`,
|
|
1832
|
+
top: `${c.value}px`,
|
|
1828
1833
|
transform: `translateX(${n.value}px)`
|
|
1829
1834
|
};
|
|
1830
1835
|
return e.zIndex !== -1 && (V["z-index"] = e.zIndex), u.value !== -1 && (V.width = `${u.value}px`), V;
|
|
1831
|
-
}),
|
|
1832
|
-
left: `${
|
|
1836
|
+
}), b = I(() => ({
|
|
1837
|
+
left: `${v.value}px`
|
|
1833
1838
|
}));
|
|
1834
|
-
function
|
|
1839
|
+
function x(V) {
|
|
1835
1840
|
if (V && e.keepWidthWithReference) {
|
|
1836
1841
|
const P = V.getBoundingClientRect();
|
|
1837
1842
|
u.value = Math.max(e.minWidth, P.width);
|
|
@@ -1842,22 +1847,22 @@ function Dt(e, t, o, l) {
|
|
|
1842
1847
|
return A > 0 ? A : P;
|
|
1843
1848
|
}
|
|
1844
1849
|
function F(V, P, A) {
|
|
1845
|
-
const $ =
|
|
1850
|
+
const $ = v.value, _ = P.left - y.value + P.width / 2 + p.value, N = P.top - w.value - (V.height + A.height) + g.value;
|
|
1846
1851
|
return { popoverLeft: _, popoverTop: N, arrowLeft: $ };
|
|
1847
1852
|
}
|
|
1848
1853
|
function E(V, P, A) {
|
|
1849
|
-
return P.top -
|
|
1854
|
+
return P.top - w.value + (P.height + A.height) + g.value;
|
|
1850
1855
|
}
|
|
1851
1856
|
function L(V, P) {
|
|
1852
|
-
const A = O(P, V), $ = V <= A ?
|
|
1857
|
+
const A = O(P, V), $ = V <= A ? v.value : V - A;
|
|
1853
1858
|
return { popoverLeft: Math.min(V, A), arrowLeft: $ };
|
|
1854
1859
|
}
|
|
1855
1860
|
function C(V, P, A) {
|
|
1856
|
-
const $ = P.left - y.value + P.width / 2 - (A.width / 2 - (V.left - y.value)) +
|
|
1861
|
+
const $ = P.left - y.value + P.width / 2 - (A.width / 2 - (V.left - y.value)) + p.value, { arrowLeft: _, popoverLeft: N } = L($, V), U = E(V, P, A);
|
|
1857
1862
|
return { popoverLeft: N, popoverTop: U, arrowLeft: _ };
|
|
1858
1863
|
}
|
|
1859
1864
|
function j(V, P, A) {
|
|
1860
|
-
const $ = P.left - y.value +
|
|
1865
|
+
const $ = P.left - y.value + p.value, { arrowLeft: _, popoverLeft: N } = L($, V), U = E(V, P, A);
|
|
1861
1866
|
return { popoverLeft: N, popoverTop: U, arrowLeft: _ };
|
|
1862
1867
|
}
|
|
1863
1868
|
const M = /* @__PURE__ */ new Map([
|
|
@@ -1868,124 +1873,124 @@ function Dt(e, t, o, l) {
|
|
|
1868
1873
|
function D(V) {
|
|
1869
1874
|
var N;
|
|
1870
1875
|
const P = V.getBoundingClientRect();
|
|
1871
|
-
|
|
1872
|
-
const A = t.value.getBoundingClientRect(), $ = (N =
|
|
1876
|
+
r.value = P.top, h.value = P.left;
|
|
1877
|
+
const A = t.value.getBoundingClientRect(), $ = (N = a.value) == null ? void 0 : N.getBoundingClientRect(), _ = M.get(f.value);
|
|
1873
1878
|
if (_) {
|
|
1874
1879
|
const { arrowLeft: U, popoverLeft: J, popoverTop: Y } = _($, P, A);
|
|
1875
|
-
|
|
1880
|
+
v.value = U, s.value = J, c.value = Y;
|
|
1876
1881
|
}
|
|
1877
|
-
e.keepWidthWithReference &&
|
|
1882
|
+
e.keepWidthWithReference && x(V);
|
|
1878
1883
|
}
|
|
1879
1884
|
function X(V) {
|
|
1880
1885
|
if (V) {
|
|
1881
1886
|
const P = V.getBoundingClientRect();
|
|
1882
|
-
(P.left !==
|
|
1887
|
+
(P.left !== h.value || P.top !== r.value) && D(V);
|
|
1883
1888
|
}
|
|
1884
1889
|
}
|
|
1885
1890
|
return {
|
|
1886
|
-
arrowStyle:
|
|
1887
|
-
popoverStyle:
|
|
1888
|
-
position:
|
|
1891
|
+
arrowStyle: b,
|
|
1892
|
+
popoverStyle: S,
|
|
1893
|
+
position: f,
|
|
1889
1894
|
popoverWidth: u,
|
|
1890
|
-
fitToReference:
|
|
1895
|
+
fitToReference: x,
|
|
1891
1896
|
followToReferencePosition: X,
|
|
1892
1897
|
locateToReference: D
|
|
1893
1898
|
};
|
|
1894
1899
|
}
|
|
1895
|
-
function At(e, t,
|
|
1896
|
-
const
|
|
1897
|
-
let
|
|
1898
|
-
function
|
|
1899
|
-
|
|
1900
|
-
}
|
|
1901
|
-
|
|
1902
|
-
if (!n.value.contains(
|
|
1900
|
+
function At(e, t, a, l, n, i, u) {
|
|
1901
|
+
const r = o(e.visible), h = I(() => r.value), { fitToReference: f, locateToReference: v } = u;
|
|
1902
|
+
let s;
|
|
1903
|
+
function c() {
|
|
1904
|
+
r.value = !1, document.body.removeEventListener("click", s), t.emit("hidden");
|
|
1905
|
+
}
|
|
1906
|
+
s = (g) => {
|
|
1907
|
+
if (!n.value.contains(g.target)) {
|
|
1903
1908
|
const y = n.value.closest(".popover");
|
|
1904
|
-
y && y.removeEventListener("click",
|
|
1909
|
+
y && y.removeEventListener("click", s), c();
|
|
1905
1910
|
}
|
|
1906
1911
|
};
|
|
1907
|
-
async function
|
|
1908
|
-
if (l.value &&
|
|
1909
|
-
|
|
1910
|
-
const y =
|
|
1911
|
-
y && y.addEventListener("click",
|
|
1912
|
+
async function p(g) {
|
|
1913
|
+
if (l.value && a.value && g) {
|
|
1914
|
+
r.value = !0, n.value = g, await K(), v(g), i.value && f(g), document.body.addEventListener("click", s);
|
|
1915
|
+
const y = g.closest(".popover");
|
|
1916
|
+
y && y.addEventListener("click", s), t.emit("shown");
|
|
1912
1917
|
}
|
|
1913
1918
|
}
|
|
1914
|
-
return t.expose({ hide:
|
|
1919
|
+
return t.expose({ hide: c, show: p, shown: h }), { showPopover: r, hidePopverOnClickBodyHandler: s };
|
|
1915
1920
|
}
|
|
1916
|
-
function Et(e, t,
|
|
1917
|
-
const { popoverWidth: i, fitToReference: u, followToReferencePosition:
|
|
1918
|
-
function
|
|
1919
|
-
if (
|
|
1920
|
-
|
|
1921
|
-
const
|
|
1922
|
-
l.value &&
|
|
1921
|
+
function Et(e, t, a, l, n) {
|
|
1922
|
+
const { popoverWidth: i, fitToReference: u, followToReferencePosition: r } = n;
|
|
1923
|
+
function h() {
|
|
1924
|
+
if (a.value) {
|
|
1925
|
+
r(a.value);
|
|
1926
|
+
const f = a.value.getBoundingClientRect();
|
|
1927
|
+
l.value && f.width !== i.value && u(a.value);
|
|
1923
1928
|
}
|
|
1924
1929
|
}
|
|
1925
|
-
return { onResize:
|
|
1930
|
+
return { onResize: h };
|
|
1926
1931
|
}
|
|
1927
1932
|
const Ht = /* @__PURE__ */ z({
|
|
1928
1933
|
name: "FPopover",
|
|
1929
1934
|
props: Rt,
|
|
1930
1935
|
emits: ["shown", "hidden"],
|
|
1931
1936
|
setup(e, t) {
|
|
1932
|
-
const
|
|
1933
|
-
host:
|
|
1934
|
-
} =
|
|
1935
|
-
position:
|
|
1936
|
-
arrowStyle:
|
|
1937
|
-
popoverStyle:
|
|
1938
|
-
fitToReference:
|
|
1939
|
-
locateToReference:
|
|
1940
|
-
} =
|
|
1937
|
+
const a = o(), l = o(), n = o(e.reference), i = o(e.keepWidthWithReference), u = I(() => !!e.title), r = jt(e), {
|
|
1938
|
+
host: h
|
|
1939
|
+
} = r, f = Dt(e, a, l, r), {
|
|
1940
|
+
position: v,
|
|
1941
|
+
arrowStyle: s,
|
|
1942
|
+
popoverStyle: c,
|
|
1943
|
+
fitToReference: p,
|
|
1944
|
+
locateToReference: g
|
|
1945
|
+
} = f, {
|
|
1941
1946
|
showPopover: y,
|
|
1942
|
-
hidePopverOnClickBodyHandler:
|
|
1943
|
-
} = At(e, t,
|
|
1947
|
+
hidePopverOnClickBodyHandler: w
|
|
1948
|
+
} = At(e, t, a, l, n, i, f), {
|
|
1944
1949
|
onResize: B
|
|
1945
|
-
} = Et(e, t, n, i,
|
|
1946
|
-
const
|
|
1950
|
+
} = Et(e, t, n, i, f), S = I(() => {
|
|
1951
|
+
const x = `popover in popover-${v.value}`, O = `bs-popover-${v.value}`, F = {
|
|
1947
1952
|
"popover-fitcontent": e.fitContent
|
|
1948
1953
|
};
|
|
1949
|
-
return F[
|
|
1950
|
-
}),
|
|
1954
|
+
return F[x] = !0, F[O] = !0, (e.class || "").split(" ").reduce((L, C) => (L[C] = !0, L), F), F;
|
|
1955
|
+
}), b = I(() => ({
|
|
1951
1956
|
"popover-content": !0,
|
|
1952
1957
|
"popover-body": !0
|
|
1953
1958
|
}));
|
|
1954
1959
|
return de(() => {
|
|
1955
|
-
e.reference &&
|
|
1960
|
+
e.reference && g(n.value), i.value && p(n.value), window.addEventListener("resize", B);
|
|
1956
1961
|
}), ce(() => {
|
|
1957
|
-
document.body.removeEventListener("click",
|
|
1958
|
-
}), () =>
|
|
1959
|
-
to:
|
|
1962
|
+
document.body.removeEventListener("click", w), window.removeEventListener("resize", B);
|
|
1963
|
+
}), () => d(se, {
|
|
1964
|
+
to: h
|
|
1960
1965
|
}, {
|
|
1961
1966
|
default: () => {
|
|
1962
|
-
var
|
|
1963
|
-
return [Q(
|
|
1967
|
+
var x;
|
|
1968
|
+
return [Q(d("div", {
|
|
1964
1969
|
ref: l,
|
|
1965
|
-
class:
|
|
1966
|
-
style:
|
|
1970
|
+
class: S.value,
|
|
1971
|
+
style: c.value,
|
|
1967
1972
|
onClick: (O) => {
|
|
1968
1973
|
O.stopPropagation();
|
|
1969
1974
|
}
|
|
1970
|
-
}, [
|
|
1971
|
-
ref:
|
|
1975
|
+
}, [d("div", {
|
|
1976
|
+
ref: a,
|
|
1972
1977
|
class: "popover-arrow arrow",
|
|
1973
|
-
style:
|
|
1974
|
-
}, null), u.value &&
|
|
1978
|
+
style: s.value
|
|
1979
|
+
}, null), u.value && d("h3", {
|
|
1975
1980
|
class: "popover-title popover-header"
|
|
1976
|
-
}, [e.title]),
|
|
1977
|
-
class:
|
|
1978
|
-
}, [t.slots.default && ((
|
|
1981
|
+
}, [e.title]), d("div", {
|
|
1982
|
+
class: b.value
|
|
1983
|
+
}, [t.slots.default && ((x = t.slots) == null ? void 0 : x.default())])]), [[re, y.value]])];
|
|
1979
1984
|
}
|
|
1980
1985
|
});
|
|
1981
1986
|
}
|
|
1982
1987
|
});
|
|
1983
|
-
function Wt(e, t,
|
|
1984
|
-
const l =
|
|
1988
|
+
function Wt(e, t, a) {
|
|
1989
|
+
const l = o(e.popupMinWidth), {
|
|
1985
1990
|
hidePopup: n,
|
|
1986
1991
|
popoverRef: i
|
|
1987
|
-
} =
|
|
1988
|
-
return () =>
|
|
1992
|
+
} = a;
|
|
1993
|
+
return () => d(Ht, {
|
|
1989
1994
|
ref: i,
|
|
1990
1995
|
visible: !0,
|
|
1991
1996
|
placement: "bottom-left",
|
|
@@ -1998,8 +2003,8 @@ function Wt(e, t, o) {
|
|
|
1998
2003
|
onHidden: n
|
|
1999
2004
|
}, {
|
|
2000
2005
|
default: () => {
|
|
2001
|
-
var u,
|
|
2002
|
-
return [(
|
|
2006
|
+
var u, r;
|
|
2007
|
+
return [(r = (u = t.slots).default) == null ? void 0 : r.call(u)];
|
|
2003
2008
|
}
|
|
2004
2009
|
});
|
|
2005
2010
|
}
|
|
@@ -2008,17 +2013,17 @@ const _t = /* @__PURE__ */ z({
|
|
|
2008
2013
|
props: he,
|
|
2009
2014
|
emits: ["updateExtendInfo", "clear", "change", "click", "clickButton", "blur", "focus", "mouseEnterIcon", "mouseLeaveIcon", "keyup", "keydown", "inputClick", "input", "update:modelValue"],
|
|
2010
2015
|
setup(e, t) {
|
|
2011
|
-
const
|
|
2016
|
+
const a = o(), l = o(e.customClass), n = o(e.modelValue), i = xt(e, t, a), {
|
|
2012
2017
|
shouldPopupContent: u,
|
|
2013
|
-
hidePopup:
|
|
2014
|
-
} = i,
|
|
2015
|
-
hasFocusedTextBox:
|
|
2016
|
-
commitValue:
|
|
2017
|
-
inputGroupClass:
|
|
2018
|
-
} =
|
|
2018
|
+
hidePopup: r
|
|
2019
|
+
} = i, h = Bt(e, t, a, i), f = o(""), v = kt(e, t, n, f, i), {
|
|
2020
|
+
hasFocusedTextBox: s,
|
|
2021
|
+
commitValue: c,
|
|
2022
|
+
inputGroupClass: p
|
|
2023
|
+
} = v, g = It(e, t, n, s, f, v), {
|
|
2019
2024
|
onMouseEnterTextBox: y,
|
|
2020
|
-
onMouseLeaveTextBox:
|
|
2021
|
-
} =
|
|
2025
|
+
onMouseLeaveTextBox: w
|
|
2026
|
+
} = g, B = I(() => {
|
|
2022
2027
|
const E = {
|
|
2023
2028
|
"f-button-edit": !0,
|
|
2024
2029
|
"f-cmp-inputgroup": !0,
|
|
@@ -2026,116 +2031,116 @@ const _t = /* @__PURE__ */ z({
|
|
|
2026
2031
|
};
|
|
2027
2032
|
return l.value && l.value.split(" ").reduce((L, C) => (L[C] = !0, L), E), E;
|
|
2028
2033
|
});
|
|
2029
|
-
function
|
|
2030
|
-
return e.multiSelect && e.inputType === "tag" ? Mt(e, n,
|
|
2034
|
+
function S() {
|
|
2035
|
+
return e.multiSelect && e.inputType === "tag" ? Mt(e, n, v) : Ft(e, n, v);
|
|
2031
2036
|
}
|
|
2032
|
-
let
|
|
2037
|
+
let b = S();
|
|
2033
2038
|
W([() => e.multiSelect, () => e.inputType], () => {
|
|
2034
|
-
|
|
2039
|
+
b = S();
|
|
2035
2040
|
});
|
|
2036
|
-
const
|
|
2037
|
-
commitValue:
|
|
2038
|
-
elementRef:
|
|
2039
|
-
hidePopup:
|
|
2041
|
+
const x = Lt(e, h, g), O = Wt(e, t, i), F = {
|
|
2042
|
+
commitValue: c,
|
|
2043
|
+
elementRef: a,
|
|
2044
|
+
hidePopup: r
|
|
2040
2045
|
};
|
|
2041
2046
|
return de(() => {
|
|
2042
|
-
|
|
2043
|
-
}), t.expose(F), () =>
|
|
2044
|
-
ref:
|
|
2047
|
+
a.value.componentInstance = F;
|
|
2048
|
+
}), t.expose(F), () => d(te, null, [d("div", Me(t.attrs, {
|
|
2049
|
+
ref: a,
|
|
2045
2050
|
class: B.value,
|
|
2046
2051
|
id: e.id
|
|
2047
|
-
}), [
|
|
2048
|
-
class:
|
|
2052
|
+
}), [d("div", {
|
|
2053
|
+
class: p.value,
|
|
2049
2054
|
onMouseenter: y,
|
|
2050
|
-
onMouseleave:
|
|
2051
|
-
}, [
|
|
2055
|
+
onMouseleave: w
|
|
2056
|
+
}, [b(), x()])]), u.value && O()]);
|
|
2052
2057
|
}
|
|
2053
2058
|
});
|
|
2054
2059
|
function $t(e) {
|
|
2055
|
-
const t =
|
|
2056
|
-
function i(
|
|
2057
|
-
const
|
|
2058
|
-
return l.value.filter((
|
|
2059
|
-
}
|
|
2060
|
-
function u(
|
|
2061
|
-
const
|
|
2062
|
-
t.value = n.value ?
|
|
2063
|
-
}
|
|
2064
|
-
function s
|
|
2065
|
-
const
|
|
2066
|
-
return l.value.filter((
|
|
2067
|
-
}
|
|
2068
|
-
function
|
|
2069
|
-
const
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2060
|
+
const t = o(""), a = o(e.modelValue), l = o(e.data || []), n = o(e.editable);
|
|
2061
|
+
function i(s) {
|
|
2062
|
+
const c = s.split(e.separator).map((g) => [g, !0]), p = new Map(c);
|
|
2063
|
+
return l.value.filter((g) => p.has(g[e.valueField]));
|
|
2064
|
+
}
|
|
2065
|
+
function u(s) {
|
|
2066
|
+
const c = i(s).map((p) => p[e.textField]).join(e.separator);
|
|
2067
|
+
t.value = n.value ? c || s : c;
|
|
2068
|
+
}
|
|
2069
|
+
function r(s) {
|
|
2070
|
+
const c = s.split(e.separator).map((g) => [g, !0]), p = new Map(c);
|
|
2071
|
+
return l.value.filter((g) => p.has(g[e.textField]));
|
|
2072
|
+
}
|
|
2073
|
+
function h(s) {
|
|
2074
|
+
const c = {};
|
|
2075
|
+
return c[e.idField] = s, c[e.textField] = s, [c];
|
|
2076
|
+
}
|
|
2077
|
+
function f(s) {
|
|
2078
|
+
let c = r(s);
|
|
2079
|
+
const p = c && c.length > 0;
|
|
2080
|
+
return n.value && !p && (c = h(s)), c;
|
|
2081
|
+
}
|
|
2082
|
+
function v() {
|
|
2083
|
+
const { url: s, method: c = "GET", headers: p = {}, body: g = null } = e.remote;
|
|
2084
|
+
fetch(s, { method: c, headers: p, body: g }).then((w) => {
|
|
2085
|
+
if (w.status === 200)
|
|
2086
|
+
return w.json();
|
|
2087
|
+
throw new Error(w.statusText);
|
|
2088
|
+
}).then((w) => {
|
|
2089
|
+
l.value = w;
|
|
2090
|
+
}).catch((w) => {
|
|
2091
|
+
console.error(w);
|
|
2078
2092
|
});
|
|
2079
2093
|
}
|
|
2080
|
-
return e.remote &&
|
|
2094
|
+
return e.remote && v(), W(() => e.data, () => {
|
|
2081
2095
|
l.value = e.data;
|
|
2082
|
-
}), W([l], ([
|
|
2096
|
+
}), W([l], ([s]) => {
|
|
2083
2097
|
if (e.modelValue) {
|
|
2084
|
-
const
|
|
2085
|
-
|
|
2098
|
+
const c = s.find((p) => p[e.valueField] === e.modelValue);
|
|
2099
|
+
c && (t.value = c[e.textField]);
|
|
2086
2100
|
}
|
|
2087
|
-
}), W(() => e.modelValue, (
|
|
2088
|
-
|
|
2089
|
-
}), u(e.modelValue), { dataSource: l, displayText: t, editable: n, modelValue:
|
|
2101
|
+
}), W(() => e.modelValue, (s) => {
|
|
2102
|
+
a.value = s, u(s);
|
|
2103
|
+
}), u(e.modelValue), { dataSource: l, displayText: t, editable: n, modelValue: a, getItemsByDisplayText: r, getItemsByValue: i, getSelectedItemsByDisplayText: f };
|
|
2090
2104
|
}
|
|
2091
2105
|
const ue = /* @__PURE__ */ z({
|
|
2092
2106
|
name: "FComboList",
|
|
2093
2107
|
props: me,
|
|
2094
2108
|
emits: ["clear", "update:modelValue", "change"],
|
|
2095
2109
|
setup(e, t) {
|
|
2096
|
-
const
|
|
2097
|
-
dataSource:
|
|
2098
|
-
displayText:
|
|
2099
|
-
editable:
|
|
2100
|
-
modelValue:
|
|
2101
|
-
|
|
2102
|
-
} = $t(e),
|
|
2103
|
-
function
|
|
2104
|
-
!
|
|
2110
|
+
const a = o(), l = o(e.disabled), n = o(e.enableClear), i = o(e.enableSearch), u = o(e.readonly), {
|
|
2111
|
+
dataSource: r,
|
|
2112
|
+
displayText: h,
|
|
2113
|
+
editable: f,
|
|
2114
|
+
modelValue: v,
|
|
2115
|
+
getSelectedItemsByDisplayText: s
|
|
2116
|
+
} = $t(e), c = I(() => e.multiSelect);
|
|
2117
|
+
function p() {
|
|
2118
|
+
!c.value && a.value && a.value.hidePopup();
|
|
2105
2119
|
}
|
|
2106
|
-
function
|
|
2107
|
-
|
|
2120
|
+
function g(S) {
|
|
2121
|
+
h.value = S.map((b) => b[e.textField]).join(e.separator), v.value = S.map((b) => b[e.valueField]).join(e.separator), t.emit("update:modelValue", v.value), t.emit("change", S), p();
|
|
2108
2122
|
}
|
|
2109
|
-
function y(
|
|
2110
|
-
|
|
2123
|
+
function y(S) {
|
|
2124
|
+
v.value = "", t.emit("update:modelValue", ""), t.emit("clear");
|
|
2111
2125
|
}
|
|
2112
|
-
function
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
S[e.idField] = h, S[e.textField] = h, t.emit("change", [S]);
|
|
2126
|
+
function w(S) {
|
|
2127
|
+
const b = s(S);
|
|
2128
|
+
g(b);
|
|
2116
2129
|
}
|
|
2117
|
-
function B(
|
|
2118
|
-
|
|
2119
|
-
T(h);
|
|
2120
|
-
return;
|
|
2121
|
-
}
|
|
2122
|
-
const S = d(h);
|
|
2123
|
-
m(S);
|
|
2124
|
-
}
|
|
2125
|
-
function x() {
|
|
2126
|
-
return p.value;
|
|
2130
|
+
function B() {
|
|
2131
|
+
return h.value;
|
|
2127
2132
|
}
|
|
2128
2133
|
return t.expose({
|
|
2129
|
-
getDisplayText:
|
|
2130
|
-
}), W([() => e.disabled, () => e.editable, () => e.enableClear, () => e.enableSearch, () => e.readonly], ([
|
|
2131
|
-
l.value =
|
|
2132
|
-
}), () =>
|
|
2133
|
-
ref:
|
|
2134
|
+
getDisplayText: B
|
|
2135
|
+
}), W([() => e.disabled, () => e.editable, () => e.enableClear, () => e.enableSearch, () => e.readonly], ([S, b, x, O, F]) => {
|
|
2136
|
+
l.value = S, f.value = b, n.value = x, i.value = O, u.value = F;
|
|
2137
|
+
}), () => d(_t, {
|
|
2138
|
+
ref: a,
|
|
2134
2139
|
id: e.id,
|
|
2135
2140
|
disable: l.value,
|
|
2136
2141
|
readonly: u.value,
|
|
2137
2142
|
forcePlaceholder: e.forcePlaceholder,
|
|
2138
|
-
editable:
|
|
2143
|
+
editable: f.value,
|
|
2139
2144
|
buttonContent: e.dropDownIcon,
|
|
2140
2145
|
placeholder: e.placeholder,
|
|
2141
2146
|
enableClear: n.value,
|
|
@@ -2144,20 +2149,21 @@ const ue = /* @__PURE__ */ z({
|
|
|
2144
2149
|
enableTitle: e.enableTitle,
|
|
2145
2150
|
multiSelect: e.multiSelect,
|
|
2146
2151
|
inputType: e.multiSelect ? "tag" : "text",
|
|
2147
|
-
modelValue:
|
|
2148
|
-
"onUpdate:modelValue": (
|
|
2152
|
+
modelValue: h.value,
|
|
2153
|
+
"onUpdate:modelValue": (S) => h.value = S,
|
|
2149
2154
|
onClear: y,
|
|
2150
|
-
onChange:
|
|
2155
|
+
onChange: w
|
|
2151
2156
|
}, {
|
|
2152
|
-
default: () => [
|
|
2157
|
+
default: () => [d(ct, {
|
|
2153
2158
|
idField: e.idField,
|
|
2154
2159
|
valueField: e.valueField,
|
|
2155
2160
|
textField: e.textField,
|
|
2156
|
-
dataSource:
|
|
2157
|
-
selectedValues:
|
|
2161
|
+
dataSource: r.value,
|
|
2162
|
+
selectedValues: v.value,
|
|
2158
2163
|
multiSelect: e.multiSelect,
|
|
2159
2164
|
enableSearch: i.value,
|
|
2160
|
-
|
|
2165
|
+
height: e.maxHeight,
|
|
2166
|
+
onSelectionChange: g
|
|
2161
2167
|
}, null)]
|
|
2162
2168
|
});
|
|
2163
2169
|
}
|
|
@@ -2167,97 +2173,97 @@ const ie = /* @__PURE__ */ z({
|
|
|
2167
2173
|
props: Le,
|
|
2168
2174
|
emits: ["change"],
|
|
2169
2175
|
setup(e, t) {
|
|
2170
|
-
const
|
|
2176
|
+
const a = o(e.items), l = o("排序列"), n = o("排序方式"), i = o("添加排序列"), u = [{
|
|
2171
2177
|
id: "asc",
|
|
2172
2178
|
name: "升序"
|
|
2173
2179
|
}, {
|
|
2174
2180
|
id: "desc",
|
|
2175
2181
|
name: "降序"
|
|
2176
|
-
}],
|
|
2177
|
-
function
|
|
2178
|
-
const
|
|
2179
|
-
|
|
2182
|
+
}], r = o(/* @__PURE__ */ new Map());
|
|
2183
|
+
function h() {
|
|
2184
|
+
const w = a.value.map((B) => [B.id, !0]);
|
|
2185
|
+
r.value = new Map(w);
|
|
2180
2186
|
}
|
|
2181
|
-
|
|
2182
|
-
const
|
|
2187
|
+
h();
|
|
2188
|
+
const f = I(() => e.dataSource.map((w) => (w.disabled = r.value.has(w.id), w))), v = I(() => ({
|
|
2183
2189
|
"f-order": !0
|
|
2184
2190
|
}));
|
|
2185
|
-
function
|
|
2186
|
-
|
|
2191
|
+
function s(w) {
|
|
2192
|
+
a.value = a.value.filter((B) => B.id !== w.id), h(), t.emit("change", a.value);
|
|
2187
2193
|
}
|
|
2188
|
-
function
|
|
2189
|
-
|
|
2194
|
+
function c() {
|
|
2195
|
+
a.value = [...a.value, {
|
|
2190
2196
|
id: Date.now().toString(),
|
|
2191
2197
|
name: "",
|
|
2192
2198
|
order: "asc"
|
|
2193
|
-
}],
|
|
2199
|
+
}], h(), t.emit("change", a.value);
|
|
2194
2200
|
}
|
|
2195
|
-
function
|
|
2196
|
-
|
|
2201
|
+
function p(w) {
|
|
2202
|
+
h(), t.emit("change", a.value);
|
|
2197
2203
|
}
|
|
2198
|
-
function
|
|
2199
|
-
if (
|
|
2204
|
+
function g(w) {
|
|
2205
|
+
if (w && w.length) {
|
|
2200
2206
|
const B = /* @__PURE__ */ new Map();
|
|
2201
|
-
|
|
2207
|
+
w.reduce((S, b) => (S.set(b.id, b), S), B), a.value = w.map((S) => B.get(S.id)), t.emit("change", a.value);
|
|
2202
2208
|
}
|
|
2203
2209
|
}
|
|
2204
2210
|
function y() {
|
|
2205
|
-
return
|
|
2211
|
+
return d(fe, {
|
|
2206
2212
|
style: "flex:1",
|
|
2207
|
-
data:
|
|
2213
|
+
data: a.value,
|
|
2208
2214
|
draggable: !0,
|
|
2209
2215
|
view: "DraggableView",
|
|
2210
2216
|
"keep-order": !0,
|
|
2211
2217
|
itemClass: "f-order-item",
|
|
2212
|
-
onRemoveItem:
|
|
2213
|
-
onChange:
|
|
2218
|
+
onRemoveItem: s,
|
|
2219
|
+
onChange: g
|
|
2214
2220
|
}, {
|
|
2215
|
-
header: () =>
|
|
2221
|
+
header: () => d("div", {
|
|
2216
2222
|
class: "f-order-header"
|
|
2217
|
-
}, [
|
|
2223
|
+
}, [d("span", {
|
|
2218
2224
|
class: "f-order-header-order-field"
|
|
2219
|
-
}, [l.value]),
|
|
2225
|
+
}, [l.value]), d("span", {
|
|
2220
2226
|
class: "f-order-header-order-type"
|
|
2221
2227
|
}, [n.value])]),
|
|
2222
|
-
itemContent: (
|
|
2228
|
+
itemContent: (w) => d("div", {
|
|
2223
2229
|
class: "f-order-item-content"
|
|
2224
|
-
}, [
|
|
2230
|
+
}, [d(ue, {
|
|
2225
2231
|
class: "f-order-item-content-order-field",
|
|
2226
|
-
data:
|
|
2232
|
+
data: f.value,
|
|
2227
2233
|
valueField: "id",
|
|
2228
2234
|
textField: "name",
|
|
2229
2235
|
idField: "id",
|
|
2230
|
-
modelValue:
|
|
2231
|
-
"onUpdate:modelValue": (B) =>
|
|
2232
|
-
onChange:
|
|
2233
|
-
onClear:
|
|
2234
|
-
}, null),
|
|
2236
|
+
modelValue: w.id,
|
|
2237
|
+
"onUpdate:modelValue": (B) => w.id = B,
|
|
2238
|
+
onChange: p,
|
|
2239
|
+
onClear: p
|
|
2240
|
+
}, null), d(ue, {
|
|
2235
2241
|
class: "f-order-item-content-order-type",
|
|
2236
2242
|
data: u,
|
|
2237
2243
|
valueField: "id",
|
|
2238
2244
|
textField: "name",
|
|
2239
2245
|
idField: "id",
|
|
2240
|
-
modelValue:
|
|
2241
|
-
"onUpdate:modelValue": (B) =>
|
|
2242
|
-
onChange:
|
|
2246
|
+
modelValue: w.order,
|
|
2247
|
+
"onUpdate:modelValue": (B) => w.order = B,
|
|
2248
|
+
onChange: p
|
|
2243
2249
|
}, null)]),
|
|
2244
|
-
footer: () =>
|
|
2250
|
+
footer: () => d("div", {
|
|
2245
2251
|
class: "f-order-footer"
|
|
2246
|
-
}, [
|
|
2252
|
+
}, [d(Ue, {
|
|
2247
2253
|
type: "link",
|
|
2248
2254
|
class: "f-order-add-button",
|
|
2249
|
-
onClick:
|
|
2255
|
+
onClick: c
|
|
2250
2256
|
}, {
|
|
2251
|
-
default: () =>
|
|
2257
|
+
default: () => d(te, null, [d("span", {
|
|
2252
2258
|
class: "f-order-add-icon"
|
|
2253
|
-
}, [
|
|
2259
|
+
}, [d("i", {
|
|
2254
2260
|
class: "f-icon f-icon-add"
|
|
2255
2261
|
}, null)]), i.value])
|
|
2256
2262
|
})])
|
|
2257
2263
|
});
|
|
2258
2264
|
}
|
|
2259
|
-
return () =>
|
|
2260
|
-
class:
|
|
2265
|
+
return () => d("div", {
|
|
2266
|
+
class: v.value
|
|
2261
2267
|
}, [y()]);
|
|
2262
2268
|
}
|
|
2263
2269
|
}), zt = {
|