@deck9/ui 0.13.3 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/ui.mjs +1941 -1553
- package/dist/src/ui.umd.js +4 -4
- package/package.json +2 -2
- package/dist/utils/usePopper.d.ts +0 -2
package/dist/src/ui.mjs
CHANGED
|
@@ -1,123 +1,123 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { FontAwesomeIcon as
|
|
3
|
-
import { library as
|
|
4
|
-
import * as
|
|
5
|
-
import * as
|
|
6
|
-
var
|
|
7
|
-
const
|
|
8
|
-
prefix:
|
|
9
|
-
iconName:
|
|
10
|
-
icon: [
|
|
11
|
-
},
|
|
12
|
-
definition:
|
|
13
|
-
faAlignJustify:
|
|
14
|
-
prefix:
|
|
15
|
-
iconName:
|
|
16
|
-
width:
|
|
17
|
-
height:
|
|
18
|
-
ligatures:
|
|
19
|
-
unicode:
|
|
20
|
-
svgPathData:
|
|
21
|
-
aliases:
|
|
1
|
+
import { defineComponent as $, computed as w, openBlock as R, createBlock as K, unref as P, mergeProps as ot, createCommentVNode as M, createElementBlock as T, normalizeClass as A, createElementVNode as I, toDisplayString as B, createVNode as N, ref as O, getCurrentInstance as In, onMounted as ee, watch as Z, Fragment as be, withDirectives as $n, vModelText as An, normalizeStyle as Ft, cloneVNode as Mn, h as Ce, inject as he, provide as ye, watchEffect as xe, nextTick as j, onUnmounted as Fe, toRaw as X, shallowRef as Vn, getCurrentScope as Nn, onScopeDispose as Fn, shallowReadonly as me, withCtx as W, renderSlot as ht, Teleport as Bn, Transition as Bt, normalizeProps as jn, guardReactiveProps as zn, resolveDynamicComponent as Un, isRef as Hn, renderList as jt, createTextVNode as Wn } from "vue";
|
|
2
|
+
import { FontAwesomeIcon as Kn } from "@fortawesome/vue-fontawesome";
|
|
3
|
+
import { library as lt } from "@fortawesome/fontawesome-svg-core";
|
|
4
|
+
import * as h from "@fortawesome/free-solid-svg-icons";
|
|
5
|
+
import * as Se from "@fortawesome/free-brands-svg-icons";
|
|
6
|
+
var zt = "fas", Ut = "numeric-input", Ht = 512, Wt = 512, Qe = [], Kt = "", Gt = "m409.445 111 2.112.004c34.066.146 46.74 3.848 59.517 10.681 13.037 6.973 23.268 17.204 30.24 30.241l.415.782c6.705 12.782 10.271 25.9 10.271 60.847v72.002c-.15 34.066-3.852 46.74-10.685 59.517-6.973 13.037-17.204 23.268-30.241 30.24l-.782.415C457.51 382.434 444.392 386 409.445 386h-306.89l-2.112-.004c-34.066-.146-46.74-3.848-59.517-10.681-13.037-6.973-23.268-17.204-30.24-30.241l-.415-.782C3.566 331.51 0 318.392 0 283.445v-69.89c0-35.66 3.713-48.592 10.685-61.629 6.973-13.037 17.204-23.268 30.241-30.24l.782-.415C54.49 114.566 67.608 111 102.555 111h306.89Zm.806 36H102.555l-2.387.005c-22.69.089-31.789 1.488-39.667 5.128l-.523.246c-.696.332-1.385.683-2.074 1.052-6.764 3.617-11.856 8.71-15.473 15.473l-.282.533c-4.492 8.62-6.116 17.401-6.148 43.312v71.502l.012 3.09c.161 24.044 1.9 32.308 6.418 40.755 3.617 6.764 8.71 11.856 15.473 15.473l.533.282c8.62 4.492 17.401 6.116 43.312 6.149h307.696c27.078 0 35.763-1.677 44.651-6.43 6.764-3.618 11.856-8.71 15.473-15.474l.282-.533c4.492-8.62 6.116-17.401 6.149-43.312v-70.696c0-27.078-1.677-35.763-6.43-44.651-3.618-6.764-8.71-11.856-15.474-15.473l-.533-.282c-8.62-4.492-17.401-6.116-43.312-6.149Zm-164.715 19c11.682 0 22.013 1.976 30.994 5.929 8.98 3.952 16.005 9.38 21.074 16.284 5.07 6.904 7.578 14.797 7.527 23.677.103 8.829-2.92 16.066-9.07 21.713-6.15 5.646-13.935 8.983-23.353 10.01v1.231c12.764 1.386 22.362 5.274 28.794 11.665 6.433 6.39 9.598 14.411 9.496 24.061.051 9.24-2.715 17.427-8.299 24.562-5.584 7.135-13.33 12.73-23.236 16.785-9.907 4.055-21.319 6.083-34.236 6.083-12.454 0-23.506-2.143-33.156-6.43-9.65-4.285-17.227-10.201-22.734-17.747-5.506-7.545-8.286-16.22-8.337-26.025h43.23c.051 3.029.99 5.737 2.817 8.124 1.827 2.386 4.336 4.247 7.527 5.582 3.19 1.334 6.845 2.002 10.962 2.002 3.962 0 7.462-.706 10.498-2.118 3.037-1.411 5.404-3.375 7.102-5.89 1.699-2.515 2.522-5.39 2.47-8.623.052-3.183-.913-6.006-2.894-8.47-1.982-2.464-4.748-4.389-8.299-5.775-3.55-1.386-7.642-2.079-12.274-2.079h-16.057v-29.566h16.057c4.271 0 8.041-.693 11.31-2.08 3.267-1.385 5.815-3.31 7.642-5.774s2.714-5.287 2.663-8.47c.051-3.08-.695-5.8-2.239-8.161-1.544-2.361-3.692-4.21-6.446-5.544-2.753-1.334-5.93-2.002-9.533-2.002-3.912 0-7.398.693-10.46 2.08-3.063 1.385-5.468 3.31-7.218 5.774s-2.65 5.287-2.702 8.47h-41.068c.051-9.65 2.715-18.172 7.99-25.563 5.275-7.392 12.518-13.192 21.73-17.401 9.212-4.21 19.788-6.314 31.728-6.314Zm-133.074 0c12.615 0 23.55 2.017 32.807 6.05 9.257 4.033 16.41 9.698 21.462 16.994 5.051 7.296 7.577 15.851 7.577 25.665 0 6.063-1.257 12.087-3.77 18.073-2.512 5.986-7.025 12.601-13.538 19.846-6.513 7.245-15.77 15.877-27.77 25.896l-14.768 12.331v.925H176V326H55.077v-30.829l58.77-48.709c3.897-3.237 7.243-6.28 10.038-9.133 2.794-2.851 4.948-5.793 6.461-8.824 1.513-3.032 2.27-6.397 2.27-10.097 0-4.059-.86-7.527-2.578-10.404-1.717-2.877-4.09-5.1-7.115-6.667-3.026-1.567-6.513-2.35-10.461-2.35-3.95 0-7.424.796-10.424 2.389-3 1.593-5.32 3.93-6.961 7.013-1.641 3.083-2.462 6.834-2.462 11.253H52c0-11.099 2.487-20.655 7.462-28.67 4.974-8.016 12-14.182 21.076-18.498 9.077-4.316 19.718-6.474 31.924-6.474Z";
|
|
7
|
+
const yt = {
|
|
8
|
+
prefix: zt,
|
|
9
|
+
iconName: Ut,
|
|
10
|
+
icon: [Ht, Wt, Qe, Kt, Gt]
|
|
11
|
+
}, Gn = {
|
|
12
|
+
definition: yt,
|
|
13
|
+
faAlignJustify: yt,
|
|
14
|
+
prefix: zt,
|
|
15
|
+
iconName: Ut,
|
|
16
|
+
width: Ht,
|
|
17
|
+
height: Wt,
|
|
18
|
+
ligatures: Qe,
|
|
19
|
+
unicode: Kt,
|
|
20
|
+
svgPathData: Gt,
|
|
21
|
+
aliases: Qe
|
|
22
22
|
};
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
23
|
+
lt.add(
|
|
24
|
+
h.faArrowUp19,
|
|
25
|
+
h.faAt,
|
|
26
|
+
h.faBold,
|
|
27
|
+
h.faBolt,
|
|
28
|
+
h.faCalendar,
|
|
29
|
+
h.faChartPie,
|
|
30
|
+
h.faCheck,
|
|
31
|
+
h.faCheckCircle,
|
|
32
|
+
h.faChevronDown,
|
|
33
|
+
h.faChevronLeft,
|
|
34
|
+
h.faChevronRight,
|
|
35
|
+
h.faChevronUp,
|
|
36
|
+
h.faCircleCheck,
|
|
37
|
+
h.faCircleNotch,
|
|
38
|
+
h.faClipboard,
|
|
39
|
+
h.faCloudDownload,
|
|
40
|
+
h.faCloudUpload,
|
|
41
|
+
h.faCog,
|
|
42
|
+
h.faCrown,
|
|
43
|
+
h.faDoorOpen,
|
|
44
|
+
h.faDotCircle,
|
|
45
|
+
h.faEllipsis,
|
|
46
|
+
h.faEllipsisVertical,
|
|
47
|
+
h.faEnvelope,
|
|
48
|
+
h.faExclamationTriangle,
|
|
49
|
+
h.faExternalLink,
|
|
50
|
+
h.faEyeDropper,
|
|
51
|
+
h.faFileLines,
|
|
52
|
+
h.faFileUpload,
|
|
53
|
+
h.faFilter,
|
|
54
|
+
h.faFingerprint,
|
|
55
|
+
h.faGlobe,
|
|
56
|
+
h.faGripHorizontal,
|
|
57
|
+
h.faGripVertical,
|
|
58
|
+
h.faHandPointRight,
|
|
59
|
+
h.faHashtag,
|
|
60
|
+
h.faHeart,
|
|
61
|
+
h.faInfoCircle,
|
|
62
|
+
h.faItalic,
|
|
63
|
+
h.faLink,
|
|
64
|
+
h.faLock,
|
|
65
|
+
h.faLockOpen,
|
|
66
|
+
h.faMedal,
|
|
67
|
+
h.faMessage,
|
|
68
|
+
h.faPencilAlt,
|
|
69
|
+
h.faPenToSquare,
|
|
70
|
+
h.faPhone,
|
|
71
|
+
h.faPlayCircle,
|
|
72
|
+
h.faPlus,
|
|
73
|
+
h.faPlusCircle,
|
|
74
|
+
h.faPoo,
|
|
75
|
+
h.faPuzzlePiece,
|
|
76
|
+
h.faReply,
|
|
77
|
+
h.faReplyAll,
|
|
78
|
+
h.faRobot,
|
|
79
|
+
h.faSave,
|
|
80
|
+
h.faShield,
|
|
81
|
+
h.faSignal,
|
|
82
|
+
h.faSignature,
|
|
83
|
+
h.faSquareCheck,
|
|
84
|
+
h.faStar,
|
|
85
|
+
h.faTimes,
|
|
86
|
+
h.faTrash,
|
|
87
|
+
h.faTree,
|
|
88
|
+
h.faTrophy,
|
|
89
|
+
h.faTurnDown,
|
|
90
|
+
h.faUpload,
|
|
91
|
+
h.faUser,
|
|
92
|
+
h.faUserShield,
|
|
93
93
|
// Brands
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
94
|
+
Se.faTwitter,
|
|
95
|
+
Se.faInstagram,
|
|
96
|
+
Se.faGithub,
|
|
97
|
+
Se.faLinkedin,
|
|
98
|
+
Se.faFacebook,
|
|
99
99
|
// Custom
|
|
100
|
-
|
|
100
|
+
Gn.definition
|
|
101
101
|
);
|
|
102
|
-
const
|
|
102
|
+
const qn = [...Object.keys(lt.definitions.fas)].sort(), xt = [...Object.keys(lt.definitions.fab)].sort(), U = /* @__PURE__ */ $({
|
|
103
103
|
__name: "Icon",
|
|
104
104
|
props: {
|
|
105
105
|
name: { default: "user" }
|
|
106
106
|
},
|
|
107
107
|
setup(e) {
|
|
108
|
-
const t = e,
|
|
108
|
+
const t = e, l = w(() => xt.includes(t.name) ? "fab" : "fas"), o = w(() => qn.includes(t.name) || xt.includes(t.name) ? !0 : (console.warn(
|
|
109
109
|
"could not load icon, because it is not available",
|
|
110
110
|
t.name
|
|
111
111
|
), !1));
|
|
112
|
-
return (n,
|
|
112
|
+
return (n, r) => o.value ? (R(), K(P(Kn), ot({
|
|
113
113
|
key: 0,
|
|
114
|
-
icon: [
|
|
115
|
-
}, n.$attrs), null, 16, ["icon"])) :
|
|
114
|
+
icon: [l.value, n.name]
|
|
115
|
+
}, n.$attrs), null, 16, ["icon"])) : M("", !0);
|
|
116
116
|
}
|
|
117
|
-
}),
|
|
117
|
+
}), Xn = ["aria-label", "tabindex"], Yn = {
|
|
118
118
|
key: 0,
|
|
119
119
|
class: "absolute inset-0 flex items-center justify-center"
|
|
120
|
-
},
|
|
120
|
+
}, Rr = /* @__PURE__ */ $({
|
|
121
121
|
__name: "Button",
|
|
122
122
|
props: {
|
|
123
123
|
label: {},
|
|
@@ -130,35 +130,35 @@ const wn = [...Object.keys(Ue.definitions.fas)].sort(), ot = [...Object.keys(Ue.
|
|
|
130
130
|
},
|
|
131
131
|
emits: ["onClick"],
|
|
132
132
|
setup(e, { emit: t }) {
|
|
133
|
-
const
|
|
133
|
+
const l = t, o = e, n = w(() => {
|
|
134
134
|
const u = {
|
|
135
|
-
"text-white bg-blue-600 border-transparent hover:bg-blue-700 active:bg-blue-700 dark:ring-blue-800 ring-offset-2 dark:ring-offset-grey-900":
|
|
136
|
-
"text-blue-600 bg-grey-100 border-transparent hover:bg-blue-100 hover:text-blue-700 active:bg-grey-100 ring-blue-300 ring-offset-2 dark:ring-offset-grey-900":
|
|
137
|
-
"text-grey-50 bg-grey-700 border-transparent hover:bg-grey-800 active:bg-grey-700 ring-grey-500 dark:ring-grey-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-grey-900":
|
|
138
|
-
"text-red-50 bg-red-500 border-transparent hover:bg-red-600 active:bg-red-600 ring-red-400 dark:ring-red-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-red-900":
|
|
135
|
+
"text-white bg-blue-600 border-transparent hover:bg-blue-700 active:bg-blue-700 dark:ring-blue-800 ring-offset-2 dark:ring-offset-grey-900": o.color === "primary",
|
|
136
|
+
"text-blue-600 bg-grey-100 border-transparent hover:bg-blue-100 hover:text-blue-700 active:bg-grey-100 ring-blue-300 ring-offset-2 dark:ring-offset-grey-900": o.color === "light",
|
|
137
|
+
"text-grey-50 bg-grey-700 border-transparent hover:bg-grey-800 active:bg-grey-700 ring-grey-500 dark:ring-grey-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-grey-900": o.color === "dark",
|
|
138
|
+
"text-red-50 bg-red-500 border-transparent hover:bg-red-600 active:bg-red-600 ring-red-400 dark:ring-red-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-red-900": o.color === "danger"
|
|
139
139
|
}, c = {
|
|
140
|
-
"pointer-events-none opacity-75 cursor-not-allowed":
|
|
140
|
+
"pointer-events-none opacity-75 cursor-not-allowed": o.isDisabled
|
|
141
141
|
}, s = {
|
|
142
|
-
"px-4 py-1 text-xs leading-5 mono-100 rounded-lg":
|
|
143
|
-
"px-5 py-2 text-sm leading-4 font-medium rounded-lg":
|
|
144
|
-
"px-8 py-3 text-base leading-6 font-medium rounded-lg":
|
|
142
|
+
"px-4 py-1 text-xs leading-5 mono-100 rounded-lg": o.size === "small",
|
|
143
|
+
"px-5 py-2 text-sm leading-4 font-medium rounded-lg": o.size === "medium",
|
|
144
|
+
"px-8 py-3 text-base leading-6 font-medium rounded-lg": o.size === "large"
|
|
145
145
|
};
|
|
146
146
|
return {
|
|
147
147
|
...u,
|
|
148
148
|
...c,
|
|
149
149
|
...s
|
|
150
150
|
};
|
|
151
|
-
}),
|
|
151
|
+
}), r = w(() => {
|
|
152
152
|
const u = {
|
|
153
|
-
"mr-2 -ml-1": ["small", "medium"].includes(
|
|
154
|
-
"mr-4 -ml-2": ["large"].includes(
|
|
153
|
+
"mr-2 -ml-1": ["small", "medium"].includes(o.size) && o.iconPosition === "left",
|
|
154
|
+
"mr-4 -ml-2": ["large"].includes(o.size) && o.iconPosition === "left"
|
|
155
155
|
}, c = {
|
|
156
|
-
"ml-3 -mr-1": ["small", "medium"].includes(
|
|
157
|
-
"ml-3 -mr-3": ["large"].includes(
|
|
156
|
+
"ml-3 -mr-1": ["small", "medium"].includes(o.size) && o.iconPosition === "right",
|
|
157
|
+
"ml-3 -mr-3": ["large"].includes(o.size) && o.iconPosition === "right"
|
|
158
158
|
}, s = {
|
|
159
|
-
"text-white":
|
|
160
|
-
"text-blue-600":
|
|
161
|
-
"text-grey-50":
|
|
159
|
+
"text-white": o.color === "primary",
|
|
160
|
+
"text-blue-600": o.color === "light",
|
|
161
|
+
"text-grey-50": o.color === "dark"
|
|
162
162
|
};
|
|
163
163
|
return {
|
|
164
164
|
...u,
|
|
@@ -167,262 +167,262 @@ const wn = [...Object.keys(Ue.definitions.fas)].sort(), ot = [...Object.keys(Ue.
|
|
|
167
167
|
};
|
|
168
168
|
});
|
|
169
169
|
function i() {
|
|
170
|
-
|
|
170
|
+
o.isDisabled || l("onClick");
|
|
171
171
|
}
|
|
172
|
-
return (u, c) => (
|
|
173
|
-
class:
|
|
172
|
+
return (u, c) => (R(), T("button", {
|
|
173
|
+
class: A(["relative inline-flex items-center focus:outline-none focus:ring active:ring transition duration-150 ease-in-out", n.value]),
|
|
174
174
|
type: "button",
|
|
175
175
|
"aria-label": u.label,
|
|
176
176
|
tabindex: u.isDisabled ? "-1" : void 0,
|
|
177
177
|
onClick: i
|
|
178
178
|
}, [
|
|
179
|
-
|
|
180
|
-
class:
|
|
179
|
+
I("div", {
|
|
180
|
+
class: A(!u.isLoading || "invisible")
|
|
181
181
|
}, [
|
|
182
|
-
u.icon && u.iconPosition === "left" ? (
|
|
182
|
+
u.icon && u.iconPosition === "left" ? (R(), K(U, {
|
|
183
183
|
key: 0,
|
|
184
184
|
name: u.icon,
|
|
185
|
-
class:
|
|
186
|
-
}, null, 8, ["name", "class"])) :
|
|
187
|
-
|
|
188
|
-
u.icon && u.iconPosition === "right" ? (
|
|
185
|
+
class: A(r.value)
|
|
186
|
+
}, null, 8, ["name", "class"])) : M("", !0),
|
|
187
|
+
I("span", null, B(u.label), 1),
|
|
188
|
+
u.icon && u.iconPosition === "right" ? (R(), K(U, {
|
|
189
189
|
key: 1,
|
|
190
190
|
name: u.icon,
|
|
191
|
-
class:
|
|
192
|
-
}, null, 8, ["name", "class"])) :
|
|
191
|
+
class: A(r.value)
|
|
192
|
+
}, null, 8, ["name", "class"])) : M("", !0)
|
|
193
193
|
], 2),
|
|
194
|
-
u.isLoading ? (
|
|
195
|
-
|
|
194
|
+
u.isLoading ? (R(), T("span", Yn, [
|
|
195
|
+
N(U, {
|
|
196
196
|
class: "animate-spin",
|
|
197
197
|
name: "circle-notch"
|
|
198
198
|
})
|
|
199
|
-
])) :
|
|
200
|
-
], 10,
|
|
199
|
+
])) : M("", !0)
|
|
200
|
+
], 10, Xn));
|
|
201
201
|
}
|
|
202
202
|
});
|
|
203
|
-
let
|
|
204
|
-
const
|
|
205
|
-
function
|
|
206
|
-
if (!
|
|
203
|
+
let Te;
|
|
204
|
+
const Zn = new Uint8Array(16);
|
|
205
|
+
function Qn() {
|
|
206
|
+
if (!Te && (Te = typeof crypto < "u" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto), !Te))
|
|
207
207
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
208
|
-
return
|
|
208
|
+
return Te(Zn);
|
|
209
209
|
}
|
|
210
|
-
const
|
|
210
|
+
const V = [];
|
|
211
211
|
for (let e = 0; e < 256; ++e)
|
|
212
|
-
|
|
213
|
-
function
|
|
214
|
-
return
|
|
212
|
+
V.push((e + 256).toString(16).slice(1));
|
|
213
|
+
function Jn(e, t = 0) {
|
|
214
|
+
return V[e[t + 0]] + V[e[t + 1]] + V[e[t + 2]] + V[e[t + 3]] + "-" + V[e[t + 4]] + V[e[t + 5]] + "-" + V[e[t + 6]] + V[e[t + 7]] + "-" + V[e[t + 8]] + V[e[t + 9]] + "-" + V[e[t + 10]] + V[e[t + 11]] + V[e[t + 12]] + V[e[t + 13]] + V[e[t + 14]] + V[e[t + 15]];
|
|
215
215
|
}
|
|
216
|
-
const
|
|
217
|
-
randomUUID:
|
|
216
|
+
const eo = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), wt = {
|
|
217
|
+
randomUUID: eo
|
|
218
218
|
};
|
|
219
|
-
function
|
|
220
|
-
if (
|
|
221
|
-
return
|
|
219
|
+
function qt(e, t, l) {
|
|
220
|
+
if (wt.randomUUID && !t && !e)
|
|
221
|
+
return wt.randomUUID();
|
|
222
222
|
e = e || {};
|
|
223
|
-
const
|
|
224
|
-
if (
|
|
225
|
-
|
|
223
|
+
const o = e.random || (e.rng || Qn)();
|
|
224
|
+
if (o[6] = o[6] & 15 | 64, o[8] = o[8] & 63 | 128, t) {
|
|
225
|
+
l = l || 0;
|
|
226
226
|
for (let n = 0; n < 16; ++n)
|
|
227
|
-
t[
|
|
227
|
+
t[l + n] = o[n];
|
|
228
228
|
return t;
|
|
229
229
|
}
|
|
230
|
-
return
|
|
230
|
+
return Jn(o);
|
|
231
231
|
}
|
|
232
|
-
const
|
|
232
|
+
const to = { class: "relative flex items-start" }, no = { class: "flex items-center h-5" }, oo = ["checked", "id"], lo = { class: "ml-2 text-sm leading-5" }, ro = ["for"], io = {
|
|
233
233
|
key: 0,
|
|
234
234
|
class: "block text-xs text-grey-400 font-normal mono-0 casual-60"
|
|
235
|
-
},
|
|
235
|
+
}, Er = /* @__PURE__ */ $({
|
|
236
236
|
__name: "Checkbox",
|
|
237
237
|
props: {
|
|
238
|
-
id: { default:
|
|
238
|
+
id: { default: qt() },
|
|
239
239
|
label: {},
|
|
240
240
|
modelValue: { type: Boolean },
|
|
241
241
|
description: {}
|
|
242
242
|
},
|
|
243
243
|
emits: ["update:modelValue"],
|
|
244
244
|
setup(e, { emit: t }) {
|
|
245
|
-
const
|
|
246
|
-
|
|
245
|
+
const l = t, o = (n) => {
|
|
246
|
+
l("update:modelValue", n.target.checked);
|
|
247
247
|
};
|
|
248
|
-
return (n,
|
|
249
|
-
|
|
250
|
-
|
|
248
|
+
return (n, r) => (R(), T("div", to, [
|
|
249
|
+
I("div", no, [
|
|
250
|
+
I("input", {
|
|
251
251
|
class: "h-4 w-4 border-grey-600 dark:text-blue-500 dark:border-grey-300 dark:checked:border-blue-500 dark:focus:ring-blue-900 dark:focus:ring-offset-grey-800 rounded-sm",
|
|
252
252
|
type: "checkbox",
|
|
253
253
|
checked: n.modelValue,
|
|
254
|
-
onChange:
|
|
254
|
+
onChange: o,
|
|
255
255
|
id: n.id
|
|
256
|
-
}, null, 40,
|
|
256
|
+
}, null, 40, oo)
|
|
257
257
|
]),
|
|
258
|
-
|
|
259
|
-
|
|
258
|
+
I("div", lo, [
|
|
259
|
+
I("label", {
|
|
260
260
|
for: n.id,
|
|
261
261
|
class: "font-medium text-grey-700 dark:text-grey-200 casual-25"
|
|
262
|
-
},
|
|
263
|
-
n.description ? (
|
|
262
|
+
}, B(n.label), 9, ro),
|
|
263
|
+
n.description ? (R(), T("p", io, B(n.description), 1)) : M("", !0)
|
|
264
264
|
])
|
|
265
265
|
]));
|
|
266
266
|
}
|
|
267
267
|
});
|
|
268
|
-
function
|
|
268
|
+
function ao() {
|
|
269
269
|
const e = O(!1);
|
|
270
|
-
return
|
|
270
|
+
return In() && ee(() => {
|
|
271
271
|
e.value = !0;
|
|
272
272
|
}), e;
|
|
273
273
|
}
|
|
274
|
-
function
|
|
275
|
-
const t =
|
|
276
|
-
return
|
|
274
|
+
function so(e) {
|
|
275
|
+
const t = ao();
|
|
276
|
+
return w(() => (t.value, !!e()));
|
|
277
277
|
}
|
|
278
|
-
function
|
|
279
|
-
const { initialValue: t = "" } = e,
|
|
280
|
-
async function n(
|
|
281
|
-
if (!
|
|
278
|
+
function uo(e = {}) {
|
|
279
|
+
const { initialValue: t = "" } = e, l = so(() => typeof window < "u" && "EyeDropper" in window), o = O(t);
|
|
280
|
+
async function n(r) {
|
|
281
|
+
if (!l.value)
|
|
282
282
|
return;
|
|
283
|
-
const u = await new window.EyeDropper().open(
|
|
284
|
-
return
|
|
283
|
+
const u = await new window.EyeDropper().open(r);
|
|
284
|
+
return o.value = u.sRGBHex, u;
|
|
285
285
|
}
|
|
286
|
-
return { isSupported:
|
|
286
|
+
return { isSupported: l, sRGBHex: o, open: n };
|
|
287
287
|
}
|
|
288
|
-
const
|
|
289
|
-
},
|
|
290
|
-
let
|
|
291
|
-
const
|
|
292
|
-
let
|
|
293
|
-
function
|
|
288
|
+
const co = () => {
|
|
289
|
+
}, fo = Array.isArray, po = (e) => typeof e == "function", mo = (e) => typeof e == "symbol";
|
|
290
|
+
let kt;
|
|
291
|
+
const St = () => kt || (kt = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {});
|
|
292
|
+
let vo;
|
|
293
|
+
function go(e, t = vo) {
|
|
294
294
|
t && t.active && t.effects.push(e);
|
|
295
295
|
}
|
|
296
|
-
const
|
|
296
|
+
const bo = (e) => {
|
|
297
297
|
const t = new Set(e);
|
|
298
298
|
return t.w = 0, t.n = 0, t;
|
|
299
|
-
},
|
|
299
|
+
}, Xt = (e) => (e.w & ie) > 0, Yt = (e) => (e.n & ie) > 0, ho = ({ deps: e }) => {
|
|
300
300
|
if (e.length)
|
|
301
301
|
for (let t = 0; t < e.length; t++)
|
|
302
|
-
e[t].w |=
|
|
303
|
-
},
|
|
302
|
+
e[t].w |= ie;
|
|
303
|
+
}, yo = (e) => {
|
|
304
304
|
const { deps: t } = e;
|
|
305
305
|
if (t.length) {
|
|
306
|
-
let
|
|
307
|
-
for (let
|
|
308
|
-
const n = t[
|
|
309
|
-
|
|
306
|
+
let l = 0;
|
|
307
|
+
for (let o = 0; o < t.length; o++) {
|
|
308
|
+
const n = t[o];
|
|
309
|
+
Xt(n) && !Yt(n) ? n.delete(e) : t[l++] = n, n.w &= ~ie, n.n &= ~ie;
|
|
310
310
|
}
|
|
311
|
-
t.length =
|
|
311
|
+
t.length = l;
|
|
312
312
|
}
|
|
313
313
|
};
|
|
314
|
-
let
|
|
315
|
-
const
|
|
314
|
+
let Oe = 0, ie = 1;
|
|
315
|
+
const Je = 30;
|
|
316
316
|
let Y;
|
|
317
|
-
class
|
|
318
|
-
constructor(t,
|
|
319
|
-
this.fn = t, this.scheduler =
|
|
317
|
+
class xo {
|
|
318
|
+
constructor(t, l = null, o) {
|
|
319
|
+
this.fn = t, this.scheduler = l, this.active = !0, this.deps = [], this.parent = void 0, go(this, o);
|
|
320
320
|
}
|
|
321
321
|
run() {
|
|
322
322
|
if (!this.active)
|
|
323
323
|
return this.fn();
|
|
324
|
-
let t = Y,
|
|
324
|
+
let t = Y, l = $e;
|
|
325
325
|
for (; t; ) {
|
|
326
326
|
if (t === this)
|
|
327
327
|
return;
|
|
328
328
|
t = t.parent;
|
|
329
329
|
}
|
|
330
330
|
try {
|
|
331
|
-
return this.parent = Y, Y = this,
|
|
331
|
+
return this.parent = Y, Y = this, $e = !0, ie = 1 << ++Oe, Oe <= Je ? ho(this) : Ot(this), this.fn();
|
|
332
332
|
} finally {
|
|
333
|
-
|
|
333
|
+
Oe <= Je && yo(this), ie = 1 << --Oe, Y = this.parent, $e = l, this.parent = void 0, this.deferStop && this.stop();
|
|
334
334
|
}
|
|
335
335
|
}
|
|
336
336
|
stop() {
|
|
337
|
-
Y === this ? this.deferStop = !0 : this.active && (
|
|
337
|
+
Y === this ? this.deferStop = !0 : this.active && (Ot(this), this.onStop && this.onStop(), this.active = !1);
|
|
338
338
|
}
|
|
339
339
|
}
|
|
340
|
-
function
|
|
340
|
+
function Ot(e) {
|
|
341
341
|
const { deps: t } = e;
|
|
342
342
|
if (t.length) {
|
|
343
|
-
for (let
|
|
344
|
-
t[
|
|
343
|
+
for (let l = 0; l < t.length; l++)
|
|
344
|
+
t[l].delete(e);
|
|
345
345
|
t.length = 0;
|
|
346
346
|
}
|
|
347
347
|
}
|
|
348
|
-
let
|
|
349
|
-
function
|
|
350
|
-
let
|
|
351
|
-
|
|
348
|
+
let $e = !0;
|
|
349
|
+
function wo(e, t) {
|
|
350
|
+
let l = !1;
|
|
351
|
+
Oe <= Je ? Yt(e) || (e.n |= ie, l = !Xt(e)) : l = !e.has(Y), l && (e.add(Y), Y.deps.push(e));
|
|
352
352
|
}
|
|
353
|
-
function
|
|
354
|
-
const
|
|
355
|
-
for (const
|
|
356
|
-
|
|
357
|
-
for (const
|
|
358
|
-
|
|
353
|
+
function ko(e, t) {
|
|
354
|
+
const l = fo(e) ? e : [...e];
|
|
355
|
+
for (const o of l)
|
|
356
|
+
o.computed && Ct(o);
|
|
357
|
+
for (const o of l)
|
|
358
|
+
o.computed || Ct(o);
|
|
359
359
|
}
|
|
360
|
-
function
|
|
360
|
+
function Ct(e, t) {
|
|
361
361
|
(e !== Y || e.allowRecurse) && (e.scheduler ? e.scheduler() : e.run());
|
|
362
362
|
}
|
|
363
363
|
new Set(
|
|
364
|
-
/* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(
|
|
364
|
+
/* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(mo)
|
|
365
365
|
);
|
|
366
|
-
function
|
|
366
|
+
function Be(e) {
|
|
367
367
|
const t = e && e.__v_raw;
|
|
368
|
-
return t ?
|
|
368
|
+
return t ? Be(t) : e;
|
|
369
369
|
}
|
|
370
|
-
function
|
|
371
|
-
|
|
370
|
+
function So(e) {
|
|
371
|
+
$e && Y && (e = Be(e), wo(e.dep || (e.dep = bo())));
|
|
372
372
|
}
|
|
373
|
-
function
|
|
374
|
-
e =
|
|
375
|
-
const
|
|
376
|
-
|
|
373
|
+
function Oo(e, t) {
|
|
374
|
+
e = Be(e);
|
|
375
|
+
const l = e.dep;
|
|
376
|
+
l && ko(l);
|
|
377
377
|
}
|
|
378
|
-
class
|
|
379
|
-
constructor(t,
|
|
380
|
-
this._setter =
|
|
381
|
-
this._dirty || (this._dirty = !0,
|
|
382
|
-
}), this.effect.computed = this, this.effect.active = this._cacheable = !n, this.__v_isReadonly =
|
|
378
|
+
class Co {
|
|
379
|
+
constructor(t, l, o, n) {
|
|
380
|
+
this._setter = l, this.dep = void 0, this.__v_isRef = !0, this.__v_isReadonly = !1, this._dirty = !0, this.effect = new xo(t, () => {
|
|
381
|
+
this._dirty || (this._dirty = !0, Oo(this));
|
|
382
|
+
}), this.effect.computed = this, this.effect.active = this._cacheable = !n, this.__v_isReadonly = o;
|
|
383
383
|
}
|
|
384
384
|
get value() {
|
|
385
|
-
const t =
|
|
386
|
-
return
|
|
385
|
+
const t = Be(this);
|
|
386
|
+
return So(t), (t._dirty || !t._cacheable) && (t._dirty = !1, t._value = t.effect.run()), t._value;
|
|
387
387
|
}
|
|
388
388
|
set value(t) {
|
|
389
389
|
this._setter(t);
|
|
390
390
|
}
|
|
391
391
|
}
|
|
392
|
-
function
|
|
393
|
-
let
|
|
394
|
-
const
|
|
395
|
-
return
|
|
392
|
+
function Ro(e, t, l = !1) {
|
|
393
|
+
let o, n;
|
|
394
|
+
const r = po(e);
|
|
395
|
+
return r ? (o = e, n = co) : (o = e.get, n = e.set), new Co(o, n, r || !n, l);
|
|
396
396
|
}
|
|
397
|
-
let
|
|
398
|
-
(
|
|
399
|
-
let
|
|
400
|
-
const
|
|
401
|
-
function
|
|
402
|
-
const t =
|
|
397
|
+
let Xe, Rt = "__VUE_INSTANCE_SETTERS__";
|
|
398
|
+
(Xe = St()[Rt]) || (Xe = St()[Rt] = []), Xe.push((e) => e);
|
|
399
|
+
let Eo = !1;
|
|
400
|
+
const Ye = (e, t) => Ro(e, t, Eo);
|
|
401
|
+
function rt(e) {
|
|
402
|
+
const t = Ye(() => ({
|
|
403
403
|
"pl-3 pr-10 py-2": !e.icon && e.type !== "color" && e.size === "small",
|
|
404
404
|
"pl-4 pr-10 py-3": !e.icon && e.type !== "color" && e.size === "medium",
|
|
405
405
|
"pl-6 pr-10 py-3": !e.icon && e.type !== "color" && e.size === "large",
|
|
406
406
|
"pl-10 pr-10 py-1": (e.icon || e.type === "color") && e.size === "small",
|
|
407
407
|
"pl-12 pr-10 py-3": (e.icon || e.type === "color") && (e.size === "medium" || e.size === "large"),
|
|
408
408
|
"w-full block": e.block === !0
|
|
409
|
-
})),
|
|
409
|
+
})), l = Ye(() => ({
|
|
410
410
|
"pointer-events-none opacity-50 cursor-not-allowed": e.isDisabled
|
|
411
|
-
})),
|
|
411
|
+
})), o = Ye(() => ({
|
|
412
412
|
"text-xs leading-4": e.size === "small",
|
|
413
413
|
"text-sm leading-4": e.size === "medium",
|
|
414
414
|
"text-base leading-5": e.size === "large"
|
|
415
415
|
}));
|
|
416
416
|
return {
|
|
417
417
|
inputClasses: t,
|
|
418
|
-
disabledClasses:
|
|
419
|
-
textSizeClasses:
|
|
418
|
+
disabledClasses: l,
|
|
419
|
+
textSizeClasses: o
|
|
420
420
|
};
|
|
421
421
|
}
|
|
422
|
-
const
|
|
422
|
+
const Do = ["placeholder", "type", "tabindex", "value"], Po = { class: "absolute inset-y-2 left-2 w-8 cursor-pointer" }, _o = {
|
|
423
423
|
inheritAttrs: !1
|
|
424
|
-
},
|
|
425
|
-
...
|
|
424
|
+
}, Dr = /* @__PURE__ */ $({
|
|
425
|
+
..._o,
|
|
426
426
|
__name: "Input",
|
|
427
427
|
props: {
|
|
428
428
|
modelValue: {},
|
|
@@ -435,83 +435,83 @@ const Jn = ["placeholder", "type", "tabindex", "value"], er = { class: "absolute
|
|
|
435
435
|
showColorPicker: { type: Boolean }
|
|
436
436
|
},
|
|
437
437
|
emits: ["update:modelValue"],
|
|
438
|
-
setup(e, { expose: t, emit:
|
|
439
|
-
const
|
|
440
|
-
|
|
441
|
-
() =>
|
|
442
|
-
(
|
|
443
|
-
typeof
|
|
438
|
+
setup(e, { expose: t, emit: l }) {
|
|
439
|
+
const o = e, n = O(o.modelValue ?? "");
|
|
440
|
+
Z(
|
|
441
|
+
() => o.modelValue,
|
|
442
|
+
(p) => {
|
|
443
|
+
typeof p == "string" && p !== n.value && (n.value = p);
|
|
444
444
|
}
|
|
445
445
|
);
|
|
446
|
-
const
|
|
447
|
-
isSupported:
|
|
448
|
-
open:
|
|
446
|
+
const r = l, { inputClasses: i, disabledClasses: u, textSizeClasses: c } = rt(o), s = w(() => o.type === "color" ? "text" : o.type), {
|
|
447
|
+
isSupported: a,
|
|
448
|
+
open: d,
|
|
449
449
|
sRGBHex: v
|
|
450
|
-
} =
|
|
451
|
-
|
|
450
|
+
} = uo(), f = () => {
|
|
451
|
+
d();
|
|
452
452
|
};
|
|
453
|
-
|
|
454
|
-
n.value =
|
|
453
|
+
Z(v, (p) => {
|
|
454
|
+
n.value = p, r("update:modelValue", p);
|
|
455
455
|
});
|
|
456
|
-
const
|
|
457
|
-
n.value = (
|
|
458
|
-
},
|
|
456
|
+
const g = function(p) {
|
|
457
|
+
n.value = (p == null ? void 0 : p.target).value, r("update:modelValue", (p == null ? void 0 : p.target).value);
|
|
458
|
+
}, m = O(null);
|
|
459
459
|
return t({
|
|
460
460
|
focus: () => {
|
|
461
|
-
|
|
461
|
+
o.isDisabled || m.value.focus();
|
|
462
462
|
}
|
|
463
|
-
}), (
|
|
464
|
-
class:
|
|
463
|
+
}), (p, S) => (R(), T("div", {
|
|
464
|
+
class: A(["relative", [p.block ? "w-full block" : "inline-block"]])
|
|
465
465
|
}, [
|
|
466
|
-
|
|
467
|
-
class: ["relative mono-50 bg-white text-grey-800 placeholder:text-grey-400 placeholder:font-normal border-grey-300 dark:bg-grey-800 dark:text-grey-100 dark:placeholder:text-grey-500 dark:border-grey-700 focus:border-blue-400 focus:ring-blue-400 dark:focus:border-blue-800 dark:focus:ring-blue-800 rounded", [
|
|
468
|
-
placeholder:
|
|
466
|
+
I("input", ot({
|
|
467
|
+
class: ["relative mono-50 bg-white text-grey-800 placeholder:text-grey-400 placeholder:font-normal border-grey-300 dark:bg-grey-800 dark:text-grey-100 dark:placeholder:text-grey-500 dark:border-grey-700 focus:border-blue-400 focus:ring-blue-400 dark:focus:border-blue-800 dark:focus:ring-blue-800 rounded", [P(i), P(c), P(u)]],
|
|
468
|
+
placeholder: p.placeholder,
|
|
469
469
|
type: s.value,
|
|
470
|
-
tabindex:
|
|
470
|
+
tabindex: p.isDisabled ? "-1" : void 0,
|
|
471
471
|
value: n.value
|
|
472
|
-
},
|
|
472
|
+
}, p.$attrs, {
|
|
473
473
|
ref_key: "input",
|
|
474
|
-
ref:
|
|
475
|
-
onInput:
|
|
476
|
-
}), null, 16,
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
474
|
+
ref: m,
|
|
475
|
+
onInput: g
|
|
476
|
+
}), null, 16, Do),
|
|
477
|
+
p.type === "color" ? (R(), T(be, { key: 0 }, [
|
|
478
|
+
I("label", Po, [
|
|
479
|
+
$n(I("input", {
|
|
480
480
|
class: "invisible",
|
|
481
481
|
type: "color",
|
|
482
|
-
"onUpdate:modelValue":
|
|
483
|
-
onInput:
|
|
482
|
+
"onUpdate:modelValue": S[0] || (S[0] = (y) => n.value = y),
|
|
483
|
+
onInput: g
|
|
484
484
|
}, null, 544), [
|
|
485
|
-
[
|
|
485
|
+
[An, n.value]
|
|
486
486
|
]),
|
|
487
|
-
|
|
487
|
+
I("span", {
|
|
488
488
|
class: "border-1 absolute inset-0 block rounded border border-grey-600/25 bg-clip-border shadow",
|
|
489
|
-
style:
|
|
489
|
+
style: Ft(`background-color: ${n.value}`)
|
|
490
490
|
}, null, 4)
|
|
491
491
|
]),
|
|
492
|
-
|
|
492
|
+
P(a) && p.showColorPicker ? (R(), T("button", {
|
|
493
493
|
key: 0,
|
|
494
494
|
type: "button",
|
|
495
495
|
class: "absolute inset-y-2 right-2 h-7 w-7 rounded-full hover:bg-grey-200",
|
|
496
|
-
onClick:
|
|
496
|
+
onClick: f
|
|
497
497
|
}, [
|
|
498
|
-
|
|
498
|
+
N(U, {
|
|
499
499
|
size: "xs",
|
|
500
500
|
name: "eyedropper"
|
|
501
501
|
})
|
|
502
|
-
])) :
|
|
503
|
-
], 64)) :
|
|
502
|
+
])) : M("", !0)
|
|
503
|
+
], 64)) : p.icon ? (R(), T("span", {
|
|
504
504
|
key: 1,
|
|
505
|
-
class:
|
|
505
|
+
class: A(["absolute left-0 inset-y-0 inline-flex items-center justify-center text-grey-700 dark:text-grey-100 px-4", P(c)])
|
|
506
506
|
}, [
|
|
507
|
-
|
|
508
|
-
], 2)) :
|
|
507
|
+
N(U, { name: p.icon }, null, 8, ["name"])
|
|
508
|
+
], 2)) : M("", !0)
|
|
509
509
|
], 2));
|
|
510
510
|
}
|
|
511
|
-
}),
|
|
511
|
+
}), To = { class: "inline-block text-grey-700 dark:text-grey-200 text-sm font-medium casual-20" }, Lo = ["for"], Io = {
|
|
512
512
|
key: 0,
|
|
513
513
|
class: "block text-xs text-grey-400 font-normal mono-0 casual-60"
|
|
514
|
-
},
|
|
514
|
+
}, Pr = /* @__PURE__ */ $({
|
|
515
515
|
__name: "Label",
|
|
516
516
|
props: {
|
|
517
517
|
id: {},
|
|
@@ -519,174 +519,174 @@ const Jn = ["placeholder", "type", "tabindex", "value"], er = { class: "absolute
|
|
|
519
519
|
description: {}
|
|
520
520
|
},
|
|
521
521
|
setup(e) {
|
|
522
|
-
return (t,
|
|
523
|
-
|
|
524
|
-
t.description ? (
|
|
522
|
+
return (t, l) => (R(), T("span", To, [
|
|
523
|
+
I("label", { for: t.id }, B(t.label), 9, Lo),
|
|
524
|
+
t.description ? (R(), T("span", Io, B(t.description), 1)) : M("", !0)
|
|
525
525
|
]));
|
|
526
526
|
}
|
|
527
527
|
});
|
|
528
|
-
function
|
|
528
|
+
function G(e, t, ...l) {
|
|
529
529
|
if (e in t) {
|
|
530
530
|
let n = t[e];
|
|
531
|
-
return typeof n == "function" ? n(...
|
|
531
|
+
return typeof n == "function" ? n(...l) : n;
|
|
532
532
|
}
|
|
533
|
-
let
|
|
534
|
-
throw Error.captureStackTrace && Error.captureStackTrace(
|
|
533
|
+
let o = new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map((n) => `"${n}"`).join(", ")}.`);
|
|
534
|
+
throw Error.captureStackTrace && Error.captureStackTrace(o, G), o;
|
|
535
535
|
}
|
|
536
|
-
var
|
|
537
|
-
function
|
|
538
|
-
var
|
|
539
|
-
let i =
|
|
536
|
+
var Re = ((e) => (e[e.None = 0] = "None", e[e.RenderStrategy = 1] = "RenderStrategy", e[e.Static = 2] = "Static", e))(Re || {}), $o = ((e) => (e[e.Unmount = 0] = "Unmount", e[e.Hidden = 1] = "Hidden", e))($o || {});
|
|
537
|
+
function z({ visible: e = !0, features: t = 0, ourProps: l, theirProps: o, ...n }) {
|
|
538
|
+
var r;
|
|
539
|
+
let i = Qt(o, l), u = Object.assign(n, { props: i });
|
|
540
540
|
if (e || t & 2 && i.static)
|
|
541
|
-
return
|
|
541
|
+
return Ze(u);
|
|
542
542
|
if (t & 1) {
|
|
543
|
-
let c = (
|
|
544
|
-
return
|
|
543
|
+
let c = (r = i.unmount) == null || r ? 0 : 1;
|
|
544
|
+
return G(c, { 0() {
|
|
545
545
|
return null;
|
|
546
546
|
}, 1() {
|
|
547
|
-
return
|
|
547
|
+
return Ze({ ...n, props: { ...i, hidden: !0, style: { display: "none" } } });
|
|
548
548
|
} });
|
|
549
549
|
}
|
|
550
|
-
return
|
|
550
|
+
return Ze(u);
|
|
551
551
|
}
|
|
552
|
-
function
|
|
553
|
-
var
|
|
554
|
-
let { as: u, ...c } =
|
|
555
|
-
if (
|
|
556
|
-
let
|
|
557
|
-
for (let [
|
|
558
|
-
typeof
|
|
559
|
-
|
|
552
|
+
function Ze({ props: e, attrs: t, slots: l, slot: o, name: n }) {
|
|
553
|
+
var r, i;
|
|
554
|
+
let { as: u, ...c } = it(e, ["unmount", "static"]), s = (r = l.default) == null ? void 0 : r.call(l, o), a = {};
|
|
555
|
+
if (o) {
|
|
556
|
+
let d = !1, v = [];
|
|
557
|
+
for (let [f, g] of Object.entries(o))
|
|
558
|
+
typeof g == "boolean" && (d = !0), g === !0 && v.push(f);
|
|
559
|
+
d && (a["data-headlessui-state"] = v.join(" "));
|
|
560
560
|
}
|
|
561
561
|
if (u === "template") {
|
|
562
|
-
if (s =
|
|
563
|
-
let [
|
|
564
|
-
if (!
|
|
565
|
-
throw new Error(['Passing props on "template"!', "", `The current component <${n} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(c).concat(Object.keys(t)).map((
|
|
566
|
-
`), "", "You can apply a few solutions:", ['Add an `as="..."` prop, to ensure that we render an actual element instead of a "template".', "Render a single element as the child so that we can forward the props onto that element."].map((
|
|
562
|
+
if (s = Zt(s ?? []), Object.keys(c).length > 0 || Object.keys(t).length > 0) {
|
|
563
|
+
let [d, ...v] = s ?? [];
|
|
564
|
+
if (!Ao(d) || v.length > 0)
|
|
565
|
+
throw new Error(['Passing props on "template"!', "", `The current component <${n} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(c).concat(Object.keys(t)).map((m) => m.trim()).filter((m, b, p) => p.indexOf(m) === b).sort((m, b) => m.localeCompare(b)).map((m) => ` - ${m}`).join(`
|
|
566
|
+
`), "", "You can apply a few solutions:", ['Add an `as="..."` prop, to ensure that we render an actual element instead of a "template".', "Render a single element as the child so that we can forward the props onto that element."].map((m) => ` - ${m}`).join(`
|
|
567
567
|
`)].join(`
|
|
568
568
|
`));
|
|
569
|
-
let
|
|
570
|
-
for (let
|
|
571
|
-
|
|
572
|
-
return
|
|
569
|
+
let f = Qt((i = d.props) != null ? i : {}, c), g = Mn(d, f);
|
|
570
|
+
for (let m in f)
|
|
571
|
+
m.startsWith("on") && (g.props || (g.props = {}), g.props[m] = f[m]);
|
|
572
|
+
return g;
|
|
573
573
|
}
|
|
574
574
|
return Array.isArray(s) && s.length === 1 ? s[0] : s;
|
|
575
575
|
}
|
|
576
|
-
return
|
|
576
|
+
return Ce(u, Object.assign({}, c, a), { default: () => s });
|
|
577
577
|
}
|
|
578
|
-
function
|
|
579
|
-
return e.flatMap((t) => t.type ===
|
|
578
|
+
function Zt(e) {
|
|
579
|
+
return e.flatMap((t) => t.type === be ? Zt(t.children) : [t]);
|
|
580
580
|
}
|
|
581
|
-
function
|
|
581
|
+
function Qt(...e) {
|
|
582
582
|
if (e.length === 0)
|
|
583
583
|
return {};
|
|
584
584
|
if (e.length === 1)
|
|
585
585
|
return e[0];
|
|
586
|
-
let t = {},
|
|
587
|
-
for (let
|
|
588
|
-
for (let n in
|
|
589
|
-
n.startsWith("on") && typeof
|
|
586
|
+
let t = {}, l = {};
|
|
587
|
+
for (let o of e)
|
|
588
|
+
for (let n in o)
|
|
589
|
+
n.startsWith("on") && typeof o[n] == "function" ? (l[n] != null || (l[n] = []), l[n].push(o[n])) : t[n] = o[n];
|
|
590
590
|
if (t.disabled || t["aria-disabled"])
|
|
591
|
-
return Object.assign(t, Object.fromEntries(Object.keys(
|
|
592
|
-
for (let
|
|
593
|
-
Object.assign(t, { [
|
|
594
|
-
let i = o
|
|
591
|
+
return Object.assign(t, Object.fromEntries(Object.keys(l).map((o) => [o, void 0])));
|
|
592
|
+
for (let o in l)
|
|
593
|
+
Object.assign(t, { [o](n, ...r) {
|
|
594
|
+
let i = l[o];
|
|
595
595
|
for (let u of i) {
|
|
596
596
|
if (n instanceof Event && n.defaultPrevented)
|
|
597
597
|
return;
|
|
598
|
-
u(n, ...
|
|
598
|
+
u(n, ...r);
|
|
599
599
|
}
|
|
600
600
|
} });
|
|
601
601
|
return t;
|
|
602
602
|
}
|
|
603
|
-
function
|
|
603
|
+
function Jt(e) {
|
|
604
604
|
let t = Object.assign({}, e);
|
|
605
|
-
for (let
|
|
606
|
-
t[
|
|
605
|
+
for (let l in t)
|
|
606
|
+
t[l] === void 0 && delete t[l];
|
|
607
607
|
return t;
|
|
608
608
|
}
|
|
609
|
-
function
|
|
610
|
-
let
|
|
611
|
-
for (let
|
|
612
|
-
|
|
613
|
-
return
|
|
609
|
+
function it(e, t = []) {
|
|
610
|
+
let l = Object.assign({}, e);
|
|
611
|
+
for (let o of t)
|
|
612
|
+
o in l && delete l[o];
|
|
613
|
+
return l;
|
|
614
614
|
}
|
|
615
|
-
function
|
|
615
|
+
function Ao(e) {
|
|
616
616
|
return e == null ? !1 : typeof e.type == "string" || typeof e.type == "object" || typeof e.type == "function";
|
|
617
617
|
}
|
|
618
|
-
let
|
|
619
|
-
function
|
|
620
|
-
return ++
|
|
618
|
+
let Mo = 0;
|
|
619
|
+
function Vo() {
|
|
620
|
+
return ++Mo;
|
|
621
621
|
}
|
|
622
|
-
function
|
|
623
|
-
return
|
|
622
|
+
function J() {
|
|
623
|
+
return Vo();
|
|
624
624
|
}
|
|
625
|
-
var
|
|
626
|
-
function
|
|
625
|
+
var D = ((e) => (e.Space = " ", e.Enter = "Enter", e.Escape = "Escape", e.Backspace = "Backspace", e.Delete = "Delete", e.ArrowLeft = "ArrowLeft", e.ArrowUp = "ArrowUp", e.ArrowRight = "ArrowRight", e.ArrowDown = "ArrowDown", e.Home = "Home", e.End = "End", e.PageUp = "PageUp", e.PageDown = "PageDown", e.Tab = "Tab", e))(D || {});
|
|
626
|
+
function No(e) {
|
|
627
627
|
throw new Error("Unexpected object: " + e);
|
|
628
628
|
}
|
|
629
629
|
var L = ((e) => (e[e.First = 0] = "First", e[e.Previous = 1] = "Previous", e[e.Next = 2] = "Next", e[e.Last = 3] = "Last", e[e.Specific = 4] = "Specific", e[e.Nothing = 5] = "Nothing", e))(L || {});
|
|
630
|
-
function
|
|
631
|
-
let
|
|
632
|
-
if (
|
|
630
|
+
function en(e, t) {
|
|
631
|
+
let l = t.resolveItems();
|
|
632
|
+
if (l.length <= 0)
|
|
633
633
|
return null;
|
|
634
|
-
let
|
|
634
|
+
let o = t.resolveActiveIndex(), n = o ?? -1, r = (() => {
|
|
635
635
|
switch (e.focus) {
|
|
636
636
|
case 0:
|
|
637
|
-
return
|
|
637
|
+
return l.findIndex((i) => !t.resolveDisabled(i));
|
|
638
638
|
case 1: {
|
|
639
|
-
let i =
|
|
640
|
-
return i === -1 ? i :
|
|
639
|
+
let i = l.slice().reverse().findIndex((u, c, s) => n !== -1 && s.length - c - 1 >= n ? !1 : !t.resolveDisabled(u));
|
|
640
|
+
return i === -1 ? i : l.length - 1 - i;
|
|
641
641
|
}
|
|
642
642
|
case 2:
|
|
643
|
-
return
|
|
643
|
+
return l.findIndex((i, u) => u <= n ? !1 : !t.resolveDisabled(i));
|
|
644
644
|
case 3: {
|
|
645
|
-
let i =
|
|
646
|
-
return i === -1 ? i :
|
|
645
|
+
let i = l.slice().reverse().findIndex((u) => !t.resolveDisabled(u));
|
|
646
|
+
return i === -1 ? i : l.length - 1 - i;
|
|
647
647
|
}
|
|
648
648
|
case 4:
|
|
649
|
-
return
|
|
649
|
+
return l.findIndex((i) => t.resolveId(i) === e.id);
|
|
650
650
|
case 5:
|
|
651
651
|
return null;
|
|
652
652
|
default:
|
|
653
|
-
|
|
653
|
+
No(e);
|
|
654
654
|
}
|
|
655
655
|
})();
|
|
656
|
-
return
|
|
656
|
+
return r === -1 ? o : r;
|
|
657
657
|
}
|
|
658
|
-
function
|
|
658
|
+
function E(e) {
|
|
659
659
|
var t;
|
|
660
660
|
return e == null || e.value == null ? null : (t = e.value.$el) != null ? t : e.value;
|
|
661
661
|
}
|
|
662
|
-
let
|
|
663
|
-
var
|
|
664
|
-
function
|
|
665
|
-
return
|
|
662
|
+
let tn = Symbol("Context");
|
|
663
|
+
var te = ((e) => (e[e.Open = 1] = "Open", e[e.Closed = 2] = "Closed", e[e.Closing = 4] = "Closing", e[e.Opening = 8] = "Opening", e))(te || {});
|
|
664
|
+
function nn() {
|
|
665
|
+
return he(tn, null);
|
|
666
666
|
}
|
|
667
|
-
function
|
|
668
|
-
|
|
667
|
+
function on(e) {
|
|
668
|
+
ye(tn, e);
|
|
669
669
|
}
|
|
670
|
-
function
|
|
670
|
+
function Et(e, t) {
|
|
671
671
|
if (e)
|
|
672
672
|
return e;
|
|
673
|
-
let
|
|
674
|
-
if (typeof
|
|
673
|
+
let l = t ?? "button";
|
|
674
|
+
if (typeof l == "string" && l.toLowerCase() === "button")
|
|
675
675
|
return "button";
|
|
676
676
|
}
|
|
677
|
-
function
|
|
678
|
-
let
|
|
679
|
-
return
|
|
680
|
-
|
|
681
|
-
}),
|
|
682
|
-
var
|
|
683
|
-
|
|
684
|
-
}),
|
|
685
|
-
}
|
|
686
|
-
var
|
|
687
|
-
class
|
|
677
|
+
function at(e, t) {
|
|
678
|
+
let l = O(Et(e.value.type, e.value.as));
|
|
679
|
+
return ee(() => {
|
|
680
|
+
l.value = Et(e.value.type, e.value.as);
|
|
681
|
+
}), xe(() => {
|
|
682
|
+
var o;
|
|
683
|
+
l.value || E(t) && E(t) instanceof HTMLButtonElement && !((o = E(t)) != null && o.hasAttribute("type")) && (l.value = "button");
|
|
684
|
+
}), l;
|
|
685
|
+
}
|
|
686
|
+
var Fo = Object.defineProperty, Bo = (e, t, l) => t in e ? Fo(e, t, { enumerable: !0, configurable: !0, writable: !0, value: l }) : e[t] = l, Dt = (e, t, l) => (Bo(e, typeof t != "symbol" ? t + "" : t, l), l);
|
|
687
|
+
class jo {
|
|
688
688
|
constructor() {
|
|
689
|
-
|
|
689
|
+
Dt(this, "current", this.detect()), Dt(this, "currentId", 0);
|
|
690
690
|
}
|
|
691
691
|
set(t) {
|
|
692
692
|
this.current !== t && (this.currentId = 0, this.current = t);
|
|
@@ -707,88 +707,88 @@ class fr {
|
|
|
707
707
|
return typeof window > "u" || typeof document > "u" ? "server" : "client";
|
|
708
708
|
}
|
|
709
709
|
}
|
|
710
|
-
let
|
|
711
|
-
function
|
|
712
|
-
if (
|
|
710
|
+
let st = new jo();
|
|
711
|
+
function ut(e) {
|
|
712
|
+
if (st.isServer)
|
|
713
713
|
return null;
|
|
714
714
|
if (e instanceof Node)
|
|
715
715
|
return e.ownerDocument;
|
|
716
716
|
if (e != null && e.hasOwnProperty("value")) {
|
|
717
|
-
let t =
|
|
717
|
+
let t = E(e);
|
|
718
718
|
if (t)
|
|
719
719
|
return t.ownerDocument;
|
|
720
720
|
}
|
|
721
721
|
return document;
|
|
722
722
|
}
|
|
723
|
-
function
|
|
724
|
-
|
|
723
|
+
function zo({ container: e, accept: t, walk: l, enabled: o }) {
|
|
724
|
+
xe(() => {
|
|
725
725
|
let n = e.value;
|
|
726
|
-
if (!n ||
|
|
726
|
+
if (!n || o !== void 0 && !o.value)
|
|
727
727
|
return;
|
|
728
|
-
let
|
|
729
|
-
if (!
|
|
728
|
+
let r = ut(e);
|
|
729
|
+
if (!r)
|
|
730
730
|
return;
|
|
731
|
-
let i = Object.assign((c) => t(c), { acceptNode: t }), u =
|
|
731
|
+
let i = Object.assign((c) => t(c), { acceptNode: t }), u = r.createTreeWalker(n, NodeFilter.SHOW_ELEMENT, i, !1);
|
|
732
732
|
for (; u.nextNode(); )
|
|
733
|
-
|
|
733
|
+
l(u.currentNode);
|
|
734
734
|
});
|
|
735
735
|
}
|
|
736
|
-
let
|
|
737
|
-
var
|
|
738
|
-
function
|
|
739
|
-
return e == null ? [] : Array.from(e.querySelectorAll(
|
|
736
|
+
let et = ["[contentEditable=true]", "[tabindex]", "a[href]", "area[href]", "button:not([disabled])", "iframe", "input:not([disabled])", "select:not([disabled])", "textarea:not([disabled])"].map((e) => `${e}:not([tabindex='-1'])`).join(",");
|
|
737
|
+
var tt = ((e) => (e[e.First = 1] = "First", e[e.Previous = 2] = "Previous", e[e.Next = 4] = "Next", e[e.Last = 8] = "Last", e[e.WrapAround = 16] = "WrapAround", e[e.NoScroll = 32] = "NoScroll", e))(tt || {}), Uo = ((e) => (e[e.Error = 0] = "Error", e[e.Overflow = 1] = "Overflow", e[e.Success = 2] = "Success", e[e.Underflow = 3] = "Underflow", e))(Uo || {}), Ho = ((e) => (e[e.Previous = -1] = "Previous", e[e.Next = 1] = "Next", e))(Ho || {});
|
|
738
|
+
function ln(e = document.body) {
|
|
739
|
+
return e == null ? [] : Array.from(e.querySelectorAll(et)).sort((t, l) => Math.sign((t.tabIndex || Number.MAX_SAFE_INTEGER) - (l.tabIndex || Number.MAX_SAFE_INTEGER)));
|
|
740
740
|
}
|
|
741
|
-
var
|
|
742
|
-
function
|
|
743
|
-
var
|
|
744
|
-
return e === ((
|
|
745
|
-
return e.matches(
|
|
741
|
+
var je = ((e) => (e[e.Strict = 0] = "Strict", e[e.Loose = 1] = "Loose", e))(je || {});
|
|
742
|
+
function ze(e, t = 0) {
|
|
743
|
+
var l;
|
|
744
|
+
return e === ((l = ut(e)) == null ? void 0 : l.body) ? !1 : G(t, { 0() {
|
|
745
|
+
return e.matches(et);
|
|
746
746
|
}, 1() {
|
|
747
|
-
let
|
|
748
|
-
for (;
|
|
749
|
-
if (
|
|
747
|
+
let o = e;
|
|
748
|
+
for (; o !== null; ) {
|
|
749
|
+
if (o.matches(et))
|
|
750
750
|
return !0;
|
|
751
|
-
|
|
751
|
+
o = o.parentElement;
|
|
752
752
|
}
|
|
753
753
|
return !1;
|
|
754
754
|
} });
|
|
755
755
|
}
|
|
756
|
-
function
|
|
757
|
-
let t =
|
|
758
|
-
|
|
759
|
-
t && !
|
|
756
|
+
function rn(e) {
|
|
757
|
+
let t = ut(e);
|
|
758
|
+
j(() => {
|
|
759
|
+
t && !ze(t.activeElement, 0) && Ko(e);
|
|
760
760
|
});
|
|
761
761
|
}
|
|
762
|
-
var
|
|
762
|
+
var Wo = ((e) => (e[e.Keyboard = 0] = "Keyboard", e[e.Mouse = 1] = "Mouse", e))(Wo || {});
|
|
763
763
|
typeof window < "u" && typeof document < "u" && (document.addEventListener("keydown", (e) => {
|
|
764
764
|
e.metaKey || e.altKey || e.ctrlKey || (document.documentElement.dataset.headlessuiFocusVisible = "");
|
|
765
765
|
}, !0), document.addEventListener("click", (e) => {
|
|
766
766
|
e.detail === 1 ? delete document.documentElement.dataset.headlessuiFocusVisible : e.detail === 0 && (document.documentElement.dataset.headlessuiFocusVisible = "");
|
|
767
767
|
}, !0));
|
|
768
|
-
function
|
|
768
|
+
function Ko(e) {
|
|
769
769
|
e == null || e.focus({ preventScroll: !0 });
|
|
770
770
|
}
|
|
771
|
-
let
|
|
772
|
-
function
|
|
773
|
-
var t,
|
|
774
|
-
return (
|
|
771
|
+
let Go = ["textarea", "input"].join(",");
|
|
772
|
+
function qo(e) {
|
|
773
|
+
var t, l;
|
|
774
|
+
return (l = (t = e == null ? void 0 : e.matches) == null ? void 0 : t.call(e, Go)) != null ? l : !1;
|
|
775
775
|
}
|
|
776
|
-
function
|
|
777
|
-
return e.slice().sort((
|
|
778
|
-
let n = t(
|
|
779
|
-
if (n === null ||
|
|
776
|
+
function ct(e, t = (l) => l) {
|
|
777
|
+
return e.slice().sort((l, o) => {
|
|
778
|
+
let n = t(l), r = t(o);
|
|
779
|
+
if (n === null || r === null)
|
|
780
780
|
return 0;
|
|
781
|
-
let i = n.compareDocumentPosition(
|
|
781
|
+
let i = n.compareDocumentPosition(r);
|
|
782
782
|
return i & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : i & Node.DOCUMENT_POSITION_PRECEDING ? 1 : 0;
|
|
783
783
|
});
|
|
784
784
|
}
|
|
785
|
-
function
|
|
786
|
-
return
|
|
785
|
+
function Xo(e, t) {
|
|
786
|
+
return Yo(ln(), t, { relativeTo: e });
|
|
787
787
|
}
|
|
788
|
-
function
|
|
789
|
-
var
|
|
790
|
-
let i = (
|
|
791
|
-
n.length > 0 && u.length > 1 && (u = u.filter((
|
|
788
|
+
function Yo(e, t, { sorted: l = !0, relativeTo: o = null, skipElements: n = [] } = {}) {
|
|
789
|
+
var r;
|
|
790
|
+
let i = (r = Array.isArray(e) ? e.length > 0 ? e[0].ownerDocument : document : e == null ? void 0 : e.ownerDocument) != null ? r : document, u = Array.isArray(e) ? l ? ct(e) : e : ln(e);
|
|
791
|
+
n.length > 0 && u.length > 1 && (u = u.filter((g) => !n.includes(g))), o = o ?? i.activeElement;
|
|
792
792
|
let c = (() => {
|
|
793
793
|
if (t & 5)
|
|
794
794
|
return 1;
|
|
@@ -799,409 +799,409 @@ function xr(e, t, { sorted: o = !0, relativeTo: r = null, skipElements: n = [] }
|
|
|
799
799
|
if (t & 1)
|
|
800
800
|
return 0;
|
|
801
801
|
if (t & 2)
|
|
802
|
-
return Math.max(0, u.indexOf(
|
|
802
|
+
return Math.max(0, u.indexOf(o)) - 1;
|
|
803
803
|
if (t & 4)
|
|
804
|
-
return Math.max(0, u.indexOf(
|
|
804
|
+
return Math.max(0, u.indexOf(o)) + 1;
|
|
805
805
|
if (t & 8)
|
|
806
806
|
return u.length - 1;
|
|
807
807
|
throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last");
|
|
808
|
-
})(),
|
|
808
|
+
})(), a = t & 32 ? { preventScroll: !0 } : {}, d = 0, v = u.length, f;
|
|
809
809
|
do {
|
|
810
|
-
if (
|
|
810
|
+
if (d >= v || d + v <= 0)
|
|
811
811
|
return 0;
|
|
812
|
-
let
|
|
812
|
+
let g = s + d;
|
|
813
813
|
if (t & 16)
|
|
814
|
-
|
|
814
|
+
g = (g + v) % v;
|
|
815
815
|
else {
|
|
816
|
-
if (
|
|
816
|
+
if (g < 0)
|
|
817
817
|
return 3;
|
|
818
|
-
if (
|
|
818
|
+
if (g >= v)
|
|
819
819
|
return 1;
|
|
820
820
|
}
|
|
821
|
-
|
|
822
|
-
} while (
|
|
823
|
-
return t & 6 &&
|
|
821
|
+
f = u[g], f == null || f.focus(a), d += c;
|
|
822
|
+
} while (f !== i.activeElement);
|
|
823
|
+
return t & 6 && qo(f) && f.select(), 2;
|
|
824
824
|
}
|
|
825
|
-
function
|
|
826
|
-
|
|
827
|
-
document.addEventListener(e, t,
|
|
825
|
+
function Le(e, t, l) {
|
|
826
|
+
st.isServer || xe((o) => {
|
|
827
|
+
document.addEventListener(e, t, l), o(() => document.removeEventListener(e, t, l));
|
|
828
828
|
});
|
|
829
829
|
}
|
|
830
|
-
function
|
|
831
|
-
|
|
832
|
-
window.addEventListener(e, t,
|
|
830
|
+
function Zo(e, t, l) {
|
|
831
|
+
st.isServer || xe((o) => {
|
|
832
|
+
window.addEventListener(e, t, l), o(() => window.removeEventListener(e, t, l));
|
|
833
833
|
});
|
|
834
834
|
}
|
|
835
|
-
function
|
|
836
|
-
function r
|
|
837
|
-
if (!
|
|
835
|
+
function an(e, t, l = w(() => !0)) {
|
|
836
|
+
function o(r, i) {
|
|
837
|
+
if (!l.value || r.defaultPrevented)
|
|
838
838
|
return;
|
|
839
|
-
let u = i(
|
|
839
|
+
let u = i(r);
|
|
840
840
|
if (u === null || !u.getRootNode().contains(u))
|
|
841
841
|
return;
|
|
842
|
-
let c = function s(
|
|
843
|
-
return typeof
|
|
842
|
+
let c = function s(a) {
|
|
843
|
+
return typeof a == "function" ? s(a()) : Array.isArray(a) || a instanceof Set ? a : [a];
|
|
844
844
|
}(e);
|
|
845
845
|
for (let s of c) {
|
|
846
846
|
if (s === null)
|
|
847
847
|
continue;
|
|
848
|
-
let
|
|
849
|
-
if (
|
|
848
|
+
let a = s instanceof HTMLElement ? s : E(s);
|
|
849
|
+
if (a != null && a.contains(u) || r.composed && r.composedPath().includes(a))
|
|
850
850
|
return;
|
|
851
851
|
}
|
|
852
|
-
return !
|
|
852
|
+
return !ze(u, je.Loose) && u.tabIndex !== -1 && r.preventDefault(), t(r, u);
|
|
853
853
|
}
|
|
854
854
|
let n = O(null);
|
|
855
|
-
|
|
855
|
+
Le("pointerdown", (r) => {
|
|
856
856
|
var i, u;
|
|
857
|
-
|
|
858
|
-
}, !0),
|
|
857
|
+
l.value && (n.value = ((u = (i = r.composedPath) == null ? void 0 : i.call(r)) == null ? void 0 : u[0]) || r.target);
|
|
858
|
+
}, !0), Le("mousedown", (r) => {
|
|
859
859
|
var i, u;
|
|
860
|
-
|
|
861
|
-
}, !0),
|
|
862
|
-
n.value && (r
|
|
863
|
-
}, !0),
|
|
860
|
+
l.value && (n.value = ((u = (i = r.composedPath) == null ? void 0 : i.call(r)) == null ? void 0 : u[0]) || r.target);
|
|
861
|
+
}, !0), Le("click", (r) => {
|
|
862
|
+
n.value && (o(r, () => n.value), n.value = null);
|
|
863
|
+
}, !0), Le("touchend", (r) => o(r, () => r.target instanceof HTMLElement ? r.target : null), !0), Zo("blur", (r) => o(r, () => window.document.activeElement instanceof HTMLIFrameElement ? window.document.activeElement : null), !0);
|
|
864
864
|
}
|
|
865
|
-
var
|
|
866
|
-
let
|
|
865
|
+
var dt = ((e) => (e[e.None = 1] = "None", e[e.Focusable = 2] = "Focusable", e[e.Hidden = 4] = "Hidden", e))(dt || {});
|
|
866
|
+
let sn = $({ name: "Hidden", props: { as: { type: [Object, String], default: "div" }, features: { type: Number, default: 1 } }, setup(e, { slots: t, attrs: l }) {
|
|
867
867
|
return () => {
|
|
868
|
-
let { features:
|
|
869
|
-
return
|
|
868
|
+
let { features: o, ...n } = e, r = { "aria-hidden": (o & 2) === 2 ? !0 : void 0, style: { position: "fixed", top: 1, left: 1, width: 1, height: 0, padding: 0, margin: -1, overflow: "hidden", clip: "rect(0, 0, 0, 0)", whiteSpace: "nowrap", borderWidth: "0", ...(o & 4) === 4 && (o & 2) !== 2 && { display: "none" } } };
|
|
869
|
+
return z({ ourProps: r, theirProps: n, slot: {}, attrs: l, slots: t, name: "Hidden" });
|
|
870
870
|
};
|
|
871
871
|
} });
|
|
872
|
-
function
|
|
873
|
-
for (let [
|
|
874
|
-
|
|
875
|
-
return
|
|
872
|
+
function un(e = {}, t = null, l = []) {
|
|
873
|
+
for (let [o, n] of Object.entries(e))
|
|
874
|
+
dn(l, cn(t, o), n);
|
|
875
|
+
return l;
|
|
876
876
|
}
|
|
877
|
-
function
|
|
877
|
+
function cn(e, t) {
|
|
878
878
|
return e ? e + "[" + t + "]" : t;
|
|
879
879
|
}
|
|
880
|
-
function
|
|
881
|
-
if (Array.isArray(
|
|
882
|
-
for (let [
|
|
883
|
-
|
|
880
|
+
function dn(e, t, l) {
|
|
881
|
+
if (Array.isArray(l))
|
|
882
|
+
for (let [o, n] of l.entries())
|
|
883
|
+
dn(e, cn(t, o.toString()), n);
|
|
884
884
|
else
|
|
885
|
-
|
|
885
|
+
l instanceof Date ? e.push([t, l.toISOString()]) : typeof l == "boolean" ? e.push([t, l ? "1" : "0"]) : typeof l == "string" ? e.push([t, l]) : typeof l == "number" ? e.push([t, `${l}`]) : l == null ? e.push([t, ""]) : un(l, t, e);
|
|
886
886
|
}
|
|
887
|
-
function
|
|
888
|
-
var t,
|
|
889
|
-
let
|
|
890
|
-
if (
|
|
891
|
-
for (let n of
|
|
887
|
+
function Qo(e) {
|
|
888
|
+
var t, l;
|
|
889
|
+
let o = (t = e == null ? void 0 : e.form) != null ? t : e.closest("form");
|
|
890
|
+
if (o) {
|
|
891
|
+
for (let n of o.elements)
|
|
892
892
|
if (n !== e && (n.tagName === "INPUT" && n.type === "submit" || n.tagName === "BUTTON" && n.type === "submit" || n.nodeName === "INPUT" && n.type === "image")) {
|
|
893
893
|
n.click();
|
|
894
894
|
return;
|
|
895
895
|
}
|
|
896
|
-
(
|
|
896
|
+
(l = o.requestSubmit) == null || l.call(o);
|
|
897
897
|
}
|
|
898
898
|
}
|
|
899
|
-
function
|
|
900
|
-
let
|
|
901
|
-
return [
|
|
902
|
-
return n.value || (
|
|
899
|
+
function fn(e, t, l) {
|
|
900
|
+
let o = O(l == null ? void 0 : l.value), n = w(() => e.value !== void 0);
|
|
901
|
+
return [w(() => n.value ? e.value : o.value), function(r) {
|
|
902
|
+
return n.value || (o.value = r), t == null ? void 0 : t(r);
|
|
903
903
|
}];
|
|
904
904
|
}
|
|
905
|
-
function
|
|
905
|
+
function Pt(e) {
|
|
906
906
|
return [e.screenX, e.screenY];
|
|
907
907
|
}
|
|
908
|
-
function
|
|
908
|
+
function pn() {
|
|
909
909
|
let e = O([-1, -1]);
|
|
910
910
|
return { wasMoved(t) {
|
|
911
|
-
let
|
|
912
|
-
return e.value[0] ===
|
|
911
|
+
let l = Pt(t);
|
|
912
|
+
return e.value[0] === l[0] && e.value[1] === l[1] ? !1 : (e.value = l, !0);
|
|
913
913
|
}, update(t) {
|
|
914
|
-
e.value =
|
|
914
|
+
e.value = Pt(t);
|
|
915
915
|
} };
|
|
916
916
|
}
|
|
917
|
-
let
|
|
918
|
-
function
|
|
919
|
-
let e =
|
|
917
|
+
let mn = Symbol("DescriptionContext");
|
|
918
|
+
function Jo() {
|
|
919
|
+
let e = he(mn, null);
|
|
920
920
|
if (e === null)
|
|
921
921
|
throw new Error("Missing parent");
|
|
922
922
|
return e;
|
|
923
923
|
}
|
|
924
|
-
function
|
|
925
|
-
let
|
|
926
|
-
function n(
|
|
927
|
-
return
|
|
928
|
-
let i =
|
|
929
|
-
i !== -1 &&
|
|
924
|
+
function el({ slot: e = O({}), name: t = "Description", props: l = {} } = {}) {
|
|
925
|
+
let o = O([]);
|
|
926
|
+
function n(r) {
|
|
927
|
+
return o.value.push(r), () => {
|
|
928
|
+
let i = o.value.indexOf(r);
|
|
929
|
+
i !== -1 && o.value.splice(i, 1);
|
|
930
930
|
};
|
|
931
931
|
}
|
|
932
|
-
return
|
|
932
|
+
return ye(mn, { register: n, slot: e, name: t, props: l }), w(() => o.value.length > 0 ? o.value.join(" ") : void 0);
|
|
933
933
|
}
|
|
934
|
-
|
|
935
|
-
let
|
|
936
|
-
return
|
|
937
|
-
let { name: n = "Description", slot:
|
|
938
|
-
return
|
|
934
|
+
$({ name: "Description", props: { as: { type: [Object, String], default: "p" }, id: { type: String, default: () => `headlessui-description-${J()}` } }, setup(e, { attrs: t, slots: l }) {
|
|
935
|
+
let o = Jo();
|
|
936
|
+
return ee(() => Fe(o.register(e.id))), () => {
|
|
937
|
+
let { name: n = "Description", slot: r = O({}), props: i = {} } = o, { id: u, ...c } = e, s = { ...Object.entries(i).reduce((a, [d, v]) => Object.assign(a, { [d]: P(v) }), {}), id: u };
|
|
938
|
+
return z({ ourProps: s, theirProps: c, slot: r.value, attrs: t, slots: l, name: n });
|
|
939
939
|
};
|
|
940
940
|
} });
|
|
941
|
-
let
|
|
942
|
-
function
|
|
943
|
-
var t,
|
|
944
|
-
let
|
|
941
|
+
let _t = /([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;
|
|
942
|
+
function Tt(e) {
|
|
943
|
+
var t, l;
|
|
944
|
+
let o = (t = e.innerText) != null ? t : "", n = e.cloneNode(!0);
|
|
945
945
|
if (!(n instanceof HTMLElement))
|
|
946
|
-
return
|
|
947
|
-
let
|
|
946
|
+
return o;
|
|
947
|
+
let r = !1;
|
|
948
948
|
for (let u of n.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))
|
|
949
|
-
u.remove(),
|
|
950
|
-
let i =
|
|
951
|
-
return
|
|
949
|
+
u.remove(), r = !0;
|
|
950
|
+
let i = r ? (l = n.innerText) != null ? l : "" : o;
|
|
951
|
+
return _t.test(i) && (i = i.replace(_t, "")), i;
|
|
952
952
|
}
|
|
953
|
-
function
|
|
953
|
+
function tl(e) {
|
|
954
954
|
let t = e.getAttribute("aria-label");
|
|
955
955
|
if (typeof t == "string")
|
|
956
956
|
return t.trim();
|
|
957
|
-
let
|
|
958
|
-
if (
|
|
959
|
-
let
|
|
960
|
-
let
|
|
961
|
-
if (
|
|
962
|
-
let i =
|
|
963
|
-
return typeof i == "string" ? i.trim() :
|
|
957
|
+
let l = e.getAttribute("aria-labelledby");
|
|
958
|
+
if (l) {
|
|
959
|
+
let o = l.split(" ").map((n) => {
|
|
960
|
+
let r = document.getElementById(n);
|
|
961
|
+
if (r) {
|
|
962
|
+
let i = r.getAttribute("aria-label");
|
|
963
|
+
return typeof i == "string" ? i.trim() : Tt(r).trim();
|
|
964
964
|
}
|
|
965
965
|
return null;
|
|
966
966
|
}).filter(Boolean);
|
|
967
|
-
if (
|
|
968
|
-
return
|
|
967
|
+
if (o.length > 0)
|
|
968
|
+
return o.join(", ");
|
|
969
969
|
}
|
|
970
|
-
return
|
|
970
|
+
return Tt(e).trim();
|
|
971
971
|
}
|
|
972
|
-
function
|
|
973
|
-
let t = O(""),
|
|
972
|
+
function vn(e) {
|
|
973
|
+
let t = O(""), l = O("");
|
|
974
974
|
return () => {
|
|
975
|
-
let
|
|
976
|
-
if (!
|
|
975
|
+
let o = E(e);
|
|
976
|
+
if (!o)
|
|
977
977
|
return "";
|
|
978
|
-
let n =
|
|
978
|
+
let n = o.innerText;
|
|
979
979
|
if (t.value === n)
|
|
980
|
-
return
|
|
981
|
-
let
|
|
982
|
-
return t.value = n,
|
|
980
|
+
return l.value;
|
|
981
|
+
let r = tl(o).trim().toLowerCase();
|
|
982
|
+
return t.value = n, l.value = r, r;
|
|
983
983
|
};
|
|
984
984
|
}
|
|
985
|
-
function
|
|
985
|
+
function nl(e, t) {
|
|
986
986
|
return e === t;
|
|
987
987
|
}
|
|
988
|
-
var
|
|
989
|
-
function
|
|
988
|
+
var ol = ((e) => (e[e.Open = 0] = "Open", e[e.Closed = 1] = "Closed", e))(ol || {}), ll = ((e) => (e[e.Single = 0] = "Single", e[e.Multi = 1] = "Multi", e))(ll || {}), rl = ((e) => (e[e.Pointer = 0] = "Pointer", e[e.Other = 1] = "Other", e))(rl || {});
|
|
989
|
+
function il(e) {
|
|
990
990
|
requestAnimationFrame(() => requestAnimationFrame(e));
|
|
991
991
|
}
|
|
992
|
-
let
|
|
993
|
-
function
|
|
994
|
-
let t =
|
|
992
|
+
let gn = Symbol("ListboxContext");
|
|
993
|
+
function De(e) {
|
|
994
|
+
let t = he(gn, null);
|
|
995
995
|
if (t === null) {
|
|
996
|
-
let
|
|
997
|
-
throw Error.captureStackTrace && Error.captureStackTrace(
|
|
996
|
+
let l = new Error(`<${e} /> is missing a parent <Listbox /> component.`);
|
|
997
|
+
throw Error.captureStackTrace && Error.captureStackTrace(l, De), l;
|
|
998
998
|
}
|
|
999
999
|
return t;
|
|
1000
1000
|
}
|
|
1001
|
-
let
|
|
1002
|
-
let n = O(1),
|
|
1003
|
-
function v(y = (
|
|
1004
|
-
let
|
|
1005
|
-
return
|
|
1001
|
+
let al = $({ name: "Listbox", emits: { "update:modelValue": (e) => !0 }, props: { as: { type: [Object, String], default: "template" }, disabled: { type: [Boolean], default: !1 }, by: { type: [String, Function], default: () => nl }, horizontal: { type: [Boolean], default: !1 }, modelValue: { type: [Object, String, Number, Boolean], default: void 0 }, defaultValue: { type: [Object, String, Number, Boolean], default: void 0 }, form: { type: String, optional: !0 }, name: { type: String, optional: !0 }, multiple: { type: [Boolean], default: !1 } }, inheritAttrs: !1, setup(e, { slots: t, attrs: l, emit: o }) {
|
|
1002
|
+
let n = O(1), r = O(null), i = O(null), u = O(null), c = O([]), s = O(""), a = O(null), d = O(1);
|
|
1003
|
+
function v(y = (x) => x) {
|
|
1004
|
+
let x = a.value !== null ? c.value[a.value] : null, k = ct(y(c.value.slice()), (C) => E(C.dataRef.domRef)), _ = x ? k.indexOf(x) : null;
|
|
1005
|
+
return _ === -1 && (_ = null), { options: k, activeOptionIndex: _ };
|
|
1006
1006
|
}
|
|
1007
|
-
let
|
|
1007
|
+
let f = w(() => e.multiple ? 1 : 0), [g, m] = fn(w(() => e.modelValue), (y) => o("update:modelValue", y), w(() => e.defaultValue)), b = w(() => g.value === void 0 ? G(f.value, { 1: [], 0: void 0 }) : g.value), p = { listboxState: n, value: b, mode: f, compare(y, x) {
|
|
1008
1008
|
if (typeof e.by == "string") {
|
|
1009
|
-
let
|
|
1010
|
-
return (y == null ? void 0 : y[
|
|
1009
|
+
let k = e.by;
|
|
1010
|
+
return (y == null ? void 0 : y[k]) === (x == null ? void 0 : x[k]);
|
|
1011
1011
|
}
|
|
1012
|
-
return e.by(y,
|
|
1013
|
-
}, orientation:
|
|
1014
|
-
e.disabled || n.value !== 1 && (n.value = 1,
|
|
1012
|
+
return e.by(y, x);
|
|
1013
|
+
}, orientation: w(() => e.horizontal ? "horizontal" : "vertical"), labelRef: r, buttonRef: i, optionsRef: u, disabled: w(() => e.disabled), options: c, searchQuery: s, activeOptionIndex: a, activationTrigger: d, closeListbox() {
|
|
1014
|
+
e.disabled || n.value !== 1 && (n.value = 1, a.value = null);
|
|
1015
1015
|
}, openListbox() {
|
|
1016
1016
|
e.disabled || n.value !== 0 && (n.value = 0);
|
|
1017
|
-
}, goToOption(y,
|
|
1017
|
+
}, goToOption(y, x, k) {
|
|
1018
1018
|
if (e.disabled || n.value === 1)
|
|
1019
1019
|
return;
|
|
1020
|
-
let
|
|
1021
|
-
s.value = "",
|
|
1020
|
+
let _ = v(), C = en(y === L.Specific ? { focus: L.Specific, id: x } : { focus: y }, { resolveItems: () => _.options, resolveActiveIndex: () => _.activeOptionIndex, resolveId: (F) => F.id, resolveDisabled: (F) => F.dataRef.disabled });
|
|
1021
|
+
s.value = "", a.value = C, d.value = k ?? 1, c.value = _.options;
|
|
1022
1022
|
}, search(y) {
|
|
1023
1023
|
if (e.disabled || n.value === 1)
|
|
1024
1024
|
return;
|
|
1025
|
-
let
|
|
1025
|
+
let x = s.value !== "" ? 0 : 1;
|
|
1026
1026
|
s.value += y.toLowerCase();
|
|
1027
|
-
let
|
|
1028
|
-
|
|
1027
|
+
let k = (a.value !== null ? c.value.slice(a.value + x).concat(c.value.slice(0, a.value + x)) : c.value).find((C) => C.dataRef.textValue.startsWith(s.value) && !C.dataRef.disabled), _ = k ? c.value.indexOf(k) : -1;
|
|
1028
|
+
_ === -1 || _ === a.value || (a.value = _, d.value = 1);
|
|
1029
1029
|
}, clearSearch() {
|
|
1030
1030
|
e.disabled || n.value !== 1 && s.value !== "" && (s.value = "");
|
|
1031
|
-
}, registerOption(y,
|
|
1032
|
-
let
|
|
1033
|
-
c.value =
|
|
1031
|
+
}, registerOption(y, x) {
|
|
1032
|
+
let k = v((_) => [..._, { id: y, dataRef: x }]);
|
|
1033
|
+
c.value = k.options, a.value = k.activeOptionIndex;
|
|
1034
1034
|
}, unregisterOption(y) {
|
|
1035
|
-
let
|
|
1036
|
-
let
|
|
1037
|
-
return
|
|
1035
|
+
let x = v((k) => {
|
|
1036
|
+
let _ = k.findIndex((C) => C.id === y);
|
|
1037
|
+
return _ !== -1 && k.splice(_, 1), k;
|
|
1038
1038
|
});
|
|
1039
|
-
c.value =
|
|
1039
|
+
c.value = x.options, a.value = x.activeOptionIndex, d.value = 1;
|
|
1040
1040
|
}, theirOnChange(y) {
|
|
1041
|
-
e.disabled ||
|
|
1041
|
+
e.disabled || m(y);
|
|
1042
1042
|
}, select(y) {
|
|
1043
|
-
e.disabled ||
|
|
1044
|
-
let
|
|
1045
|
-
return
|
|
1043
|
+
e.disabled || m(G(f.value, { 0: () => y, 1: () => {
|
|
1044
|
+
let x = X(p.value.value).slice(), k = X(y), _ = x.findIndex((C) => p.compare(k, X(C)));
|
|
1045
|
+
return _ === -1 ? x.push(k) : x.splice(_, 1), x;
|
|
1046
1046
|
} }));
|
|
1047
1047
|
} };
|
|
1048
|
-
|
|
1049
|
-
var
|
|
1050
|
-
|
|
1051
|
-
},
|
|
1052
|
-
let
|
|
1048
|
+
an([i, u], (y, x) => {
|
|
1049
|
+
var k;
|
|
1050
|
+
p.closeListbox(), ze(x, je.Loose) || (y.preventDefault(), (k = E(i)) == null || k.focus());
|
|
1051
|
+
}, w(() => n.value === 0)), ye(gn, p), on(w(() => G(n.value, { 0: te.Open, 1: te.Closed })));
|
|
1052
|
+
let S = w(() => {
|
|
1053
1053
|
var y;
|
|
1054
|
-
return (y =
|
|
1054
|
+
return (y = E(i)) == null ? void 0 : y.closest("form");
|
|
1055
1055
|
});
|
|
1056
|
-
return
|
|
1057
|
-
|
|
1058
|
-
if (!
|
|
1056
|
+
return ee(() => {
|
|
1057
|
+
Z([S], () => {
|
|
1058
|
+
if (!S.value || e.defaultValue === void 0)
|
|
1059
1059
|
return;
|
|
1060
1060
|
function y() {
|
|
1061
|
-
|
|
1061
|
+
p.theirOnChange(e.defaultValue);
|
|
1062
1062
|
}
|
|
1063
|
-
return
|
|
1064
|
-
var
|
|
1065
|
-
(
|
|
1063
|
+
return S.value.addEventListener("reset", y), () => {
|
|
1064
|
+
var x;
|
|
1065
|
+
(x = S.value) == null || x.removeEventListener("reset", y);
|
|
1066
1066
|
};
|
|
1067
1067
|
}, { immediate: !0 });
|
|
1068
1068
|
}), () => {
|
|
1069
|
-
let { name: y, modelValue:
|
|
1070
|
-
return
|
|
1069
|
+
let { name: y, modelValue: x, disabled: k, form: _, ...C } = e, F = { open: n.value === 0, disabled: k, value: b.value };
|
|
1070
|
+
return Ce(be, [...y != null && b.value != null ? un({ [y]: b.value }).map(([re, _e]) => Ce(sn, Jt({ features: dt.Hidden, key: re, as: "input", type: "hidden", hidden: !0, readOnly: !0, form: _, name: re, value: _e }))) : [], z({ ourProps: {}, theirProps: { ...l, ...it(C, ["defaultValue", "onUpdate:modelValue", "horizontal", "multiple", "by"]) }, slot: F, slots: t, attrs: l, name: "Listbox" })]);
|
|
1071
1071
|
};
|
|
1072
1072
|
} });
|
|
1073
|
-
|
|
1074
|
-
let
|
|
1073
|
+
$({ name: "ListboxLabel", props: { as: { type: [Object, String], default: "label" }, id: { type: String, default: () => `headlessui-listbox-label-${J()}` } }, setup(e, { attrs: t, slots: l }) {
|
|
1074
|
+
let o = De("ListboxLabel");
|
|
1075
1075
|
function n() {
|
|
1076
|
-
var
|
|
1077
|
-
(
|
|
1076
|
+
var r;
|
|
1077
|
+
(r = E(o.buttonRef)) == null || r.focus({ preventScroll: !0 });
|
|
1078
1078
|
}
|
|
1079
1079
|
return () => {
|
|
1080
|
-
let
|
|
1081
|
-
return
|
|
1080
|
+
let r = { open: o.listboxState.value === 0, disabled: o.disabled.value }, { id: i, ...u } = e, c = { id: i, ref: o.labelRef, onClick: n };
|
|
1081
|
+
return z({ ourProps: c, theirProps: u, slot: r, attrs: t, slots: l, name: "ListboxLabel" });
|
|
1082
1082
|
};
|
|
1083
1083
|
} });
|
|
1084
|
-
let
|
|
1085
|
-
let n =
|
|
1086
|
-
|
|
1087
|
-
function
|
|
1084
|
+
let sl = $({ name: "ListboxButton", props: { as: { type: [Object, String], default: "button" }, id: { type: String, default: () => `headlessui-listbox-button-${J()}` } }, setup(e, { attrs: t, slots: l, expose: o }) {
|
|
1085
|
+
let n = De("ListboxButton");
|
|
1086
|
+
o({ el: n.buttonRef, $el: n.buttonRef });
|
|
1087
|
+
function r(s) {
|
|
1088
1088
|
switch (s.key) {
|
|
1089
|
-
case
|
|
1090
|
-
case
|
|
1091
|
-
case
|
|
1092
|
-
s.preventDefault(), n.openListbox(),
|
|
1093
|
-
var
|
|
1094
|
-
(
|
|
1089
|
+
case D.Space:
|
|
1090
|
+
case D.Enter:
|
|
1091
|
+
case D.ArrowDown:
|
|
1092
|
+
s.preventDefault(), n.openListbox(), j(() => {
|
|
1093
|
+
var a;
|
|
1094
|
+
(a = E(n.optionsRef)) == null || a.focus({ preventScroll: !0 }), n.value.value || n.goToOption(L.First);
|
|
1095
1095
|
});
|
|
1096
1096
|
break;
|
|
1097
|
-
case
|
|
1098
|
-
s.preventDefault(), n.openListbox(),
|
|
1099
|
-
var
|
|
1100
|
-
(
|
|
1097
|
+
case D.ArrowUp:
|
|
1098
|
+
s.preventDefault(), n.openListbox(), j(() => {
|
|
1099
|
+
var a;
|
|
1100
|
+
(a = E(n.optionsRef)) == null || a.focus({ preventScroll: !0 }), n.value.value || n.goToOption(L.Last);
|
|
1101
1101
|
});
|
|
1102
1102
|
break;
|
|
1103
1103
|
}
|
|
1104
1104
|
}
|
|
1105
1105
|
function i(s) {
|
|
1106
1106
|
switch (s.key) {
|
|
1107
|
-
case
|
|
1107
|
+
case D.Space:
|
|
1108
1108
|
s.preventDefault();
|
|
1109
1109
|
break;
|
|
1110
1110
|
}
|
|
1111
1111
|
}
|
|
1112
1112
|
function u(s) {
|
|
1113
|
-
n.disabled.value || (n.listboxState.value === 0 ? (n.closeListbox(),
|
|
1114
|
-
var
|
|
1115
|
-
return (
|
|
1116
|
-
})) : (s.preventDefault(), n.openListbox(),
|
|
1117
|
-
var
|
|
1118
|
-
return (
|
|
1113
|
+
n.disabled.value || (n.listboxState.value === 0 ? (n.closeListbox(), j(() => {
|
|
1114
|
+
var a;
|
|
1115
|
+
return (a = E(n.buttonRef)) == null ? void 0 : a.focus({ preventScroll: !0 });
|
|
1116
|
+
})) : (s.preventDefault(), n.openListbox(), il(() => {
|
|
1117
|
+
var a;
|
|
1118
|
+
return (a = E(n.optionsRef)) == null ? void 0 : a.focus({ preventScroll: !0 });
|
|
1119
1119
|
})));
|
|
1120
1120
|
}
|
|
1121
|
-
let c =
|
|
1121
|
+
let c = at(w(() => ({ as: e.as, type: t.type })), n.buttonRef);
|
|
1122
1122
|
return () => {
|
|
1123
|
-
var s,
|
|
1124
|
-
let
|
|
1125
|
-
return
|
|
1123
|
+
var s, a;
|
|
1124
|
+
let d = { open: n.listboxState.value === 0, disabled: n.disabled.value, value: n.value.value }, { id: v, ...f } = e, g = { ref: n.buttonRef, id: v, type: c.value, "aria-haspopup": "listbox", "aria-controls": (s = E(n.optionsRef)) == null ? void 0 : s.id, "aria-expanded": n.listboxState.value === 0, "aria-labelledby": n.labelRef.value ? [(a = E(n.labelRef)) == null ? void 0 : a.id, v].join(" ") : void 0, disabled: n.disabled.value === !0 ? !0 : void 0, onKeydown: r, onKeyup: i, onClick: u };
|
|
1125
|
+
return z({ ourProps: g, theirProps: f, slot: d, attrs: t, slots: l, name: "ListboxButton" });
|
|
1126
1126
|
};
|
|
1127
|
-
} }),
|
|
1128
|
-
let n =
|
|
1129
|
-
|
|
1127
|
+
} }), ul = $({ name: "ListboxOptions", props: { as: { type: [Object, String], default: "ul" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, id: { type: String, default: () => `headlessui-listbox-options-${J()}` } }, setup(e, { attrs: t, slots: l, expose: o }) {
|
|
1128
|
+
let n = De("ListboxOptions"), r = O(null);
|
|
1129
|
+
o({ el: n.optionsRef, $el: n.optionsRef });
|
|
1130
1130
|
function i(s) {
|
|
1131
|
-
switch (
|
|
1132
|
-
case
|
|
1131
|
+
switch (r.value && clearTimeout(r.value), s.key) {
|
|
1132
|
+
case D.Space:
|
|
1133
1133
|
if (n.searchQuery.value !== "")
|
|
1134
1134
|
return s.preventDefault(), s.stopPropagation(), n.search(s.key);
|
|
1135
|
-
case
|
|
1135
|
+
case D.Enter:
|
|
1136
1136
|
if (s.preventDefault(), s.stopPropagation(), n.activeOptionIndex.value !== null) {
|
|
1137
|
-
let
|
|
1138
|
-
n.select(
|
|
1137
|
+
let a = n.options.value[n.activeOptionIndex.value];
|
|
1138
|
+
n.select(a.dataRef.value);
|
|
1139
1139
|
}
|
|
1140
|
-
n.mode.value === 0 && (n.closeListbox(),
|
|
1141
|
-
var
|
|
1142
|
-
return (
|
|
1140
|
+
n.mode.value === 0 && (n.closeListbox(), j(() => {
|
|
1141
|
+
var a;
|
|
1142
|
+
return (a = E(n.buttonRef)) == null ? void 0 : a.focus({ preventScroll: !0 });
|
|
1143
1143
|
}));
|
|
1144
1144
|
break;
|
|
1145
|
-
case
|
|
1145
|
+
case G(n.orientation.value, { vertical: D.ArrowDown, horizontal: D.ArrowRight }):
|
|
1146
1146
|
return s.preventDefault(), s.stopPropagation(), n.goToOption(L.Next);
|
|
1147
|
-
case
|
|
1147
|
+
case G(n.orientation.value, { vertical: D.ArrowUp, horizontal: D.ArrowLeft }):
|
|
1148
1148
|
return s.preventDefault(), s.stopPropagation(), n.goToOption(L.Previous);
|
|
1149
|
-
case
|
|
1150
|
-
case
|
|
1149
|
+
case D.Home:
|
|
1150
|
+
case D.PageUp:
|
|
1151
1151
|
return s.preventDefault(), s.stopPropagation(), n.goToOption(L.First);
|
|
1152
|
-
case
|
|
1153
|
-
case
|
|
1152
|
+
case D.End:
|
|
1153
|
+
case D.PageDown:
|
|
1154
1154
|
return s.preventDefault(), s.stopPropagation(), n.goToOption(L.Last);
|
|
1155
|
-
case
|
|
1156
|
-
s.preventDefault(), s.stopPropagation(), n.closeListbox(),
|
|
1157
|
-
var
|
|
1158
|
-
return (
|
|
1155
|
+
case D.Escape:
|
|
1156
|
+
s.preventDefault(), s.stopPropagation(), n.closeListbox(), j(() => {
|
|
1157
|
+
var a;
|
|
1158
|
+
return (a = E(n.buttonRef)) == null ? void 0 : a.focus({ preventScroll: !0 });
|
|
1159
1159
|
});
|
|
1160
1160
|
break;
|
|
1161
|
-
case
|
|
1161
|
+
case D.Tab:
|
|
1162
1162
|
s.preventDefault(), s.stopPropagation();
|
|
1163
1163
|
break;
|
|
1164
1164
|
default:
|
|
1165
|
-
s.key.length === 1 && (n.search(s.key),
|
|
1165
|
+
s.key.length === 1 && (n.search(s.key), r.value = setTimeout(() => n.clearSearch(), 350));
|
|
1166
1166
|
break;
|
|
1167
1167
|
}
|
|
1168
1168
|
}
|
|
1169
|
-
let u =
|
|
1169
|
+
let u = nn(), c = w(() => u !== null ? (u.value & te.Open) === te.Open : n.listboxState.value === 0);
|
|
1170
1170
|
return () => {
|
|
1171
|
-
var s,
|
|
1172
|
-
let
|
|
1173
|
-
return
|
|
1171
|
+
var s, a, d, v;
|
|
1172
|
+
let f = { open: n.listboxState.value === 0 }, { id: g, ...m } = e, b = { "aria-activedescendant": n.activeOptionIndex.value === null || (s = n.options.value[n.activeOptionIndex.value]) == null ? void 0 : s.id, "aria-multiselectable": n.mode.value === 1 ? !0 : void 0, "aria-labelledby": (v = (a = E(n.labelRef)) == null ? void 0 : a.id) != null ? v : (d = E(n.buttonRef)) == null ? void 0 : d.id, "aria-orientation": n.orientation.value, id: g, onKeydown: i, role: "listbox", tabIndex: 0, ref: n.optionsRef };
|
|
1173
|
+
return z({ ourProps: b, theirProps: m, slot: f, attrs: t, slots: l, features: Re.RenderStrategy | Re.Static, visible: c.value, name: "ListboxOptions" });
|
|
1174
1174
|
};
|
|
1175
|
-
} }),
|
|
1176
|
-
let n =
|
|
1177
|
-
|
|
1178
|
-
let i =
|
|
1179
|
-
var
|
|
1180
|
-
let
|
|
1181
|
-
return ((
|
|
1182
|
-
}, 0: () => u.value })), s =
|
|
1175
|
+
} }), cl = $({ name: "ListboxOption", props: { as: { type: [Object, String], default: "li" }, value: { type: [Object, String, Number, Boolean] }, disabled: { type: Boolean, default: !1 }, id: { type: String, default: () => `headlessui-listbox.option-${J()}` } }, setup(e, { slots: t, attrs: l, expose: o }) {
|
|
1176
|
+
let n = De("ListboxOption"), r = O(null);
|
|
1177
|
+
o({ el: r, $el: r });
|
|
1178
|
+
let i = w(() => n.activeOptionIndex.value !== null ? n.options.value[n.activeOptionIndex.value].id === e.id : !1), u = w(() => G(n.mode.value, { 0: () => n.compare(X(n.value.value), X(e.value)), 1: () => X(n.value.value).some((p) => n.compare(X(p), X(e.value))) })), c = w(() => G(n.mode.value, { 1: () => {
|
|
1179
|
+
var p;
|
|
1180
|
+
let S = X(n.value.value);
|
|
1181
|
+
return ((p = n.options.value.find((y) => S.some((x) => n.compare(X(x), X(y.dataRef.value))))) == null ? void 0 : p.id) === e.id;
|
|
1182
|
+
}, 0: () => u.value })), s = vn(r), a = w(() => ({ disabled: e.disabled, value: e.value, get textValue() {
|
|
1183
1183
|
return s();
|
|
1184
|
-
}, domRef:
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
n.listboxState.value === 0 && u.value &&
|
|
1184
|
+
}, domRef: r }));
|
|
1185
|
+
ee(() => n.registerOption(e.id, a)), Fe(() => n.unregisterOption(e.id)), ee(() => {
|
|
1186
|
+
Z([n.listboxState, u], () => {
|
|
1187
|
+
n.listboxState.value === 0 && u.value && G(n.mode.value, { 1: () => {
|
|
1188
1188
|
c.value && n.goToOption(L.Specific, e.id);
|
|
1189
1189
|
}, 0: () => {
|
|
1190
1190
|
n.goToOption(L.Specific, e.id);
|
|
1191
1191
|
} });
|
|
1192
1192
|
}, { immediate: !0 });
|
|
1193
|
-
}),
|
|
1194
|
-
n.listboxState.value === 0 && i.value && n.activationTrigger.value !== 0 &&
|
|
1195
|
-
var
|
|
1196
|
-
return (
|
|
1193
|
+
}), xe(() => {
|
|
1194
|
+
n.listboxState.value === 0 && i.value && n.activationTrigger.value !== 0 && j(() => {
|
|
1195
|
+
var p, S;
|
|
1196
|
+
return (S = (p = E(r)) == null ? void 0 : p.scrollIntoView) == null ? void 0 : S.call(p, { block: "nearest" });
|
|
1197
1197
|
});
|
|
1198
1198
|
});
|
|
1199
|
-
function
|
|
1199
|
+
function d(p) {
|
|
1200
1200
|
if (e.disabled)
|
|
1201
|
-
return
|
|
1202
|
-
n.select(e.value), n.mode.value === 0 && (n.closeListbox(),
|
|
1203
|
-
var
|
|
1204
|
-
return (
|
|
1201
|
+
return p.preventDefault();
|
|
1202
|
+
n.select(e.value), n.mode.value === 0 && (n.closeListbox(), j(() => {
|
|
1203
|
+
var S;
|
|
1204
|
+
return (S = E(n.buttonRef)) == null ? void 0 : S.focus({ preventScroll: !0 });
|
|
1205
1205
|
}));
|
|
1206
1206
|
}
|
|
1207
1207
|
function v() {
|
|
@@ -1209,866 +1209,1257 @@ let _r = _({ name: "ListboxButton", props: { as: { type: [Object, String], defau
|
|
|
1209
1209
|
return n.goToOption(L.Nothing);
|
|
1210
1210
|
n.goToOption(L.Specific, e.id);
|
|
1211
1211
|
}
|
|
1212
|
-
let
|
|
1213
|
-
function
|
|
1214
|
-
|
|
1212
|
+
let f = pn();
|
|
1213
|
+
function g(p) {
|
|
1214
|
+
f.update(p);
|
|
1215
1215
|
}
|
|
1216
|
-
function
|
|
1217
|
-
|
|
1216
|
+
function m(p) {
|
|
1217
|
+
f.wasMoved(p) && (e.disabled || i.value || n.goToOption(L.Specific, e.id, 0));
|
|
1218
1218
|
}
|
|
1219
|
-
function
|
|
1220
|
-
|
|
1219
|
+
function b(p) {
|
|
1220
|
+
f.wasMoved(p) && (e.disabled || i.value && n.goToOption(L.Nothing));
|
|
1221
1221
|
}
|
|
1222
1222
|
return () => {
|
|
1223
|
-
let { disabled:
|
|
1224
|
-
return
|
|
1223
|
+
let { disabled: p } = e, S = { active: i.value, selected: u.value, disabled: p }, { id: y, value: x, disabled: k, ..._ } = e, C = { id: y, ref: r, role: "option", tabIndex: p === !0 ? void 0 : -1, "aria-disabled": p === !0 ? !0 : void 0, "aria-selected": u.value, disabled: void 0, onClick: d, onFocus: v, onPointerenter: g, onMouseenter: g, onPointermove: m, onMousemove: m, onPointerleave: b, onMouseleave: b };
|
|
1224
|
+
return z({ ourProps: C, theirProps: _, slot: S, attrs: l, slots: t, name: "ListboxOption" });
|
|
1225
1225
|
};
|
|
1226
1226
|
} });
|
|
1227
|
-
var
|
|
1228
|
-
function
|
|
1227
|
+
var dl = ((e) => (e[e.Open = 0] = "Open", e[e.Closed = 1] = "Closed", e))(dl || {}), fl = ((e) => (e[e.Pointer = 0] = "Pointer", e[e.Other = 1] = "Other", e))(fl || {});
|
|
1228
|
+
function pl(e) {
|
|
1229
1229
|
requestAnimationFrame(() => requestAnimationFrame(e));
|
|
1230
1230
|
}
|
|
1231
|
-
let
|
|
1232
|
-
function
|
|
1233
|
-
let t =
|
|
1231
|
+
let bn = Symbol("MenuContext");
|
|
1232
|
+
function Ue(e) {
|
|
1233
|
+
let t = he(bn, null);
|
|
1234
1234
|
if (t === null) {
|
|
1235
|
-
let
|
|
1236
|
-
throw Error.captureStackTrace && Error.captureStackTrace(
|
|
1235
|
+
let l = new Error(`<${e} /> is missing a parent <Menu /> component.`);
|
|
1236
|
+
throw Error.captureStackTrace && Error.captureStackTrace(l, Ue), l;
|
|
1237
1237
|
}
|
|
1238
1238
|
return t;
|
|
1239
1239
|
}
|
|
1240
|
-
let
|
|
1241
|
-
let
|
|
1242
|
-
function
|
|
1243
|
-
let
|
|
1244
|
-
return
|
|
1245
|
-
}
|
|
1246
|
-
let
|
|
1247
|
-
|
|
1248
|
-
}, openMenu: () =>
|
|
1249
|
-
let
|
|
1250
|
-
u.value = "", c.value =
|
|
1240
|
+
let ml = $({ name: "Menu", props: { as: { type: [Object, String], default: "template" } }, setup(e, { slots: t, attrs: l }) {
|
|
1241
|
+
let o = O(1), n = O(null), r = O(null), i = O([]), u = O(""), c = O(null), s = O(1);
|
|
1242
|
+
function a(v = (f) => f) {
|
|
1243
|
+
let f = c.value !== null ? i.value[c.value] : null, g = ct(v(i.value.slice()), (b) => E(b.dataRef.domRef)), m = f ? g.indexOf(f) : null;
|
|
1244
|
+
return m === -1 && (m = null), { items: g, activeItemIndex: m };
|
|
1245
|
+
}
|
|
1246
|
+
let d = { menuState: o, buttonRef: n, itemsRef: r, items: i, searchQuery: u, activeItemIndex: c, activationTrigger: s, closeMenu: () => {
|
|
1247
|
+
o.value = 1, c.value = null;
|
|
1248
|
+
}, openMenu: () => o.value = 0, goToItem(v, f, g) {
|
|
1249
|
+
let m = a(), b = en(v === L.Specific ? { focus: L.Specific, id: f } : { focus: v }, { resolveItems: () => m.items, resolveActiveIndex: () => m.activeItemIndex, resolveId: (p) => p.id, resolveDisabled: (p) => p.dataRef.disabled });
|
|
1250
|
+
u.value = "", c.value = b, s.value = g ?? 1, i.value = m.items;
|
|
1251
1251
|
}, search(v) {
|
|
1252
|
-
let
|
|
1252
|
+
let f = u.value !== "" ? 0 : 1;
|
|
1253
1253
|
u.value += v.toLowerCase();
|
|
1254
|
-
let
|
|
1255
|
-
|
|
1254
|
+
let g = (c.value !== null ? i.value.slice(c.value + f).concat(i.value.slice(0, c.value + f)) : i.value).find((b) => b.dataRef.textValue.startsWith(u.value) && !b.dataRef.disabled), m = g ? i.value.indexOf(g) : -1;
|
|
1255
|
+
m === -1 || m === c.value || (c.value = m, s.value = 1);
|
|
1256
1256
|
}, clearSearch() {
|
|
1257
1257
|
u.value = "";
|
|
1258
|
-
}, registerItem(v,
|
|
1259
|
-
let
|
|
1260
|
-
i.value =
|
|
1258
|
+
}, registerItem(v, f) {
|
|
1259
|
+
let g = a((m) => [...m, { id: v, dataRef: f }]);
|
|
1260
|
+
i.value = g.items, c.value = g.activeItemIndex, s.value = 1;
|
|
1261
1261
|
}, unregisterItem(v) {
|
|
1262
|
-
let
|
|
1263
|
-
let
|
|
1264
|
-
return
|
|
1262
|
+
let f = a((g) => {
|
|
1263
|
+
let m = g.findIndex((b) => b.id === v);
|
|
1264
|
+
return m !== -1 && g.splice(m, 1), g;
|
|
1265
1265
|
});
|
|
1266
|
-
i.value =
|
|
1266
|
+
i.value = f.items, c.value = f.activeItemIndex, s.value = 1;
|
|
1267
1267
|
} };
|
|
1268
|
-
return
|
|
1269
|
-
var
|
|
1270
|
-
|
|
1271
|
-
},
|
|
1272
|
-
let v = { open:
|
|
1273
|
-
return
|
|
1268
|
+
return an([n, r], (v, f) => {
|
|
1269
|
+
var g;
|
|
1270
|
+
d.closeMenu(), ze(f, je.Loose) || (v.preventDefault(), (g = E(n)) == null || g.focus());
|
|
1271
|
+
}, w(() => o.value === 0)), ye(bn, d), on(w(() => G(o.value, { 0: te.Open, 1: te.Closed }))), () => {
|
|
1272
|
+
let v = { open: o.value === 0, close: d.closeMenu };
|
|
1273
|
+
return z({ ourProps: {}, theirProps: e, slot: v, slots: t, attrs: l, name: "Menu" });
|
|
1274
1274
|
};
|
|
1275
|
-
} }),
|
|
1276
|
-
let n =
|
|
1277
|
-
|
|
1278
|
-
function
|
|
1275
|
+
} }), vl = $({ name: "MenuButton", props: { disabled: { type: Boolean, default: !1 }, as: { type: [Object, String], default: "button" }, id: { type: String, default: () => `headlessui-menu-button-${J()}` } }, setup(e, { attrs: t, slots: l, expose: o }) {
|
|
1276
|
+
let n = Ue("MenuButton");
|
|
1277
|
+
o({ el: n.buttonRef, $el: n.buttonRef });
|
|
1278
|
+
function r(s) {
|
|
1279
1279
|
switch (s.key) {
|
|
1280
|
-
case
|
|
1281
|
-
case
|
|
1282
|
-
case
|
|
1283
|
-
s.preventDefault(), s.stopPropagation(), n.openMenu(),
|
|
1284
|
-
var
|
|
1285
|
-
(
|
|
1280
|
+
case D.Space:
|
|
1281
|
+
case D.Enter:
|
|
1282
|
+
case D.ArrowDown:
|
|
1283
|
+
s.preventDefault(), s.stopPropagation(), n.openMenu(), j(() => {
|
|
1284
|
+
var a;
|
|
1285
|
+
(a = E(n.itemsRef)) == null || a.focus({ preventScroll: !0 }), n.goToItem(L.First);
|
|
1286
1286
|
});
|
|
1287
1287
|
break;
|
|
1288
|
-
case
|
|
1289
|
-
s.preventDefault(), s.stopPropagation(), n.openMenu(),
|
|
1290
|
-
var
|
|
1291
|
-
(
|
|
1288
|
+
case D.ArrowUp:
|
|
1289
|
+
s.preventDefault(), s.stopPropagation(), n.openMenu(), j(() => {
|
|
1290
|
+
var a;
|
|
1291
|
+
(a = E(n.itemsRef)) == null || a.focus({ preventScroll: !0 }), n.goToItem(L.Last);
|
|
1292
1292
|
});
|
|
1293
1293
|
break;
|
|
1294
1294
|
}
|
|
1295
1295
|
}
|
|
1296
1296
|
function i(s) {
|
|
1297
1297
|
switch (s.key) {
|
|
1298
|
-
case
|
|
1298
|
+
case D.Space:
|
|
1299
1299
|
s.preventDefault();
|
|
1300
1300
|
break;
|
|
1301
1301
|
}
|
|
1302
1302
|
}
|
|
1303
1303
|
function u(s) {
|
|
1304
|
-
e.disabled || (n.menuState.value === 0 ? (n.closeMenu(),
|
|
1305
|
-
var
|
|
1306
|
-
return (
|
|
1307
|
-
})) : (s.preventDefault(), n.openMenu(),
|
|
1308
|
-
var
|
|
1309
|
-
return (
|
|
1304
|
+
e.disabled || (n.menuState.value === 0 ? (n.closeMenu(), j(() => {
|
|
1305
|
+
var a;
|
|
1306
|
+
return (a = E(n.buttonRef)) == null ? void 0 : a.focus({ preventScroll: !0 });
|
|
1307
|
+
})) : (s.preventDefault(), n.openMenu(), pl(() => {
|
|
1308
|
+
var a;
|
|
1309
|
+
return (a = E(n.itemsRef)) == null ? void 0 : a.focus({ preventScroll: !0 });
|
|
1310
1310
|
})));
|
|
1311
1311
|
}
|
|
1312
|
-
let c =
|
|
1312
|
+
let c = at(w(() => ({ as: e.as, type: t.type })), n.buttonRef);
|
|
1313
1313
|
return () => {
|
|
1314
1314
|
var s;
|
|
1315
|
-
let
|
|
1316
|
-
return
|
|
1315
|
+
let a = { open: n.menuState.value === 0 }, { id: d, ...v } = e, f = { ref: n.buttonRef, id: d, type: c.value, "aria-haspopup": "menu", "aria-controls": (s = E(n.itemsRef)) == null ? void 0 : s.id, "aria-expanded": n.menuState.value === 0, onKeydown: r, onKeyup: i, onClick: u };
|
|
1316
|
+
return z({ ourProps: f, theirProps: v, slot: a, attrs: t, slots: l, name: "MenuButton" });
|
|
1317
1317
|
};
|
|
1318
|
-
} }),
|
|
1319
|
-
let n =
|
|
1320
|
-
|
|
1321
|
-
return
|
|
1322
|
-
}, walk(
|
|
1323
|
-
|
|
1318
|
+
} }), gl = $({ name: "MenuItems", props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, id: { type: String, default: () => `headlessui-menu-items-${J()}` } }, setup(e, { attrs: t, slots: l, expose: o }) {
|
|
1319
|
+
let n = Ue("MenuItems"), r = O(null);
|
|
1320
|
+
o({ el: n.itemsRef, $el: n.itemsRef }), zo({ container: w(() => E(n.itemsRef)), enabled: w(() => n.menuState.value === 0), accept(a) {
|
|
1321
|
+
return a.getAttribute("role") === "menuitem" ? NodeFilter.FILTER_REJECT : a.hasAttribute("role") ? NodeFilter.FILTER_SKIP : NodeFilter.FILTER_ACCEPT;
|
|
1322
|
+
}, walk(a) {
|
|
1323
|
+
a.setAttribute("role", "none");
|
|
1324
1324
|
} });
|
|
1325
|
-
function i(
|
|
1326
|
-
var
|
|
1327
|
-
switch (
|
|
1328
|
-
case
|
|
1325
|
+
function i(a) {
|
|
1326
|
+
var d;
|
|
1327
|
+
switch (r.value && clearTimeout(r.value), a.key) {
|
|
1328
|
+
case D.Space:
|
|
1329
1329
|
if (n.searchQuery.value !== "")
|
|
1330
|
-
return
|
|
1331
|
-
case
|
|
1332
|
-
if (
|
|
1330
|
+
return a.preventDefault(), a.stopPropagation(), n.search(a.key);
|
|
1331
|
+
case D.Enter:
|
|
1332
|
+
if (a.preventDefault(), a.stopPropagation(), n.activeItemIndex.value !== null) {
|
|
1333
1333
|
let v = n.items.value[n.activeItemIndex.value];
|
|
1334
|
-
(
|
|
1334
|
+
(d = E(v.dataRef.domRef)) == null || d.click();
|
|
1335
1335
|
}
|
|
1336
|
-
n.closeMenu(),
|
|
1336
|
+
n.closeMenu(), rn(E(n.buttonRef));
|
|
1337
1337
|
break;
|
|
1338
|
-
case
|
|
1339
|
-
return
|
|
1340
|
-
case
|
|
1341
|
-
return
|
|
1342
|
-
case
|
|
1343
|
-
case
|
|
1344
|
-
return
|
|
1345
|
-
case
|
|
1346
|
-
case
|
|
1347
|
-
return
|
|
1348
|
-
case
|
|
1349
|
-
|
|
1338
|
+
case D.ArrowDown:
|
|
1339
|
+
return a.preventDefault(), a.stopPropagation(), n.goToItem(L.Next);
|
|
1340
|
+
case D.ArrowUp:
|
|
1341
|
+
return a.preventDefault(), a.stopPropagation(), n.goToItem(L.Previous);
|
|
1342
|
+
case D.Home:
|
|
1343
|
+
case D.PageUp:
|
|
1344
|
+
return a.preventDefault(), a.stopPropagation(), n.goToItem(L.First);
|
|
1345
|
+
case D.End:
|
|
1346
|
+
case D.PageDown:
|
|
1347
|
+
return a.preventDefault(), a.stopPropagation(), n.goToItem(L.Last);
|
|
1348
|
+
case D.Escape:
|
|
1349
|
+
a.preventDefault(), a.stopPropagation(), n.closeMenu(), j(() => {
|
|
1350
1350
|
var v;
|
|
1351
|
-
return (v =
|
|
1351
|
+
return (v = E(n.buttonRef)) == null ? void 0 : v.focus({ preventScroll: !0 });
|
|
1352
1352
|
});
|
|
1353
1353
|
break;
|
|
1354
|
-
case
|
|
1355
|
-
|
|
1354
|
+
case D.Tab:
|
|
1355
|
+
a.preventDefault(), a.stopPropagation(), n.closeMenu(), j(() => Xo(E(n.buttonRef), a.shiftKey ? tt.Previous : tt.Next));
|
|
1356
1356
|
break;
|
|
1357
1357
|
default:
|
|
1358
|
-
|
|
1358
|
+
a.key.length === 1 && (n.search(a.key), r.value = setTimeout(() => n.clearSearch(), 350));
|
|
1359
1359
|
break;
|
|
1360
1360
|
}
|
|
1361
1361
|
}
|
|
1362
|
-
function u(
|
|
1363
|
-
switch (
|
|
1364
|
-
case
|
|
1365
|
-
|
|
1362
|
+
function u(a) {
|
|
1363
|
+
switch (a.key) {
|
|
1364
|
+
case D.Space:
|
|
1365
|
+
a.preventDefault();
|
|
1366
1366
|
break;
|
|
1367
1367
|
}
|
|
1368
1368
|
}
|
|
1369
|
-
let c =
|
|
1369
|
+
let c = nn(), s = w(() => c !== null ? (c.value & te.Open) === te.Open : n.menuState.value === 0);
|
|
1370
1370
|
return () => {
|
|
1371
|
-
var
|
|
1372
|
-
let v = { open: n.menuState.value === 0 }, { id:
|
|
1373
|
-
return
|
|
1371
|
+
var a, d;
|
|
1372
|
+
let v = { open: n.menuState.value === 0 }, { id: f, ...g } = e, m = { "aria-activedescendant": n.activeItemIndex.value === null || (a = n.items.value[n.activeItemIndex.value]) == null ? void 0 : a.id, "aria-labelledby": (d = E(n.buttonRef)) == null ? void 0 : d.id, id: f, onKeydown: i, onKeyup: u, role: "menu", tabIndex: 0, ref: n.itemsRef };
|
|
1373
|
+
return z({ ourProps: m, theirProps: g, slot: v, attrs: t, slots: l, features: Re.RenderStrategy | Re.Static, visible: s.value, name: "MenuItems" });
|
|
1374
1374
|
};
|
|
1375
|
-
} }),
|
|
1376
|
-
let n =
|
|
1377
|
-
|
|
1378
|
-
let i =
|
|
1375
|
+
} }), bl = $({ name: "MenuItem", inheritAttrs: !1, props: { as: { type: [Object, String], default: "template" }, disabled: { type: Boolean, default: !1 }, id: { type: String, default: () => `headlessui-menu-item-${J()}` } }, setup(e, { slots: t, attrs: l, expose: o }) {
|
|
1376
|
+
let n = Ue("MenuItem"), r = O(null);
|
|
1377
|
+
o({ el: r, $el: r });
|
|
1378
|
+
let i = w(() => n.activeItemIndex.value !== null ? n.items.value[n.activeItemIndex.value].id === e.id : !1), u = vn(r), c = w(() => ({ disabled: e.disabled, get textValue() {
|
|
1379
1379
|
return u();
|
|
1380
|
-
}, domRef:
|
|
1381
|
-
|
|
1382
|
-
n.menuState.value === 0 && i.value && n.activationTrigger.value !== 0 &&
|
|
1383
|
-
var
|
|
1384
|
-
return (
|
|
1380
|
+
}, domRef: r }));
|
|
1381
|
+
ee(() => n.registerItem(e.id, c)), Fe(() => n.unregisterItem(e.id)), xe(() => {
|
|
1382
|
+
n.menuState.value === 0 && i.value && n.activationTrigger.value !== 0 && j(() => {
|
|
1383
|
+
var m, b;
|
|
1384
|
+
return (b = (m = E(r)) == null ? void 0 : m.scrollIntoView) == null ? void 0 : b.call(m, { block: "nearest" });
|
|
1385
1385
|
});
|
|
1386
1386
|
});
|
|
1387
|
-
function s(
|
|
1387
|
+
function s(m) {
|
|
1388
1388
|
if (e.disabled)
|
|
1389
|
-
return
|
|
1390
|
-
n.closeMenu(),
|
|
1389
|
+
return m.preventDefault();
|
|
1390
|
+
n.closeMenu(), rn(E(n.buttonRef));
|
|
1391
1391
|
}
|
|
1392
|
-
function
|
|
1392
|
+
function a() {
|
|
1393
1393
|
if (e.disabled)
|
|
1394
1394
|
return n.goToItem(L.Nothing);
|
|
1395
1395
|
n.goToItem(L.Specific, e.id);
|
|
1396
1396
|
}
|
|
1397
|
-
let
|
|
1398
|
-
function v(
|
|
1399
|
-
|
|
1397
|
+
let d = pn();
|
|
1398
|
+
function v(m) {
|
|
1399
|
+
d.update(m);
|
|
1400
1400
|
}
|
|
1401
|
-
function
|
|
1402
|
-
|
|
1401
|
+
function f(m) {
|
|
1402
|
+
d.wasMoved(m) && (e.disabled || i.value || n.goToItem(L.Specific, e.id, 0));
|
|
1403
1403
|
}
|
|
1404
|
-
function
|
|
1405
|
-
|
|
1404
|
+
function g(m) {
|
|
1405
|
+
d.wasMoved(m) && (e.disabled || i.value && n.goToItem(L.Nothing));
|
|
1406
1406
|
}
|
|
1407
1407
|
return () => {
|
|
1408
|
-
let { disabled:
|
|
1409
|
-
return
|
|
1408
|
+
let { disabled: m } = e, b = { active: i.value, disabled: m, close: n.closeMenu }, { id: p, ...S } = e;
|
|
1409
|
+
return z({ ourProps: { id: p, ref: r, role: "menuitem", tabIndex: m === !0 ? void 0 : -1, "aria-disabled": m === !0 ? !0 : void 0, disabled: void 0, onClick: s, onFocus: a, onPointerenter: v, onMouseenter: v, onPointermove: f, onMousemove: f, onPointerleave: g, onMouseleave: g }, theirProps: { ...l, ...S }, slot: b, attrs: l, slots: t, name: "MenuItem" });
|
|
1410
1410
|
};
|
|
1411
|
-
} }),
|
|
1412
|
-
function
|
|
1413
|
-
let e =
|
|
1411
|
+
} }), hn = Symbol("LabelContext");
|
|
1412
|
+
function yn() {
|
|
1413
|
+
let e = he(hn, null);
|
|
1414
1414
|
if (e === null) {
|
|
1415
1415
|
let t = new Error("You used a <Label /> component, but it is not inside a parent.");
|
|
1416
|
-
throw Error.captureStackTrace && Error.captureStackTrace(t,
|
|
1416
|
+
throw Error.captureStackTrace && Error.captureStackTrace(t, yn), t;
|
|
1417
1417
|
}
|
|
1418
1418
|
return e;
|
|
1419
1419
|
}
|
|
1420
|
-
function
|
|
1421
|
-
let
|
|
1422
|
-
function n(
|
|
1423
|
-
return
|
|
1424
|
-
let i =
|
|
1425
|
-
i !== -1 &&
|
|
1420
|
+
function hl({ slot: e = {}, name: t = "Label", props: l = {} } = {}) {
|
|
1421
|
+
let o = O([]);
|
|
1422
|
+
function n(r) {
|
|
1423
|
+
return o.value.push(r), () => {
|
|
1424
|
+
let i = o.value.indexOf(r);
|
|
1425
|
+
i !== -1 && o.value.splice(i, 1);
|
|
1426
1426
|
};
|
|
1427
1427
|
}
|
|
1428
|
-
return
|
|
1428
|
+
return ye(hn, { register: n, slot: e, name: t, props: l }), w(() => o.value.length > 0 ? o.value.join(" ") : void 0);
|
|
1429
1429
|
}
|
|
1430
|
-
|
|
1431
|
-
let
|
|
1432
|
-
return
|
|
1433
|
-
let { name: n = "Label", slot:
|
|
1434
|
-
return c && (delete
|
|
1430
|
+
$({ name: "Label", props: { as: { type: [Object, String], default: "label" }, passive: { type: [Boolean], default: !1 }, id: { type: String, default: () => `headlessui-label-${J()}` } }, setup(e, { slots: t, attrs: l }) {
|
|
1431
|
+
let o = yn();
|
|
1432
|
+
return ee(() => Fe(o.register(e.id))), () => {
|
|
1433
|
+
let { name: n = "Label", slot: r = {}, props: i = {} } = o, { id: u, passive: c, ...s } = e, a = { ...Object.entries(i).reduce((d, [v, f]) => Object.assign(d, { [v]: P(f) }), {}), id: u };
|
|
1434
|
+
return c && (delete a.onClick, delete a.htmlFor, delete s.onClick), z({ ourProps: a, theirProps: s, slot: r, attrs: l, slots: t, name: n });
|
|
1435
1435
|
};
|
|
1436
1436
|
} });
|
|
1437
|
-
let
|
|
1438
|
-
|
|
1439
|
-
let
|
|
1437
|
+
let xn = Symbol("GroupContext");
|
|
1438
|
+
$({ name: "SwitchGroup", props: { as: { type: [Object, String], default: "template" } }, setup(e, { slots: t, attrs: l }) {
|
|
1439
|
+
let o = O(null), n = hl({ name: "SwitchLabel", props: { htmlFor: w(() => {
|
|
1440
1440
|
var i;
|
|
1441
|
-
return (i =
|
|
1441
|
+
return (i = o.value) == null ? void 0 : i.id;
|
|
1442
1442
|
}), onClick(i) {
|
|
1443
|
-
|
|
1444
|
-
} } }),
|
|
1445
|
-
return
|
|
1443
|
+
o.value && (i.currentTarget.tagName === "LABEL" && i.preventDefault(), o.value.click(), o.value.focus({ preventScroll: !0 }));
|
|
1444
|
+
} } }), r = el({ name: "SwitchDescription" });
|
|
1445
|
+
return ye(xn, { switchRef: o, labelledby: n, describedby: r }), () => z({ theirProps: e, ourProps: {}, slot: {}, slots: t, attrs: l, name: "SwitchGroup" });
|
|
1446
1446
|
} });
|
|
1447
|
-
let
|
|
1448
|
-
let
|
|
1447
|
+
let yl = $({ name: "Switch", emits: { "update:modelValue": (e) => !0 }, props: { as: { type: [Object, String], default: "button" }, modelValue: { type: Boolean, default: void 0 }, defaultChecked: { type: Boolean, optional: !0 }, form: { type: String, optional: !0 }, name: { type: String, optional: !0 }, value: { type: String, optional: !0 }, id: { type: String, default: () => `headlessui-switch-${J()}` } }, inheritAttrs: !1, setup(e, { emit: t, attrs: l, slots: o, expose: n }) {
|
|
1448
|
+
let r = he(xn, null), [i, u] = fn(w(() => e.modelValue), (b) => t("update:modelValue", b), w(() => e.defaultChecked));
|
|
1449
1449
|
function c() {
|
|
1450
1450
|
u(!i.value);
|
|
1451
1451
|
}
|
|
1452
|
-
let s = O(null),
|
|
1453
|
-
n({ el:
|
|
1454
|
-
function v(
|
|
1455
|
-
|
|
1452
|
+
let s = O(null), a = r === null ? s : r.switchRef, d = at(w(() => ({ as: e.as, type: l.type })), a);
|
|
1453
|
+
n({ el: a, $el: a });
|
|
1454
|
+
function v(b) {
|
|
1455
|
+
b.preventDefault(), c();
|
|
1456
1456
|
}
|
|
1457
|
-
function
|
|
1458
|
-
|
|
1457
|
+
function f(b) {
|
|
1458
|
+
b.key === D.Space ? (b.preventDefault(), c()) : b.key === D.Enter && Qo(b.currentTarget);
|
|
1459
1459
|
}
|
|
1460
|
-
function
|
|
1461
|
-
|
|
1460
|
+
function g(b) {
|
|
1461
|
+
b.preventDefault();
|
|
1462
1462
|
}
|
|
1463
|
-
let
|
|
1464
|
-
var
|
|
1465
|
-
return (
|
|
1463
|
+
let m = w(() => {
|
|
1464
|
+
var b, p;
|
|
1465
|
+
return (p = (b = E(a)) == null ? void 0 : b.closest) == null ? void 0 : p.call(b, "form");
|
|
1466
1466
|
});
|
|
1467
|
-
return
|
|
1468
|
-
|
|
1469
|
-
if (!
|
|
1467
|
+
return ee(() => {
|
|
1468
|
+
Z([m], () => {
|
|
1469
|
+
if (!m.value || e.defaultChecked === void 0)
|
|
1470
1470
|
return;
|
|
1471
|
-
function
|
|
1471
|
+
function b() {
|
|
1472
1472
|
u(e.defaultChecked);
|
|
1473
1473
|
}
|
|
1474
|
-
return
|
|
1475
|
-
var
|
|
1476
|
-
(
|
|
1474
|
+
return m.value.addEventListener("reset", b), () => {
|
|
1475
|
+
var p;
|
|
1476
|
+
(p = m.value) == null || p.removeEventListener("reset", b);
|
|
1477
1477
|
};
|
|
1478
1478
|
}, { immediate: !0 });
|
|
1479
1479
|
}), () => {
|
|
1480
|
-
let { id:
|
|
1481
|
-
return
|
|
1480
|
+
let { id: b, name: p, value: S, form: y, ...x } = e, k = { checked: i.value }, _ = { id: b, ref: a, role: "switch", type: d.value, tabIndex: 0, "aria-checked": i.value, "aria-labelledby": r == null ? void 0 : r.labelledby.value, "aria-describedby": r == null ? void 0 : r.describedby.value, onClick: v, onKeyup: f, onKeypress: g };
|
|
1481
|
+
return Ce(be, [p != null && i.value != null ? Ce(sn, Jt({ features: dt.Hidden, as: "input", type: "checkbox", hidden: !0, readOnly: !0, checked: i.value, form: y, name: p, value: S })) : null, z({ ourProps: _, theirProps: { ...l, ...it(x, ["modelValue", "defaultChecked"]) }, slot: k, attrs: l, slots: o, name: "Switch" })]);
|
|
1482
1482
|
};
|
|
1483
1483
|
} });
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
}
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
var t = K(e).HTMLElement;
|
|
1499
|
-
return e instanceof t || e instanceof HTMLElement;
|
|
1500
|
-
}
|
|
1501
|
-
function en(e) {
|
|
1502
|
-
if (typeof ShadowRoot > "u")
|
|
1503
|
-
return !1;
|
|
1504
|
-
var t = K(e).ShadowRoot;
|
|
1505
|
-
return e instanceof t || e instanceof ShadowRoot;
|
|
1506
|
-
}
|
|
1507
|
-
var ie = Math.round;
|
|
1508
|
-
function Ve() {
|
|
1509
|
-
var e = navigator.userAgentData;
|
|
1510
|
-
return e != null && e.brands && Array.isArray(e.brands) ? e.brands.map(function(t) {
|
|
1511
|
-
return t.brand + "/" + t.version;
|
|
1512
|
-
}).join(" ") : navigator.userAgent;
|
|
1513
|
-
}
|
|
1514
|
-
function Wr() {
|
|
1515
|
-
return !/^((?!chrome|android).)*safari/i.test(Ve());
|
|
1516
|
-
}
|
|
1517
|
-
function Oe(e, t, o) {
|
|
1518
|
-
t === void 0 && (t = !1), o === void 0 && (o = !1);
|
|
1519
|
-
var r = e.getBoundingClientRect(), n = 1, a = 1;
|
|
1520
|
-
t && q(e) && (n = e.offsetWidth > 0 && ie(r.width) / e.offsetWidth || 1, a = e.offsetHeight > 0 && ie(r.height) / e.offsetHeight || 1);
|
|
1521
|
-
var i = Ze(e) ? K(e) : window, u = i.visualViewport, c = !Wr() && o, s = (r.left + (c && u ? u.offsetLeft : 0)) / n, l = (r.top + (c && u ? u.offsetTop : 0)) / a, m = r.width / n, v = r.height / a;
|
|
1522
|
-
return {
|
|
1523
|
-
width: m,
|
|
1524
|
-
height: v,
|
|
1525
|
-
top: l,
|
|
1526
|
-
right: s + m,
|
|
1527
|
-
bottom: l + v,
|
|
1528
|
-
left: s,
|
|
1529
|
-
x: s,
|
|
1530
|
-
y: l
|
|
1531
|
-
};
|
|
1532
|
-
}
|
|
1533
|
-
function tn(e) {
|
|
1534
|
-
var t = K(e), o = t.pageXOffset, r = t.pageYOffset;
|
|
1535
|
-
return {
|
|
1536
|
-
scrollLeft: o,
|
|
1537
|
-
scrollTop: r
|
|
1538
|
-
};
|
|
1539
|
-
}
|
|
1540
|
-
function Kr(e) {
|
|
1541
|
-
return {
|
|
1542
|
-
scrollLeft: e.scrollLeft,
|
|
1543
|
-
scrollTop: e.scrollTop
|
|
1544
|
-
};
|
|
1545
|
-
}
|
|
1546
|
-
function Gr(e) {
|
|
1547
|
-
return e === K(e) || !q(e) ? tn(e) : Kr(e);
|
|
1548
|
-
}
|
|
1549
|
-
function ee(e) {
|
|
1550
|
-
return e ? (e.nodeName || "").toLowerCase() : null;
|
|
1551
|
-
}
|
|
1552
|
-
function Re(e) {
|
|
1553
|
-
return ((Ze(e) ? e.ownerDocument : (
|
|
1554
|
-
// $FlowFixMe[prop-missing]
|
|
1555
|
-
e.document
|
|
1556
|
-
)) || window.document).documentElement;
|
|
1557
|
-
}
|
|
1558
|
-
function qr(e) {
|
|
1559
|
-
return Oe(Re(e)).left + tn(e).scrollLeft;
|
|
1484
|
+
const Ae = Math.min, ue = Math.max, Me = Math.round, Ie = Math.floor, ae = (e) => ({
|
|
1485
|
+
x: e,
|
|
1486
|
+
y: e
|
|
1487
|
+
}), xl = {
|
|
1488
|
+
left: "right",
|
|
1489
|
+
right: "left",
|
|
1490
|
+
bottom: "top",
|
|
1491
|
+
top: "bottom"
|
|
1492
|
+
}, wl = {
|
|
1493
|
+
start: "end",
|
|
1494
|
+
end: "start"
|
|
1495
|
+
};
|
|
1496
|
+
function Lt(e, t, l) {
|
|
1497
|
+
return ue(e, Ae(t, l));
|
|
1560
1498
|
}
|
|
1561
|
-
function
|
|
1562
|
-
return
|
|
1499
|
+
function He(e, t) {
|
|
1500
|
+
return typeof e == "function" ? e(t) : e;
|
|
1563
1501
|
}
|
|
1564
|
-
function
|
|
1565
|
-
|
|
1566
|
-
return /auto|scroll|overlay|hidden/.test(o + n + r);
|
|
1502
|
+
function ce(e) {
|
|
1503
|
+
return e.split("-")[0];
|
|
1567
1504
|
}
|
|
1568
|
-
function
|
|
1569
|
-
|
|
1570
|
-
return o !== 1 || r !== 1;
|
|
1505
|
+
function We(e) {
|
|
1506
|
+
return e.split("-")[1];
|
|
1571
1507
|
}
|
|
1572
|
-
function
|
|
1573
|
-
|
|
1574
|
-
var r = q(t), n = q(t) && Xr(t), a = Re(t), i = Oe(e, n, o), u = {
|
|
1575
|
-
scrollLeft: 0,
|
|
1576
|
-
scrollTop: 0
|
|
1577
|
-
}, c = {
|
|
1578
|
-
x: 0,
|
|
1579
|
-
y: 0
|
|
1580
|
-
};
|
|
1581
|
-
return (r || !r && !o) && ((ee(t) !== "body" || // https://github.com/popperjs/popper-core/issues/1078
|
|
1582
|
-
Qe(a)) && (u = Gr(t)), q(t) ? (c = Oe(t, !0), c.x += t.clientLeft, c.y += t.clientTop) : a && (c.x = qr(a))), {
|
|
1583
|
-
x: i.left + u.scrollLeft - c.x,
|
|
1584
|
-
y: i.top + u.scrollTop - c.y,
|
|
1585
|
-
width: i.width,
|
|
1586
|
-
height: i.height
|
|
1587
|
-
};
|
|
1508
|
+
function wn(e) {
|
|
1509
|
+
return e === "x" ? "y" : "x";
|
|
1588
1510
|
}
|
|
1589
|
-
function
|
|
1590
|
-
|
|
1591
|
-
return Math.abs(t.width - o) <= 1 && (o = t.width), Math.abs(t.height - r) <= 1 && (r = t.height), {
|
|
1592
|
-
x: e.offsetLeft,
|
|
1593
|
-
y: e.offsetTop,
|
|
1594
|
-
width: o,
|
|
1595
|
-
height: r
|
|
1596
|
-
};
|
|
1511
|
+
function kn(e) {
|
|
1512
|
+
return e === "y" ? "height" : "width";
|
|
1597
1513
|
}
|
|
1598
|
-
function
|
|
1599
|
-
return
|
|
1600
|
-
// this is a quicker (but less type safe) way to save quite some bytes from the bundle
|
|
1601
|
-
// $FlowFixMe[incompatible-return]
|
|
1602
|
-
// $FlowFixMe[prop-missing]
|
|
1603
|
-
e.assignedSlot || // step into the shadow DOM of the parent of a slotted node
|
|
1604
|
-
e.parentNode || // DOM Element detected
|
|
1605
|
-
(en(e) ? e.host : null) || // ShadowRoot detected
|
|
1606
|
-
// $FlowFixMe[incompatible-call]: HTMLElement is a Node
|
|
1607
|
-
Re(e)
|
|
1608
|
-
);
|
|
1514
|
+
function Ke(e) {
|
|
1515
|
+
return ["top", "bottom"].includes(ce(e)) ? "y" : "x";
|
|
1609
1516
|
}
|
|
1610
|
-
function
|
|
1611
|
-
return
|
|
1517
|
+
function Sn(e) {
|
|
1518
|
+
return wn(Ke(e));
|
|
1612
1519
|
}
|
|
1613
|
-
function
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
return
|
|
1618
|
-
// $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here
|
|
1619
|
-
u.concat(xe(Je(i)))
|
|
1620
|
-
);
|
|
1520
|
+
function kl(e, t, l) {
|
|
1521
|
+
l === void 0 && (l = !1);
|
|
1522
|
+
const o = We(e), n = Sn(e), r = kn(n);
|
|
1523
|
+
let i = n === "x" ? o === (l ? "end" : "start") ? "right" : "left" : o === "start" ? "bottom" : "top";
|
|
1524
|
+
return t.reference[r] > t.floating[r] && (i = Ve(i)), [i, Ve(i)];
|
|
1621
1525
|
}
|
|
1622
|
-
function
|
|
1623
|
-
|
|
1526
|
+
function Sl(e) {
|
|
1527
|
+
const t = Ve(e);
|
|
1528
|
+
return [nt(e), t, nt(t)];
|
|
1624
1529
|
}
|
|
1625
|
-
function
|
|
1626
|
-
return
|
|
1627
|
-
re(e).position === "fixed" ? null : e.offsetParent;
|
|
1530
|
+
function nt(e) {
|
|
1531
|
+
return e.replace(/start|end/g, (t) => wl[t]);
|
|
1628
1532
|
}
|
|
1629
|
-
function
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
return
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
return n;
|
|
1641
|
-
n = n.parentNode;
|
|
1533
|
+
function Ol(e, t, l) {
|
|
1534
|
+
const o = ["left", "right"], n = ["right", "left"], r = ["top", "bottom"], i = ["bottom", "top"];
|
|
1535
|
+
switch (e) {
|
|
1536
|
+
case "top":
|
|
1537
|
+
case "bottom":
|
|
1538
|
+
return l ? t ? n : o : t ? o : n;
|
|
1539
|
+
case "left":
|
|
1540
|
+
case "right":
|
|
1541
|
+
return t ? r : i;
|
|
1542
|
+
default:
|
|
1543
|
+
return [];
|
|
1642
1544
|
}
|
|
1643
|
-
return null;
|
|
1644
1545
|
}
|
|
1645
|
-
function
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
return
|
|
1649
|
-
}
|
|
1650
|
-
var ke = "top", Ne = "bottom", Be = "right", Se = "left", eo = "start", Fe = "end", to = "beforeRead", no = "read", ro = "afterRead", oo = "beforeMain", ao = "main", lo = "afterMain", io = "beforeWrite", so = "write", uo = "afterWrite", co = [to, no, ro, oo, ao, lo, io, so, uo];
|
|
1651
|
-
function fo(e) {
|
|
1652
|
-
var t = /* @__PURE__ */ new Map(), o = /* @__PURE__ */ new Set(), r = [];
|
|
1653
|
-
e.forEach(function(a) {
|
|
1654
|
-
t.set(a.name, a);
|
|
1655
|
-
});
|
|
1656
|
-
function n(a) {
|
|
1657
|
-
o.add(a.name);
|
|
1658
|
-
var i = [].concat(a.requires || [], a.requiresIfExists || []);
|
|
1659
|
-
i.forEach(function(u) {
|
|
1660
|
-
if (!o.has(u)) {
|
|
1661
|
-
var c = t.get(u);
|
|
1662
|
-
c && n(c);
|
|
1663
|
-
}
|
|
1664
|
-
}), r.push(a);
|
|
1665
|
-
}
|
|
1666
|
-
return e.forEach(function(a) {
|
|
1667
|
-
o.has(a.name) || n(a);
|
|
1668
|
-
}), r;
|
|
1546
|
+
function Cl(e, t, l, o) {
|
|
1547
|
+
const n = We(e);
|
|
1548
|
+
let r = Ol(ce(e), l === "start", o);
|
|
1549
|
+
return n && (r = r.map((i) => i + "-" + n), t && (r = r.concat(r.map(nt)))), r;
|
|
1669
1550
|
}
|
|
1670
|
-
function
|
|
1671
|
-
|
|
1672
|
-
return co.reduce(function(o, r) {
|
|
1673
|
-
return o.concat(t.filter(function(n) {
|
|
1674
|
-
return n.phase === r;
|
|
1675
|
-
}));
|
|
1676
|
-
}, []);
|
|
1551
|
+
function Ve(e) {
|
|
1552
|
+
return e.replace(/left|right|bottom|top/g, (t) => xl[t]);
|
|
1677
1553
|
}
|
|
1678
|
-
function
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
})), t;
|
|
1554
|
+
function Rl(e) {
|
|
1555
|
+
return {
|
|
1556
|
+
top: 0,
|
|
1557
|
+
right: 0,
|
|
1558
|
+
bottom: 0,
|
|
1559
|
+
left: 0,
|
|
1560
|
+
...e
|
|
1686
1561
|
};
|
|
1687
1562
|
}
|
|
1688
|
-
function
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
}, {});
|
|
1696
|
-
return Object.keys(t).map(function(o) {
|
|
1697
|
-
return t[o];
|
|
1698
|
-
});
|
|
1699
|
-
}
|
|
1700
|
-
function on(e) {
|
|
1701
|
-
return e.split("-")[0];
|
|
1702
|
-
}
|
|
1703
|
-
function an(e) {
|
|
1704
|
-
return e.split("-")[1];
|
|
1563
|
+
function El(e) {
|
|
1564
|
+
return typeof e != "number" ? Rl(e) : {
|
|
1565
|
+
top: e,
|
|
1566
|
+
right: e,
|
|
1567
|
+
bottom: e,
|
|
1568
|
+
left: e
|
|
1569
|
+
};
|
|
1705
1570
|
}
|
|
1706
|
-
function
|
|
1707
|
-
return
|
|
1571
|
+
function Ne(e) {
|
|
1572
|
+
return {
|
|
1573
|
+
...e,
|
|
1574
|
+
top: e.y,
|
|
1575
|
+
left: e.x,
|
|
1576
|
+
right: e.x + e.width,
|
|
1577
|
+
bottom: e.y + e.height
|
|
1578
|
+
};
|
|
1708
1579
|
}
|
|
1709
|
-
function
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1580
|
+
function It(e, t, l) {
|
|
1581
|
+
let {
|
|
1582
|
+
reference: o,
|
|
1583
|
+
floating: n
|
|
1584
|
+
} = e;
|
|
1585
|
+
const r = Ke(t), i = Sn(t), u = kn(i), c = ce(t), s = r === "y", a = o.x + o.width / 2 - n.width / 2, d = o.y + o.height / 2 - n.height / 2, v = o[u] / 2 - n[u] / 2;
|
|
1586
|
+
let f;
|
|
1587
|
+
switch (c) {
|
|
1588
|
+
case "top":
|
|
1589
|
+
f = {
|
|
1590
|
+
x: a,
|
|
1591
|
+
y: o.y - n.height
|
|
1716
1592
|
};
|
|
1717
1593
|
break;
|
|
1718
|
-
case
|
|
1719
|
-
|
|
1720
|
-
x:
|
|
1721
|
-
y:
|
|
1594
|
+
case "bottom":
|
|
1595
|
+
f = {
|
|
1596
|
+
x: a,
|
|
1597
|
+
y: o.y + o.height
|
|
1722
1598
|
};
|
|
1723
1599
|
break;
|
|
1724
|
-
case
|
|
1725
|
-
|
|
1726
|
-
x:
|
|
1727
|
-
y:
|
|
1600
|
+
case "right":
|
|
1601
|
+
f = {
|
|
1602
|
+
x: o.x + o.width,
|
|
1603
|
+
y: d
|
|
1728
1604
|
};
|
|
1729
1605
|
break;
|
|
1730
|
-
case
|
|
1731
|
-
|
|
1732
|
-
x:
|
|
1733
|
-
y:
|
|
1606
|
+
case "left":
|
|
1607
|
+
f = {
|
|
1608
|
+
x: o.x - n.width,
|
|
1609
|
+
y: d
|
|
1734
1610
|
};
|
|
1735
1611
|
break;
|
|
1736
1612
|
default:
|
|
1737
|
-
|
|
1738
|
-
x:
|
|
1739
|
-
y:
|
|
1613
|
+
f = {
|
|
1614
|
+
x: o.x,
|
|
1615
|
+
y: o.y
|
|
1740
1616
|
};
|
|
1741
1617
|
}
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1618
|
+
switch (We(t)) {
|
|
1619
|
+
case "start":
|
|
1620
|
+
f[i] -= v * (l && s ? -1 : 1);
|
|
1621
|
+
break;
|
|
1622
|
+
case "end":
|
|
1623
|
+
f[i] += v * (l && s ? -1 : 1);
|
|
1624
|
+
break;
|
|
1625
|
+
}
|
|
1626
|
+
return f;
|
|
1627
|
+
}
|
|
1628
|
+
const Dl = async (e, t, l) => {
|
|
1629
|
+
const {
|
|
1630
|
+
placement: o = "bottom",
|
|
1631
|
+
strategy: n = "absolute",
|
|
1632
|
+
middleware: r = [],
|
|
1633
|
+
platform: i
|
|
1634
|
+
} = l, u = r.filter(Boolean), c = await (i.isRTL == null ? void 0 : i.isRTL(t));
|
|
1635
|
+
let s = await i.getElementRects({
|
|
1636
|
+
reference: e,
|
|
1637
|
+
floating: t,
|
|
1638
|
+
strategy: n
|
|
1639
|
+
}), {
|
|
1640
|
+
x: a,
|
|
1641
|
+
y: d
|
|
1642
|
+
} = It(s, o, c), v = o, f = {}, g = 0;
|
|
1643
|
+
for (let m = 0; m < u.length; m++) {
|
|
1644
|
+
const {
|
|
1645
|
+
name: b,
|
|
1646
|
+
fn: p
|
|
1647
|
+
} = u[m], {
|
|
1648
|
+
x: S,
|
|
1649
|
+
y,
|
|
1650
|
+
data: x,
|
|
1651
|
+
reset: k
|
|
1652
|
+
} = await p({
|
|
1653
|
+
x: a,
|
|
1654
|
+
y: d,
|
|
1655
|
+
initialPlacement: o,
|
|
1656
|
+
placement: v,
|
|
1657
|
+
strategy: n,
|
|
1658
|
+
middlewareData: f,
|
|
1659
|
+
rects: s,
|
|
1660
|
+
platform: i,
|
|
1661
|
+
elements: {
|
|
1662
|
+
reference: e,
|
|
1663
|
+
floating: t
|
|
1664
|
+
}
|
|
1665
|
+
});
|
|
1666
|
+
if (a = S ?? a, d = y ?? d, f = {
|
|
1667
|
+
...f,
|
|
1668
|
+
[b]: {
|
|
1669
|
+
...f[b],
|
|
1670
|
+
...x
|
|
1671
|
+
}
|
|
1672
|
+
}, k && g <= 50) {
|
|
1673
|
+
g++, typeof k == "object" && (k.placement && (v = k.placement), k.rects && (s = k.rects === !0 ? await i.getElementRects({
|
|
1674
|
+
reference: e,
|
|
1675
|
+
floating: t,
|
|
1676
|
+
strategy: n
|
|
1677
|
+
}) : k.rects), {
|
|
1678
|
+
x: a,
|
|
1679
|
+
y: d
|
|
1680
|
+
} = It(s, v, c)), m = -1;
|
|
1681
|
+
continue;
|
|
1752
1682
|
}
|
|
1753
1683
|
}
|
|
1754
|
-
return
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1684
|
+
return {
|
|
1685
|
+
x: a,
|
|
1686
|
+
y: d,
|
|
1687
|
+
placement: v,
|
|
1688
|
+
strategy: n,
|
|
1689
|
+
middlewareData: f
|
|
1690
|
+
};
|
|
1760
1691
|
};
|
|
1761
|
-
function
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1692
|
+
async function On(e, t) {
|
|
1693
|
+
var l;
|
|
1694
|
+
t === void 0 && (t = {});
|
|
1695
|
+
const {
|
|
1696
|
+
x: o,
|
|
1697
|
+
y: n,
|
|
1698
|
+
platform: r,
|
|
1699
|
+
rects: i,
|
|
1700
|
+
elements: u,
|
|
1701
|
+
strategy: c
|
|
1702
|
+
} = e, {
|
|
1703
|
+
boundary: s = "clippingAncestors",
|
|
1704
|
+
rootBoundary: a = "viewport",
|
|
1705
|
+
elementContext: d = "floating",
|
|
1706
|
+
altBoundary: v = !1,
|
|
1707
|
+
padding: f = 0
|
|
1708
|
+
} = He(t, e), g = El(f), b = u[v ? d === "floating" ? "reference" : "floating" : d], p = Ne(await r.getClippingRect({
|
|
1709
|
+
element: (l = await (r.isElement == null ? void 0 : r.isElement(b))) == null || l ? b : b.contextElement || await (r.getDocumentElement == null ? void 0 : r.getDocumentElement(u.floating)),
|
|
1710
|
+
boundary: s,
|
|
1711
|
+
rootBoundary: a,
|
|
1712
|
+
strategy: c
|
|
1713
|
+
})), S = d === "floating" ? {
|
|
1714
|
+
...i.floating,
|
|
1715
|
+
x: o,
|
|
1716
|
+
y: n
|
|
1717
|
+
} : i.reference, y = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(u.floating)), x = await (r.isElement == null ? void 0 : r.isElement(y)) ? await (r.getScale == null ? void 0 : r.getScale(y)) || {
|
|
1718
|
+
x: 1,
|
|
1719
|
+
y: 1
|
|
1720
|
+
} : {
|
|
1721
|
+
x: 1,
|
|
1722
|
+
y: 1
|
|
1723
|
+
}, k = Ne(r.convertOffsetParentRelativeRectToViewportRelativeRect ? await r.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
1724
|
+
rect: S,
|
|
1725
|
+
offsetParent: y,
|
|
1726
|
+
strategy: c
|
|
1727
|
+
}) : S);
|
|
1728
|
+
return {
|
|
1729
|
+
top: (p.top - k.top + g.top) / x.y,
|
|
1730
|
+
bottom: (k.bottom - p.bottom + g.bottom) / x.y,
|
|
1731
|
+
left: (p.left - k.left + g.left) / x.x,
|
|
1732
|
+
right: (k.right - p.right + g.right) / x.x
|
|
1733
|
+
};
|
|
1767
1734
|
}
|
|
1768
|
-
function
|
|
1769
|
-
e === void 0 && (e = {})
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
},
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
};
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
}
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
l.reset = !1, w = -1;
|
|
1815
|
-
continue;
|
|
1816
|
-
}
|
|
1817
|
-
var x = l.orderedModifiers[w], S = x.fn, $ = x.options, X = $ === void 0 ? {} : $, ae = x.name;
|
|
1818
|
-
typeof S == "function" && (l = S({
|
|
1819
|
-
state: l,
|
|
1820
|
-
options: X,
|
|
1821
|
-
name: ae,
|
|
1822
|
-
instance: p
|
|
1823
|
-
}) || l);
|
|
1735
|
+
const Pl = function(e) {
|
|
1736
|
+
return e === void 0 && (e = {}), {
|
|
1737
|
+
name: "flip",
|
|
1738
|
+
options: e,
|
|
1739
|
+
async fn(t) {
|
|
1740
|
+
var l, o;
|
|
1741
|
+
const {
|
|
1742
|
+
placement: n,
|
|
1743
|
+
middlewareData: r,
|
|
1744
|
+
rects: i,
|
|
1745
|
+
initialPlacement: u,
|
|
1746
|
+
platform: c,
|
|
1747
|
+
elements: s
|
|
1748
|
+
} = t, {
|
|
1749
|
+
mainAxis: a = !0,
|
|
1750
|
+
crossAxis: d = !0,
|
|
1751
|
+
fallbackPlacements: v,
|
|
1752
|
+
fallbackStrategy: f = "bestFit",
|
|
1753
|
+
fallbackAxisSideDirection: g = "none",
|
|
1754
|
+
flipAlignment: m = !0,
|
|
1755
|
+
...b
|
|
1756
|
+
} = He(e, t);
|
|
1757
|
+
if ((l = r.arrow) != null && l.alignmentOffset)
|
|
1758
|
+
return {};
|
|
1759
|
+
const p = ce(n), S = ce(u) === u, y = await (c.isRTL == null ? void 0 : c.isRTL(s.floating)), x = v || (S || !m ? [Ve(u)] : Sl(u));
|
|
1760
|
+
!v && g !== "none" && x.push(...Cl(u, m, g, y));
|
|
1761
|
+
const k = [u, ...x], _ = await On(t, b), C = [];
|
|
1762
|
+
let F = ((o = r.flip) == null ? void 0 : o.overflows) || [];
|
|
1763
|
+
if (a && C.push(_[p]), d) {
|
|
1764
|
+
const se = kl(n, i, y);
|
|
1765
|
+
C.push(_[se[0]], _[se[1]]);
|
|
1766
|
+
}
|
|
1767
|
+
if (F = [...F, {
|
|
1768
|
+
placement: n,
|
|
1769
|
+
overflows: C
|
|
1770
|
+
}], !C.every((se) => se <= 0)) {
|
|
1771
|
+
var re, _e;
|
|
1772
|
+
const se = (((re = r.flip) == null ? void 0 : re.index) || 0) + 1, bt = k[se];
|
|
1773
|
+
if (bt)
|
|
1774
|
+
return {
|
|
1775
|
+
data: {
|
|
1776
|
+
index: se,
|
|
1777
|
+
overflows: F
|
|
1778
|
+
},
|
|
1779
|
+
reset: {
|
|
1780
|
+
placement: bt
|
|
1824
1781
|
}
|
|
1782
|
+
};
|
|
1783
|
+
let we = (_e = F.filter((fe) => fe.overflows[0] <= 0).sort((fe, pe) => fe.overflows[1] - pe.overflows[1])[0]) == null ? void 0 : _e.placement;
|
|
1784
|
+
if (!we)
|
|
1785
|
+
switch (f) {
|
|
1786
|
+
case "bestFit": {
|
|
1787
|
+
var gt;
|
|
1788
|
+
const fe = (gt = F.map((pe) => [pe.placement, pe.overflows.filter((ke) => ke > 0).reduce((ke, Ln) => ke + Ln, 0)]).sort((pe, ke) => pe[1] - ke[1])[0]) == null ? void 0 : gt[0];
|
|
1789
|
+
fe && (we = fe);
|
|
1790
|
+
break;
|
|
1791
|
+
}
|
|
1792
|
+
case "initialPlacement":
|
|
1793
|
+
we = u;
|
|
1794
|
+
break;
|
|
1825
1795
|
}
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
return new Promise(function(g) {
|
|
1832
|
-
p.forceUpdate(), g(l);
|
|
1833
|
-
});
|
|
1834
|
-
}),
|
|
1835
|
-
destroy: function() {
|
|
1836
|
-
d(), v = !0;
|
|
1837
|
-
}
|
|
1838
|
-
};
|
|
1839
|
-
if (!ht(u, c))
|
|
1840
|
-
return p;
|
|
1841
|
-
p.setOptions(s).then(function(g) {
|
|
1842
|
-
!v && s.onFirstUpdate && s.onFirstUpdate(g);
|
|
1843
|
-
});
|
|
1844
|
-
function h() {
|
|
1845
|
-
l.orderedModifiers.forEach(function(g) {
|
|
1846
|
-
var f = g.name, C = g.options, y = C === void 0 ? {} : C, w = g.effect;
|
|
1847
|
-
if (typeof w == "function") {
|
|
1848
|
-
var x = w({
|
|
1849
|
-
state: l,
|
|
1850
|
-
name: f,
|
|
1851
|
-
instance: p,
|
|
1852
|
-
options: y
|
|
1853
|
-
}), S = function() {
|
|
1796
|
+
if (n !== we)
|
|
1797
|
+
return {
|
|
1798
|
+
reset: {
|
|
1799
|
+
placement: we
|
|
1800
|
+
}
|
|
1854
1801
|
};
|
|
1855
|
-
|
|
1802
|
+
}
|
|
1803
|
+
return {};
|
|
1804
|
+
}
|
|
1805
|
+
};
|
|
1806
|
+
};
|
|
1807
|
+
async function _l(e, t) {
|
|
1808
|
+
const {
|
|
1809
|
+
placement: l,
|
|
1810
|
+
platform: o,
|
|
1811
|
+
elements: n
|
|
1812
|
+
} = e, r = await (o.isRTL == null ? void 0 : o.isRTL(n.floating)), i = ce(l), u = We(l), c = Ke(l) === "y", s = ["left", "top"].includes(i) ? -1 : 1, a = r && c ? -1 : 1, d = He(t, e);
|
|
1813
|
+
let {
|
|
1814
|
+
mainAxis: v,
|
|
1815
|
+
crossAxis: f,
|
|
1816
|
+
alignmentAxis: g
|
|
1817
|
+
} = typeof d == "number" ? {
|
|
1818
|
+
mainAxis: d,
|
|
1819
|
+
crossAxis: 0,
|
|
1820
|
+
alignmentAxis: null
|
|
1821
|
+
} : {
|
|
1822
|
+
mainAxis: 0,
|
|
1823
|
+
crossAxis: 0,
|
|
1824
|
+
alignmentAxis: null,
|
|
1825
|
+
...d
|
|
1826
|
+
};
|
|
1827
|
+
return u && typeof g == "number" && (f = u === "end" ? g * -1 : g), c ? {
|
|
1828
|
+
x: f * a,
|
|
1829
|
+
y: v * s
|
|
1830
|
+
} : {
|
|
1831
|
+
x: v * s,
|
|
1832
|
+
y: f * a
|
|
1833
|
+
};
|
|
1834
|
+
}
|
|
1835
|
+
const Tl = function(e) {
|
|
1836
|
+
return e === void 0 && (e = 0), {
|
|
1837
|
+
name: "offset",
|
|
1838
|
+
options: e,
|
|
1839
|
+
async fn(t) {
|
|
1840
|
+
var l, o;
|
|
1841
|
+
const {
|
|
1842
|
+
x: n,
|
|
1843
|
+
y: r,
|
|
1844
|
+
placement: i,
|
|
1845
|
+
middlewareData: u
|
|
1846
|
+
} = t, c = await _l(t, e);
|
|
1847
|
+
return i === ((l = u.offset) == null ? void 0 : l.placement) && (o = u.arrow) != null && o.alignmentOffset ? {} : {
|
|
1848
|
+
x: n + c.x,
|
|
1849
|
+
y: r + c.y,
|
|
1850
|
+
data: {
|
|
1851
|
+
...c,
|
|
1852
|
+
placement: i
|
|
1856
1853
|
}
|
|
1857
|
-
}
|
|
1854
|
+
};
|
|
1858
1855
|
}
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1856
|
+
};
|
|
1857
|
+
}, Ll = function(e) {
|
|
1858
|
+
return e === void 0 && (e = {}), {
|
|
1859
|
+
name: "shift",
|
|
1860
|
+
options: e,
|
|
1861
|
+
async fn(t) {
|
|
1862
|
+
const {
|
|
1863
|
+
x: l,
|
|
1864
|
+
y: o,
|
|
1865
|
+
placement: n
|
|
1866
|
+
} = t, {
|
|
1867
|
+
mainAxis: r = !0,
|
|
1868
|
+
crossAxis: i = !1,
|
|
1869
|
+
limiter: u = {
|
|
1870
|
+
fn: (b) => {
|
|
1871
|
+
let {
|
|
1872
|
+
x: p,
|
|
1873
|
+
y: S
|
|
1874
|
+
} = b;
|
|
1875
|
+
return {
|
|
1876
|
+
x: p,
|
|
1877
|
+
y: S
|
|
1878
|
+
};
|
|
1879
|
+
}
|
|
1880
|
+
},
|
|
1881
|
+
...c
|
|
1882
|
+
} = He(e, t), s = {
|
|
1883
|
+
x: l,
|
|
1884
|
+
y: o
|
|
1885
|
+
}, a = await On(t, c), d = Ke(ce(n)), v = wn(d);
|
|
1886
|
+
let f = s[v], g = s[d];
|
|
1887
|
+
if (r) {
|
|
1888
|
+
const b = v === "y" ? "top" : "left", p = v === "y" ? "bottom" : "right", S = f + a[b], y = f - a[p];
|
|
1889
|
+
f = Lt(S, f, y);
|
|
1890
|
+
}
|
|
1891
|
+
if (i) {
|
|
1892
|
+
const b = d === "y" ? "top" : "left", p = d === "y" ? "bottom" : "right", S = g + a[b], y = g - a[p];
|
|
1893
|
+
g = Lt(S, g, y);
|
|
1894
|
+
}
|
|
1895
|
+
const m = u.fn({
|
|
1896
|
+
...t,
|
|
1897
|
+
[v]: f,
|
|
1898
|
+
[d]: g
|
|
1899
|
+
});
|
|
1900
|
+
return {
|
|
1901
|
+
...m,
|
|
1902
|
+
data: {
|
|
1903
|
+
x: m.x - l,
|
|
1904
|
+
y: m.y - o
|
|
1905
|
+
}
|
|
1906
|
+
};
|
|
1863
1907
|
}
|
|
1864
|
-
return p;
|
|
1865
1908
|
};
|
|
1866
|
-
}
|
|
1867
|
-
var ye = {
|
|
1868
|
-
passive: !0
|
|
1869
1909
|
};
|
|
1870
|
-
function
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1910
|
+
function ne(e) {
|
|
1911
|
+
return ft(e) ? (e.nodeName || "").toLowerCase() : "#document";
|
|
1912
|
+
}
|
|
1913
|
+
function H(e) {
|
|
1914
|
+
var t;
|
|
1915
|
+
return (e == null || (t = e.ownerDocument) == null ? void 0 : t.defaultView) || window;
|
|
1916
|
+
}
|
|
1917
|
+
function le(e) {
|
|
1918
|
+
var t;
|
|
1919
|
+
return (t = (ft(e) ? e.ownerDocument : e.document) || window.document) == null ? void 0 : t.documentElement;
|
|
1920
|
+
}
|
|
1921
|
+
function ft(e) {
|
|
1922
|
+
return e instanceof Node || e instanceof H(e).Node;
|
|
1923
|
+
}
|
|
1924
|
+
function oe(e) {
|
|
1925
|
+
return e instanceof Element || e instanceof H(e).Element;
|
|
1926
|
+
}
|
|
1927
|
+
function Q(e) {
|
|
1928
|
+
return e instanceof HTMLElement || e instanceof H(e).HTMLElement;
|
|
1929
|
+
}
|
|
1930
|
+
function $t(e) {
|
|
1931
|
+
return typeof ShadowRoot > "u" ? !1 : e instanceof ShadowRoot || e instanceof H(e).ShadowRoot;
|
|
1932
|
+
}
|
|
1933
|
+
function Pe(e) {
|
|
1934
|
+
const {
|
|
1935
|
+
overflow: t,
|
|
1936
|
+
overflowX: l,
|
|
1937
|
+
overflowY: o,
|
|
1938
|
+
display: n
|
|
1939
|
+
} = q(e);
|
|
1940
|
+
return /auto|scroll|overlay|hidden|clip/.test(t + o + l) && !["inline", "contents"].includes(n);
|
|
1941
|
+
}
|
|
1942
|
+
function Il(e) {
|
|
1943
|
+
return ["table", "td", "th"].includes(ne(e));
|
|
1944
|
+
}
|
|
1945
|
+
function pt(e) {
|
|
1946
|
+
const t = mt(), l = q(e);
|
|
1947
|
+
return l.transform !== "none" || l.perspective !== "none" || (l.containerType ? l.containerType !== "normal" : !1) || !t && (l.backdropFilter ? l.backdropFilter !== "none" : !1) || !t && (l.filter ? l.filter !== "none" : !1) || ["transform", "perspective", "filter"].some((o) => (l.willChange || "").includes(o)) || ["paint", "layout", "strict", "content"].some((o) => (l.contain || "").includes(o));
|
|
1948
|
+
}
|
|
1949
|
+
function $l(e) {
|
|
1950
|
+
let t = ge(e);
|
|
1951
|
+
for (; Q(t) && !Ge(t); ) {
|
|
1952
|
+
if (pt(t))
|
|
1953
|
+
return t;
|
|
1954
|
+
t = ge(t);
|
|
1955
|
+
}
|
|
1956
|
+
return null;
|
|
1957
|
+
}
|
|
1958
|
+
function mt() {
|
|
1959
|
+
return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
|
|
1960
|
+
}
|
|
1961
|
+
function Ge(e) {
|
|
1962
|
+
return ["html", "body", "#document"].includes(ne(e));
|
|
1963
|
+
}
|
|
1964
|
+
function q(e) {
|
|
1965
|
+
return H(e).getComputedStyle(e);
|
|
1966
|
+
}
|
|
1967
|
+
function qe(e) {
|
|
1968
|
+
return oe(e) ? {
|
|
1969
|
+
scrollLeft: e.scrollLeft,
|
|
1970
|
+
scrollTop: e.scrollTop
|
|
1971
|
+
} : {
|
|
1972
|
+
scrollLeft: e.pageXOffset,
|
|
1973
|
+
scrollTop: e.pageYOffset
|
|
1878
1974
|
};
|
|
1879
1975
|
}
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1976
|
+
function ge(e) {
|
|
1977
|
+
if (ne(e) === "html")
|
|
1978
|
+
return e;
|
|
1979
|
+
const t = (
|
|
1980
|
+
// Step into the shadow DOM of the parent of a slotted node.
|
|
1981
|
+
e.assignedSlot || // DOM Element detected.
|
|
1982
|
+
e.parentNode || // ShadowRoot detected.
|
|
1983
|
+
$t(e) && e.host || // Fallback.
|
|
1984
|
+
le(e)
|
|
1985
|
+
);
|
|
1986
|
+
return $t(t) ? t.host : t;
|
|
1987
|
+
}
|
|
1988
|
+
function Cn(e) {
|
|
1989
|
+
const t = ge(e);
|
|
1990
|
+
return Ge(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : Q(t) && Pe(t) ? t : Cn(t);
|
|
1991
|
+
}
|
|
1992
|
+
function Ee(e, t, l) {
|
|
1993
|
+
var o;
|
|
1994
|
+
t === void 0 && (t = []), l === void 0 && (l = !0);
|
|
1995
|
+
const n = Cn(e), r = n === ((o = e.ownerDocument) == null ? void 0 : o.body), i = H(n);
|
|
1996
|
+
return r ? t.concat(i, i.visualViewport || [], Pe(n) ? n : [], i.frameElement && l ? Ee(i.frameElement) : []) : t.concat(n, Ee(n, [], l));
|
|
1997
|
+
}
|
|
1998
|
+
function Rn(e) {
|
|
1999
|
+
const t = q(e);
|
|
2000
|
+
let l = parseFloat(t.width) || 0, o = parseFloat(t.height) || 0;
|
|
2001
|
+
const n = Q(e), r = n ? e.offsetWidth : l, i = n ? e.offsetHeight : o, u = Me(l) !== r || Me(o) !== i;
|
|
2002
|
+
return u && (l = r, o = i), {
|
|
2003
|
+
width: l,
|
|
2004
|
+
height: o,
|
|
2005
|
+
$: u
|
|
2006
|
+
};
|
|
2007
|
+
}
|
|
2008
|
+
function vt(e) {
|
|
2009
|
+
return oe(e) ? e : e.contextElement;
|
|
2010
|
+
}
|
|
2011
|
+
function ve(e) {
|
|
2012
|
+
const t = vt(e);
|
|
2013
|
+
if (!Q(t))
|
|
2014
|
+
return ae(1);
|
|
2015
|
+
const l = t.getBoundingClientRect(), {
|
|
2016
|
+
width: o,
|
|
2017
|
+
height: n,
|
|
2018
|
+
$: r
|
|
2019
|
+
} = Rn(t);
|
|
2020
|
+
let i = (r ? Me(l.width) : l.width) / o, u = (r ? Me(l.height) : l.height) / n;
|
|
2021
|
+
return (!i || !Number.isFinite(i)) && (i = 1), (!u || !Number.isFinite(u)) && (u = 1), {
|
|
2022
|
+
x: i,
|
|
2023
|
+
y: u
|
|
2024
|
+
};
|
|
2025
|
+
}
|
|
2026
|
+
const Al = /* @__PURE__ */ ae(0);
|
|
2027
|
+
function En(e) {
|
|
2028
|
+
const t = H(e);
|
|
2029
|
+
return !mt() || !t.visualViewport ? Al : {
|
|
2030
|
+
x: t.visualViewport.offsetLeft,
|
|
2031
|
+
y: t.visualViewport.offsetTop
|
|
2032
|
+
};
|
|
2033
|
+
}
|
|
2034
|
+
function Ml(e, t, l) {
|
|
2035
|
+
return t === void 0 && (t = !1), !l || t && l !== H(e) ? !1 : t;
|
|
2036
|
+
}
|
|
2037
|
+
function de(e, t, l, o) {
|
|
2038
|
+
t === void 0 && (t = !1), l === void 0 && (l = !1);
|
|
2039
|
+
const n = e.getBoundingClientRect(), r = vt(e);
|
|
2040
|
+
let i = ae(1);
|
|
2041
|
+
t && (o ? oe(o) && (i = ve(o)) : i = ve(e));
|
|
2042
|
+
const u = Ml(r, l, o) ? En(r) : ae(0);
|
|
2043
|
+
let c = (n.left + u.x) / i.x, s = (n.top + u.y) / i.y, a = n.width / i.x, d = n.height / i.y;
|
|
2044
|
+
if (r) {
|
|
2045
|
+
const v = H(r), f = o && oe(o) ? H(o) : o;
|
|
2046
|
+
let g = v.frameElement;
|
|
2047
|
+
for (; g && o && f !== v; ) {
|
|
2048
|
+
const m = ve(g), b = g.getBoundingClientRect(), p = q(g), S = b.left + (g.clientLeft + parseFloat(p.paddingLeft)) * m.x, y = b.top + (g.clientTop + parseFloat(p.paddingTop)) * m.y;
|
|
2049
|
+
c *= m.x, s *= m.y, a *= m.x, d *= m.y, c += S, s += y, g = H(g).frameElement;
|
|
2050
|
+
}
|
|
2051
|
+
}
|
|
2052
|
+
return Ne({
|
|
2053
|
+
width: a,
|
|
2054
|
+
height: d,
|
|
2055
|
+
x: c,
|
|
2056
|
+
y: s
|
|
1896
2057
|
});
|
|
1897
2058
|
}
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
};
|
|
1911
|
-
|
|
1912
|
-
|
|
2059
|
+
function Vl(e) {
|
|
2060
|
+
let {
|
|
2061
|
+
rect: t,
|
|
2062
|
+
offsetParent: l,
|
|
2063
|
+
strategy: o
|
|
2064
|
+
} = e;
|
|
2065
|
+
const n = Q(l), r = le(l);
|
|
2066
|
+
if (l === r)
|
|
2067
|
+
return t;
|
|
2068
|
+
let i = {
|
|
2069
|
+
scrollLeft: 0,
|
|
2070
|
+
scrollTop: 0
|
|
2071
|
+
}, u = ae(1);
|
|
2072
|
+
const c = ae(0);
|
|
2073
|
+
if ((n || !n && o !== "fixed") && ((ne(l) !== "body" || Pe(r)) && (i = qe(l)), Q(l))) {
|
|
2074
|
+
const s = de(l);
|
|
2075
|
+
u = ve(l), c.x = s.x + l.clientLeft, c.y = s.y + l.clientTop;
|
|
2076
|
+
}
|
|
1913
2077
|
return {
|
|
1914
|
-
|
|
1915
|
-
|
|
2078
|
+
width: t.width * u.x,
|
|
2079
|
+
height: t.height * u.y,
|
|
2080
|
+
x: t.x * u.x - i.scrollLeft * u.x + c.x,
|
|
2081
|
+
y: t.y * u.y - i.scrollTop * u.y + c.y
|
|
1916
2082
|
};
|
|
1917
2083
|
}
|
|
1918
|
-
function
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
2084
|
+
function Nl(e) {
|
|
2085
|
+
return Array.from(e.getClientRects());
|
|
2086
|
+
}
|
|
2087
|
+
function Dn(e) {
|
|
2088
|
+
return de(le(e)).left + qe(e).scrollLeft;
|
|
2089
|
+
}
|
|
2090
|
+
function Fl(e) {
|
|
2091
|
+
const t = le(e), l = qe(e), o = e.ownerDocument.body, n = ue(t.scrollWidth, t.clientWidth, o.scrollWidth, o.clientWidth), r = ue(t.scrollHeight, t.clientHeight, o.scrollHeight, o.clientHeight);
|
|
2092
|
+
let i = -l.scrollLeft + Dn(e);
|
|
2093
|
+
const u = -l.scrollTop;
|
|
2094
|
+
return q(o).direction === "rtl" && (i += ue(t.clientWidth, o.clientWidth) - n), {
|
|
2095
|
+
width: n,
|
|
2096
|
+
height: r,
|
|
2097
|
+
x: i,
|
|
2098
|
+
y: u
|
|
1925
2099
|
};
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
S[$]
|
|
1935
|
-
);
|
|
1936
|
-
d -= ae - r.height, d *= c ? 1 : -1;
|
|
1937
|
-
}
|
|
1938
|
-
if (n === Se || (n === ke || n === Ne) && a === Fe) {
|
|
1939
|
-
y = Be;
|
|
1940
|
-
var le = m && S === x && x.visualViewport ? x.visualViewport.width : (
|
|
1941
|
-
// $FlowFixMe[prop-missing]
|
|
1942
|
-
S[X]
|
|
1943
|
-
);
|
|
1944
|
-
p -= le - r.width, p *= c ? 1 : -1;
|
|
1945
|
-
}
|
|
2100
|
+
}
|
|
2101
|
+
function Bl(e, t) {
|
|
2102
|
+
const l = H(e), o = le(e), n = l.visualViewport;
|
|
2103
|
+
let r = o.clientWidth, i = o.clientHeight, u = 0, c = 0;
|
|
2104
|
+
if (n) {
|
|
2105
|
+
r = n.width, i = n.height;
|
|
2106
|
+
const s = mt();
|
|
2107
|
+
(!s || s && t === "fixed") && (u = n.offsetLeft, c = n.offsetTop);
|
|
1946
2108
|
}
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
x:
|
|
1951
|
-
y:
|
|
1952
|
-
}
|
|
1953
|
-
|
|
1954
|
-
|
|
2109
|
+
return {
|
|
2110
|
+
width: r,
|
|
2111
|
+
height: i,
|
|
2112
|
+
x: u,
|
|
2113
|
+
y: c
|
|
2114
|
+
};
|
|
2115
|
+
}
|
|
2116
|
+
function jl(e, t) {
|
|
2117
|
+
const l = de(e, !0, t === "fixed"), o = l.top + e.clientTop, n = l.left + e.clientLeft, r = Q(e) ? ve(e) : ae(1), i = e.clientWidth * r.x, u = e.clientHeight * r.y, c = n * r.x, s = o * r.y;
|
|
2118
|
+
return {
|
|
2119
|
+
width: i,
|
|
2120
|
+
height: u,
|
|
2121
|
+
x: c,
|
|
2122
|
+
y: s
|
|
1955
2123
|
};
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
2124
|
+
}
|
|
2125
|
+
function At(e, t, l) {
|
|
2126
|
+
let o;
|
|
2127
|
+
if (t === "viewport")
|
|
2128
|
+
o = Bl(e, l);
|
|
2129
|
+
else if (t === "document")
|
|
2130
|
+
o = Fl(le(e));
|
|
2131
|
+
else if (oe(t))
|
|
2132
|
+
o = jl(t, l);
|
|
2133
|
+
else {
|
|
2134
|
+
const n = En(e);
|
|
2135
|
+
o = {
|
|
2136
|
+
...t,
|
|
2137
|
+
x: t.x - n.x,
|
|
2138
|
+
y: t.y - n.y
|
|
2139
|
+
};
|
|
2140
|
+
}
|
|
2141
|
+
return Ne(o);
|
|
2142
|
+
}
|
|
2143
|
+
function Pn(e, t) {
|
|
2144
|
+
const l = ge(e);
|
|
2145
|
+
return l === t || !oe(l) || Ge(l) ? !1 : q(l).position === "fixed" || Pn(l, t);
|
|
2146
|
+
}
|
|
2147
|
+
function zl(e, t) {
|
|
2148
|
+
const l = t.get(e);
|
|
2149
|
+
if (l)
|
|
2150
|
+
return l;
|
|
2151
|
+
let o = Ee(e, [], !1).filter((u) => oe(u) && ne(u) !== "body"), n = null;
|
|
2152
|
+
const r = q(e).position === "fixed";
|
|
2153
|
+
let i = r ? ge(e) : e;
|
|
2154
|
+
for (; oe(i) && !Ge(i); ) {
|
|
2155
|
+
const u = q(i), c = pt(i);
|
|
2156
|
+
!c && u.position === "fixed" && (n = null), (r ? !c && !n : !c && u.position === "static" && !!n && ["absolute", "fixed"].includes(n.position) || Pe(i) && !c && Pn(e, i)) ? o = o.filter((a) => a !== i) : n = u, i = ge(i);
|
|
2157
|
+
}
|
|
2158
|
+
return t.set(e, o), o;
|
|
2159
|
+
}
|
|
2160
|
+
function Ul(e) {
|
|
2161
|
+
let {
|
|
2162
|
+
element: t,
|
|
2163
|
+
boundary: l,
|
|
2164
|
+
rootBoundary: o,
|
|
2165
|
+
strategy: n
|
|
2166
|
+
} = e;
|
|
2167
|
+
const i = [...l === "clippingAncestors" ? zl(t, this._c) : [].concat(l), o], u = i[0], c = i.reduce((s, a) => {
|
|
2168
|
+
const d = At(t, a, n);
|
|
2169
|
+
return s.top = ue(d.top, s.top), s.right = Ae(d.right, s.right), s.bottom = Ae(d.bottom, s.bottom), s.left = ue(d.left, s.left), s;
|
|
2170
|
+
}, At(t, u, n));
|
|
2171
|
+
return {
|
|
2172
|
+
width: c.right - c.left,
|
|
2173
|
+
height: c.bottom - c.top,
|
|
2174
|
+
x: c.left,
|
|
2175
|
+
y: c.top
|
|
1970
2176
|
};
|
|
1971
|
-
t.modifiersData.popperOffsets != null && (t.styles.popper = Object.assign({}, t.styles.popper, yt(Object.assign({}, s, {
|
|
1972
|
-
offsets: t.modifiersData.popperOffsets,
|
|
1973
|
-
position: t.options.strategy,
|
|
1974
|
-
adaptive: i,
|
|
1975
|
-
roundOffsets: c
|
|
1976
|
-
})))), t.modifiersData.arrow != null && (t.styles.arrow = Object.assign({}, t.styles.arrow, yt(Object.assign({}, s, {
|
|
1977
|
-
offsets: t.modifiersData.arrow,
|
|
1978
|
-
position: "absolute",
|
|
1979
|
-
adaptive: !1,
|
|
1980
|
-
roundOffsets: c
|
|
1981
|
-
})))), t.attributes.popper = Object.assign({}, t.attributes.popper, {
|
|
1982
|
-
"data-popper-placement": t.placement
|
|
1983
|
-
});
|
|
1984
2177
|
}
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
Object.keys(t.elements).forEach(function(o) {
|
|
1995
|
-
var r = t.styles[o] || {}, n = t.attributes[o] || {}, a = t.elements[o];
|
|
1996
|
-
!q(a) || !ee(a) || (Object.assign(a.style, r), Object.keys(n).forEach(function(i) {
|
|
1997
|
-
var u = n[i];
|
|
1998
|
-
u === !1 ? a.removeAttribute(i) : a.setAttribute(i, u === !0 ? "" : u);
|
|
1999
|
-
}));
|
|
2000
|
-
});
|
|
2178
|
+
function Hl(e) {
|
|
2179
|
+
const {
|
|
2180
|
+
width: t,
|
|
2181
|
+
height: l
|
|
2182
|
+
} = Rn(e);
|
|
2183
|
+
return {
|
|
2184
|
+
width: t,
|
|
2185
|
+
height: l
|
|
2186
|
+
};
|
|
2001
2187
|
}
|
|
2002
|
-
function
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
top: "0",
|
|
2008
|
-
margin: "0"
|
|
2009
|
-
},
|
|
2010
|
-
arrow: {
|
|
2011
|
-
position: "absolute"
|
|
2012
|
-
},
|
|
2013
|
-
reference: {}
|
|
2188
|
+
function Wl(e, t, l) {
|
|
2189
|
+
const o = Q(t), n = le(t), r = l === "fixed", i = de(e, !0, r, t);
|
|
2190
|
+
let u = {
|
|
2191
|
+
scrollLeft: 0,
|
|
2192
|
+
scrollTop: 0
|
|
2014
2193
|
};
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2194
|
+
const c = ae(0);
|
|
2195
|
+
if (o || !o && !r)
|
|
2196
|
+
if ((ne(t) !== "body" || Pe(n)) && (u = qe(t)), o) {
|
|
2197
|
+
const s = de(t, !0, r, t);
|
|
2198
|
+
c.x = s.x + t.clientLeft, c.y = s.y + t.clientTop;
|
|
2199
|
+
} else
|
|
2200
|
+
n && (c.x = Dn(n));
|
|
2201
|
+
return {
|
|
2202
|
+
x: i.left + u.scrollLeft - c.x,
|
|
2203
|
+
y: i.top + u.scrollTop - c.y,
|
|
2204
|
+
width: i.width,
|
|
2205
|
+
height: i.height
|
|
2024
2206
|
};
|
|
2025
2207
|
}
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2208
|
+
function Mt(e, t) {
|
|
2209
|
+
return !Q(e) || q(e).position === "fixed" ? null : t ? t(e) : e.offsetParent;
|
|
2210
|
+
}
|
|
2211
|
+
function _n(e, t) {
|
|
2212
|
+
const l = H(e);
|
|
2213
|
+
if (!Q(e))
|
|
2214
|
+
return l;
|
|
2215
|
+
let o = Mt(e, t);
|
|
2216
|
+
for (; o && Il(o) && q(o).position === "static"; )
|
|
2217
|
+
o = Mt(o, t);
|
|
2218
|
+
return o && (ne(o) === "html" || ne(o) === "body" && q(o).position === "static" && !pt(o)) ? l : o || $l(e) || l;
|
|
2219
|
+
}
|
|
2220
|
+
const Kl = async function(e) {
|
|
2221
|
+
let {
|
|
2222
|
+
reference: t,
|
|
2223
|
+
floating: l,
|
|
2224
|
+
strategy: o
|
|
2225
|
+
} = e;
|
|
2226
|
+
const n = this.getOffsetParent || _n, r = this.getDimensions;
|
|
2227
|
+
return {
|
|
2228
|
+
reference: Wl(t, await n(l), o),
|
|
2229
|
+
floating: {
|
|
2230
|
+
x: 0,
|
|
2231
|
+
y: 0,
|
|
2232
|
+
...await r(l)
|
|
2233
|
+
}
|
|
2234
|
+
};
|
|
2033
2235
|
};
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
}
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2236
|
+
function Gl(e) {
|
|
2237
|
+
return q(e).direction === "rtl";
|
|
2238
|
+
}
|
|
2239
|
+
const ql = {
|
|
2240
|
+
convertOffsetParentRelativeRectToViewportRelativeRect: Vl,
|
|
2241
|
+
getDocumentElement: le,
|
|
2242
|
+
getClippingRect: Ul,
|
|
2243
|
+
getOffsetParent: _n,
|
|
2244
|
+
getElementRects: Kl,
|
|
2245
|
+
getClientRects: Nl,
|
|
2246
|
+
getDimensions: Hl,
|
|
2247
|
+
getScale: ve,
|
|
2248
|
+
isElement: oe,
|
|
2249
|
+
isRTL: Gl
|
|
2250
|
+
};
|
|
2251
|
+
function Xl(e, t) {
|
|
2252
|
+
let l = null, o;
|
|
2253
|
+
const n = le(e);
|
|
2254
|
+
function r() {
|
|
2255
|
+
clearTimeout(o), l && l.disconnect(), l = null;
|
|
2256
|
+
}
|
|
2257
|
+
function i(u, c) {
|
|
2258
|
+
u === void 0 && (u = !1), c === void 0 && (c = 1), r();
|
|
2259
|
+
const {
|
|
2260
|
+
left: s,
|
|
2261
|
+
top: a,
|
|
2262
|
+
width: d,
|
|
2263
|
+
height: v
|
|
2264
|
+
} = e.getBoundingClientRect();
|
|
2265
|
+
if (u || t(), !d || !v)
|
|
2266
|
+
return;
|
|
2267
|
+
const f = Ie(a), g = Ie(n.clientWidth - (s + d)), m = Ie(n.clientHeight - (a + v)), b = Ie(s), S = {
|
|
2268
|
+
rootMargin: -f + "px " + -g + "px " + -m + "px " + -b + "px",
|
|
2269
|
+
threshold: ue(0, Ae(1, c)) || 1
|
|
2270
|
+
};
|
|
2271
|
+
let y = !0;
|
|
2272
|
+
function x(k) {
|
|
2273
|
+
const _ = k[0].intersectionRatio;
|
|
2274
|
+
if (_ !== c) {
|
|
2275
|
+
if (!y)
|
|
2276
|
+
return i();
|
|
2277
|
+
_ ? i(!1, _) : o = setTimeout(() => {
|
|
2278
|
+
i(!1, 1e-7);
|
|
2279
|
+
}, 100);
|
|
2280
|
+
}
|
|
2281
|
+
y = !1;
|
|
2282
|
+
}
|
|
2283
|
+
try {
|
|
2284
|
+
l = new IntersectionObserver(x, {
|
|
2285
|
+
...S,
|
|
2286
|
+
// Handle <iframe>s
|
|
2287
|
+
root: n.ownerDocument
|
|
2288
|
+
});
|
|
2289
|
+
} catch {
|
|
2290
|
+
l = new IntersectionObserver(x, S);
|
|
2291
|
+
}
|
|
2292
|
+
l.observe(e);
|
|
2293
|
+
}
|
|
2294
|
+
return i(!0), r;
|
|
2295
|
+
}
|
|
2296
|
+
function Yl(e, t, l, o) {
|
|
2297
|
+
o === void 0 && (o = {});
|
|
2298
|
+
const {
|
|
2299
|
+
ancestorScroll: n = !0,
|
|
2300
|
+
ancestorResize: r = !0,
|
|
2301
|
+
elementResize: i = typeof ResizeObserver == "function",
|
|
2302
|
+
layoutShift: u = typeof IntersectionObserver == "function",
|
|
2303
|
+
animationFrame: c = !1
|
|
2304
|
+
} = o, s = vt(e), a = n || r ? [...s ? Ee(s) : [], ...Ee(t)] : [];
|
|
2305
|
+
a.forEach((p) => {
|
|
2306
|
+
n && p.addEventListener("scroll", l, {
|
|
2307
|
+
passive: !0
|
|
2308
|
+
}), r && p.addEventListener("resize", l);
|
|
2309
|
+
});
|
|
2310
|
+
const d = s && u ? Xl(s, l) : null;
|
|
2311
|
+
let v = -1, f = null;
|
|
2312
|
+
i && (f = new ResizeObserver((p) => {
|
|
2313
|
+
let [S] = p;
|
|
2314
|
+
S && S.target === s && f && (f.unobserve(t), cancelAnimationFrame(v), v = requestAnimationFrame(() => {
|
|
2315
|
+
f && f.observe(t);
|
|
2316
|
+
})), l();
|
|
2317
|
+
}), s && !c && f.observe(s), f.observe(t));
|
|
2318
|
+
let g, m = c ? de(e) : null;
|
|
2319
|
+
c && b();
|
|
2320
|
+
function b() {
|
|
2321
|
+
const p = de(e);
|
|
2322
|
+
m && (p.x !== m.x || p.y !== m.y || p.width !== m.width || p.height !== m.height) && l(), m = p, g = requestAnimationFrame(b);
|
|
2323
|
+
}
|
|
2324
|
+
return l(), () => {
|
|
2325
|
+
a.forEach((p) => {
|
|
2326
|
+
n && p.removeEventListener("scroll", l), r && p.removeEventListener("resize", l);
|
|
2327
|
+
}), d && d(), f && f.disconnect(), f = null, c && cancelAnimationFrame(g);
|
|
2328
|
+
};
|
|
2329
|
+
}
|
|
2330
|
+
const Zl = Ll, Ql = Pl, Jl = (e, t, l) => {
|
|
2331
|
+
const o = /* @__PURE__ */ new Map(), n = {
|
|
2332
|
+
platform: ql,
|
|
2333
|
+
...l
|
|
2334
|
+
}, r = {
|
|
2335
|
+
...n.platform,
|
|
2336
|
+
_c: o
|
|
2337
|
+
};
|
|
2338
|
+
return Dl(e, t, {
|
|
2339
|
+
...n,
|
|
2340
|
+
platform: r
|
|
2341
|
+
});
|
|
2342
|
+
};
|
|
2343
|
+
function er(e) {
|
|
2344
|
+
return e != null && typeof e == "object" && "$el" in e;
|
|
2345
|
+
}
|
|
2346
|
+
function Vt(e) {
|
|
2347
|
+
if (er(e)) {
|
|
2348
|
+
const t = e.$el;
|
|
2349
|
+
return ft(t) && ne(t) === "#comment" ? null : t;
|
|
2350
|
+
}
|
|
2351
|
+
return e;
|
|
2352
|
+
}
|
|
2353
|
+
function Tn(e) {
|
|
2354
|
+
return typeof window > "u" ? 1 : (e.ownerDocument.defaultView || window).devicePixelRatio || 1;
|
|
2355
|
+
}
|
|
2356
|
+
function Nt(e, t) {
|
|
2357
|
+
const l = Tn(e);
|
|
2358
|
+
return Math.round(t * l) / l;
|
|
2359
|
+
}
|
|
2360
|
+
function tr(e, t, l) {
|
|
2361
|
+
l === void 0 && (l = {});
|
|
2362
|
+
const o = l.whileElementsMounted, n = w(() => {
|
|
2363
|
+
var C;
|
|
2364
|
+
return (C = P(l.open)) != null ? C : !0;
|
|
2365
|
+
}), r = w(() => P(l.middleware)), i = w(() => {
|
|
2366
|
+
var C;
|
|
2367
|
+
return (C = P(l.placement)) != null ? C : "bottom";
|
|
2368
|
+
}), u = w(() => {
|
|
2369
|
+
var C;
|
|
2370
|
+
return (C = P(l.strategy)) != null ? C : "absolute";
|
|
2371
|
+
}), c = w(() => {
|
|
2372
|
+
var C;
|
|
2373
|
+
return (C = P(l.transform)) != null ? C : !0;
|
|
2374
|
+
}), s = w(() => Vt(e.value)), a = w(() => Vt(t.value)), d = O(0), v = O(0), f = O(u.value), g = O(i.value), m = Vn({}), b = O(!1), p = w(() => {
|
|
2375
|
+
const C = {
|
|
2376
|
+
position: f.value,
|
|
2377
|
+
left: "0",
|
|
2378
|
+
top: "0"
|
|
2379
|
+
};
|
|
2380
|
+
if (!a.value)
|
|
2381
|
+
return C;
|
|
2382
|
+
const F = Nt(a.value, d.value), re = Nt(a.value, v.value);
|
|
2383
|
+
return c.value ? {
|
|
2384
|
+
...C,
|
|
2385
|
+
transform: "translate(" + F + "px, " + re + "px)",
|
|
2386
|
+
...Tn(a.value) >= 1.5 && {
|
|
2387
|
+
willChange: "transform"
|
|
2388
|
+
}
|
|
2389
|
+
} : {
|
|
2390
|
+
position: f.value,
|
|
2391
|
+
left: F + "px",
|
|
2392
|
+
top: re + "px"
|
|
2393
|
+
};
|
|
2394
|
+
});
|
|
2395
|
+
let S;
|
|
2396
|
+
function y() {
|
|
2397
|
+
s.value == null || a.value == null || Jl(s.value, a.value, {
|
|
2398
|
+
middleware: r.value,
|
|
2399
|
+
placement: i.value,
|
|
2400
|
+
strategy: u.value
|
|
2401
|
+
}).then((C) => {
|
|
2402
|
+
d.value = C.x, v.value = C.y, f.value = C.strategy, g.value = C.placement, m.value = C.middlewareData, b.value = !0;
|
|
2048
2403
|
});
|
|
2049
|
-
}
|
|
2404
|
+
}
|
|
2405
|
+
function x() {
|
|
2406
|
+
typeof S == "function" && (S(), S = void 0);
|
|
2407
|
+
}
|
|
2408
|
+
function k() {
|
|
2409
|
+
if (x(), o === void 0) {
|
|
2410
|
+
y();
|
|
2411
|
+
return;
|
|
2412
|
+
}
|
|
2413
|
+
if (s.value != null && a.value != null) {
|
|
2414
|
+
S = o(s.value, a.value, y);
|
|
2415
|
+
return;
|
|
2416
|
+
}
|
|
2417
|
+
}
|
|
2418
|
+
function _() {
|
|
2419
|
+
n.value || (b.value = !1);
|
|
2420
|
+
}
|
|
2421
|
+
return Z([r, i, u], y, {
|
|
2422
|
+
flush: "sync"
|
|
2423
|
+
}), Z([s, a], k, {
|
|
2424
|
+
flush: "sync"
|
|
2425
|
+
}), Z(n, _, {
|
|
2426
|
+
flush: "sync"
|
|
2427
|
+
}), Nn() && Fn(x), {
|
|
2428
|
+
x: me(d),
|
|
2429
|
+
y: me(v),
|
|
2430
|
+
strategy: me(f),
|
|
2431
|
+
placement: me(g),
|
|
2432
|
+
middlewareData: me(m),
|
|
2433
|
+
isPositioned: me(b),
|
|
2434
|
+
floatingStyles: p,
|
|
2435
|
+
update: y
|
|
2436
|
+
};
|
|
2050
2437
|
}
|
|
2051
|
-
const
|
|
2438
|
+
const _r = /* @__PURE__ */ $({
|
|
2052
2439
|
__name: "MenuContainer",
|
|
2053
2440
|
props: {
|
|
2054
2441
|
position: { default: "left" },
|
|
2055
2442
|
usePortal: { type: [Boolean, String], default: !1 }
|
|
2056
2443
|
},
|
|
2057
2444
|
setup(e) {
|
|
2058
|
-
const o =
|
|
2059
|
-
|
|
2445
|
+
const t = e, l = O(null), o = O(null), n = t.position === "left" ? "bottom-end" : "bottom-start", { floatingStyles: r } = tr(l, o, {
|
|
2446
|
+
placement: n,
|
|
2447
|
+
whileElementsMounted: Yl,
|
|
2448
|
+
middleware: [Tl(6), Ql(), Zl({ padding: 6 })]
|
|
2449
|
+
});
|
|
2450
|
+
return (i, u) => (R(), K(P(ml), {
|
|
2060
2451
|
as: "div",
|
|
2061
|
-
class: "
|
|
2452
|
+
class: "inline-block text-left"
|
|
2062
2453
|
}, {
|
|
2063
|
-
default:
|
|
2064
|
-
|
|
2454
|
+
default: W(() => [
|
|
2455
|
+
N(P(vl), {
|
|
2065
2456
|
class: "focus:outline-none",
|
|
2066
|
-
ref_key: "
|
|
2067
|
-
ref:
|
|
2457
|
+
ref_key: "reference",
|
|
2458
|
+
ref: l
|
|
2068
2459
|
}, {
|
|
2069
|
-
default:
|
|
2070
|
-
|
|
2071
|
-
|
|
2460
|
+
default: W(() => [
|
|
2461
|
+
ht(i.$slots, "button", {}, () => [
|
|
2462
|
+
N(P(U), {
|
|
2072
2463
|
class: "fill-current",
|
|
2073
2464
|
name: "ellipsis-h"
|
|
2074
2465
|
})
|
|
@@ -2076,16 +2467,17 @@ const ia = /* @__PURE__ */ _({
|
|
|
2076
2467
|
]),
|
|
2077
2468
|
_: 3
|
|
2078
2469
|
}, 512),
|
|
2079
|
-
(
|
|
2080
|
-
to: typeof
|
|
2081
|
-
disabled: !
|
|
2470
|
+
(R(), K(Bn, {
|
|
2471
|
+
to: typeof i.usePortal == "string" ? i.usePortal : "body",
|
|
2472
|
+
disabled: !i.usePortal
|
|
2082
2473
|
}, [
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2474
|
+
I("div", {
|
|
2475
|
+
class: "w-56",
|
|
2476
|
+
style: Ft(P(r)),
|
|
2477
|
+
ref_key: "floating",
|
|
2478
|
+
ref: o
|
|
2087
2479
|
}, [
|
|
2088
|
-
|
|
2480
|
+
N(Bt, {
|
|
2089
2481
|
"enter-active-class": "transition duration-200 ease-in-out",
|
|
2090
2482
|
"enter-from-class": "transform -translate-y-4 opacity-0",
|
|
2091
2483
|
"enter-to-class": "transform opacity-100",
|
|
@@ -2093,34 +2485,30 @@ const ia = /* @__PURE__ */ _({
|
|
|
2093
2485
|
"leave-from-class": "transform opacity-100",
|
|
2094
2486
|
"leave-to-class": "transform -translate-y-2 opacity-0"
|
|
2095
2487
|
}, {
|
|
2096
|
-
default:
|
|
2097
|
-
|
|
2098
|
-
class:
|
|
2099
|
-
{
|
|
2100
|
-
"absolute left-0 origin-top-left": !a.usePortal && a.position === "right",
|
|
2101
|
-
"absolute right-0 origin-top-right": !a.usePortal && a.position === "left"
|
|
2102
|
-
},
|
|
2488
|
+
default: W(() => [
|
|
2489
|
+
N(P(gl), {
|
|
2490
|
+
class: A([
|
|
2103
2491
|
"z-40 mt-1 p-1 bg-white rounded shadow-lg text-grey-700 focus:outline-none w-full"
|
|
2104
2492
|
])
|
|
2105
2493
|
}, {
|
|
2106
|
-
default:
|
|
2107
|
-
|
|
2494
|
+
default: W(() => [
|
|
2495
|
+
ht(i.$slots, "default")
|
|
2108
2496
|
]),
|
|
2109
2497
|
_: 3
|
|
2110
|
-
}
|
|
2498
|
+
})
|
|
2111
2499
|
]),
|
|
2112
2500
|
_: 3
|
|
2113
2501
|
})
|
|
2114
|
-
],
|
|
2502
|
+
], 4)
|
|
2115
2503
|
], 8, ["to", "disabled"]))
|
|
2116
2504
|
]),
|
|
2117
2505
|
_: 3
|
|
2118
2506
|
}));
|
|
2119
2507
|
}
|
|
2120
|
-
}),
|
|
2508
|
+
}), nr = {
|
|
2121
2509
|
key: 0,
|
|
2122
2510
|
class: "bg-grey-300 px-2 rounded-lg max-w-[66px] truncate"
|
|
2123
|
-
},
|
|
2511
|
+
}, Tr = /* @__PURE__ */ $({
|
|
2124
2512
|
__name: "MenuLink",
|
|
2125
2513
|
props: {
|
|
2126
2514
|
label: {},
|
|
@@ -2129,17 +2517,17 @@ const ia = /* @__PURE__ */ _({
|
|
|
2129
2517
|
as: {}
|
|
2130
2518
|
},
|
|
2131
2519
|
setup(e) {
|
|
2132
|
-
return (t,
|
|
2133
|
-
default:
|
|
2134
|
-
(
|
|
2135
|
-
class:
|
|
2136
|
-
|
|
2520
|
+
return (t, l) => (R(), K(P(bl), jn(zn({ disabled: t.disabled })), {
|
|
2521
|
+
default: W(({ active: o }) => [
|
|
2522
|
+
(R(), K(Un(t.as || "span"), {
|
|
2523
|
+
class: A(["flex items-center justify-between px-4 py-2 text-xs leading-5 transition-colors duration-100 rounded-lg", [
|
|
2524
|
+
o ? "bg-grey-200" : "",
|
|
2137
2525
|
t.disabled ? "opacity-50 pointer-events-none" : "hover:bg-grey-200 focus:bg-grey-200 focus:outline-none"
|
|
2138
2526
|
]])
|
|
2139
2527
|
}, {
|
|
2140
|
-
default:
|
|
2141
|
-
|
|
2142
|
-
t.meta ? (
|
|
2528
|
+
default: W(() => [
|
|
2529
|
+
I("span", null, B(t.label), 1),
|
|
2530
|
+
t.meta ? (R(), T("span", nr, B(t.meta), 1)) : M("", !0)
|
|
2143
2531
|
]),
|
|
2144
2532
|
_: 2
|
|
2145
2533
|
}, 1032, ["class"]))
|
|
@@ -2147,19 +2535,19 @@ const ia = /* @__PURE__ */ _({
|
|
|
2147
2535
|
_: 1
|
|
2148
2536
|
}, 16));
|
|
2149
2537
|
}
|
|
2150
|
-
}),
|
|
2538
|
+
}), or = { class: "relative" }, lr = {
|
|
2151
2539
|
key: 0,
|
|
2152
2540
|
class: "absolute left-0 inset-y-0 inline-flex items-center justify-center text-grey-700 dark:text-grey-100 px-4 pointer-events-none"
|
|
2153
|
-
},
|
|
2541
|
+
}, rr = {
|
|
2154
2542
|
key: 1,
|
|
2155
2543
|
class: "block truncate"
|
|
2156
|
-
},
|
|
2544
|
+
}, ir = {
|
|
2157
2545
|
key: 2,
|
|
2158
2546
|
class: "text-grey-500 truncate"
|
|
2159
|
-
},
|
|
2547
|
+
}, ar = { class: "absolute right-0 inset-y-0 inline-flex items-center justify-center text-grey-700 dark:text-grey-100 px-4 pointer-events-none" }, sr = { class: "absolute right-2 inset-y-0 flex items-center" }, ur = {
|
|
2160
2548
|
key: 0,
|
|
2161
2549
|
class: "bg-grey-500 text-grey-100 rounded text-xs px-2 py-1"
|
|
2162
|
-
},
|
|
2550
|
+
}, Lr = /* @__PURE__ */ $({
|
|
2163
2551
|
__name: "Select",
|
|
2164
2552
|
props: {
|
|
2165
2553
|
modelValue: {},
|
|
@@ -2172,37 +2560,37 @@ const ia = /* @__PURE__ */ _({
|
|
|
2172
2560
|
},
|
|
2173
2561
|
emits: ["update:modelValue"],
|
|
2174
2562
|
setup(e, { emit: t }) {
|
|
2175
|
-
const
|
|
2176
|
-
return
|
|
2177
|
-
() =>
|
|
2563
|
+
const l = e, o = l.modelValue ? O(l.modelValue) : O(void 0), n = t, { inputClasses: r, disabledClasses: i, textSizeClasses: u } = rt(l);
|
|
2564
|
+
return Z(
|
|
2565
|
+
() => l.modelValue,
|
|
2178
2566
|
(c) => {
|
|
2179
2567
|
var s;
|
|
2180
|
-
c && c.id !== ((s =
|
|
2568
|
+
c && c.id !== ((s = o.value) == null ? void 0 : s.id) && (o.value = c);
|
|
2181
2569
|
}
|
|
2182
|
-
),
|
|
2570
|
+
), Z(o, (c) => {
|
|
2183
2571
|
c && n("update:modelValue", c);
|
|
2184
|
-
}), (c, s) => (
|
|
2572
|
+
}), (c, s) => (R(), K(P(al), {
|
|
2185
2573
|
as: "div",
|
|
2186
|
-
modelValue:
|
|
2187
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
2574
|
+
modelValue: P(o),
|
|
2575
|
+
"onUpdate:modelValue": s[0] || (s[0] = (a) => Hn(o) ? o.value = a : null),
|
|
2188
2576
|
disabled: c.isDisabled
|
|
2189
2577
|
}, {
|
|
2190
|
-
default:
|
|
2191
|
-
|
|
2192
|
-
|
|
2193
|
-
class:
|
|
2578
|
+
default: W(() => [
|
|
2579
|
+
I("div", or, [
|
|
2580
|
+
N(P(sl), {
|
|
2581
|
+
class: A(["w-full mono-50 bg-white text-grey-800 placeholder-grey-600 border border-grey-300 dark:bg-grey-800 dark:text-grey-100 dark:placeholder-grey-400 dark:border-grey-700 focus:ring-2 focus:border-blue-400 focus:ring-blue-400 focus:outline-none dark:focus:border-blue-800 dark:focus:ring-blue-800 cursor-default rounded font-normal text-left", [P(r), P(u), P(i)]])
|
|
2194
2582
|
}, {
|
|
2195
|
-
default:
|
|
2196
|
-
var
|
|
2583
|
+
default: W(() => {
|
|
2584
|
+
var a;
|
|
2197
2585
|
return [
|
|
2198
|
-
c.icon ? (
|
|
2199
|
-
|
|
2200
|
-
name: ((
|
|
2586
|
+
c.icon ? (R(), T("span", lr, [
|
|
2587
|
+
N(U, {
|
|
2588
|
+
name: ((a = P(o)) == null ? void 0 : a.icon) ?? c.icon
|
|
2201
2589
|
}, null, 8, ["name"])
|
|
2202
|
-
])) :
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2590
|
+
])) : M("", !0),
|
|
2591
|
+
P(o) ? (R(), T("span", rr, B(P(o).label), 1)) : (R(), T("span", ir, B(c.placeholder), 1)),
|
|
2592
|
+
I("span", ar, [
|
|
2593
|
+
N(U, {
|
|
2206
2594
|
class: "text-grey-400",
|
|
2207
2595
|
name: "chevron-down",
|
|
2208
2596
|
"aria-hidden": "true"
|
|
@@ -2212,57 +2600,57 @@ const ia = /* @__PURE__ */ _({
|
|
|
2212
2600
|
}),
|
|
2213
2601
|
_: 1
|
|
2214
2602
|
}, 8, ["class"]),
|
|
2215
|
-
|
|
2603
|
+
N(Bt, {
|
|
2216
2604
|
"leave-active-class": "transition ease-in duration-100",
|
|
2217
2605
|
"leave-from-class": "opacity-100",
|
|
2218
2606
|
"leave-to-class": "opacity-0"
|
|
2219
2607
|
}, {
|
|
2220
|
-
default:
|
|
2221
|
-
|
|
2222
|
-
default:
|
|
2223
|
-
(
|
|
2608
|
+
default: W(() => [
|
|
2609
|
+
N(P(ul), { class: "absolute z-10 mt-1 w-full bg-white dark:bg-grey-700 dark:text-grey-50 shadow-lg max-h-60 rounded-md py-1 text-base ring-1 ring-black ring-opacity-5 overflow-auto focus:outline-none sm:text-sm" }, {
|
|
2610
|
+
default: W(() => [
|
|
2611
|
+
(R(!0), T(be, null, jt(c.options, (a) => (R(), K(P(cl), {
|
|
2224
2612
|
as: "template",
|
|
2225
|
-
key:
|
|
2226
|
-
value:
|
|
2227
|
-
disabled:
|
|
2613
|
+
key: a.id,
|
|
2614
|
+
value: a,
|
|
2615
|
+
disabled: a.disabled
|
|
2228
2616
|
}, {
|
|
2229
|
-
default:
|
|
2230
|
-
|
|
2231
|
-
class:
|
|
2232
|
-
|
|
2617
|
+
default: W(({ active: d, selected: v }) => [
|
|
2618
|
+
I("li", {
|
|
2619
|
+
class: A([
|
|
2620
|
+
d ? "text-white bg-blue-500" : "text-grey-900 dark:text-grey-50",
|
|
2233
2621
|
"cursor-default select-none relative py-2 pl-3 pr-12",
|
|
2234
|
-
{ "opacity-50 bg-grey-100":
|
|
2622
|
+
{ "opacity-50 bg-grey-100": a.disabled }
|
|
2235
2623
|
])
|
|
2236
2624
|
}, [
|
|
2237
|
-
|
|
2238
|
-
|
|
2625
|
+
I("div", sr, [
|
|
2626
|
+
a.disabled && c.disabledBadge ? (R(), T("span", ur, B(c.disabledBadge), 1)) : M("", !0)
|
|
2239
2627
|
]),
|
|
2240
|
-
|
|
2241
|
-
class:
|
|
2628
|
+
I("span", {
|
|
2629
|
+
class: A([
|
|
2242
2630
|
v ? "font-semibold" : "font-normal",
|
|
2243
2631
|
"block truncate"
|
|
2244
2632
|
])
|
|
2245
2633
|
}, [
|
|
2246
|
-
|
|
2634
|
+
a.icon ? (R(), K(U, {
|
|
2247
2635
|
key: 0,
|
|
2248
2636
|
class: "inline-block mr-1",
|
|
2249
|
-
name:
|
|
2250
|
-
}, null, 8, ["name"])) :
|
|
2251
|
-
|
|
2637
|
+
name: a.icon
|
|
2638
|
+
}, null, 8, ["name"])) : M("", !0),
|
|
2639
|
+
Wn(" " + B(a.label), 1)
|
|
2252
2640
|
], 2),
|
|
2253
|
-
v ? (
|
|
2641
|
+
v ? (R(), T("span", {
|
|
2254
2642
|
key: 0,
|
|
2255
|
-
class:
|
|
2256
|
-
|
|
2643
|
+
class: A([
|
|
2644
|
+
d ? "text-blue-100" : "text-blue-500",
|
|
2257
2645
|
"absolute inset-y-0 right-0 flex items-center pr-4"
|
|
2258
2646
|
])
|
|
2259
2647
|
}, [
|
|
2260
|
-
|
|
2648
|
+
N(U, {
|
|
2261
2649
|
name: "check",
|
|
2262
2650
|
class: "h-5 w-5",
|
|
2263
2651
|
"aria-hidden": "true"
|
|
2264
2652
|
})
|
|
2265
|
-
], 2)) :
|
|
2653
|
+
], 2)) : M("", !0)
|
|
2266
2654
|
], 2)
|
|
2267
2655
|
]),
|
|
2268
2656
|
_: 2
|
|
@@ -2278,19 +2666,19 @@ const ia = /* @__PURE__ */ _({
|
|
|
2278
2666
|
_: 1
|
|
2279
2667
|
}, 8, ["modelValue", "disabled"]));
|
|
2280
2668
|
}
|
|
2281
|
-
}),
|
|
2669
|
+
}), cr = { class: "animate-pulse" }, dr = { class: "flex items-center justify-between space-x-4" }, fr = {
|
|
2282
2670
|
key: 0,
|
|
2283
2671
|
class: "w-12 h-12 bg-current rounded-full shrink-0"
|
|
2284
|
-
},
|
|
2672
|
+
}, pr = {
|
|
2285
2673
|
key: 1,
|
|
2286
2674
|
class: "w-full h-8 bg-current rounded-lg"
|
|
2287
|
-
},
|
|
2675
|
+
}, mr = {
|
|
2288
2676
|
key: 0,
|
|
2289
2677
|
class: "mt-6 space-y-2"
|
|
2290
|
-
},
|
|
2678
|
+
}, vr = {
|
|
2291
2679
|
key: 1,
|
|
2292
2680
|
class: "w-1/3 h-10 mt-6 bg-current rounded-lg"
|
|
2293
|
-
},
|
|
2681
|
+
}, Ir = /* @__PURE__ */ $({
|
|
2294
2682
|
__name: "Skeleton",
|
|
2295
2683
|
props: {
|
|
2296
2684
|
avatar: { type: Boolean, default: !1 },
|
|
@@ -2299,38 +2687,38 @@ const ia = /* @__PURE__ */ _({
|
|
|
2299
2687
|
footer: { type: Boolean, default: !1 }
|
|
2300
2688
|
},
|
|
2301
2689
|
setup(e) {
|
|
2302
|
-
const t = e,
|
|
2303
|
-
const
|
|
2690
|
+
const t = e, l = new Array(t.lines).fill(void 0).map(() => {
|
|
2691
|
+
const o = [4, 5, 6, 8, 10, 16, 24, 32];
|
|
2304
2692
|
return {
|
|
2305
|
-
margin: `mr-${
|
|
2693
|
+
margin: `mr-${o[Math.floor(Math.random() * o.length)]}`
|
|
2306
2694
|
};
|
|
2307
2695
|
});
|
|
2308
|
-
return (
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
|
|
2696
|
+
return (o, n) => (R(), T("div", cr, [
|
|
2697
|
+
I("div", dr, [
|
|
2698
|
+
o.avatar ? (R(), T("div", fr)) : M("", !0),
|
|
2699
|
+
o.title ? (R(), T("div", pr)) : M("", !0)
|
|
2312
2700
|
]),
|
|
2313
|
-
|
|
2314
|
-
(
|
|
2315
|
-
class:
|
|
2701
|
+
o.lines > 0 ? (R(), T("div", mr, [
|
|
2702
|
+
(R(!0), T(be, null, jt(P(l), (r, i) => (R(), T("div", {
|
|
2703
|
+
class: A(["h-4 bg-current rounded-lg", r.margin]),
|
|
2316
2704
|
key: i
|
|
2317
2705
|
}, null, 2))), 128))
|
|
2318
|
-
])) :
|
|
2319
|
-
|
|
2706
|
+
])) : M("", !0),
|
|
2707
|
+
o.footer ? (R(), T("div", vr)) : M("", !0)
|
|
2320
2708
|
]));
|
|
2321
2709
|
}
|
|
2322
|
-
}),
|
|
2710
|
+
}), $r = /* @__PURE__ */ $({
|
|
2323
2711
|
__name: "Spinner",
|
|
2324
2712
|
setup(e) {
|
|
2325
|
-
return (t,
|
|
2713
|
+
return (t, l) => (R(), K(P(U), {
|
|
2326
2714
|
class: "animate-spin",
|
|
2327
2715
|
name: "circle-notch"
|
|
2328
2716
|
}));
|
|
2329
2717
|
}
|
|
2330
|
-
}),
|
|
2718
|
+
}), gr = { class: "relative inline-flex items-center" }, br = ["aria-label", "tabindex"], hr = {
|
|
2331
2719
|
key: 0,
|
|
2332
2720
|
class: "absolute inset-0 flex items-center justify-center"
|
|
2333
|
-
},
|
|
2721
|
+
}, Ar = /* @__PURE__ */ $({
|
|
2334
2722
|
__name: "SplitButton",
|
|
2335
2723
|
props: {
|
|
2336
2724
|
label: {},
|
|
@@ -2342,88 +2730,88 @@ const ia = /* @__PURE__ */ _({
|
|
|
2342
2730
|
},
|
|
2343
2731
|
emits: ["onClick", "onClickSplit"],
|
|
2344
2732
|
setup(e, { emit: t }) {
|
|
2345
|
-
const
|
|
2733
|
+
const l = t, o = e, n = w(() => {
|
|
2346
2734
|
const s = {
|
|
2347
|
-
"text-white bg-blue-600 border-transparent hover:bg-blue-700 active:bg-blue-700 dark:ring-blue-800 ring-offset-2 dark:ring-offset-grey-900":
|
|
2348
|
-
"text-blue-600 bg-grey-100 border-transparent hover:bg-blue-100 hover:text-blue-700 active:bg-grey-100 ring-blue-300 ring-offset-2 dark:ring-offset-grey-900":
|
|
2349
|
-
"text-grey-50 bg-grey-700 border-transparent hover:bg-grey-800 active:bg-grey-700 ring-grey-500 dark:ring-grey-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-grey-900":
|
|
2350
|
-
"text-red-50 bg-red-500 border-transparent hover:bg-red-600 active:bg-red-600 ring-red-400 dark:ring-red-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-red-900":
|
|
2351
|
-
},
|
|
2352
|
-
"px-4 py-1 text-xs leading-5 mono-100":
|
|
2353
|
-
"px-5 py-2 text-sm leading-4 font-medium":
|
|
2354
|
-
"px-8 pr-4 py-3 text-base leading-6 font-medium":
|
|
2355
|
-
},
|
|
2356
|
-
"pointer-events-none opacity-75 cursor-not-allowed":
|
|
2735
|
+
"text-white bg-blue-600 border-transparent hover:bg-blue-700 active:bg-blue-700 dark:ring-blue-800 ring-offset-2 dark:ring-offset-grey-900": o.color === "primary",
|
|
2736
|
+
"text-blue-600 bg-grey-100 border-transparent hover:bg-blue-100 hover:text-blue-700 active:bg-grey-100 ring-blue-300 ring-offset-2 dark:ring-offset-grey-900": o.color === "light",
|
|
2737
|
+
"text-grey-50 bg-grey-700 border-transparent hover:bg-grey-800 active:bg-grey-700 ring-grey-500 dark:ring-grey-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-grey-900": o.color === "dark",
|
|
2738
|
+
"text-red-50 bg-red-500 border-transparent hover:bg-red-600 active:bg-red-600 ring-red-400 dark:ring-red-400 dark:ring-opacity-50 ring-offset-2 dark:ring-offset-red-900": o.color === "danger"
|
|
2739
|
+
}, a = {
|
|
2740
|
+
"px-4 py-1 text-xs leading-5 mono-100": o.size === "small",
|
|
2741
|
+
"px-5 py-2 text-sm leading-4 font-medium": o.size === "medium",
|
|
2742
|
+
"px-8 pr-4 py-3 text-base leading-6 font-medium": o.size === "large"
|
|
2743
|
+
}, d = {
|
|
2744
|
+
"pointer-events-none opacity-75 cursor-not-allowed": o.isDisabled
|
|
2357
2745
|
};
|
|
2358
2746
|
return {
|
|
2359
2747
|
...s,
|
|
2360
|
-
...
|
|
2361
|
-
...
|
|
2748
|
+
...d,
|
|
2749
|
+
...a
|
|
2362
2750
|
};
|
|
2363
|
-
}),
|
|
2751
|
+
}), r = w(() => {
|
|
2364
2752
|
const s = {
|
|
2365
|
-
"border-l-white/50 border-l":
|
|
2366
|
-
"border-l-blue-100 border-l":
|
|
2367
|
-
"border-l-grey-600 border-l":
|
|
2368
|
-
"border-l-red-600 border-l":
|
|
2369
|
-
},
|
|
2370
|
-
"pl-2 pr-3":
|
|
2371
|
-
"pl-3 pr-3":
|
|
2372
|
-
"pl-4 pr-5":
|
|
2753
|
+
"border-l-white/50 border-l": o.color === "primary",
|
|
2754
|
+
"border-l-blue-100 border-l": o.color === "light",
|
|
2755
|
+
"border-l-grey-600 border-l": o.color === "dark",
|
|
2756
|
+
"border-l-red-600 border-l": o.color === "danger"
|
|
2757
|
+
}, a = {
|
|
2758
|
+
"pl-2 pr-3": o.size === "small",
|
|
2759
|
+
"pl-3 pr-3": o.size === "medium",
|
|
2760
|
+
"pl-4 pr-5": o.size === "large"
|
|
2373
2761
|
};
|
|
2374
2762
|
return {
|
|
2375
2763
|
...s,
|
|
2376
|
-
...
|
|
2764
|
+
...a
|
|
2377
2765
|
};
|
|
2378
|
-
}), i =
|
|
2766
|
+
}), i = w(() => ({
|
|
2379
2767
|
...{
|
|
2380
|
-
"text-white":
|
|
2381
|
-
"text-blue-600":
|
|
2382
|
-
"text-grey-50":
|
|
2768
|
+
"text-white": o.color === "primary",
|
|
2769
|
+
"text-blue-600": o.color === "light",
|
|
2770
|
+
"text-grey-50": o.color === "dark"
|
|
2383
2771
|
}
|
|
2384
2772
|
}));
|
|
2385
2773
|
function u() {
|
|
2386
|
-
|
|
2774
|
+
o.isDisabled || l("onClick");
|
|
2387
2775
|
}
|
|
2388
2776
|
function c() {
|
|
2389
|
-
|
|
2777
|
+
o.isDisabled || l("onClickSplit");
|
|
2390
2778
|
}
|
|
2391
|
-
return (s,
|
|
2392
|
-
|
|
2779
|
+
return (s, a) => (R(), T("div", gr, [
|
|
2780
|
+
I("button", {
|
|
2393
2781
|
type: "button",
|
|
2394
2782
|
"aria-label": s.label,
|
|
2395
2783
|
tabindex: s.isDisabled ? "-1" : void 0,
|
|
2396
|
-
class:
|
|
2784
|
+
class: A(["relative transition duration-150 ease-in-out rounded-l-lg", n.value]),
|
|
2397
2785
|
onClick: u
|
|
2398
2786
|
}, [
|
|
2399
|
-
|
|
2400
|
-
class:
|
|
2787
|
+
I("div", {
|
|
2788
|
+
class: A(!s.isLoading || "invisible")
|
|
2401
2789
|
}, [
|
|
2402
|
-
|
|
2790
|
+
I("span", null, B(s.label), 1)
|
|
2403
2791
|
], 2),
|
|
2404
|
-
s.isLoading ? (
|
|
2405
|
-
|
|
2792
|
+
s.isLoading ? (R(), T("span", hr, [
|
|
2793
|
+
N(U, {
|
|
2406
2794
|
class: "ml-3 animate-spin",
|
|
2407
2795
|
name: "circle-notch"
|
|
2408
2796
|
})
|
|
2409
|
-
])) :
|
|
2410
|
-
], 10,
|
|
2411
|
-
|
|
2797
|
+
])) : M("", !0)
|
|
2798
|
+
], 10, br),
|
|
2799
|
+
I("button", {
|
|
2412
2800
|
type: "button",
|
|
2413
|
-
class:
|
|
2801
|
+
class: A(["border-l-white/50 border-l transition duration-150 ease-in-out rounded-r-lg", [n.value, r.value]]),
|
|
2414
2802
|
onClick: c
|
|
2415
2803
|
}, [
|
|
2416
|
-
|
|
2417
|
-
class:
|
|
2804
|
+
N(U, {
|
|
2805
|
+
class: A([i.value]),
|
|
2418
2806
|
name: s.icon
|
|
2419
2807
|
}, null, 8, ["class", "name"])
|
|
2420
2808
|
], 2)
|
|
2421
2809
|
]));
|
|
2422
2810
|
}
|
|
2423
|
-
}),
|
|
2811
|
+
}), yr = { class: "sr-only" }, Mr = /* @__PURE__ */ $({
|
|
2424
2812
|
__name: "Switch",
|
|
2425
2813
|
props: {
|
|
2426
|
-
id: { default:
|
|
2814
|
+
id: { default: qt() },
|
|
2427
2815
|
label: {},
|
|
2428
2816
|
modelValue: { type: Boolean },
|
|
2429
2817
|
description: {},
|
|
@@ -2432,31 +2820,31 @@ const ia = /* @__PURE__ */ _({
|
|
|
2432
2820
|
},
|
|
2433
2821
|
emits: ["update:modelValue", "change"],
|
|
2434
2822
|
setup(e, { emit: t }) {
|
|
2435
|
-
const
|
|
2436
|
-
|
|
2823
|
+
const l = t, o = (n) => {
|
|
2824
|
+
l("update:modelValue", n), l("change", n);
|
|
2437
2825
|
};
|
|
2438
|
-
return (n,
|
|
2826
|
+
return (n, r) => (R(), K(P(yl), {
|
|
2439
2827
|
modelValue: n.modelValue,
|
|
2440
2828
|
label: n.label,
|
|
2441
|
-
class:
|
|
2442
|
-
"onUpdate:modelValue":
|
|
2829
|
+
class: A([n.modelValue ? "bg-blue-700" : "bg-grey-700", "relative inline-flex items-center h-6 transition rounded-full w-14 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-offset-grey-900 focus:ring-blue-300"]),
|
|
2830
|
+
"onUpdate:modelValue": o
|
|
2443
2831
|
}, {
|
|
2444
|
-
default:
|
|
2445
|
-
|
|
2446
|
-
class:
|
|
2447
|
-
},
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
class:
|
|
2832
|
+
default: W(() => [
|
|
2833
|
+
I("span", {
|
|
2834
|
+
class: A(["absolute text-xs text-center text-white inset-x-2", n.modelValue ? "pr-3" : "pl-3"])
|
|
2835
|
+
}, B(n.modelValue === !0 ? n.onLabel : n.offLabel), 3),
|
|
2836
|
+
I("span", yr, B(n.label), 1),
|
|
2837
|
+
I("span", {
|
|
2838
|
+
class: A([n.modelValue ? "translate-x-9" : "translate-x-1", "inline-block w-4 h-4 transition bg-white rounded-full"])
|
|
2451
2839
|
}, null, 2)
|
|
2452
2840
|
]),
|
|
2453
2841
|
_: 1
|
|
2454
2842
|
}, 8, ["modelValue", "label", "class"]));
|
|
2455
2843
|
}
|
|
2456
|
-
}),
|
|
2844
|
+
}), xr = { class: "relative" }, wr = ["tabindex", "value"], kr = {
|
|
2457
2845
|
inheritAttrs: !1
|
|
2458
|
-
},
|
|
2459
|
-
...
|
|
2846
|
+
}, Vr = /* @__PURE__ */ $({
|
|
2847
|
+
...kr,
|
|
2460
2848
|
__name: "Textarea",
|
|
2461
2849
|
props: {
|
|
2462
2850
|
modelValue: {},
|
|
@@ -2465,44 +2853,44 @@ const ia = /* @__PURE__ */ _({
|
|
|
2465
2853
|
block: { type: Boolean }
|
|
2466
2854
|
},
|
|
2467
2855
|
emits: ["update:modelValue"],
|
|
2468
|
-
setup(e, { expose: t, emit:
|
|
2469
|
-
const
|
|
2470
|
-
n("update:modelValue", (
|
|
2856
|
+
setup(e, { expose: t, emit: l }) {
|
|
2857
|
+
const o = e, n = l, { inputClasses: r, disabledClasses: i, textSizeClasses: u } = rt(o), c = function(d) {
|
|
2858
|
+
n("update:modelValue", (d == null ? void 0 : d.target).value);
|
|
2471
2859
|
}, s = O(null);
|
|
2472
2860
|
return t({
|
|
2473
2861
|
focus: () => {
|
|
2474
|
-
|
|
2862
|
+
o.isDisabled || s.value.focus();
|
|
2475
2863
|
}
|
|
2476
|
-
}), (
|
|
2477
|
-
|
|
2478
|
-
class: ["mono-50 bg-white text-grey-800 placeholder:text-grey-400 placeholder:font-normal border-grey-300 dark:bg-grey-800 dark:text-grey-100 dark:placeholder:text-grey-500 dark:border-grey-700 focus:border-blue-400 focus:ring-blue-400 dark:focus:border-blue-800 dark:focus:ring-blue-800 rounded", [
|
|
2479
|
-
tabindex:
|
|
2480
|
-
value:
|
|
2481
|
-
},
|
|
2864
|
+
}), (d, v) => (R(), T("div", xr, [
|
|
2865
|
+
I("textarea", ot({
|
|
2866
|
+
class: ["mono-50 bg-white text-grey-800 placeholder:text-grey-400 placeholder:font-normal border-grey-300 dark:bg-grey-800 dark:text-grey-100 dark:placeholder:text-grey-500 dark:border-grey-700 focus:border-blue-400 focus:ring-blue-400 dark:focus:border-blue-800 dark:focus:ring-blue-800 rounded", [P(r), P(u), P(i)]],
|
|
2867
|
+
tabindex: d.isDisabled ? "-1" : void 0,
|
|
2868
|
+
value: d.modelValue ?? ""
|
|
2869
|
+
}, d.$attrs, {
|
|
2482
2870
|
ref_key: "input",
|
|
2483
2871
|
ref: s,
|
|
2484
2872
|
cols: "56",
|
|
2485
2873
|
rows: "8",
|
|
2486
2874
|
onInput: c
|
|
2487
2875
|
}), `
|
|
2488
|
-
`, 16,
|
|
2876
|
+
`, 16, wr)
|
|
2489
2877
|
]));
|
|
2490
2878
|
}
|
|
2491
2879
|
});
|
|
2492
2880
|
export {
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
|
|
2881
|
+
Rr as D9Button,
|
|
2882
|
+
Er as D9Checkbox,
|
|
2883
|
+
U as D9Icon,
|
|
2884
|
+
Dr as D9Input,
|
|
2885
|
+
Pr as D9Label,
|
|
2886
|
+
_r as D9Menu,
|
|
2887
|
+
Tr as D9MenuLink,
|
|
2888
|
+
Lr as D9Select,
|
|
2889
|
+
Ir as D9Skeleton,
|
|
2890
|
+
$r as D9Spinner,
|
|
2891
|
+
Ar as D9SplitButton,
|
|
2892
|
+
Mr as D9Switch,
|
|
2893
|
+
Vr as D9Textarea,
|
|
2894
|
+
xt as brands,
|
|
2895
|
+
qn as icons
|
|
2508
2896
|
};
|