bt-core-app 2.2.6 → 2.2.7
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/dist/bt-core/core/node_modules/vuetify/lib/components/transitions/index.mjs +10 -11
- package/dist/components/BT-Background-Task.vue.mjs +44 -46
- package/dist/components/BT-Blade-Item.vue.mjs +64 -63
- package/dist/components/BT-Blade-Items.vue.mjs +2 -2
- package/dist/components/BT-Blade-Items.vue2.mjs +239 -238
- package/dist/components/BT-Blade-Steps.vue.mjs +2 -2
- package/dist/components/BT-Blade-Steps.vue2.mjs +457 -456
- package/dist/components/BT-Blade.vue.mjs +187 -189
- package/dist/components/BT-Camera-Overlay.vue.mjs +139 -141
- package/dist/components/BT-Cron.vue.mjs +127 -126
- package/dist/components/BT-Dialog-Select.vue.mjs +91 -90
- package/dist/components/BT-Drag-Counter.vue.mjs +2 -2
- package/dist/components/BT-Drag-Counter.vue2.mjs +87 -89
- package/dist/components/BT-Entity.vue.mjs +79 -81
- package/dist/components/BT-Error.vue.mjs +23 -25
- package/dist/components/BT-Form-Builder.vue.mjs +221 -220
- package/dist/components/BT-Form-Field.vue.mjs +67 -66
- package/dist/components/BT-Form.vue.mjs +192 -191
- package/dist/components/BT-Header-Option.vue.mjs +21 -20
- package/dist/components/BT-Numpad.vue.mjs +143 -145
- package/dist/components/BT-Select-List-Box.vue.mjs +270 -272
- package/dist/components/BT-Signature-Overlay.vue.mjs +107 -109
- package/dist/components/BT-Signature.vue.mjs +91 -93
- package/dist/components/BT-Slider.vue.mjs +91 -93
- package/dist/components/BT-Square-Check.vue.mjs +66 -68
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,35 +1,36 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as N, ref as h, computed as T, onUnmounted as O, resolveComponent as w, openBlock as m, createBlock as c, unref as l, withCtx as u, createVNode as r, createElementBlock as F, createTextVNode as B, toDisplayString as E, withModifiers as V, createCommentVNode as f, createElementVNode as R, createSlots as k, Fragment as U, renderList as W } from "vue";
|
|
2
2
|
import { useNested as G } from "../composables/nested.mjs";
|
|
3
3
|
import { registerDialog as I } from "../composables/dialog-items.mjs";
|
|
4
4
|
import { useList as A } from "../composables/list.mjs";
|
|
5
|
-
import { isLengthyArray as D, isArrayOfLength as
|
|
6
|
-
import
|
|
7
|
-
import { VDialog as
|
|
8
|
-
import { VCard as
|
|
9
|
-
import { VCardTitle as
|
|
10
|
-
import { VSpacer as
|
|
11
|
-
import { VBtn as
|
|
12
|
-
import { VTextField as
|
|
13
|
-
import { VList as
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
|
|
5
|
+
import { isLengthyArray as D, isArrayOfLength as Y } from "../composables/helpers.mjs";
|
|
6
|
+
import j from "./BT-Loader.vue.mjs";
|
|
7
|
+
import { VDialog as q } from "../bt-core/core/node_modules/vuetify/lib/components/VDialog/VDialog.mjs";
|
|
8
|
+
import { VCard as z } from "../bt-core/core/node_modules/vuetify/lib/components/VCard/VCard.mjs";
|
|
9
|
+
import { VCardTitle as H } from "../bt-core/core/node_modules/vuetify/lib/components/VCard/VCardTitle.mjs";
|
|
10
|
+
import { VSpacer as J } from "../bt-core/core/node_modules/vuetify/lib/components/VGrid/VSpacer.mjs";
|
|
11
|
+
import { VBtn as x } from "../bt-core/core/node_modules/vuetify/lib/components/VBtn/VBtn.mjs";
|
|
12
|
+
import { VTextField as K } from "../bt-core/core/node_modules/vuetify/lib/components/VTextField/VTextField.mjs";
|
|
13
|
+
import { VList as Q } from "../bt-core/core/node_modules/vuetify/lib/components/VList/VList.mjs";
|
|
14
|
+
import { VSlideYTransition as X } from "../bt-core/core/node_modules/vuetify/lib/components/transitions/index.mjs";
|
|
15
|
+
import { VListItem as Z } from "../bt-core/core/node_modules/vuetify/lib/components/VList/VListItem.mjs";
|
|
16
|
+
import { VListItemTitle as ee } from "../bt-core/core/node_modules/vuetify/lib/components/VList/VListItemTitle.mjs";
|
|
17
|
+
import { VListItemSubtitle as te } from "../bt-core/core/node_modules/vuetify/lib/components/VList/VListItemSubtitle.mjs";
|
|
18
|
+
const le = {
|
|
18
19
|
key: 0,
|
|
19
20
|
class: "d-flex align-center"
|
|
20
|
-
},
|
|
21
|
+
}, ie = { class: "d-flex align-center" }, Se = /* @__PURE__ */ N({
|
|
21
22
|
__name: "BT-Dialog-Select",
|
|
22
|
-
setup(
|
|
23
|
-
const
|
|
23
|
+
setup(ae) {
|
|
24
|
+
const v = h(!1), e = h({}), o = h([]), { getValue: C } = G();
|
|
24
25
|
let d, n = A(e.value);
|
|
25
|
-
const
|
|
26
|
+
const S = T(() => ({
|
|
26
27
|
itemText: e.value.itemTitle,
|
|
27
28
|
prefix: e.value.itemTitlePrefix,
|
|
28
29
|
textFilter: e.value.itemTitleFilter,
|
|
29
30
|
textFunction: e.value.itemTitleFunction,
|
|
30
31
|
truncate: e.value.itemTitleTruncate,
|
|
31
32
|
value: e.value.itemTitleProp ?? e.value.itemTitle
|
|
32
|
-
})),
|
|
33
|
+
})), b = T(() => {
|
|
33
34
|
let t = {
|
|
34
35
|
itemText: e.value.itemSubtitle,
|
|
35
36
|
prefix: e.value.itemSubtitlePrefix,
|
|
@@ -39,7 +40,7 @@ const te = {
|
|
|
39
40
|
value: e.value.itemSubtitleProp ?? e.value.itemSubtitle
|
|
40
41
|
};
|
|
41
42
|
return t.itemText != null || t.textFilter != null || t.textFunction != null || t.value != null ? t : void 0;
|
|
42
|
-
}),
|
|
43
|
+
}), y = T(() => {
|
|
43
44
|
let t = {
|
|
44
45
|
itemText: e.value.itemActionTitle,
|
|
45
46
|
prefix: e.value.itemActionPrefix,
|
|
@@ -49,29 +50,29 @@ const te = {
|
|
|
49
50
|
value: e.value.itemActionProp ?? e.value.itemActionTitle
|
|
50
51
|
};
|
|
51
52
|
return t.itemText != null || t.textFilter != null || t.textFunction != null || t.value != null ? t : void 0;
|
|
52
|
-
}),
|
|
53
|
+
}), _ = I({
|
|
53
54
|
dialogType: "items",
|
|
54
55
|
open: (t, a) => {
|
|
55
56
|
t.height ?? (t.height = "65vh"), t.maxWidth ?? (t.maxWidth = "350px"), t.cancelText ?? (t.cancelText = "Cancel"), t.confirmText ?? (t.confirmText = "Confirm"), t.onDisabled ?? (t.onDisabled = () => !1), e.value = t;
|
|
56
|
-
const s = t.selector ?? ((
|
|
57
|
-
t.onGetSuccessAsync = async (
|
|
57
|
+
const s = t.selector ?? ((i) => i.id);
|
|
58
|
+
t.onGetSuccessAsync = async (i) => {
|
|
58
59
|
if (t.selected != null)
|
|
59
60
|
if (Array.isArray(t.selected))
|
|
60
|
-
o.value =
|
|
61
|
+
o.value = i.data.filter((p) => {
|
|
61
62
|
var g;
|
|
62
|
-
return (g = t.selected) == null ? void 0 : g.some((
|
|
63
|
+
return (g = t.selected) == null ? void 0 : g.some((M) => s(M) == s(p));
|
|
63
64
|
});
|
|
64
65
|
else {
|
|
65
|
-
const
|
|
66
|
-
|
|
66
|
+
const p = i.data.filter((g) => s(g) == s(t.selected));
|
|
67
|
+
p != null && (o.value = [p]);
|
|
67
68
|
}
|
|
68
69
|
else
|
|
69
70
|
o.value = [];
|
|
70
|
-
return
|
|
71
|
-
}, n = A(t, void 0, { isNotSetup: !0 }), n.refresh({ deepRefresh: t.refresh }),
|
|
71
|
+
return i;
|
|
72
|
+
}, n = A(t, void 0, { isNotSetup: !0 }), n.refresh({ deepRefresh: t.refresh }), v.value = !0, d = a;
|
|
72
73
|
}
|
|
73
74
|
});
|
|
74
|
-
function
|
|
75
|
+
function L(t) {
|
|
75
76
|
if (e.value.selectMode == "single") {
|
|
76
77
|
if (e.value.onCanSelectItem != null && !e.value.onCanSelectItem(t))
|
|
77
78
|
return;
|
|
@@ -80,56 +81,56 @@ const te = {
|
|
|
80
81
|
isConfirmed: !0,
|
|
81
82
|
isError: !1,
|
|
82
83
|
result: t.value == !0 ? t.id : void 0
|
|
83
|
-
}),
|
|
84
|
+
}), v.value = !1;
|
|
84
85
|
}
|
|
85
86
|
}
|
|
86
|
-
function
|
|
87
|
+
function P() {
|
|
87
88
|
d != null && d({
|
|
88
89
|
isCancelled: !1,
|
|
89
90
|
isConfirmed: !0,
|
|
90
91
|
isError: !1,
|
|
91
|
-
result: e.value.selectMode == "single" &&
|
|
92
|
-
}),
|
|
92
|
+
result: e.value.selectMode == "single" && Y(o.value, 0) ? void 0 : o.value
|
|
93
|
+
}), v.value = !1;
|
|
93
94
|
}
|
|
94
|
-
function
|
|
95
|
+
function $() {
|
|
95
96
|
d != null && d({
|
|
96
97
|
isCancelled: !0,
|
|
97
98
|
isConfirmed: !1,
|
|
98
99
|
isError: !1
|
|
99
|
-
}),
|
|
100
|
+
}), v.value = !1;
|
|
100
101
|
}
|
|
101
|
-
return
|
|
102
|
-
|
|
102
|
+
return O(() => {
|
|
103
|
+
_();
|
|
103
104
|
}), (t, a) => {
|
|
104
|
-
const s =
|
|
105
|
-
return m(),
|
|
105
|
+
const s = w("bt-header-option");
|
|
106
|
+
return m(), c(l(q), {
|
|
106
107
|
"max-width": e.value.maxWidth,
|
|
107
|
-
modelValue:
|
|
108
|
-
"onUpdate:modelValue": a[7] || (a[7] = (i) =>
|
|
108
|
+
modelValue: v.value,
|
|
109
|
+
"onUpdate:modelValue": a[7] || (a[7] = (i) => v.value = i)
|
|
109
110
|
}, {
|
|
110
|
-
default:
|
|
111
|
-
|
|
111
|
+
default: u(() => [
|
|
112
|
+
r(l(z), {
|
|
112
113
|
subtitle: e.value.subtitle,
|
|
113
114
|
text: e.value.text
|
|
114
115
|
}, {
|
|
115
|
-
default:
|
|
116
|
-
e.value.title != null ? (m(),
|
|
117
|
-
|
|
118
|
-
default:
|
|
116
|
+
default: u(() => [
|
|
117
|
+
e.value.title != null ? (m(), F("div", le, [
|
|
118
|
+
r(l(H), null, {
|
|
119
|
+
default: u(() => [
|
|
119
120
|
B(E(e.value.title), 1)
|
|
120
121
|
]),
|
|
121
122
|
_: 1
|
|
122
123
|
}),
|
|
123
|
-
|
|
124
|
-
|
|
124
|
+
r(l(J)),
|
|
125
|
+
r(l(x), {
|
|
125
126
|
onClick: a[0] || (a[0] = V((i) => l(n).refresh({ deepRefresh: !0 }), ["stop"])),
|
|
126
127
|
icon: "$refresh",
|
|
127
128
|
title: "Refresh list",
|
|
128
129
|
variant: "text"
|
|
129
130
|
})
|
|
130
|
-
])) :
|
|
131
|
-
R("div",
|
|
132
|
-
l(D)(e.value.searchProps) ? (m(),
|
|
131
|
+
])) : f("", !0),
|
|
132
|
+
R("div", ie, [
|
|
133
|
+
l(D)(e.value.searchProps) ? (m(), c(l(K), {
|
|
133
134
|
key: 0,
|
|
134
135
|
autofocus: "",
|
|
135
136
|
clearable: "",
|
|
@@ -137,11 +138,11 @@ const te = {
|
|
|
137
138
|
placeholder: "Search",
|
|
138
139
|
modelValue: l(n).searchString.value,
|
|
139
140
|
"onUpdate:modelValue": a[2] || (a[2] = (i) => l(n).searchString.value = i)
|
|
140
|
-
},
|
|
141
|
+
}, k({ _: 2 }, [
|
|
141
142
|
e.value.title == null ? {
|
|
142
143
|
name: "append-inner",
|
|
143
|
-
fn:
|
|
144
|
-
|
|
144
|
+
fn: u(() => [
|
|
145
|
+
r(l(x), {
|
|
145
146
|
onClick: a[1] || (a[1] = V((i) => l(n).refresh({ deepRefresh: !0 }), ["stop"])),
|
|
146
147
|
icon: "$refresh",
|
|
147
148
|
title: "Refresh list",
|
|
@@ -150,17 +151,17 @@ const te = {
|
|
|
150
151
|
]),
|
|
151
152
|
key: "0"
|
|
152
153
|
} : void 0
|
|
153
|
-
]), 1032, ["modelValue"])) :
|
|
154
|
-
!l(D)(e.value.searchProps) && e.value.title == null ? (m(),
|
|
154
|
+
]), 1032, ["modelValue"])) : f("", !0),
|
|
155
|
+
!l(D)(e.value.searchProps) && e.value.title == null ? (m(), c(l(x), {
|
|
155
156
|
key: 1,
|
|
156
157
|
onClick: a[3] || (a[3] = V((i) => l(n).refresh({ deepRefresh: !0 }), ["stop"])),
|
|
157
158
|
icon: "$refresh",
|
|
158
159
|
title: "Refresh list",
|
|
159
160
|
variant: "text"
|
|
160
|
-
})) :
|
|
161
|
+
})) : f("", !0)
|
|
161
162
|
]),
|
|
162
|
-
|
|
163
|
-
"onClick:select":
|
|
163
|
+
r(l(Q), {
|
|
164
|
+
"onClick:select": L,
|
|
164
165
|
height: e.value.height,
|
|
165
166
|
lines: e.value.lines,
|
|
166
167
|
"open-strategy": "multiple",
|
|
@@ -168,44 +169,44 @@ const te = {
|
|
|
168
169
|
selected: o.value,
|
|
169
170
|
"onUpdate:selected": a[4] || (a[4] = (i) => o.value = i)
|
|
170
171
|
}, {
|
|
171
|
-
default:
|
|
172
|
-
|
|
172
|
+
default: u(() => [
|
|
173
|
+
r(l(X), {
|
|
173
174
|
group: "",
|
|
174
175
|
"hide-on-leave": ""
|
|
175
176
|
}, {
|
|
176
|
-
default:
|
|
177
|
-
(m(!0),
|
|
178
|
-
key: `${i.id ?? l(
|
|
179
|
-
value: l(
|
|
177
|
+
default: u(() => [
|
|
178
|
+
(m(!0), F(U, null, W(l(n).filteredItems.value, (i) => (m(), c(l(Z), {
|
|
179
|
+
key: `${i.id ?? l(C)(i, e.value.itemValue)}-table-list-item`,
|
|
180
|
+
value: l(C)(i, e.value.itemValue),
|
|
180
181
|
disabled: e.value.onDisabled(i)
|
|
181
|
-
},
|
|
182
|
-
default:
|
|
183
|
-
|
|
184
|
-
default:
|
|
185
|
-
|
|
186
|
-
option:
|
|
182
|
+
}, k({
|
|
183
|
+
default: u(() => [
|
|
184
|
+
S.value != null ? (m(), c(l(ee), { key: 0 }, {
|
|
185
|
+
default: u(() => [
|
|
186
|
+
r(s, {
|
|
187
|
+
option: S.value,
|
|
187
188
|
data: i
|
|
188
189
|
}, null, 8, ["option", "data"])
|
|
189
190
|
]),
|
|
190
191
|
_: 2
|
|
191
|
-
}, 1024)) :
|
|
192
|
-
|
|
193
|
-
default:
|
|
194
|
-
|
|
195
|
-
option:
|
|
192
|
+
}, 1024)) : f("", !0),
|
|
193
|
+
b.value != null ? (m(), c(l(te), { key: 1 }, {
|
|
194
|
+
default: u(() => [
|
|
195
|
+
r(s, {
|
|
196
|
+
option: b.value,
|
|
196
197
|
data: i
|
|
197
198
|
}, null, 8, ["option", "data"])
|
|
198
199
|
]),
|
|
199
200
|
_: 2
|
|
200
|
-
}, 1024)) :
|
|
201
|
+
}, 1024)) : f("", !0)
|
|
201
202
|
]),
|
|
202
203
|
_: 2
|
|
203
204
|
}, [
|
|
204
|
-
|
|
205
|
+
y.value != null ? {
|
|
205
206
|
name: "append",
|
|
206
|
-
fn:
|
|
207
|
-
|
|
208
|
-
option:
|
|
207
|
+
fn: u(() => [
|
|
208
|
+
r(s, {
|
|
209
|
+
option: y.value,
|
|
209
210
|
data: i
|
|
210
211
|
}, null, 8, ["option", "data"])
|
|
211
212
|
]),
|
|
@@ -218,17 +219,17 @@ const te = {
|
|
|
218
219
|
]),
|
|
219
220
|
_: 1
|
|
220
221
|
}, 8, ["height", "lines", "select-strategy", "selected"]),
|
|
221
|
-
|
|
222
|
+
r(j, {
|
|
222
223
|
loadingMsg: l(n).loadingMsg.value
|
|
223
224
|
}, null, 8, ["loadingMsg"])
|
|
224
225
|
]),
|
|
225
|
-
actions:
|
|
226
|
-
|
|
227
|
-
onClick: a[5] || (a[5] = () =>
|
|
226
|
+
actions: u(() => [
|
|
227
|
+
r(l(x), {
|
|
228
|
+
onClick: a[5] || (a[5] = () => $()),
|
|
228
229
|
text: e.value.cancelText
|
|
229
230
|
}, null, 8, ["text"]),
|
|
230
|
-
|
|
231
|
-
onClick: a[6] || (a[6] = () =>
|
|
231
|
+
r(l(x), {
|
|
232
|
+
onClick: a[6] || (a[6] = () => P()),
|
|
232
233
|
text: e.value.confirmText
|
|
233
234
|
}, null, 8, ["text"])
|
|
234
235
|
]),
|
|
@@ -241,5 +242,5 @@ const te = {
|
|
|
241
242
|
}
|
|
242
243
|
});
|
|
243
244
|
export {
|
|
244
|
-
|
|
245
|
+
Se as default
|
|
245
246
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./BT-Drag-Counter.vue2.mjs";
|
|
2
2
|
import "./BT-Drag-Counter.vue3.mjs";
|
|
3
3
|
import r from "../_virtual/_plugin-vue_export-helper.mjs";
|
|
4
|
-
const
|
|
4
|
+
const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-bd9e67a1"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
m as default
|
|
7
7
|
};
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { defineComponent as I, ref as
|
|
2
|
-
import { watchDebounced as
|
|
3
|
-
import { t as
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
|
|
1
|
+
import { defineComponent as I, ref as v, computed as w, watch as R, openBlock as p, createElementBlock as c, normalizeClass as F, createVNode as m, unref as h, withCtx as D, renderSlot as E, createCommentVNode as x, mergeProps as G, withModifiers as P, normalizeStyle as H, toDisplayString as b } from "vue";
|
|
2
|
+
import { watchDebounced as J, useEventListener as L } from "@vueuse/core";
|
|
3
|
+
import { t as K } from "../bt-core/core/node_modules/thenby/thenBy.module.mjs";
|
|
4
|
+
import { VSlideYReverseTransition as Y, VSlideYTransition as Q } from "../bt-core/core/node_modules/vuetify/lib/components/transitions/index.mjs";
|
|
5
|
+
import { VBtn as U } from "../bt-core/core/node_modules/vuetify/lib/components/VBtn/VBtn.mjs";
|
|
6
|
+
import { VIcon as W } from "../bt-core/core/node_modules/vuetify/lib/components/VIcon/VIcon.mjs";
|
|
7
|
+
const Z = { key: 0 }, ee = {
|
|
7
8
|
class: "mr-1",
|
|
8
9
|
key: "2"
|
|
9
|
-
},
|
|
10
|
+
}, te = { key: "3" }, ae = { key: 0 }, ue = /* @__PURE__ */ I({
|
|
10
11
|
__name: "BT-Drag-Counter",
|
|
11
12
|
props: {
|
|
12
13
|
applyOnEnd: { type: Boolean },
|
|
@@ -35,15 +36,15 @@ const W = { key: 0 }, Z = {
|
|
|
35
36
|
"startDragging",
|
|
36
37
|
"stopDragging"
|
|
37
38
|
],
|
|
38
|
-
setup(
|
|
39
|
-
const t =
|
|
39
|
+
setup(q, { emit: A }) {
|
|
40
|
+
const t = q, l = A, a = v(0), f = v("x1"), i = v(!1), O = v(!1), o = v(!1), N = w(() => {
|
|
40
41
|
var e = "position: absolute;";
|
|
41
42
|
return t.popupDirection == "top" ? e = `${e} bottom: 130%` : t.popupDirection == "bottom" ? e = `${e} top: 130%` : t.popupDirection == "left" ? e = `${e} right: 130%` : t.popupDirection == "right" && (e = `${e} left: 130%`), e;
|
|
42
|
-
}), j =
|
|
43
|
+
}), j = w(() => {
|
|
43
44
|
if (t.centerOfParent)
|
|
44
|
-
return t.opaque && !
|
|
45
|
+
return t.opaque && !i.value ? "center-of-parent-opaque" : "center-of-parent";
|
|
45
46
|
});
|
|
46
|
-
let
|
|
47
|
+
let V = 0, z, S, r = [], y = { x: 0, y: 0 }, B = t.mathOptions ?? [
|
|
47
48
|
{ yLevelLessThan: 25, xDifTrigger: 40, valOnTrigger: 1, txt: "x1" },
|
|
48
49
|
{ yLevelLessThan: 50, xDifTrigger: 30, valOnTrigger: 1, txt: "x2" },
|
|
49
50
|
{ yLevelLessThan: 75, xDifTrigger: 20, valOnTrigger: 1, txt: "x3" },
|
|
@@ -52,107 +53,104 @@ const W = { key: 0 }, Z = {
|
|
|
52
53
|
{ yLevelLessThan: 400, xDifTrigger: 1, valOnTrigger: 10, txt: "x50" },
|
|
53
54
|
{ yLevelLessThan: 4e3, xDifTrigger: 1, valOnTrigger: 100, txt: "x100" }
|
|
54
55
|
];
|
|
55
|
-
|
|
56
|
+
B = B.sort(K.firstBy((e) => e.yLevelLessThan, "asc")), R(i, (e) => {
|
|
56
57
|
l(e ? "startDragging" : "stopDragging");
|
|
57
58
|
});
|
|
58
|
-
function
|
|
59
|
-
r.push(
|
|
59
|
+
function M() {
|
|
60
|
+
r.push(L("mousemove", X)), r.push(L("touchmove", X)), i.value = !0, o.value = !0, a.value = t.modelValue ?? 0, f.value = "x1", V = y.x;
|
|
60
61
|
}
|
|
61
|
-
function
|
|
62
|
-
|
|
62
|
+
function _(e) {
|
|
63
|
+
O.value = !0;
|
|
63
64
|
const n = e.type === "touchstart" && e.touches.length > 0 ? e.touches[0] : e;
|
|
64
|
-
y = { x: n.clientX, y: n.clientY }, r.push(
|
|
65
|
-
const
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
},
|
|
65
|
+
y = { x: n.clientX, y: n.clientY }, r.push(L("mouseup", k)), r.push(L("touchend", k));
|
|
66
|
+
const s = t.delay ?? 0;
|
|
67
|
+
s <= 0 ? M() : setTimeout(() => {
|
|
68
|
+
O.value && M();
|
|
69
|
+
}, s), e.preventDefault(), e.stopPropagation();
|
|
69
70
|
}
|
|
70
|
-
function
|
|
71
|
-
|
|
71
|
+
function k() {
|
|
72
|
+
O.value = !1, r.forEach((e) => {
|
|
72
73
|
e();
|
|
73
|
-
}), r.length = 0,
|
|
74
|
+
}), r.length = 0, i.value && t.applyOnEnd ? (l("update:modelValue", a.value), l("change", a.value)) : i.value || l("click", a.value), i.value = !1, t.clearOnLastChange && (a.value = 0), z = void 0, S = void 0;
|
|
74
75
|
}
|
|
75
|
-
function
|
|
76
|
+
function X(e) {
|
|
76
77
|
const n = e.type == "touchmove" && e.touches.length > 0 ? e.touches[0] : e;
|
|
77
78
|
if (y ?? (y = {
|
|
78
79
|
x: n.clientX,
|
|
79
80
|
y: n.clientY
|
|
80
|
-
}),
|
|
81
|
-
if (
|
|
81
|
+
}), i.value)
|
|
82
|
+
if (z ?? (z = e.timeStamp), S ?? (S = n.clientX), t.max != null && t.useMaxer && e.timeStamp - z < t.toMaxSpeed && n.clientX - S > t.toMaxDistance)
|
|
82
83
|
a.value < t.max && (f.value = "MAX", a.value = t.max, t.applyOnEnd || (l("update:modelValue", a.value), l("change", a.value)), l("dragging"));
|
|
83
84
|
else {
|
|
84
|
-
let
|
|
85
|
-
if (
|
|
85
|
+
let s = n.clientX - V;
|
|
86
|
+
if (s > 0 && f.value == "MAX")
|
|
86
87
|
return;
|
|
87
88
|
{
|
|
88
89
|
let g = n.clientY - y.y;
|
|
89
90
|
g = g < 0 ? 0 - g : g;
|
|
90
|
-
const
|
|
91
|
-
if (
|
|
92
|
-
f.value =
|
|
93
|
-
let
|
|
94
|
-
if (
|
|
95
|
-
|
|
96
|
-
let u = a.value + (
|
|
91
|
+
const T = B.find((d) => g < d.yLevelLessThan);
|
|
92
|
+
if (T != null) {
|
|
93
|
+
f.value = T.txt;
|
|
94
|
+
let d = T.xDifTrigger, $ = T.valOnTrigger;
|
|
95
|
+
if (s > d || s < 0 - d) {
|
|
96
|
+
V = n.clientX;
|
|
97
|
+
let u = a.value + (s > d ? $ : 0 - $);
|
|
97
98
|
t.max != null && u > t.max && (u = t.max), t.min != null && u < t.min && (u = t.min), a.value != u && (a.value = u, t.applyOnEnd || (l("update:modelValue", a.value), l("change", a.value)), l("dragging"));
|
|
98
99
|
}
|
|
99
100
|
}
|
|
100
101
|
}
|
|
101
102
|
}
|
|
102
103
|
}
|
|
103
|
-
return
|
|
104
|
-
e || (
|
|
105
|
-
}, { debounce: 1e3 }), (e, C) => {
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
})
|
|
152
|
-
], 2);
|
|
153
|
-
};
|
|
104
|
+
return J(i, (e) => {
|
|
105
|
+
e || (o.value = !1);
|
|
106
|
+
}, { debounce: 1e3 }), (e, C) => (p(), c("div", {
|
|
107
|
+
class: F([j.value, "d-flex"])
|
|
108
|
+
}, [
|
|
109
|
+
m(h(Y), null, {
|
|
110
|
+
default: D(() => [
|
|
111
|
+
o.value ? x("", !0) : (p(), c("div", Z, [
|
|
112
|
+
E(e.$slots, "prepend", { size: e.size }, void 0, !0)
|
|
113
|
+
]))
|
|
114
|
+
]),
|
|
115
|
+
_: 3
|
|
116
|
+
}),
|
|
117
|
+
m(h(U), G(e.$attrs, {
|
|
118
|
+
icon: e.icon,
|
|
119
|
+
size: e.size,
|
|
120
|
+
onMousedown: P(_, ["stop"]),
|
|
121
|
+
onTouchstart: P(_, ["stop"])
|
|
122
|
+
}), {
|
|
123
|
+
default: D(() => [
|
|
124
|
+
m(h(W), {
|
|
125
|
+
icon: e.icon,
|
|
126
|
+
size: e.iconSize
|
|
127
|
+
}, null, 8, ["icon", "size"]),
|
|
128
|
+
m(h(Q), null, {
|
|
129
|
+
default: D(() => [
|
|
130
|
+
o.value ? (p(), c("span", {
|
|
131
|
+
key: 0,
|
|
132
|
+
style: H(N.value)
|
|
133
|
+
}, [
|
|
134
|
+
o.value ? (p(), c("span", ee, "(" + b(f.value) + ")", 1)) : x("", !0),
|
|
135
|
+
o.value ? (p(), c("span", te, b(a.value), 1)) : x("", !0)
|
|
136
|
+
], 4)) : x("", !0)
|
|
137
|
+
]),
|
|
138
|
+
_: 1
|
|
139
|
+
})
|
|
140
|
+
]),
|
|
141
|
+
_: 1
|
|
142
|
+
}, 16, ["icon", "size"]),
|
|
143
|
+
m(h(Y), null, {
|
|
144
|
+
default: D(() => [
|
|
145
|
+
o.value ? x("", !0) : (p(), c("div", ae, [
|
|
146
|
+
E(e.$slots, "append", { size: e.size }, void 0, !0)
|
|
147
|
+
]))
|
|
148
|
+
]),
|
|
149
|
+
_: 3
|
|
150
|
+
})
|
|
151
|
+
], 2));
|
|
154
152
|
}
|
|
155
153
|
});
|
|
156
154
|
export {
|
|
157
|
-
|
|
155
|
+
ue as default
|
|
158
156
|
};
|