@scalar/api-client 0.5.4 → 0.6.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/components/ApiClient/AddressBar.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/ApiClient.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Request/Request.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Request/RequestAuth.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Request/RequestBody.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Request/RequestHeaders.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Request/RequestQuery.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Request/RequestVariables.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/RequestHistory.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/RequestHistoryItem.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Response/Response.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Response/ResponseBody.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Response/ResponseHeaders.vue.d.ts.map +1 -1
- package/dist/components/ApiClient/Response/ResponseMetaInformation.vue.d.ts.map +1 -1
- package/dist/components/CollapsibleSection/CollapsibleSection.vue.d.ts.map +1 -1
- package/dist/components/FlowModal.vue.d.ts.map +1 -1
- package/dist/components/Grid/Grid.vue.d.ts.map +1 -1
- package/dist/components/Grid/SimpleGrid.vue.d.ts.map +1 -1
- package/dist/components/HelpfulLink.vue.d.ts.map +1 -1
- package/dist/components/SimpleTable/SimpleCell.vue.d.ts.map +1 -1
- package/dist/components/SimpleTable/SimpleHeader.vue.d.ts.map +1 -1
- package/dist/components/SimpleTable/SimpleRow.vue.d.ts.map +1 -1
- package/dist/components/SimpleTable/SimpleTable.vue.d.ts.map +1 -1
- package/dist/index.js +306 -287
- package/package.json +43 -45
package/dist/index.js
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
console.error("vite-plugin-css-injected-by-js", e);
|
|
11
11
|
}
|
|
12
12
|
})();
|
|
13
|
-
import { cloneVNode, h as h$2, Fragment, inject, provide, ref, onMounted, watchEffect, computed, defineComponent, onUnmounted, watch, Teleport, reactive, unref, shallowRef, nextTick, getCurrentScope, onScopeDispose,
|
|
13
|
+
import { cloneVNode, h as h$2, Fragment, inject, provide, ref, onMounted, watchEffect, computed, defineComponent, onUnmounted, watch, Teleport, reactive, unref, shallowRef, nextTick, getCurrentScope, onScopeDispose, getCurrentInstance, readonly, openBlock, createBlock, withCtx, createElementVNode, createVNode, normalizeClass, normalizeStyle, createTextVNode, toDisplayString, createCommentVNode, renderSlot, createElementBlock, renderList, createStaticVNode, withDirectives, withModifiers, vShow, vModelSelect, vModelText, vModelCheckbox, withKeys } from "vue";
|
|
14
14
|
import { CodeMirror } from "@scalar/use-codemirror";
|
|
15
15
|
function u$3(r2, n2, ...a2) {
|
|
16
16
|
if (r2 in n2) {
|
|
@@ -23,22 +23,22 @@ function u$3(r2, n2, ...a2) {
|
|
|
23
23
|
var N$2 = ((o2) => (o2[o2.None = 0] = "None", o2[o2.RenderStrategy = 1] = "RenderStrategy", o2[o2.Static = 2] = "Static", o2))(N$2 || {}), S$2 = ((e2) => (e2[e2.Unmount = 0] = "Unmount", e2[e2.Hidden = 1] = "Hidden", e2))(S$2 || {});
|
|
24
24
|
function H$1({ visible: r2 = true, features: t2 = 0, ourProps: e2, theirProps: o2, ...i2 }) {
|
|
25
25
|
var a2;
|
|
26
|
-
let n2 = j$
|
|
26
|
+
let n2 = j$1(o2, e2), l2 = Object.assign(i2, { props: n2 });
|
|
27
27
|
if (r2 || t2 & 2 && n2.static)
|
|
28
|
-
return y$
|
|
28
|
+
return y$2(l2);
|
|
29
29
|
if (t2 & 1) {
|
|
30
30
|
let d2 = (a2 = n2.unmount) == null || a2 ? 0 : 1;
|
|
31
31
|
return u$3(d2, { [0]() {
|
|
32
32
|
return null;
|
|
33
33
|
}, [1]() {
|
|
34
|
-
return y$
|
|
34
|
+
return y$2({ ...i2, props: { ...n2, hidden: true, style: { display: "none" } } });
|
|
35
35
|
} });
|
|
36
36
|
}
|
|
37
|
-
return y$
|
|
37
|
+
return y$2(l2);
|
|
38
38
|
}
|
|
39
|
-
function y$
|
|
39
|
+
function y$2({ props: r2, attrs: t2, slots: e2, slot: o2, name: i2 }) {
|
|
40
40
|
var m2, h2;
|
|
41
|
-
let { as: n2, ...l2 } = T$
|
|
41
|
+
let { as: n2, ...l2 } = T$2(r2, ["unmount", "static"]), a2 = (m2 = e2.default) == null ? void 0 : m2.call(e2, o2), d2 = {};
|
|
42
42
|
if (o2) {
|
|
43
43
|
let u2 = false, c2 = [];
|
|
44
44
|
for (let [p2, f2] of Object.entries(o2))
|
|
@@ -49,11 +49,11 @@ function y$1({ props: r2, attrs: t2, slots: e2, slot: o2, name: i2 }) {
|
|
|
49
49
|
if (a2 = b$2(a2 != null ? a2 : []), Object.keys(l2).length > 0 || Object.keys(t2).length > 0) {
|
|
50
50
|
let [u2, ...c2] = a2 != null ? a2 : [];
|
|
51
51
|
if (!v$1(u2) || c2.length > 0)
|
|
52
|
-
throw new Error(['Passing props on "template"!', "", `The current component <${i2} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(l2).concat(Object.keys(t2)).map((s2) => s2.trim()).filter((s2,
|
|
52
|
+
throw new Error(['Passing props on "template"!', "", `The current component <${i2} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(l2).concat(Object.keys(t2)).map((s2) => s2.trim()).filter((s2, g, R) => R.indexOf(s2) === g).sort((s2, g) => s2.localeCompare(g)).map((s2) => ` - ${s2}`).join(`
|
|
53
53
|
`), "", "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((s2) => ` - ${s2}`).join(`
|
|
54
54
|
`)].join(`
|
|
55
55
|
`));
|
|
56
|
-
let p2 = j$
|
|
56
|
+
let p2 = j$1((h2 = u2.props) != null ? h2 : {}, l2), f2 = cloneVNode(u2, p2);
|
|
57
57
|
for (let s2 in p2)
|
|
58
58
|
s2.startsWith("on") && (f2.props || (f2.props = {}), f2.props[s2] = p2[s2]);
|
|
59
59
|
return f2;
|
|
@@ -65,7 +65,7 @@ function y$1({ props: r2, attrs: t2, slots: e2, slot: o2, name: i2 }) {
|
|
|
65
65
|
function b$2(r2) {
|
|
66
66
|
return r2.flatMap((t2) => t2.type === Fragment ? b$2(t2.children) : [t2]);
|
|
67
67
|
}
|
|
68
|
-
function j$
|
|
68
|
+
function j$1(...r2) {
|
|
69
69
|
if (r2.length === 0)
|
|
70
70
|
return {};
|
|
71
71
|
if (r2.length === 1)
|
|
@@ -87,7 +87,7 @@ function j$2(...r2) {
|
|
|
87
87
|
} });
|
|
88
88
|
return t2;
|
|
89
89
|
}
|
|
90
|
-
function T$
|
|
90
|
+
function T$2(r2, t2 = []) {
|
|
91
91
|
let e2 = Object.assign({}, r2);
|
|
92
92
|
for (let o2 of t2)
|
|
93
93
|
o2 in e2 && delete e2[o2];
|
|
@@ -103,20 +103,20 @@ function n$3() {
|
|
|
103
103
|
function t$4() {
|
|
104
104
|
return n$3();
|
|
105
105
|
}
|
|
106
|
-
var o$
|
|
107
|
-
function o(n2) {
|
|
106
|
+
var o$2 = ((r2) => (r2.Space = " ", r2.Enter = "Enter", r2.Escape = "Escape", r2.Backspace = "Backspace", r2.Delete = "Delete", r2.ArrowLeft = "ArrowLeft", r2.ArrowUp = "ArrowUp", r2.ArrowRight = "ArrowRight", r2.ArrowDown = "ArrowDown", r2.Home = "Home", r2.End = "End", r2.PageUp = "PageUp", r2.PageDown = "PageDown", r2.Tab = "Tab", r2))(o$2 || {});
|
|
107
|
+
function o$1(n2) {
|
|
108
108
|
var l2;
|
|
109
109
|
return n2 == null || n2.value == null ? null : (l2 = n2.value.$el) != null ? l2 : n2.value;
|
|
110
110
|
}
|
|
111
111
|
let n$2 = Symbol("Context");
|
|
112
112
|
var l$1 = ((e2) => (e2[e2.Open = 1] = "Open", e2[e2.Closed = 2] = "Closed", e2[e2.Closing = 4] = "Closing", e2[e2.Opening = 8] = "Opening", e2))(l$1 || {});
|
|
113
|
-
function p$
|
|
113
|
+
function p$3() {
|
|
114
114
|
return inject(n$2, null);
|
|
115
115
|
}
|
|
116
116
|
function c$3(o2) {
|
|
117
117
|
provide(n$2, o2);
|
|
118
118
|
}
|
|
119
|
-
function r
|
|
119
|
+
function r(t2, e2) {
|
|
120
120
|
if (t2)
|
|
121
121
|
return t2;
|
|
122
122
|
let n2 = e2 != null ? e2 : "button";
|
|
@@ -124,12 +124,12 @@ function r$1(t2, e2) {
|
|
|
124
124
|
return "button";
|
|
125
125
|
}
|
|
126
126
|
function b$1(t2, e2) {
|
|
127
|
-
let n2 = ref(r
|
|
127
|
+
let n2 = ref(r(t2.value.type, t2.value.as));
|
|
128
128
|
return onMounted(() => {
|
|
129
|
-
n2.value = r
|
|
129
|
+
n2.value = r(t2.value.type, t2.value.as);
|
|
130
130
|
}), watchEffect(() => {
|
|
131
|
-
var
|
|
132
|
-
n2.value || o(e2) && o(e2) instanceof HTMLButtonElement && !((
|
|
131
|
+
var o2;
|
|
132
|
+
n2.value || o$1(e2) && o$1(e2) instanceof HTMLButtonElement && !((o2 = o$1(e2)) != null && o2.hasAttribute("type")) && (n2.value = "button");
|
|
133
133
|
}), n2;
|
|
134
134
|
}
|
|
135
135
|
var i$1 = Object.defineProperty;
|
|
@@ -166,19 +166,19 @@ function m$2(r2) {
|
|
|
166
166
|
if (r2 instanceof Node)
|
|
167
167
|
return r2.ownerDocument;
|
|
168
168
|
if (r2 != null && r2.hasOwnProperty("value")) {
|
|
169
|
-
let n2 = o(r2);
|
|
169
|
+
let n2 = o$1(r2);
|
|
170
170
|
if (n2)
|
|
171
171
|
return n2.ownerDocument;
|
|
172
172
|
}
|
|
173
173
|
return document;
|
|
174
174
|
}
|
|
175
175
|
let c$1 = ["[contentEditable=true]", "[tabindex]", "a[href]", "area[href]", "button:not([disabled])", "iframe", "input:not([disabled])", "select:not([disabled])", "textarea:not([disabled])"].map((e2) => `${e2}:not([tabindex='-1'])`).join(",");
|
|
176
|
-
var N$1 = ((n2) => (n2[n2.First = 1] = "First", n2[n2.Previous = 2] = "Previous", n2[n2.Next = 4] = "Next", n2[n2.Last = 8] = "Last", n2[n2.WrapAround = 16] = "WrapAround", n2[n2.NoScroll = 32] = "NoScroll", n2))(N$1 || {}), T = ((o2) => (o2[o2.Error = 0] = "Error", o2[o2.Overflow = 1] = "Overflow", o2[o2.Success = 2] = "Success", o2[o2.Underflow = 3] = "Underflow", o2))(T || {}), F$
|
|
176
|
+
var N$1 = ((n2) => (n2[n2.First = 1] = "First", n2[n2.Previous = 2] = "Previous", n2[n2.Next = 4] = "Next", n2[n2.Last = 8] = "Last", n2[n2.WrapAround = 16] = "WrapAround", n2[n2.NoScroll = 32] = "NoScroll", n2))(N$1 || {}), T$1 = ((o2) => (o2[o2.Error = 0] = "Error", o2[o2.Overflow = 1] = "Overflow", o2[o2.Success = 2] = "Success", o2[o2.Underflow = 3] = "Underflow", o2))(T$1 || {}), F$1 = ((t2) => (t2[t2.Previous = -1] = "Previous", t2[t2.Next = 1] = "Next", t2))(F$1 || {});
|
|
177
177
|
function E$4(e2 = document.body) {
|
|
178
178
|
return e2 == null ? [] : Array.from(e2.querySelectorAll(c$1)).sort((r2, t2) => Math.sign((r2.tabIndex || Number.MAX_SAFE_INTEGER) - (t2.tabIndex || Number.MAX_SAFE_INTEGER)));
|
|
179
179
|
}
|
|
180
180
|
var h$1 = ((t2) => (t2[t2.Strict = 0] = "Strict", t2[t2.Loose = 1] = "Loose", t2))(h$1 || {});
|
|
181
|
-
function w$
|
|
181
|
+
function w$2(e2, r2 = 0) {
|
|
182
182
|
var t2;
|
|
183
183
|
return e2 === ((t2 = m$2(e2)) == null ? void 0 : t2.body) ? false : u$3(r2, { [0]() {
|
|
184
184
|
return e2.matches(c$1);
|
|
@@ -192,7 +192,7 @@ function w$1(e2, r2 = 0) {
|
|
|
192
192
|
return false;
|
|
193
193
|
} });
|
|
194
194
|
}
|
|
195
|
-
var y = ((t2) => (t2[t2.Keyboard = 0] = "Keyboard", t2[t2.Mouse = 1] = "Mouse", t2))(y || {});
|
|
195
|
+
var y$1 = ((t2) => (t2[t2.Keyboard = 0] = "Keyboard", t2[t2.Mouse = 1] = "Mouse", t2))(y$1 || {});
|
|
196
196
|
typeof window != "undefined" && typeof document != "undefined" && (document.addEventListener("keydown", (e2) => {
|
|
197
197
|
e2.metaKey || e2.altKey || e2.ctrlKey || (document.documentElement.dataset.headlessuiFocusVisible = "");
|
|
198
198
|
}, true), document.addEventListener("click", (e2) => {
|
|
@@ -206,7 +206,7 @@ function I(e2) {
|
|
|
206
206
|
var r2, t2;
|
|
207
207
|
return (t2 = (r2 = e2 == null ? void 0 : e2.matches) == null ? void 0 : r2.call(e2, H)) != null ? t2 : false;
|
|
208
208
|
}
|
|
209
|
-
function O(e2, r2 = (t2) => t2) {
|
|
209
|
+
function O$1(e2, r2 = (t2) => t2) {
|
|
210
210
|
return e2.slice().sort((t2, l2) => {
|
|
211
211
|
let o2 = r2(t2), i2 = r2(l2);
|
|
212
212
|
if (o2 === null || i2 === null)
|
|
@@ -217,7 +217,7 @@ function O(e2, r2 = (t2) => t2) {
|
|
|
217
217
|
}
|
|
218
218
|
function P$1(e2, r2, { sorted: t2 = true, relativeTo: l2 = null, skipElements: o2 = [] } = {}) {
|
|
219
219
|
var m2;
|
|
220
|
-
let i2 = (m2 = Array.isArray(e2) ? e2.length > 0 ? e2[0].ownerDocument : document : e2 == null ? void 0 : e2.ownerDocument) != null ? m2 : document, n2 = Array.isArray(e2) ? t2 ? O(e2) : e2 : E$4(e2);
|
|
220
|
+
let i2 = (m2 = Array.isArray(e2) ? e2.length > 0 ? e2[0].ownerDocument : document : e2 == null ? void 0 : e2.ownerDocument) != null ? m2 : document, n2 = Array.isArray(e2) ? t2 ? O$1(e2) : e2 : E$4(e2);
|
|
221
221
|
o2.length > 0 && n2.length > 1 && (n2 = n2.filter((s2) => !o2.includes(s2))), l2 = l2 != null ? l2 : i2.activeElement;
|
|
222
222
|
let x2 = (() => {
|
|
223
223
|
if (r2 & 5)
|
|
@@ -257,37 +257,40 @@ function u$2(e2, t2, n2) {
|
|
|
257
257
|
document.addEventListener(e2, t2, n2), o2(() => document.removeEventListener(e2, t2, n2));
|
|
258
258
|
});
|
|
259
259
|
}
|
|
260
|
-
function w(e2, n2, t2) {
|
|
260
|
+
function w$1(e2, n2, t2) {
|
|
261
261
|
c$2.isServer || watchEffect((o2) => {
|
|
262
262
|
window.addEventListener(e2, n2, t2), o2(() => window.removeEventListener(e2, n2, t2));
|
|
263
263
|
});
|
|
264
264
|
}
|
|
265
|
-
function
|
|
266
|
-
function
|
|
267
|
-
if (!
|
|
265
|
+
function y(f2, c2, i2 = computed(() => true)) {
|
|
266
|
+
function a2(e2, r2) {
|
|
267
|
+
if (!i2.value || e2.defaultPrevented)
|
|
268
268
|
return;
|
|
269
|
-
let
|
|
270
|
-
if (
|
|
269
|
+
let t2 = r2(e2);
|
|
270
|
+
if (t2 === null || !t2.getRootNode().contains(t2))
|
|
271
271
|
return;
|
|
272
|
-
let
|
|
273
|
-
return typeof
|
|
272
|
+
let m2 = function o2(n2) {
|
|
273
|
+
return typeof n2 == "function" ? o2(n2()) : Array.isArray(n2) || n2 instanceof Set ? n2 : [n2];
|
|
274
274
|
}(f2);
|
|
275
|
-
for (let
|
|
276
|
-
if (
|
|
275
|
+
for (let o2 of m2) {
|
|
276
|
+
if (o2 === null)
|
|
277
277
|
continue;
|
|
278
|
-
let
|
|
279
|
-
if (
|
|
278
|
+
let n2 = o2 instanceof HTMLElement ? o2 : o$1(o2);
|
|
279
|
+
if (n2 != null && n2.contains(t2) || e2.composed && e2.composedPath().includes(n2))
|
|
280
280
|
return;
|
|
281
281
|
}
|
|
282
|
-
return !w$
|
|
282
|
+
return !w$2(t2, h$1.Loose) && t2.tabIndex !== -1 && e2.preventDefault(), c2(e2, t2);
|
|
283
283
|
}
|
|
284
|
-
let
|
|
285
|
-
u$2("
|
|
286
|
-
var
|
|
287
|
-
|
|
284
|
+
let u2 = ref(null);
|
|
285
|
+
u$2("pointerdown", (e2) => {
|
|
286
|
+
var r2, t2;
|
|
287
|
+
i2.value && (u2.value = ((t2 = (r2 = e2.composedPath) == null ? void 0 : r2.call(e2)) == null ? void 0 : t2[0]) || e2.target);
|
|
288
|
+
}, true), u$2("mousedown", (e2) => {
|
|
289
|
+
var r2, t2;
|
|
290
|
+
i2.value && (u2.value = ((t2 = (r2 = e2.composedPath) == null ? void 0 : r2.call(e2)) == null ? void 0 : t2[0]) || e2.target);
|
|
288
291
|
}, true), u$2("click", (e2) => {
|
|
289
|
-
|
|
290
|
-
}, true), w("blur", (e2) =>
|
|
292
|
+
u2.value && (a2(e2, () => u2.value), u2.value = null);
|
|
293
|
+
}, true), u$2("touchend", (e2) => a2(e2, () => e2.target instanceof HTMLElement ? e2.target : null), true), w$1("blur", (e2) => a2(e2, () => window.document.activeElement instanceof HTMLIFrameElement ? window.document.activeElement : null), true);
|
|
291
294
|
}
|
|
292
295
|
var a$2 = ((e2) => (e2[e2.None = 1] = "None", e2[e2.Focusable = 2] = "Focusable", e2[e2.Hidden = 4] = "Hidden", e2))(a$2 || {});
|
|
293
296
|
let f$1 = defineComponent({ name: "Hidden", props: { as: { type: [Object, String], default: "div" }, features: { type: Number, default: 1 } }, setup(r2, { slots: t2, attrs: d2 }) {
|
|
@@ -299,9 +302,14 @@ let f$1 = defineComponent({ name: "Hidden", props: { as: { type: [Object, String
|
|
|
299
302
|
function t$3() {
|
|
300
303
|
return /iPhone/gi.test(window.navigator.platform) || /Mac/gi.test(window.navigator.platform) && window.navigator.maxTouchPoints > 0;
|
|
301
304
|
}
|
|
302
|
-
function
|
|
303
|
-
|
|
304
|
-
|
|
305
|
+
function t$2(e2) {
|
|
306
|
+
typeof queueMicrotask == "function" ? queueMicrotask(e2) : Promise.resolve().then(e2).catch((o2) => setTimeout(() => {
|
|
307
|
+
throw o2;
|
|
308
|
+
}));
|
|
309
|
+
}
|
|
310
|
+
function o() {
|
|
311
|
+
let a2 = [], s2 = { addEventListener(e2, t2, r2, i2) {
|
|
312
|
+
return e2.addEventListener(t2, r2, i2), s2.add(() => e2.removeEventListener(t2, r2, i2));
|
|
305
313
|
}, requestAnimationFrame(...e2) {
|
|
306
314
|
let t2 = requestAnimationFrame(...e2);
|
|
307
315
|
s2.add(() => cancelAnimationFrame(t2));
|
|
@@ -312,23 +320,30 @@ function r() {
|
|
|
312
320
|
}, setTimeout(...e2) {
|
|
313
321
|
let t2 = setTimeout(...e2);
|
|
314
322
|
s2.add(() => clearTimeout(t2));
|
|
315
|
-
},
|
|
316
|
-
let
|
|
317
|
-
return
|
|
318
|
-
|
|
323
|
+
}, microTask(...e2) {
|
|
324
|
+
let t2 = { current: true };
|
|
325
|
+
return t$2(() => {
|
|
326
|
+
t2.current && e2[0]();
|
|
327
|
+
}), s2.add(() => {
|
|
328
|
+
t2.current = false;
|
|
329
|
+
});
|
|
330
|
+
}, style(e2, t2, r2) {
|
|
331
|
+
let i2 = e2.style.getPropertyValue(t2);
|
|
332
|
+
return Object.assign(e2.style, { [t2]: r2 }), this.add(() => {
|
|
333
|
+
Object.assign(e2.style, { [t2]: i2 });
|
|
319
334
|
});
|
|
320
335
|
}, group(e2) {
|
|
321
|
-
let t2 =
|
|
336
|
+
let t2 = o();
|
|
322
337
|
return e2(t2), this.add(() => t2.dispose());
|
|
323
338
|
}, add(e2) {
|
|
324
|
-
return
|
|
325
|
-
let t2 =
|
|
339
|
+
return a2.push(e2), () => {
|
|
340
|
+
let t2 = a2.indexOf(e2);
|
|
326
341
|
if (t2 >= 0)
|
|
327
|
-
for (let
|
|
328
|
-
|
|
342
|
+
for (let r2 of a2.splice(t2, 1))
|
|
343
|
+
r2();
|
|
329
344
|
};
|
|
330
345
|
}, dispose() {
|
|
331
|
-
for (let e2 of
|
|
346
|
+
for (let e2 of a2.splice(0))
|
|
332
347
|
e2();
|
|
333
348
|
} };
|
|
334
349
|
return s2;
|
|
@@ -336,7 +351,7 @@ function r() {
|
|
|
336
351
|
var d$2 = ((r2) => (r2[r2.Forwards = 0] = "Forwards", r2[r2.Backwards = 1] = "Backwards", r2))(d$2 || {});
|
|
337
352
|
function n() {
|
|
338
353
|
let o2 = ref(0);
|
|
339
|
-
return w("keydown", (e2) => {
|
|
354
|
+
return w$1("keydown", (e2) => {
|
|
340
355
|
e2.key === "Tab" && (o2.value = e2.shiftKey ? 1 : 0);
|
|
341
356
|
}), o2;
|
|
342
357
|
}
|
|
@@ -345,43 +360,38 @@ function E$3(n2, e2, o2, r2) {
|
|
|
345
360
|
n2 = n2 != null ? n2 : window, n2.addEventListener(e2, o2, r2), t2(() => n2.removeEventListener(e2, o2, r2));
|
|
346
361
|
});
|
|
347
362
|
}
|
|
348
|
-
function t$2(e2) {
|
|
349
|
-
typeof queueMicrotask == "function" ? queueMicrotask(e2) : Promise.resolve().then(e2).catch((o2) => setTimeout(() => {
|
|
350
|
-
throw o2;
|
|
351
|
-
}));
|
|
352
|
-
}
|
|
353
363
|
function t$1(n2) {
|
|
354
364
|
function e2() {
|
|
355
365
|
document.readyState !== "loading" && (n2(), document.removeEventListener("DOMContentLoaded", e2));
|
|
356
366
|
}
|
|
357
367
|
typeof window != "undefined" && typeof document != "undefined" && (document.addEventListener("DOMContentLoaded", e2), e2());
|
|
358
368
|
}
|
|
359
|
-
function B
|
|
369
|
+
function B(e2) {
|
|
360
370
|
if (!e2)
|
|
361
371
|
return /* @__PURE__ */ new Set();
|
|
362
372
|
if (typeof e2 == "function")
|
|
363
373
|
return new Set(e2());
|
|
364
374
|
let t2 = /* @__PURE__ */ new Set();
|
|
365
375
|
for (let l2 of e2.value) {
|
|
366
|
-
let
|
|
367
|
-
|
|
376
|
+
let o2 = o$1(l2);
|
|
377
|
+
o2 instanceof HTMLElement && t2.add(o2);
|
|
368
378
|
}
|
|
369
379
|
return t2;
|
|
370
380
|
}
|
|
371
381
|
var A = ((n2) => (n2[n2.None = 1] = "None", n2[n2.InitialFocus = 2] = "InitialFocus", n2[n2.TabLock = 4] = "TabLock", n2[n2.FocusLock = 8] = "FocusLock", n2[n2.RestoreFocus = 16] = "RestoreFocus", n2[n2.All = 30] = "All", n2))(A || {});
|
|
372
|
-
let ce = Object.assign(defineComponent({ name: "FocusTrap", props: { as: { type: [Object, String], default: "div" }, initialFocus: { type: Object, default: null }, features: { type: Number, default: 30 }, containers: { type: [Object, Function], default: ref(/* @__PURE__ */ new Set()) } }, inheritAttrs: false, setup(e2, { attrs: t2, slots: l2, expose:
|
|
382
|
+
let ce = Object.assign(defineComponent({ name: "FocusTrap", props: { as: { type: [Object, String], default: "div" }, initialFocus: { type: Object, default: null }, features: { type: Number, default: 30 }, containers: { type: [Object, Function], default: ref(/* @__PURE__ */ new Set()) } }, inheritAttrs: false, setup(e2, { attrs: t2, slots: l2, expose: o2 }) {
|
|
373
383
|
let r2 = ref(null);
|
|
374
|
-
|
|
384
|
+
o2({ el: r2, $el: r2 });
|
|
375
385
|
let i2 = computed(() => m$2(r2)), n$12 = ref(false);
|
|
376
386
|
onMounted(() => n$12.value = true), onUnmounted(() => n$12.value = false), z({ ownerDocument: i2 }, computed(() => n$12.value && Boolean(e2.features & 16)));
|
|
377
387
|
let m2 = J({ ownerDocument: i2, container: r2, initialFocus: computed(() => e2.initialFocus) }, computed(() => n$12.value && Boolean(e2.features & 2)));
|
|
378
|
-
Q
|
|
388
|
+
Q({ ownerDocument: i2, container: r2, containers: e2.containers, previousActiveElement: m2 }, computed(() => n$12.value && Boolean(e2.features & 8)));
|
|
379
389
|
let c2 = n();
|
|
380
390
|
function u2(a2) {
|
|
381
|
-
let d2 = o(r2);
|
|
391
|
+
let d2 = o$1(r2);
|
|
382
392
|
if (!d2)
|
|
383
393
|
return;
|
|
384
|
-
((
|
|
394
|
+
((g) => g())(() => {
|
|
385
395
|
u$3(c2.value, { [d$2.Forwards]: () => {
|
|
386
396
|
P$1(d2, N$1.First, { skipElements: [a2.relatedTarget] });
|
|
387
397
|
}, [d$2.Backwards]: () => {
|
|
@@ -398,13 +408,13 @@ let ce = Object.assign(defineComponent({ name: "FocusTrap", props: { as: { type:
|
|
|
398
408
|
function M2(a2) {
|
|
399
409
|
if (!n$12.value)
|
|
400
410
|
return;
|
|
401
|
-
let d2 = B
|
|
402
|
-
o(r2) instanceof HTMLElement && d2.add(o(r2));
|
|
411
|
+
let d2 = B(e2.containers);
|
|
412
|
+
o$1(r2) instanceof HTMLElement && d2.add(o$1(r2));
|
|
403
413
|
let E2 = a2.relatedTarget;
|
|
404
|
-
E2 instanceof HTMLElement && E2.dataset.headlessuiFocusGuard !== "true" && (N(d2, E2) || (s2.value ? P$1(o(r2), u$3(c2.value, { [d$2.Forwards]: () => N$1.Next, [d$2.Backwards]: () => N$1.Previous }) | N$1.WrapAround, { relativeTo: a2.target }) : a2.target instanceof HTMLElement && S$1(a2.target)));
|
|
414
|
+
E2 instanceof HTMLElement && E2.dataset.headlessuiFocusGuard !== "true" && (N(d2, E2) || (s2.value ? P$1(o$1(r2), u$3(c2.value, { [d$2.Forwards]: () => N$1.Next, [d$2.Backwards]: () => N$1.Previous }) | N$1.WrapAround, { relativeTo: a2.target }) : a2.target instanceof HTMLElement && S$1(a2.target)));
|
|
405
415
|
}
|
|
406
416
|
return () => {
|
|
407
|
-
let a2 = {}, d2 = { ref: r2, onKeydown: H2, onFocusout: M2 }, { features: E2, initialFocus:
|
|
417
|
+
let a2 = {}, d2 = { ref: r2, onKeydown: H2, onFocusout: M2 }, { features: E2, initialFocus: g, containers: X2, ...O2 } = e2;
|
|
408
418
|
return h$2(Fragment, [Boolean(E2 & 4) && h$2(f$1, { as: "button", type: "button", "data-headlessui-focus-guard": true, onFocus: u2, features: a$2.Focusable }), H$1({ ourProps: d2, theirProps: { ...t2, ...O2 }, slot: a2, attrs: t2, slots: l2, name: "FocusTrap" }), Boolean(E2 & 4) && h$2(f$1, { as: "button", type: "button", "data-headlessui-focus-guard": true, onFocus: u2, features: a$2.Focusable })]);
|
|
409
419
|
};
|
|
410
420
|
} }), { features: A }), L = [];
|
|
@@ -414,7 +424,7 @@ t$1(() => {
|
|
|
414
424
|
}
|
|
415
425
|
window.addEventListener("click", e2, { capture: true }), window.addEventListener("mousedown", e2, { capture: true }), window.addEventListener("focus", e2, { capture: true }), document.body.addEventListener("click", e2, { capture: true }), document.body.addEventListener("mousedown", e2, { capture: true }), document.body.addEventListener("focus", e2, { capture: true });
|
|
416
426
|
});
|
|
417
|
-
function x
|
|
427
|
+
function x(e2) {
|
|
418
428
|
let t2 = ref(L.slice());
|
|
419
429
|
return watch([e2], ([l2], [o2]) => {
|
|
420
430
|
o2 === true && l2 === false ? t$2(() => {
|
|
@@ -426,7 +436,7 @@ function x$1(e2) {
|
|
|
426
436
|
};
|
|
427
437
|
}
|
|
428
438
|
function z({ ownerDocument: e2 }, t2) {
|
|
429
|
-
let l2 = x
|
|
439
|
+
let l2 = x(t2);
|
|
430
440
|
onMounted(() => {
|
|
431
441
|
watchEffect(() => {
|
|
432
442
|
var o2, r2;
|
|
@@ -436,18 +446,18 @@ function z({ ownerDocument: e2 }, t2) {
|
|
|
436
446
|
t2.value && S$1(l2());
|
|
437
447
|
});
|
|
438
448
|
}
|
|
439
|
-
function J({ ownerDocument: e2, container: t2, initialFocus: l2 },
|
|
449
|
+
function J({ ownerDocument: e2, container: t2, initialFocus: l2 }, o2) {
|
|
440
450
|
let r2 = ref(null), i2 = ref(false);
|
|
441
451
|
return onMounted(() => i2.value = true), onUnmounted(() => i2.value = false), onMounted(() => {
|
|
442
|
-
watch([t2, l2,
|
|
443
|
-
if (n2.every((u2, s2) => (m2 == null ? void 0 : m2[s2]) === u2) || !
|
|
452
|
+
watch([t2, l2, o2], (n2, m2) => {
|
|
453
|
+
if (n2.every((u2, s2) => (m2 == null ? void 0 : m2[s2]) === u2) || !o2.value)
|
|
444
454
|
return;
|
|
445
|
-
let c2 = o(t2);
|
|
455
|
+
let c2 = o$1(t2);
|
|
446
456
|
c2 && t$2(() => {
|
|
447
457
|
var H2, M2;
|
|
448
458
|
if (!i2.value)
|
|
449
459
|
return;
|
|
450
|
-
let u2 = o(l2), s2 = (H2 = e2.value) == null ? void 0 : H2.activeElement;
|
|
460
|
+
let u2 = o$1(l2), s2 = (H2 = e2.value) == null ? void 0 : H2.activeElement;
|
|
451
461
|
if (u2) {
|
|
452
462
|
if (u2 === s2) {
|
|
453
463
|
r2.value = s2;
|
|
@@ -457,23 +467,23 @@ function J({ ownerDocument: e2, container: t2, initialFocus: l2 }, o$12) {
|
|
|
457
467
|
r2.value = s2;
|
|
458
468
|
return;
|
|
459
469
|
}
|
|
460
|
-
u2 ? S$1(u2) : P$1(c2, N$1.First | N$1.NoScroll) === T.Error && console.warn("There are no focusable elements inside the <FocusTrap />"), r2.value = (M2 = e2.value) == null ? void 0 : M2.activeElement;
|
|
470
|
+
u2 ? S$1(u2) : P$1(c2, N$1.First | N$1.NoScroll) === T$1.Error && console.warn("There are no focusable elements inside the <FocusTrap />"), r2.value = (M2 = e2.value) == null ? void 0 : M2.activeElement;
|
|
461
471
|
});
|
|
462
472
|
}, { immediate: true, flush: "post" });
|
|
463
473
|
}), r2;
|
|
464
474
|
}
|
|
465
|
-
function Q
|
|
475
|
+
function Q({ ownerDocument: e2, container: t2, containers: l2, previousActiveElement: o2 }, r2) {
|
|
466
476
|
var i2;
|
|
467
477
|
E$3((i2 = e2.value) == null ? void 0 : i2.defaultView, "focus", (n2) => {
|
|
468
478
|
if (!r2.value)
|
|
469
479
|
return;
|
|
470
|
-
let m2 = B
|
|
471
|
-
o(t2) instanceof HTMLElement && m2.add(o(t2));
|
|
472
|
-
let c2 =
|
|
480
|
+
let m2 = B(l2);
|
|
481
|
+
o$1(t2) instanceof HTMLElement && m2.add(o$1(t2));
|
|
482
|
+
let c2 = o2.value;
|
|
473
483
|
if (!c2)
|
|
474
484
|
return;
|
|
475
485
|
let u2 = n2.target;
|
|
476
|
-
u2 && u2 instanceof HTMLElement ? N(m2, u2) ? (
|
|
486
|
+
u2 && u2 instanceof HTMLElement ? N(m2, u2) ? (o2.value = u2, S$1(u2)) : (n2.preventDefault(), n2.stopPropagation(), S$1(c2)) : S$1(o2.value);
|
|
477
487
|
}, true);
|
|
478
488
|
}
|
|
479
489
|
function N(e2, t2) {
|
|
@@ -484,14 +494,14 @@ function N(e2, t2) {
|
|
|
484
494
|
}
|
|
485
495
|
let i = /* @__PURE__ */ new Map(), t = /* @__PURE__ */ new Map();
|
|
486
496
|
function E$2(d2, f2 = ref(true)) {
|
|
487
|
-
watchEffect((
|
|
497
|
+
watchEffect((o2) => {
|
|
488
498
|
var a2;
|
|
489
499
|
if (!f2.value)
|
|
490
500
|
return;
|
|
491
|
-
let e2 = o(d2);
|
|
501
|
+
let e2 = o$1(d2);
|
|
492
502
|
if (!e2)
|
|
493
503
|
return;
|
|
494
|
-
|
|
504
|
+
o2(function() {
|
|
495
505
|
var u2;
|
|
496
506
|
if (!e2)
|
|
497
507
|
return;
|
|
@@ -528,24 +538,24 @@ function E$1(t2) {
|
|
|
528
538
|
let r2 = e2.createElement("div");
|
|
529
539
|
return r2.setAttribute("id", "headlessui-portal-root"), e2.body.appendChild(r2);
|
|
530
540
|
}
|
|
531
|
-
let U$
|
|
532
|
-
let r2 = ref(null), i2 = computed(() => m$2(r2)), l2 = u$1(), n2 = inject(h, null),
|
|
541
|
+
let U$2 = defineComponent({ name: "Portal", props: { as: { type: [Object, String], default: "div" } }, setup(t2, { slots: e2, attrs: u2 }) {
|
|
542
|
+
let r2 = ref(null), i2 = computed(() => m$2(r2)), l2 = u$1(), n2 = inject(h, null), o2 = ref(l2 === true || n2 == null ? E$1(r2.value) : n2.resolveTarget());
|
|
533
543
|
watchEffect(() => {
|
|
534
|
-
l2 || n2 != null && (
|
|
544
|
+
l2 || n2 != null && (o2.value = n2.resolveTarget());
|
|
535
545
|
});
|
|
536
546
|
let d2 = inject(f, null);
|
|
537
547
|
return onMounted(() => {
|
|
538
|
-
let a2 = o(r2);
|
|
548
|
+
let a2 = o$1(r2);
|
|
539
549
|
a2 && d2 && onUnmounted(d2.register(a2));
|
|
540
550
|
}), onUnmounted(() => {
|
|
541
551
|
var v2, P2;
|
|
542
552
|
let a2 = (v2 = i2.value) == null ? void 0 : v2.getElementById("headlessui-portal-root");
|
|
543
|
-
a2 &&
|
|
553
|
+
a2 && o2.value === a2 && o2.value.children.length <= 0 && ((P2 = o2.value.parentElement) == null || P2.removeChild(o2.value));
|
|
544
554
|
}), () => {
|
|
545
|
-
if (
|
|
555
|
+
if (o2.value === null)
|
|
546
556
|
return null;
|
|
547
557
|
let a2 = { ref: r2, "data-headlessui-portal": "" };
|
|
548
|
-
return h$2(Teleport, { to:
|
|
558
|
+
return h$2(Teleport, { to: o2.value }, H$1({ ourProps: a2, theirProps: t2, slot: {}, attrs: u2, slots: e2, name: "Portal" }));
|
|
549
559
|
};
|
|
550
560
|
} }), f = Symbol("PortalParentContext");
|
|
551
561
|
function V$1() {
|
|
@@ -575,7 +585,7 @@ let h = Symbol("PortalGroupContext"), _ = defineComponent({ name: "PortalGroup",
|
|
|
575
585
|
};
|
|
576
586
|
} });
|
|
577
587
|
let u = Symbol("StackContext");
|
|
578
|
-
var p$
|
|
588
|
+
var p$2 = ((e2) => (e2[e2.Add = 0] = "Add", e2[e2.Remove = 1] = "Remove", e2))(p$2 || {});
|
|
579
589
|
function v() {
|
|
580
590
|
return inject(u, () => {
|
|
581
591
|
});
|
|
@@ -593,9 +603,9 @@ function S({ type: o2, enabled: r2, element: e2, onUpdate: i2 }) {
|
|
|
593
603
|
r2.value && t2(1, o2, e2);
|
|
594
604
|
}), provide(u, t2);
|
|
595
605
|
}
|
|
596
|
-
let p$
|
|
606
|
+
let p$1 = Symbol("DescriptionContext");
|
|
597
607
|
function b() {
|
|
598
|
-
let t2 = inject(p$
|
|
608
|
+
let t2 = inject(p$1, null);
|
|
599
609
|
if (t2 === null)
|
|
600
610
|
throw new Error("Missing parent");
|
|
601
611
|
return t2;
|
|
@@ -608,12 +618,12 @@ function M$1({ slot: t2 = ref({}), name: i2 = "Description", props: o2 = {} } =
|
|
|
608
618
|
r2 !== -1 && e2.value.splice(r2, 1);
|
|
609
619
|
};
|
|
610
620
|
}
|
|
611
|
-
return provide(p$
|
|
621
|
+
return provide(p$1, { register: s2, slot: t2, name: i2, props: o2 }), computed(() => e2.value.length > 0 ? e2.value.join(" ") : void 0);
|
|
612
622
|
}
|
|
613
623
|
let E = defineComponent({ name: "Description", props: { as: { type: [Object, String], default: "p" }, id: { type: String, default: () => `headlessui-description-${t$4()}` } }, setup(t2, { attrs: i2, slots: o2 }) {
|
|
614
624
|
let e2 = b();
|
|
615
625
|
return onMounted(() => onUnmounted(e2.register(t2.id))), () => {
|
|
616
|
-
let { name: s2 = "Description", slot: n2 = ref({}), props: r2 = {} } = e2, { id: d2, ...l2 } = t2, c2 = { ...Object.entries(r2).reduce((f2, [a2,
|
|
626
|
+
let { name: s2 = "Description", slot: n2 = ref({}), props: r2 = {} } = e2, { id: d2, ...l2 } = t2, c2 = { ...Object.entries(r2).reduce((f2, [a2, g]) => Object.assign(f2, { [a2]: unref(g) }), {}), id: d2 };
|
|
617
627
|
return H$1({ ourProps: c2, theirProps: l2, slot: n2.value, attrs: i2, slots: o2, name: s2 });
|
|
618
628
|
};
|
|
619
629
|
} });
|
|
@@ -645,32 +655,36 @@ function c() {
|
|
|
645
655
|
n2.style(t2, "paddingRight", `${r2}px`);
|
|
646
656
|
} };
|
|
647
657
|
}
|
|
648
|
-
function
|
|
658
|
+
function w() {
|
|
649
659
|
if (!t$3())
|
|
650
660
|
return {};
|
|
651
|
-
let
|
|
661
|
+
let r2;
|
|
652
662
|
return { before() {
|
|
653
|
-
|
|
654
|
-
}, after({ doc:
|
|
663
|
+
r2 = window.pageYOffset;
|
|
664
|
+
}, after({ doc: n2, d: o$12, meta: s2 }) {
|
|
655
665
|
function i2(e2) {
|
|
656
666
|
return s2.containers.flatMap((t2) => t2()).some((t2) => t2.contains(e2));
|
|
657
667
|
}
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
668
|
+
if (window.getComputedStyle(n2.documentElement).scrollBehavior !== "auto") {
|
|
669
|
+
let e2 = o();
|
|
670
|
+
e2.style(n2.documentElement, "scroll-behavior", "auto"), o$12.add(() => o$12.microTask(() => e2.dispose()));
|
|
671
|
+
}
|
|
672
|
+
o$12.style(n2.body, "marginTop", `-${r2}px`), window.scrollTo(0, 0);
|
|
673
|
+
let l2 = null;
|
|
674
|
+
o$12.addEventListener(n2, "click", (e2) => {
|
|
661
675
|
if (e2.target instanceof HTMLElement)
|
|
662
676
|
try {
|
|
663
677
|
let t2 = e2.target.closest("a");
|
|
664
678
|
if (!t2)
|
|
665
679
|
return;
|
|
666
|
-
let { hash: c2 } = new URL(t2.href), a2 =
|
|
667
|
-
a2 && !i2(a2) && (
|
|
680
|
+
let { hash: c2 } = new URL(t2.href), a2 = n2.querySelector(c2);
|
|
681
|
+
a2 && !i2(a2) && (l2 = a2);
|
|
668
682
|
} catch {
|
|
669
683
|
}
|
|
670
|
-
}, true),
|
|
684
|
+
}, true), o$12.addEventListener(n2, "touchmove", (e2) => {
|
|
671
685
|
e2.target instanceof HTMLElement && !i2(e2.target) && e2.preventDefault();
|
|
672
|
-
}, { passive: false }),
|
|
673
|
-
window.scrollTo(0, window.pageYOffset +
|
|
686
|
+
}, { passive: false }), o$12.add(() => {
|
|
687
|
+
window.scrollTo(0, window.pageYOffset + r2), l2 && l2.isConnected && (l2.scrollIntoView({ block: "nearest" }), l2 = null);
|
|
674
688
|
});
|
|
675
689
|
} };
|
|
676
690
|
}
|
|
@@ -686,14 +700,14 @@ function m(e2) {
|
|
|
686
700
|
return n2;
|
|
687
701
|
}
|
|
688
702
|
let a = a$1(() => /* @__PURE__ */ new Map(), { PUSH(e2, n2) {
|
|
689
|
-
var
|
|
690
|
-
let t2 = (
|
|
703
|
+
var o$12;
|
|
704
|
+
let t2 = (o$12 = this.get(e2)) != null ? o$12 : { doc: e2, count: 0, d: o(), meta: /* @__PURE__ */ new Set() };
|
|
691
705
|
return t2.count++, t2.meta.add(n2), this.set(e2, t2), this;
|
|
692
706
|
}, POP(e2, n2) {
|
|
693
707
|
let t2 = this.get(e2);
|
|
694
708
|
return t2 && (t2.count--, t2.meta.delete(n2)), this;
|
|
695
709
|
}, SCROLL_PREVENT({ doc: e2, d: n2, meta: t2 }) {
|
|
696
|
-
let o2 = { doc: e2, d: n2, meta: m(t2) }, c$12 = [
|
|
710
|
+
let o2 = { doc: e2, d: n2, meta: m(t2) }, c$12 = [w(), c(), l()];
|
|
697
711
|
c$12.forEach(({ before: r2 }) => r2 == null ? void 0 : r2(o2)), c$12.forEach(({ after: r2 }) => r2 == null ? void 0 : r2(o2));
|
|
698
712
|
}, SCROLL_ALLOW({ d: e2 }) {
|
|
699
713
|
e2.dispose();
|
|
@@ -724,24 +738,24 @@ function d$1(t2, a$12, n2) {
|
|
|
724
738
|
});
|
|
725
739
|
}, { immediate: true }), l2;
|
|
726
740
|
}
|
|
727
|
-
function p({ defaultContainers:
|
|
728
|
-
let
|
|
741
|
+
function p({ defaultContainers: t2 = [], portals: o2, mainTreeNodeRef: s2 } = {}) {
|
|
742
|
+
let i2 = ref(null), r2 = m$2(i2);
|
|
729
743
|
function u2() {
|
|
730
|
-
var
|
|
744
|
+
var l2;
|
|
731
745
|
let n2 = [];
|
|
732
|
-
for (let e2 of
|
|
746
|
+
for (let e2 of t2)
|
|
733
747
|
e2 !== null && (e2 instanceof HTMLElement ? n2.push(e2) : "value" in e2 && e2.value instanceof HTMLElement && n2.push(e2.value));
|
|
734
|
-
if (
|
|
735
|
-
for (let e2 of
|
|
748
|
+
if (o2 != null && o2.value)
|
|
749
|
+
for (let e2 of o2.value)
|
|
736
750
|
n2.push(e2);
|
|
737
|
-
for (let e2 of (
|
|
738
|
-
e2 !== document.body && e2 !== document.head && e2 instanceof HTMLElement && e2.id !== "headlessui-portal-root" && (e2.contains(o(
|
|
751
|
+
for (let e2 of (l2 = r2 == null ? void 0 : r2.querySelectorAll("html > *, body > *")) != null ? l2 : [])
|
|
752
|
+
e2 !== document.body && e2 !== document.head && e2 instanceof HTMLElement && e2.id !== "headlessui-portal-root" && (e2.contains(o$1(i2)) || n2.some((c2) => e2.contains(c2)) || n2.push(e2));
|
|
739
753
|
return n2;
|
|
740
754
|
}
|
|
741
755
|
return { resolveContainers: u2, contains(n2) {
|
|
742
|
-
return u2().some((
|
|
743
|
-
}, mainTreeNodeRef:
|
|
744
|
-
return h$2(f$1, { features: a$2.Hidden, ref:
|
|
756
|
+
return u2().some((l2) => l2.contains(n2));
|
|
757
|
+
}, mainTreeNodeRef: i2, MainTreeNode() {
|
|
758
|
+
return s2 != null ? null : h$2(f$1, { features: a$2.Hidden, ref: i2 });
|
|
745
759
|
} };
|
|
746
760
|
}
|
|
747
761
|
var Oe = ((t2) => (t2[t2.Open = 0] = "Open", t2[t2.Closed = 1] = "Closed", t2))(Oe || {});
|
|
@@ -754,46 +768,46 @@ function C(o2) {
|
|
|
754
768
|
}
|
|
755
769
|
return n2;
|
|
756
770
|
}
|
|
757
|
-
let M = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", Ue = defineComponent({ name: "Dialog", inheritAttrs: false, props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, open: { type: [Boolean, String], default: M }, initialFocus: { type: Object, default: null }, id: { type: String, default: () => `headlessui-dialog-${t$4()}` } }, emits: { close: (o2) => true }, setup(
|
|
771
|
+
let M = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", Ue = defineComponent({ name: "Dialog", inheritAttrs: false, props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, open: { type: [Boolean, String], default: M }, initialFocus: { type: Object, default: null }, id: { type: String, default: () => `headlessui-dialog-${t$4()}` } }, emits: { close: (o2) => true }, setup(o2, { emit: n2, attrs: t2, slots: u2, expose: i2 }) {
|
|
758
772
|
var N2;
|
|
759
773
|
let r2 = ref(false);
|
|
760
774
|
onMounted(() => {
|
|
761
775
|
r2.value = true;
|
|
762
776
|
});
|
|
763
|
-
let s2 = ref(0), p$12 = p$
|
|
764
|
-
if (i2({ el: v2, $el: v2 }), !(
|
|
777
|
+
let s2 = ref(0), p$12 = p$3(), m2 = computed(() => o2.open === M && p$12 !== null ? (p$12.value & l$1.Open) === l$1.Open : o2.open), v2 = ref(null), T2 = computed(() => m$2(v2));
|
|
778
|
+
if (i2({ el: v2, $el: v2 }), !(o2.open !== M || p$12 !== null))
|
|
765
779
|
throw new Error("You forgot to provide an `open` prop to the `Dialog`.");
|
|
766
780
|
if (typeof m2.value != "boolean")
|
|
767
|
-
throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${m2.value === M ? void 0 :
|
|
781
|
+
throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${m2.value === M ? void 0 : o2.open}`);
|
|
768
782
|
let c2 = computed(() => r2.value && m2.value ? 0 : 1), R = computed(() => c2.value === 0), E2 = computed(() => s2.value > 1), $2 = inject(F, null) !== null, [G, V2] = V$1(), { resolveContainers: x2, mainTreeNodeRef: j2, MainTreeNode: W } = p({ portals: G, defaultContainers: [computed(() => {
|
|
769
783
|
var e2;
|
|
770
|
-
return (e2 =
|
|
784
|
+
return (e2 = y$12.panelRef.value) != null ? e2 : v2.value;
|
|
771
785
|
})] }), J2 = computed(() => E2.value ? "parent" : "leaf"), H2 = computed(() => p$12 !== null ? (p$12.value & l$1.Closing) === l$1.Closing : false), Q2 = computed(() => $2 || H2.value ? false : R.value), X2 = computed(() => {
|
|
772
786
|
var e2, l2, f2;
|
|
773
|
-
return (f2 = Array.from((l2 = (e2 = T2.value) == null ? void 0 : e2.querySelectorAll("body > *")) != null ? l2 : []).find((d2) => d2.id === "headlessui-portal-root" ? false : d2.contains(o(j2)) && d2 instanceof HTMLElement)) != null ? f2 : null;
|
|
787
|
+
return (f2 = Array.from((l2 = (e2 = T2.value) == null ? void 0 : e2.querySelectorAll("body > *")) != null ? l2 : []).find((d2) => d2.id === "headlessui-portal-root" ? false : d2.contains(o$1(j2)) && d2 instanceof HTMLElement)) != null ? f2 : null;
|
|
774
788
|
});
|
|
775
789
|
E$2(X2, Q2);
|
|
776
790
|
let Z = computed(() => E2.value ? true : R.value), ee = computed(() => {
|
|
777
791
|
var e2, l2, f2;
|
|
778
|
-
return (f2 = Array.from((l2 = (e2 = T2.value) == null ? void 0 : e2.querySelectorAll("[data-headlessui-portal]")) != null ? l2 : []).find((d2) => d2.contains(o(j2)) && d2 instanceof HTMLElement)) != null ? f2 : null;
|
|
792
|
+
return (f2 = Array.from((l2 = (e2 = T2.value) == null ? void 0 : e2.querySelectorAll("[data-headlessui-portal]")) != null ? l2 : []).find((d2) => d2.contains(o$1(j2)) && d2 instanceof HTMLElement)) != null ? f2 : null;
|
|
779
793
|
});
|
|
780
794
|
E$2(ee, Z), S({ type: "Dialog", enabled: computed(() => c2.value === 0), element: v2, onUpdate: (e2, l2) => {
|
|
781
795
|
if (l2 === "Dialog")
|
|
782
|
-
return u$3(e2, { [p$
|
|
796
|
+
return u$3(e2, { [p$2.Add]: () => s2.value += 1, [p$2.Remove]: () => s2.value -= 1 });
|
|
783
797
|
} });
|
|
784
|
-
let te2 = M$1({ name: "DialogDescription", slot: computed(() => ({ open: m2.value })) }), k2 = ref(null),
|
|
798
|
+
let te2 = M$1({ name: "DialogDescription", slot: computed(() => ({ open: m2.value })) }), k2 = ref(null), y$12 = { titleId: k2, panelRef: ref(null), dialogState: c2, setTitleId(e2) {
|
|
785
799
|
k2.value !== e2 && (k2.value = e2);
|
|
786
800
|
}, close() {
|
|
787
801
|
n2("close", false);
|
|
788
802
|
} };
|
|
789
|
-
provide(F,
|
|
803
|
+
provide(F, y$12);
|
|
790
804
|
let le2 = computed(() => !(!R.value || E2.value));
|
|
791
|
-
|
|
792
|
-
|
|
805
|
+
y(x2, (e2, l2) => {
|
|
806
|
+
y$12.close(), nextTick(() => l2 == null ? void 0 : l2.focus());
|
|
793
807
|
}, le2);
|
|
794
808
|
let oe = computed(() => !(E2.value || c2.value !== 0));
|
|
795
809
|
E$3((N2 = T2.value) == null ? void 0 : N2.defaultView, "keydown", (e2) => {
|
|
796
|
-
oe.value && (e2.defaultPrevented || e2.key === o$
|
|
810
|
+
oe.value && (e2.defaultPrevented || e2.key === o$2.Escape && (e2.preventDefault(), e2.stopPropagation(), y$12.close()));
|
|
797
811
|
});
|
|
798
812
|
let re = computed(() => !(H2.value || c2.value !== 0 || $2));
|
|
799
813
|
return d$1(T2, re, (e2) => {
|
|
@@ -802,19 +816,19 @@ let M = "DC8F892D-2EBD-447C-A4C8-A03058436FF4", Ue = defineComponent({ name: "Di
|
|
|
802
816
|
}), watchEffect((e2) => {
|
|
803
817
|
if (c2.value !== 0)
|
|
804
818
|
return;
|
|
805
|
-
let l2 = o(v2);
|
|
819
|
+
let l2 = o$1(v2);
|
|
806
820
|
if (!l2)
|
|
807
821
|
return;
|
|
808
822
|
let f2 = new ResizeObserver((d2) => {
|
|
809
823
|
for (let A2 of d2) {
|
|
810
824
|
let D = A2.target.getBoundingClientRect();
|
|
811
|
-
D.x === 0 && D.y === 0 && D.width === 0 && D.height === 0 &&
|
|
825
|
+
D.x === 0 && D.y === 0 && D.width === 0 && D.height === 0 && y$12.close();
|
|
812
826
|
}
|
|
813
827
|
});
|
|
814
828
|
f2.observe(l2), e2(() => f2.disconnect());
|
|
815
829
|
}), () => {
|
|
816
|
-
let { id: e2, open: l2, initialFocus: f2, ...d2 } =
|
|
817
|
-
return h$2(P, { force: true }, () => [h$2(U$
|
|
830
|
+
let { id: e2, open: l2, initialFocus: f2, ...d2 } = o2, A2 = { ...t2, ref: v2, id: e2, role: "dialog", "aria-modal": c2.value === 0 ? true : void 0, "aria-labelledby": k2.value, "aria-describedby": te2.value }, D = { open: c2.value === 0 };
|
|
831
|
+
return h$2(P, { force: true }, () => [h$2(U$2, () => h$2(_, { target: v2.value }, () => h$2(P, { force: false }, () => h$2(ce, { initialFocus: f2, containers: x2, features: R.value ? u$3(J2.value, { parent: ce.features.RestoreFocus, leaf: ce.features.All & ~ce.features.FocusLock }) : ce.features.None }, () => h$2(V2, {}, () => H$1({ ourProps: A2, theirProps: { ...d2, ...t2 }, slot: D, attrs: t2, slots: u2, visible: c2.value === 0, features: N$2.RenderStrategy | N$2.Static, name: "Dialog" })))))), h$2(W)]);
|
|
818
832
|
};
|
|
819
833
|
} });
|
|
820
834
|
defineComponent({ name: "DialogOverlay", props: { as: { type: [Object, String], default: "div" }, id: { type: String, default: () => `headlessui-dialog-overlay-${t$4()}` } }, setup(o2, { attrs: n2, slots: t2 }) {
|
|
@@ -834,7 +848,7 @@ defineComponent({ name: "DialogBackdrop", props: { as: { type: [Object, String],
|
|
|
834
848
|
throw new Error("A <DialogBackdrop /> component is being used, but a <DialogPanel /> component is missing.");
|
|
835
849
|
}), () => {
|
|
836
850
|
let { id: s2, ...p2 } = o2, m2 = { id: s2, ref: r2, "aria-hidden": true };
|
|
837
|
-
return h$2(P, { force: true }, () => h$2(U$
|
|
851
|
+
return h$2(P, { force: true }, () => h$2(U$2, () => H$1({ ourProps: m2, theirProps: { ...n2, ...p2 }, slot: { open: i2.dialogState.value === 0 }, attrs: n2, slots: t2, name: "DialogBackdrop" })));
|
|
838
852
|
};
|
|
839
853
|
} });
|
|
840
854
|
let Ge = defineComponent({ name: "DialogPanel", props: { as: { type: [Object, String], default: "div" }, id: { type: String, default: () => `headlessui-dialog-panel-${t$4()}` } }, setup(o2, { attrs: n2, slots: t2, expose: u2 }) {
|
|
@@ -856,90 +870,92 @@ let Ge = defineComponent({ name: "DialogPanel", props: { as: { type: [Object, St
|
|
|
856
870
|
return H$1({ ourProps: { id: i2 }, theirProps: r2, slot: { open: u2.dialogState.value === 0 }, attrs: n2, slots: t2, name: "DialogTitle" });
|
|
857
871
|
};
|
|
858
872
|
} }), We = E;
|
|
859
|
-
var
|
|
860
|
-
let
|
|
861
|
-
function
|
|
862
|
-
let r2 = inject(
|
|
873
|
+
var $$1 = ((o2) => (o2[o2.Open = 0] = "Open", o2[o2.Closed = 1] = "Closed", o2))($$1 || {});
|
|
874
|
+
let T = Symbol("DisclosureContext");
|
|
875
|
+
function O(t2) {
|
|
876
|
+
let r2 = inject(T, null);
|
|
863
877
|
if (r2 === null) {
|
|
864
878
|
let o2 = new Error(`<${t2} /> is missing a parent <Disclosure /> component.`);
|
|
865
|
-
throw Error.captureStackTrace && Error.captureStackTrace(o2,
|
|
879
|
+
throw Error.captureStackTrace && Error.captureStackTrace(o2, O), o2;
|
|
866
880
|
}
|
|
867
881
|
return r2;
|
|
868
882
|
}
|
|
869
|
-
let
|
|
870
|
-
function
|
|
871
|
-
return inject(
|
|
883
|
+
let k$1 = Symbol("DisclosurePanelContext");
|
|
884
|
+
function U$1() {
|
|
885
|
+
return inject(k$1, null);
|
|
872
886
|
}
|
|
873
|
-
let
|
|
874
|
-
let
|
|
875
|
-
|
|
887
|
+
let V = defineComponent({ name: "Disclosure", props: { as: { type: [Object, String], default: "template" }, defaultOpen: { type: [Boolean], default: false } }, setup(t2, { slots: r2, attrs: o2 }) {
|
|
888
|
+
let s2 = ref(t2.defaultOpen ? 0 : 1), e2 = ref(null), i2 = ref(null), n2 = { buttonId: ref(`headlessui-disclosure-button-${t$4()}`), panelId: ref(`headlessui-disclosure-panel-${t$4()}`), disclosureState: s2, panel: e2, button: i2, toggleDisclosure() {
|
|
889
|
+
s2.value = u$3(s2.value, { [0]: 1, [1]: 0 });
|
|
876
890
|
}, closeDisclosure() {
|
|
877
|
-
|
|
891
|
+
s2.value !== 1 && (s2.value = 1);
|
|
878
892
|
}, close(l2) {
|
|
879
|
-
|
|
880
|
-
let a2 = (() => l2 ? l2 instanceof HTMLElement ? l2 : l2.value instanceof HTMLElement ? o(l2) : o(
|
|
893
|
+
n2.closeDisclosure();
|
|
894
|
+
let a2 = (() => l2 ? l2 instanceof HTMLElement ? l2 : l2.value instanceof HTMLElement ? o$1(l2) : o$1(n2.button) : o$1(n2.button))();
|
|
881
895
|
a2 == null || a2.focus();
|
|
882
896
|
} };
|
|
883
|
-
return provide(
|
|
884
|
-
let { defaultOpen: l2, ...a2 } = t2, c2 = { open:
|
|
885
|
-
return H$1({ theirProps: a2, ourProps: {}, slot: c2, slots: r2, attrs:
|
|
897
|
+
return provide(T, n2), c$3(computed(() => u$3(s2.value, { [0]: l$1.Open, [1]: l$1.Closed }))), () => {
|
|
898
|
+
let { defaultOpen: l2, ...a2 } = t2, c2 = { open: s2.value === 0, close: n2.close };
|
|
899
|
+
return H$1({ theirProps: a2, ourProps: {}, slot: c2, slots: r2, attrs: o2, name: "Disclosure" });
|
|
886
900
|
};
|
|
887
|
-
} }),
|
|
888
|
-
let e2 =
|
|
901
|
+
} }), X = defineComponent({ name: "DisclosureButton", props: { as: { type: [Object, String], default: "button" }, disabled: { type: [Boolean], default: false }, id: { type: String, default: null } }, setup(t2, { attrs: r2, slots: o2, expose: s2 }) {
|
|
902
|
+
let e2 = O("DisclosureButton"), i2 = U$1(), n2 = computed(() => i2 === null ? false : i2.value === e2.panelId.value);
|
|
889
903
|
onMounted(() => {
|
|
890
|
-
e2.buttonId.value = t2.id;
|
|
904
|
+
n2.value || t2.id !== null && (e2.buttonId.value = t2.id);
|
|
891
905
|
}), onUnmounted(() => {
|
|
892
|
-
e2.buttonId.value = null;
|
|
906
|
+
n2.value || (e2.buttonId.value = null);
|
|
893
907
|
});
|
|
894
|
-
let
|
|
895
|
-
|
|
908
|
+
let l2 = ref(null);
|
|
909
|
+
s2({ el: l2, $el: l2 }), n2.value || watchEffect(() => {
|
|
896
910
|
e2.button.value = l2.value;
|
|
897
911
|
});
|
|
898
912
|
let a2 = b$1(computed(() => ({ as: t2.as, type: r2.type })), l2);
|
|
899
913
|
function c2() {
|
|
900
|
-
var
|
|
901
|
-
t2.disabled || (
|
|
914
|
+
var u2;
|
|
915
|
+
t2.disabled || (n2.value ? (e2.toggleDisclosure(), (u2 = o$1(e2.button)) == null || u2.focus()) : e2.toggleDisclosure());
|
|
902
916
|
}
|
|
903
|
-
function D(
|
|
917
|
+
function D(u2) {
|
|
904
918
|
var S2;
|
|
905
919
|
if (!t2.disabled)
|
|
906
|
-
if (
|
|
907
|
-
switch (
|
|
908
|
-
case o$
|
|
909
|
-
case o$
|
|
910
|
-
|
|
920
|
+
if (n2.value)
|
|
921
|
+
switch (u2.key) {
|
|
922
|
+
case o$2.Space:
|
|
923
|
+
case o$2.Enter:
|
|
924
|
+
u2.preventDefault(), u2.stopPropagation(), e2.toggleDisclosure(), (S2 = o$1(e2.button)) == null || S2.focus();
|
|
911
925
|
break;
|
|
912
926
|
}
|
|
913
927
|
else
|
|
914
|
-
switch (
|
|
915
|
-
case o$
|
|
916
|
-
case o$
|
|
917
|
-
|
|
928
|
+
switch (u2.key) {
|
|
929
|
+
case o$2.Space:
|
|
930
|
+
case o$2.Enter:
|
|
931
|
+
u2.preventDefault(), u2.stopPropagation(), e2.toggleDisclosure();
|
|
918
932
|
break;
|
|
919
933
|
}
|
|
920
934
|
}
|
|
921
|
-
function
|
|
922
|
-
switch (
|
|
923
|
-
case o$
|
|
924
|
-
|
|
935
|
+
function v2(u2) {
|
|
936
|
+
switch (u2.key) {
|
|
937
|
+
case o$2.Space:
|
|
938
|
+
u2.preventDefault();
|
|
925
939
|
break;
|
|
926
940
|
}
|
|
927
941
|
}
|
|
928
942
|
return () => {
|
|
929
|
-
|
|
930
|
-
|
|
943
|
+
var C2;
|
|
944
|
+
let u2 = { open: e2.disclosureState.value === 0 }, { id: S2, ...K } = t2, M2 = n2.value ? { ref: l2, type: a2.value, onClick: c2, onKeydown: D } : { id: (C2 = e2.buttonId.value) != null ? C2 : S2, ref: l2, type: a2.value, "aria-expanded": e2.disclosureState.value === 0, "aria-controls": e2.disclosureState.value === 0 || o$1(e2.panel) ? e2.panelId.value : void 0, disabled: t2.disabled ? true : void 0, onClick: c2, onKeydown: D, onKeyup: v2 };
|
|
945
|
+
return H$1({ ourProps: M2, theirProps: K, slot: u2, attrs: r2, slots: o2, name: "DisclosureButton" });
|
|
931
946
|
};
|
|
932
|
-
} }),
|
|
933
|
-
let e2 =
|
|
947
|
+
} }), Y = defineComponent({ name: "DisclosurePanel", props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, id: { type: String, default: null } }, setup(t2, { attrs: r2, slots: o2, expose: s2 }) {
|
|
948
|
+
let e2 = O("DisclosurePanel");
|
|
934
949
|
onMounted(() => {
|
|
935
|
-
e2.panelId.value = t2.id;
|
|
950
|
+
t2.id !== null && (e2.panelId.value = t2.id);
|
|
936
951
|
}), onUnmounted(() => {
|
|
937
952
|
e2.panelId.value = null;
|
|
938
|
-
}),
|
|
939
|
-
let i2 = p$
|
|
953
|
+
}), s2({ el: e2.panel, $el: e2.panel }), provide(k$1, e2.panelId);
|
|
954
|
+
let i2 = p$3(), n2 = computed(() => i2 !== null ? (i2.value & l$1.Open) === l$1.Open : e2.disclosureState.value === 0);
|
|
940
955
|
return () => {
|
|
941
|
-
|
|
942
|
-
|
|
956
|
+
var v2;
|
|
957
|
+
let l2 = { open: e2.disclosureState.value === 0, close: e2.close }, { id: a2, ...c2 } = t2, D = { id: (v2 = e2.panelId.value) != null ? v2 : a2, ref: e2.panel };
|
|
958
|
+
return H$1({ ourProps: D, theirProps: c2, slot: l2, attrs: r2, slots: o2, features: N$2.RenderStrategy | N$2.Static, visible: n2.value, name: "DisclosurePanel" });
|
|
943
959
|
};
|
|
944
960
|
} });
|
|
945
961
|
let d = defineComponent({ props: { onFocus: { type: Function, required: true } }, setup(t2) {
|
|
@@ -973,17 +989,17 @@ function k(a2) {
|
|
|
973
989
|
return v2;
|
|
974
990
|
}
|
|
975
991
|
let j = Symbol("TabsSSRContext"), xe = defineComponent({ name: "TabGroup", emits: { change: (a2) => true }, props: { as: { type: [Object, String], default: "template" }, selectedIndex: { type: [Number], default: null }, defaultIndex: { type: [Number], default: 0 }, vertical: { type: [Boolean], default: false }, manual: { type: [Boolean], default: false } }, inheritAttrs: false, setup(a2, { slots: v2, attrs: i2, emit: s2 }) {
|
|
976
|
-
var
|
|
977
|
-
let l2 = ref((
|
|
992
|
+
var P2;
|
|
993
|
+
let l2 = ref((P2 = a2.selectedIndex) != null ? P2 : a2.defaultIndex), n2 = ref([]), o2 = ref([]), h2 = computed(() => a2.selectedIndex !== null), b2 = computed(() => h2.value ? a2.selectedIndex : l2.value);
|
|
978
994
|
function m2(t2) {
|
|
979
995
|
var S2;
|
|
980
|
-
let e2 = O(r2.tabs.value, o), u2 = O(r2.panels.value, o), f2 = e2.filter((p2) => {
|
|
981
|
-
var
|
|
982
|
-
return !((
|
|
996
|
+
let e2 = O$1(r2.tabs.value, o$1), u2 = O$1(r2.panels.value, o$1), f2 = e2.filter((p2) => {
|
|
997
|
+
var g;
|
|
998
|
+
return !((g = o$1(p2)) != null && g.hasAttribute("disabled"));
|
|
983
999
|
});
|
|
984
1000
|
if (t2 < 0 || t2 > e2.length - 1) {
|
|
985
|
-
let p2 = u$3(l2.value === null ? 0 : Math.sign(t2 - l2.value), { [-1]: () => 1, [0]: () => u$3(Math.sign(t2), { [-1]: () => 0, [0]: () => 0, [1]: () => 1 }), [1]: () => 0 });
|
|
986
|
-
|
|
1001
|
+
let p2 = u$3(l2.value === null ? 0 : Math.sign(t2 - l2.value), { [-1]: () => 1, [0]: () => u$3(Math.sign(t2), { [-1]: () => 0, [0]: () => 0, [1]: () => 1 }), [1]: () => 0 }), g = u$3(p2, { [0]: () => e2.indexOf(f2[0]), [1]: () => e2.indexOf(f2[f2.length - 1]) });
|
|
1002
|
+
g !== -1 && (l2.value = g), r2.tabs.value = e2, r2.panels.value = u2;
|
|
987
1003
|
} else {
|
|
988
1004
|
let p2 = e2.slice(0, t2), G = [...e2.slice(t2), ...p2].find((W) => f2.includes(W));
|
|
989
1005
|
if (!G)
|
|
@@ -995,51 +1011,51 @@ let j = Symbol("TabsSSRContext"), xe = defineComponent({ name: "TabGroup", emits
|
|
|
995
1011
|
let r2 = { selectedIndex: computed(() => {
|
|
996
1012
|
var t2, e2;
|
|
997
1013
|
return (e2 = (t2 = l2.value) != null ? t2 : a2.defaultIndex) != null ? e2 : null;
|
|
998
|
-
}), orientation: computed(() => a2.vertical ? "vertical" : "horizontal"), activation: computed(() => a2.manual ? "manual" : "auto"), tabs: n2, panels:
|
|
999
|
-
b2.value !== t2 && s2("change", t2),
|
|
1014
|
+
}), orientation: computed(() => a2.vertical ? "vertical" : "horizontal"), activation: computed(() => a2.manual ? "manual" : "auto"), tabs: n2, panels: o2, setSelectedIndex(t2) {
|
|
1015
|
+
b2.value !== t2 && s2("change", t2), h2.value || m2(t2);
|
|
1000
1016
|
}, registerTab(t2) {
|
|
1001
1017
|
var f2;
|
|
1002
1018
|
if (n2.value.includes(t2))
|
|
1003
1019
|
return;
|
|
1004
1020
|
let e2 = n2.value[l2.value];
|
|
1005
|
-
n2.value.push(t2), n2.value = O(n2.value, o);
|
|
1021
|
+
n2.value.push(t2), n2.value = O$1(n2.value, o$1);
|
|
1006
1022
|
let u2 = (f2 = n2.value.indexOf(e2)) != null ? f2 : l2.value;
|
|
1007
1023
|
u2 !== -1 && (l2.value = u2);
|
|
1008
1024
|
}, unregisterTab(t2) {
|
|
1009
1025
|
let e2 = n2.value.indexOf(t2);
|
|
1010
1026
|
e2 !== -1 && n2.value.splice(e2, 1);
|
|
1011
1027
|
}, registerPanel(t2) {
|
|
1012
|
-
|
|
1028
|
+
o2.value.includes(t2) || (o2.value.push(t2), o2.value = O$1(o2.value, o$1));
|
|
1013
1029
|
}, unregisterPanel(t2) {
|
|
1014
|
-
let e2 =
|
|
1015
|
-
e2 !== -1 &&
|
|
1030
|
+
let e2 = o2.value.indexOf(t2);
|
|
1031
|
+
e2 !== -1 && o2.value.splice(e2, 1);
|
|
1016
1032
|
} };
|
|
1017
1033
|
provide(U, r2);
|
|
1018
|
-
let
|
|
1034
|
+
let w2 = ref({ tabs: [], panels: [] }), y2 = ref(false);
|
|
1019
1035
|
onMounted(() => {
|
|
1020
1036
|
y2.value = true;
|
|
1021
|
-
}), provide(j, computed(() => y2.value ? null :
|
|
1022
|
-
let
|
|
1037
|
+
}), provide(j, computed(() => y2.value ? null : w2.value));
|
|
1038
|
+
let E2 = computed(() => a2.selectedIndex);
|
|
1023
1039
|
return onMounted(() => {
|
|
1024
|
-
watch([
|
|
1040
|
+
watch([E2], () => {
|
|
1025
1041
|
var t2;
|
|
1026
1042
|
return m2((t2 = a2.selectedIndex) != null ? t2 : a2.defaultIndex);
|
|
1027
1043
|
}, { immediate: true });
|
|
1028
1044
|
}), watchEffect(() => {
|
|
1029
|
-
if (!
|
|
1045
|
+
if (!h2.value || b2.value == null || r2.tabs.value.length <= 0)
|
|
1030
1046
|
return;
|
|
1031
|
-
let t2 = O(r2.tabs.value, o);
|
|
1032
|
-
t2.some((u2, f2) => o(r2.tabs.value[f2]) !== o(u2)) && r2.setSelectedIndex(t2.findIndex((u2) => o(u2) === o(r2.tabs.value[b2.value])));
|
|
1047
|
+
let t2 = O$1(r2.tabs.value, o$1);
|
|
1048
|
+
t2.some((u2, f2) => o$1(r2.tabs.value[f2]) !== o$1(u2)) && r2.setSelectedIndex(t2.findIndex((u2) => o$1(u2) === o$1(r2.tabs.value[b2.value])));
|
|
1033
1049
|
}), () => {
|
|
1034
1050
|
let t2 = { selectedIndex: l2.value };
|
|
1035
1051
|
return h$2(Fragment, [n2.value.length <= 0 && h$2(d, { onFocus: () => {
|
|
1036
1052
|
for (let e2 of n2.value) {
|
|
1037
|
-
let u2 = o(e2);
|
|
1053
|
+
let u2 = o$1(e2);
|
|
1038
1054
|
if ((u2 == null ? void 0 : u2.tabIndex) === 0)
|
|
1039
1055
|
return u2.focus(), true;
|
|
1040
1056
|
}
|
|
1041
1057
|
return false;
|
|
1042
|
-
} }), H$1({ theirProps: { ...i2, ...T$
|
|
1058
|
+
} }), H$1({ theirProps: { ...i2, ...T$2(a2, ["selectedIndex", "defaultIndex", "manual", "vertical", "onChange"]) }, ourProps: {}, slot: t2, slots: v2, attrs: i2, name: "TabGroup" })]);
|
|
1043
1059
|
};
|
|
1044
1060
|
} }), Ie = defineComponent({ name: "TabList", props: { as: { type: [Object, String], default: "div" } }, setup(a2, { attrs: v2, slots: i2 }) {
|
|
1045
1061
|
let s2 = k("TabList");
|
|
@@ -1050,60 +1066,60 @@ let j = Symbol("TabsSSRContext"), xe = defineComponent({ name: "TabGroup", emits
|
|
|
1050
1066
|
} }), ye = defineComponent({ name: "Tab", props: { as: { type: [Object, String], default: "button" }, disabled: { type: [Boolean], default: false }, id: { type: String, default: () => `headlessui-tabs-tab-${t$4()}` } }, setup(a2, { attrs: v2, slots: i2, expose: s2 }) {
|
|
1051
1067
|
let l2 = k("Tab"), n2 = ref(null);
|
|
1052
1068
|
s2({ el: n2, $el: n2 }), onMounted(() => l2.registerTab(n2)), onUnmounted(() => l2.unregisterTab(n2));
|
|
1053
|
-
let
|
|
1054
|
-
if (
|
|
1055
|
-
let e2 =
|
|
1056
|
-
return e2 === -1 ?
|
|
1069
|
+
let o2 = inject(j), h2 = computed(() => {
|
|
1070
|
+
if (o2.value) {
|
|
1071
|
+
let e2 = o2.value.tabs.indexOf(a2.id);
|
|
1072
|
+
return e2 === -1 ? o2.value.tabs.push(a2.id) - 1 : e2;
|
|
1057
1073
|
}
|
|
1058
1074
|
return -1;
|
|
1059
1075
|
}), b2 = computed(() => {
|
|
1060
1076
|
let e2 = l2.tabs.value.indexOf(n2);
|
|
1061
|
-
return e2 === -1 ?
|
|
1077
|
+
return e2 === -1 ? h2.value : e2;
|
|
1062
1078
|
}), m2 = computed(() => b2.value === l2.selectedIndex.value);
|
|
1063
1079
|
function r2(e2) {
|
|
1064
1080
|
var f2;
|
|
1065
1081
|
let u2 = e2();
|
|
1066
|
-
if (u2 === T.Success && l2.activation.value === "auto") {
|
|
1067
|
-
let S2 = (f2 = m$2(n2)) == null ? void 0 : f2.activeElement, p2 = l2.tabs.value.findIndex((
|
|
1082
|
+
if (u2 === T$1.Success && l2.activation.value === "auto") {
|
|
1083
|
+
let S2 = (f2 = m$2(n2)) == null ? void 0 : f2.activeElement, p2 = l2.tabs.value.findIndex((g) => o$1(g) === S2);
|
|
1068
1084
|
p2 !== -1 && l2.setSelectedIndex(p2);
|
|
1069
1085
|
}
|
|
1070
1086
|
return u2;
|
|
1071
1087
|
}
|
|
1072
|
-
function
|
|
1073
|
-
let u2 = l2.tabs.value.map((S2) => o(S2)).filter(Boolean);
|
|
1074
|
-
if (e2.key === o$
|
|
1088
|
+
function w2(e2) {
|
|
1089
|
+
let u2 = l2.tabs.value.map((S2) => o$1(S2)).filter(Boolean);
|
|
1090
|
+
if (e2.key === o$2.Space || e2.key === o$2.Enter) {
|
|
1075
1091
|
e2.preventDefault(), e2.stopPropagation(), l2.setSelectedIndex(b2.value);
|
|
1076
1092
|
return;
|
|
1077
1093
|
}
|
|
1078
1094
|
switch (e2.key) {
|
|
1079
|
-
case o$
|
|
1080
|
-
case o$
|
|
1095
|
+
case o$2.Home:
|
|
1096
|
+
case o$2.PageUp:
|
|
1081
1097
|
return e2.preventDefault(), e2.stopPropagation(), r2(() => P$1(u2, N$1.First));
|
|
1082
|
-
case o$
|
|
1083
|
-
case o$
|
|
1098
|
+
case o$2.End:
|
|
1099
|
+
case o$2.PageDown:
|
|
1084
1100
|
return e2.preventDefault(), e2.stopPropagation(), r2(() => P$1(u2, N$1.Last));
|
|
1085
1101
|
}
|
|
1086
1102
|
if (r2(() => u$3(l2.orientation.value, { vertical() {
|
|
1087
|
-
return e2.key === o$
|
|
1103
|
+
return e2.key === o$2.ArrowUp ? P$1(u2, N$1.Previous | N$1.WrapAround) : e2.key === o$2.ArrowDown ? P$1(u2, N$1.Next | N$1.WrapAround) : T$1.Error;
|
|
1088
1104
|
}, horizontal() {
|
|
1089
|
-
return e2.key === o$
|
|
1090
|
-
} })) === T.Success)
|
|
1105
|
+
return e2.key === o$2.ArrowLeft ? P$1(u2, N$1.Previous | N$1.WrapAround) : e2.key === o$2.ArrowRight ? P$1(u2, N$1.Next | N$1.WrapAround) : T$1.Error;
|
|
1106
|
+
} })) === T$1.Success)
|
|
1091
1107
|
return e2.preventDefault();
|
|
1092
1108
|
}
|
|
1093
1109
|
let y2 = ref(false);
|
|
1094
|
-
function
|
|
1110
|
+
function E2() {
|
|
1095
1111
|
var e2;
|
|
1096
|
-
y2.value || (y2.value = true, !a2.disabled && ((e2 = o(n2)) == null || e2.focus(), l2.setSelectedIndex(b2.value), t$2(() => {
|
|
1112
|
+
y2.value || (y2.value = true, !a2.disabled && ((e2 = o$1(n2)) == null || e2.focus({ preventScroll: true }), l2.setSelectedIndex(b2.value), t$2(() => {
|
|
1097
1113
|
y2.value = false;
|
|
1098
1114
|
})));
|
|
1099
1115
|
}
|
|
1100
|
-
function
|
|
1116
|
+
function P2(e2) {
|
|
1101
1117
|
e2.preventDefault();
|
|
1102
1118
|
}
|
|
1103
1119
|
let t2 = b$1(computed(() => ({ as: a2.as, type: v2.type })), n2);
|
|
1104
1120
|
return () => {
|
|
1105
1121
|
var p2;
|
|
1106
|
-
let e2 = { selected: m2.value }, { id: u2, ...f2 } = a2, S2 = { ref: n2, onKeydown:
|
|
1122
|
+
let e2 = { selected: m2.value }, { id: u2, ...f2 } = a2, S2 = { ref: n2, onKeydown: w2, onMousedown: P2, onClick: E2, id: u2, role: "tab", type: t2.value, "aria-controls": (p2 = o$1(l2.panels.value[b2.value])) == null ? void 0 : p2.id, "aria-selected": m2.value, tabIndex: m2.value ? 0 : -1, disabled: a2.disabled ? true : void 0 };
|
|
1107
1123
|
return H$1({ ourProps: S2, theirProps: f2, slot: e2, attrs: v2, slots: i2, name: "Tab" });
|
|
1108
1124
|
};
|
|
1109
1125
|
} }), Se = defineComponent({ name: "TabPanels", props: { as: { type: [Object, String], default: "div" } }, setup(a2, { slots: v2, attrs: i2 }) {
|
|
@@ -1115,20 +1131,20 @@ let j = Symbol("TabsSSRContext"), xe = defineComponent({ name: "TabGroup", emits
|
|
|
1115
1131
|
} }), ge = defineComponent({ name: "TabPanel", props: { as: { type: [Object, String], default: "div" }, static: { type: Boolean, default: false }, unmount: { type: Boolean, default: true }, id: { type: String, default: () => `headlessui-tabs-panel-${t$4()}` }, tabIndex: { type: Number, default: 0 } }, setup(a2, { attrs: v2, slots: i2, expose: s2 }) {
|
|
1116
1132
|
let l2 = k("TabPanel"), n2 = ref(null);
|
|
1117
1133
|
s2({ el: n2, $el: n2 }), onMounted(() => l2.registerPanel(n2)), onUnmounted(() => l2.unregisterPanel(n2));
|
|
1118
|
-
let
|
|
1119
|
-
if (
|
|
1120
|
-
let r2 =
|
|
1121
|
-
return r2 === -1 ?
|
|
1134
|
+
let o2 = inject(j), h2 = computed(() => {
|
|
1135
|
+
if (o2.value) {
|
|
1136
|
+
let r2 = o2.value.panels.indexOf(a2.id);
|
|
1137
|
+
return r2 === -1 ? o2.value.panels.push(a2.id) - 1 : r2;
|
|
1122
1138
|
}
|
|
1123
1139
|
return -1;
|
|
1124
1140
|
}), b2 = computed(() => {
|
|
1125
1141
|
let r2 = l2.panels.value.indexOf(n2);
|
|
1126
|
-
return r2 === -1 ?
|
|
1142
|
+
return r2 === -1 ? h2.value : r2;
|
|
1127
1143
|
}), m2 = computed(() => b2.value === l2.selectedIndex.value);
|
|
1128
1144
|
return () => {
|
|
1129
1145
|
var t2;
|
|
1130
|
-
let r2 = { selected: m2.value }, { id:
|
|
1131
|
-
return !m2.value && a2.unmount && !a2.static ? h$2(f$1, { as: "span", ...
|
|
1146
|
+
let r2 = { selected: m2.value }, { id: w2, tabIndex: y2, ...E2 } = a2, P2 = { ref: n2, id: w2, role: "tabpanel", "aria-labelledby": (t2 = o$1(l2.tabs.value[b2.value])) == null ? void 0 : t2.id, tabIndex: m2.value ? y2 : -1 };
|
|
1147
|
+
return !m2.value && a2.unmount && !a2.static ? h$2(f$1, { as: "span", ...P2 }) : H$1({ ourProps: P2, theirProps: E2, slot: r2, attrs: v2, slots: i2, features: N$2.Static | N$2.RenderStrategy, visible: m2.value, name: "TabPanel" });
|
|
1132
1148
|
};
|
|
1133
1149
|
} });
|
|
1134
1150
|
const scrollbar = "";
|
|
@@ -1195,15 +1211,10 @@ function tryOnScopeDispose(fn) {
|
|
|
1195
1211
|
}
|
|
1196
1212
|
return false;
|
|
1197
1213
|
}
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
};
|
|
1201
|
-
function toRef(...args) {
|
|
1202
|
-
if (args.length !== 1)
|
|
1203
|
-
return toRef$1(...args);
|
|
1204
|
-
const r2 = args[0];
|
|
1205
|
-
return typeof r2 === "function" ? readonly(customRef(() => ({ get: r2, set: noop$1 }))) : ref(r2);
|
|
1214
|
+
function toValue(r2) {
|
|
1215
|
+
return typeof r2 === "function" ? r2() : unref(r2);
|
|
1206
1216
|
}
|
|
1217
|
+
const isClient = typeof window !== "undefined" && typeof document !== "undefined";
|
|
1207
1218
|
const defaultWindow = isClient ? window : void 0;
|
|
1208
1219
|
function useMounted() {
|
|
1209
1220
|
const isMounted = ref(false);
|
|
@@ -1226,29 +1237,33 @@ function useMediaQuery(query, options = {}) {
|
|
|
1226
1237
|
const isSupported = useSupported(() => window2 && "matchMedia" in window2 && typeof window2.matchMedia === "function");
|
|
1227
1238
|
let mediaQuery;
|
|
1228
1239
|
const matches = ref(false);
|
|
1240
|
+
const handler = (event) => {
|
|
1241
|
+
matches.value = event.matches;
|
|
1242
|
+
};
|
|
1229
1243
|
const cleanup = () => {
|
|
1230
1244
|
if (!mediaQuery)
|
|
1231
1245
|
return;
|
|
1232
1246
|
if ("removeEventListener" in mediaQuery)
|
|
1233
|
-
mediaQuery.removeEventListener("change",
|
|
1247
|
+
mediaQuery.removeEventListener("change", handler);
|
|
1234
1248
|
else
|
|
1235
|
-
mediaQuery.removeListener(
|
|
1249
|
+
mediaQuery.removeListener(handler);
|
|
1236
1250
|
};
|
|
1237
|
-
const
|
|
1251
|
+
const stopWatch = watchEffect(() => {
|
|
1238
1252
|
if (!isSupported.value)
|
|
1239
1253
|
return;
|
|
1240
1254
|
cleanup();
|
|
1241
|
-
mediaQuery = window2.matchMedia(
|
|
1242
|
-
matches.value = !!(mediaQuery == null ? void 0 : mediaQuery.matches);
|
|
1243
|
-
if (!mediaQuery)
|
|
1244
|
-
return;
|
|
1255
|
+
mediaQuery = window2.matchMedia(toValue(query));
|
|
1245
1256
|
if ("addEventListener" in mediaQuery)
|
|
1246
|
-
mediaQuery.addEventListener("change",
|
|
1257
|
+
mediaQuery.addEventListener("change", handler);
|
|
1247
1258
|
else
|
|
1248
|
-
mediaQuery.addListener(
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
tryOnScopeDispose(() =>
|
|
1259
|
+
mediaQuery.addListener(handler);
|
|
1260
|
+
matches.value = mediaQuery.matches;
|
|
1261
|
+
});
|
|
1262
|
+
tryOnScopeDispose(() => {
|
|
1263
|
+
stopWatch();
|
|
1264
|
+
cleanup();
|
|
1265
|
+
mediaQuery = void 0;
|
|
1266
|
+
});
|
|
1252
1267
|
return matches;
|
|
1253
1268
|
}
|
|
1254
1269
|
function defaultState() {
|
|
@@ -4100,8 +4115,9 @@ const reduceDescriptors = (obj, reducer) => {
|
|
|
4100
4115
|
const descriptors2 = Object.getOwnPropertyDescriptors(obj);
|
|
4101
4116
|
const reducedDescriptors = {};
|
|
4102
4117
|
forEach(descriptors2, (descriptor, name) => {
|
|
4103
|
-
|
|
4104
|
-
|
|
4118
|
+
let ret;
|
|
4119
|
+
if ((ret = reducer(descriptor, name, obj)) !== false) {
|
|
4120
|
+
reducedDescriptors[name] = ret || descriptor;
|
|
4105
4121
|
}
|
|
4106
4122
|
});
|
|
4107
4123
|
Object.defineProperties(obj, reducedDescriptors);
|
|
@@ -4626,9 +4642,6 @@ function formDataToJSON(formData) {
|
|
|
4626
4642
|
}
|
|
4627
4643
|
return null;
|
|
4628
4644
|
}
|
|
4629
|
-
const DEFAULT_CONTENT_TYPE = {
|
|
4630
|
-
"Content-Type": void 0
|
|
4631
|
-
};
|
|
4632
4645
|
function stringifySafely(rawValue, parser, encoder) {
|
|
4633
4646
|
if (utils.isString(rawValue)) {
|
|
4634
4647
|
try {
|
|
@@ -4644,7 +4657,7 @@ function stringifySafely(rawValue, parser, encoder) {
|
|
|
4644
4657
|
}
|
|
4645
4658
|
const defaults = {
|
|
4646
4659
|
transitional: transitionalDefaults,
|
|
4647
|
-
adapter:
|
|
4660
|
+
adapter: platform.isNode ? "http" : "xhr",
|
|
4648
4661
|
transformRequest: [function transformRequest(data, headers) {
|
|
4649
4662
|
const contentType = headers.getContentType() || "";
|
|
4650
4663
|
const hasJSONContentType = contentType.indexOf("application/json") > -1;
|
|
@@ -4727,16 +4740,14 @@ const defaults = {
|
|
|
4727
4740
|
},
|
|
4728
4741
|
headers: {
|
|
4729
4742
|
common: {
|
|
4730
|
-
"Accept": "application/json, text/plain, */*"
|
|
4743
|
+
"Accept": "application/json, text/plain, */*",
|
|
4744
|
+
"Content-Type": void 0
|
|
4731
4745
|
}
|
|
4732
4746
|
}
|
|
4733
4747
|
};
|
|
4734
|
-
utils.forEach(["delete", "get", "head"],
|
|
4748
|
+
utils.forEach(["delete", "get", "head", "post", "put", "patch"], (method) => {
|
|
4735
4749
|
defaults.headers[method] = {};
|
|
4736
4750
|
});
|
|
4737
|
-
utils.forEach(["post", "put", "patch"], function forEachMethodWithData(method) {
|
|
4738
|
-
defaults.headers[method] = utils.merge(DEFAULT_CONTENT_TYPE);
|
|
4739
|
-
});
|
|
4740
4751
|
const defaults$1 = defaults;
|
|
4741
4752
|
const ignoreDuplicateOf = utils.toObjectSet([
|
|
4742
4753
|
"age",
|
|
@@ -4986,7 +4997,15 @@ class AxiosHeaders {
|
|
|
4986
4997
|
}
|
|
4987
4998
|
}
|
|
4988
4999
|
AxiosHeaders.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
|
|
4989
|
-
utils.
|
|
5000
|
+
utils.reduceDescriptors(AxiosHeaders.prototype, ({ value }, key) => {
|
|
5001
|
+
let mapped = key[0].toUpperCase() + key.slice(1);
|
|
5002
|
+
return {
|
|
5003
|
+
get: () => value,
|
|
5004
|
+
set(headerValue) {
|
|
5005
|
+
this[mapped] = headerValue;
|
|
5006
|
+
}
|
|
5007
|
+
};
|
|
5008
|
+
});
|
|
4990
5009
|
utils.freezeMethods(AxiosHeaders);
|
|
4991
5010
|
const AxiosHeaders$1 = AxiosHeaders;
|
|
4992
5011
|
function transformData(fns, response) {
|
|
@@ -5482,7 +5501,7 @@ function mergeConfig(config1, config2) {
|
|
|
5482
5501
|
});
|
|
5483
5502
|
return config;
|
|
5484
5503
|
}
|
|
5485
|
-
const VERSION = "1.
|
|
5504
|
+
const VERSION = "1.5.0";
|
|
5486
5505
|
const validators$1 = {};
|
|
5487
5506
|
["object", "boolean", "number", "function", "string", "symbol"].forEach((type, i2) => {
|
|
5488
5507
|
validators$1[type] = function validator2(thing) {
|
|
@@ -5585,12 +5604,11 @@ class Axios {
|
|
|
5585
5604
|
}
|
|
5586
5605
|
}
|
|
5587
5606
|
config.method = (config.method || this.defaults.method || "get").toLowerCase();
|
|
5588
|
-
let contextHeaders
|
|
5589
|
-
contextHeaders = headers && utils.merge(
|
|
5607
|
+
let contextHeaders = headers && utils.merge(
|
|
5590
5608
|
headers.common,
|
|
5591
5609
|
headers[config.method]
|
|
5592
5610
|
);
|
|
5593
|
-
|
|
5611
|
+
headers && utils.forEach(
|
|
5594
5612
|
["delete", "get", "head", "post", "put", "patch", "common"],
|
|
5595
5613
|
(method) => {
|
|
5596
5614
|
delete headers[method];
|
|
@@ -5655,7 +5673,7 @@ class Axios {
|
|
|
5655
5673
|
return buildURL(fullPath, config.params, config.paramsSerializer);
|
|
5656
5674
|
}
|
|
5657
5675
|
}
|
|
5658
|
-
utils.forEach(["delete", "get", "head", "options"], function
|
|
5676
|
+
utils.forEach(["delete", "get", "head", "options"], function forEachMethodNoData(method) {
|
|
5659
5677
|
Axios.prototype[method] = function(url, config) {
|
|
5660
5678
|
return this.request(mergeConfig(config || {}, {
|
|
5661
5679
|
method,
|
|
@@ -5664,7 +5682,7 @@ utils.forEach(["delete", "get", "head", "options"], function forEachMethodNoData
|
|
|
5664
5682
|
}));
|
|
5665
5683
|
};
|
|
5666
5684
|
});
|
|
5667
|
-
utils.forEach(["post", "put", "patch"], function
|
|
5685
|
+
utils.forEach(["post", "put", "patch"], function forEachMethodWithData(method) {
|
|
5668
5686
|
function generateHTTPMethod(isForm) {
|
|
5669
5687
|
return function httpMethod(url, data, config) {
|
|
5670
5688
|
return this.request(mergeConfig(config || {}, {
|
|
@@ -5873,6 +5891,7 @@ axios.isAxiosError = isAxiosError;
|
|
|
5873
5891
|
axios.mergeConfig = mergeConfig;
|
|
5874
5892
|
axios.AxiosHeaders = AxiosHeaders$1;
|
|
5875
5893
|
axios.formToJSON = (thing) => formDataToJSON(utils.isHTMLForm(thing) ? new FormData(thing) : thing);
|
|
5894
|
+
axios.getAdapter = adapters.getAdapter;
|
|
5876
5895
|
axios.HttpStatusCode = HttpStatusCode$1;
|
|
5877
5896
|
axios.default = axios;
|
|
5878
5897
|
const axios$1 = axios;
|
|
@@ -6143,7 +6162,7 @@ const BYTE_UNITS = [
|
|
|
6143
6162
|
];
|
|
6144
6163
|
const BIBYTE_UNITS = [
|
|
6145
6164
|
"B",
|
|
6146
|
-
"
|
|
6165
|
+
"KiB",
|
|
6147
6166
|
"MiB",
|
|
6148
6167
|
"GiB",
|
|
6149
6168
|
"TiB",
|
|
@@ -6610,12 +6629,12 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
|
|
|
6610
6629
|
},
|
|
6611
6630
|
setup(__props) {
|
|
6612
6631
|
return (_ctx, _cache) => {
|
|
6613
|
-
return openBlock(), createBlock(unref(
|
|
6632
|
+
return openBlock(), createBlock(unref(V), { defaultOpen: true }, {
|
|
6614
6633
|
default: withCtx(({ open }) => [
|
|
6615
6634
|
createElementVNode("div", {
|
|
6616
6635
|
class: normalizeClass(["scalar-api-client__item", { "scalar-api-client__item--open": open }])
|
|
6617
6636
|
}, [
|
|
6618
|
-
createVNode(unref(
|
|
6637
|
+
createVNode(unref(X), { class: "scalar-api-client__toggle" }, {
|
|
6619
6638
|
default: withCtx(() => [
|
|
6620
6639
|
_hoisted_1$g,
|
|
6621
6640
|
createElementVNode("span", _hoisted_2$6, toDisplayString(_ctx.title), 1),
|
|
@@ -6625,7 +6644,7 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
|
|
|
6625
6644
|
]),
|
|
6626
6645
|
_: 2
|
|
6627
6646
|
}, 1024),
|
|
6628
|
-
createVNode(unref(
|
|
6647
|
+
createVNode(unref(Y), null, {
|
|
6629
6648
|
default: withCtx(() => [
|
|
6630
6649
|
createElementVNode("div", _hoisted_4$5, [
|
|
6631
6650
|
renderSlot(_ctx.$slots, "default")
|