@ddict/popup 1.0.8 → 1.0.10

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/popup.es.js CHANGED
@@ -1,23 +1,71 @@
1
- import { computed as _, unref as R, shallowRef as an, watch as j, triggerRef as rt, onScopeDispose as Ye, ref as S, onUnmounted as St, inject as Ce, watchEffect as le, onMounted as de, cloneVNode as Ot, h as Oe, Fragment as X, defineComponent as se, provide as Qe, reactive as Et, nextTick as Q, toRaw as K, openBlock as P, createElementBlock as V, createElementVNode as I, mergeModels as un, useModel as cn, createBlock as xe, withCtx as Pe, createVNode as H, renderList as ge, normalizeClass as it, toDisplayString as ne, effectScope as It, markRaw as ae, hasInjectionContext as dn, getCurrentInstance as $t, isRef as be, isReactive as Ze, toRef as Be, getCurrentScope as Ct, toRefs as at, createCommentVNode as ue, withModifiers as fn, withDirectives as Xe, vModelCheckbox as vn, createTextVNode as pn, vModelText as Tt } from "vue";
2
- function _e(e, o, t) {
1
+ import { openBlock as w, createElementBlock as O, createElementVNode as g, computed as y, unref as T, shallowRef as cn, watch as F, triggerRef as it, onScopeDispose as Xe, ref as E, onUnmounted as wt, inject as Le, watchEffect as ie, onMounted as ve, cloneVNode as Et, h as Se, Fragment as W, defineComponent as ae, provide as et, reactive as St, nextTick as te, toRaw as K, mergeModels as dn, useModel as fn, createBlock as X, withCtx as Ve, createVNode as H, renderList as se, normalizeClass as _e, toDisplayString as ee, effectScope as Ot, markRaw as de, hasInjectionContext as vn, getCurrentInstance as $t, isRef as xe, isReactive as tt, toRef as Ze, getCurrentScope as It, toRefs as at, createCommentVNode as Q, withModifiers as pn, createTextVNode as hn, withDirectives as Lt, vModelText as Tt, pushScopeId as mn, popScopeId as gn } from "vue";
2
+ const bn = "data:image/svg+xml,%3csvg%20width='96'%20height='32'%20viewBox='0%200%2096%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M40.151%208.94498H35.7256V23.055H40.151C44.7473%2023.055%2047.826%2020.0825%2047.826%2015.9795C47.8267%2011.8093%2044.7678%208.94498%2040.151%208.94498ZM40.1312%2021.025H37.993V10.9974H40.1312C43.4217%2010.9974%2045.4972%2012.9846%2045.4972%2015.9795C45.4965%2018.9296%2043.4012%2021.025%2040.1312%2021.025Z'%20fill='%233B5695'/%3e%3cpath%20d='M54.5158%208.94498H50.0903V23.055H54.5158C59.1121%2023.055%2062.1908%2020.0825%2062.1908%2015.9795C62.1914%2011.8093%2059.1351%208.94498%2054.5158%208.94498ZM54.496%2021.025H52.3578V10.9974H54.496C57.789%2010.9974%2059.8619%2012.9846%2059.8619%2015.9795C59.8613%2018.9296%2057.766%2021.025%2054.496%2021.025Z'%20fill='%233B5695'/%3e%3cpath%20d='M66.7237%208.94498H64.4575V23.055H66.7237V8.94498Z'%20fill='%233B5695'/%3e%3cpath%20d='M76.4301%2010.7837C78.29%2010.7837%2079.7436%2011.6603%2080.7487%2013.2207L82.4589%2011.9591C81.2401%209.97057%2078.9957%208.70953%2076.409%208.70953C72.3898%208.64555%2068.9048%2011.9591%2068.9906%2016C68.9048%2020.0403%2072.3898%2023.3544%2076.409%2023.2905C79.0385%2023.2905%2081.2618%2022.0294%2082.4589%2020.0409L80.7487%2018.7793C79.7436%2020.3397%2078.29%2021.2163%2076.4301%2021.2163C73.544%2021.2163%2071.3418%2018.993%2071.3418%2016C71.3418%2013.007%2073.5433%2010.7837%2076.4301%2010.7837Z'%20fill='%233B5695'/%3e%3cpath%20d='M83.3135%208.94498V10.9757H88.0595V23.055H90.3256V10.9757H95.0934V8.94498H83.3135Z'%20fill='%233B5695'/%3e%3cpath%20d='M8.66351%204.7121H4.604V15.4427L6.87208%2013.3839V6.79143H8.64559C11.4639%206.79143%2013.2835%208.47857%2013.2835%2011.0877C13.2835%2013.6916%2011.421%2015.4427%208.64559%2015.4427H4.604V17.5016H8.66351C12.7531%2017.5016%2015.6098%2014.8644%2015.6098%2011.0877C15.6104%207.27575%2012.8196%204.7121%208.66351%204.7121Z'%20fill='%233B5695'/%3e%3cpath%20d='M26.2425%209.25528H21.5502L20.7537%2014.293L21.4523%2014.3308L21.4069%2014.7294C21.3916%2014.8656%2021.3289%2015.0448%2021.112%2015.1734C21.1017%2015.9399%2021.0845%2017.0493%2020.9706%2018.1766H26.5937V19.8586H21.4677C22.4133%2022.9424%2024.1254%2024.9648%2026.5611%2025.8669L27.1536%2026.0864L26.6795%2026.5048C26.4875%2026.6737%2026.2182%2027.0141%2026.0896%2027.2489L25.9258%2027.5438L25.6155%2027.4152C23.167%2026.4095%2021.4223%2024.4926%2020.2905%2021.563C19.3602%2024.3365%2017.5797%2026.2553%2014.8592%2027.428L14.5438%2027.5617L14.3775%2027.2642C14.2764%2027.08%2014.0294%2026.7876%2013.8151%2026.5989L13.3564%2026.1951L13.9239%2025.9655C16.4555%2024.9392%2018.064%2023.1414%2018.8228%2020.4837C19.6647%2019.8381%2020.2099%2018.8221%2020.2169%2017.6801V4.53231C20.2169%202.58349%2018.6334%201%2016.6846%201H3.53487C1.58349%201%200%202.58349%200%204.53231V17.6795C0%2019.6283%201.58349%2021.2143%203.53487%2021.2143H8.25528V27.2431C8.25528%2029.3135%209.93986%2031%2012.0096%2031H26.2431C28.3161%2031%2029.9974%2029.3129%2029.9974%2027.2431V13.0096C29.9974%2010.9392%2028.3154%209.25528%2026.2425%209.25528ZM3.53487%2019.4517C2.55662%2019.4517%201.762%2018.6603%201.762%2017.6788V4.53231C1.762%203.55662%202.55598%202.762%203.53487%202.762H16.6839C17.6571%202.762%2018.4517%203.55598%2018.4517%204.53231V17.6795C18.4517%2017.778%2018.444%2017.8733%2018.4267%2017.9667C18.3941%2018.1811%2018.3231%2018.38%2018.215%2018.5592C17.9149%2019.0934%2017.3372%2019.4517%2016.6846%2019.4517H3.53487Z'%20fill='%233B5695'/%3e%3c/svg%3e", Cn = "data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M6.5%203.25C5.25736%203.25%204.25%204.25736%204.25%205.5H3.5H2.75C2.75%203.42893%204.42893%201.75%206.5%201.75H17.5C17.9142%201.75%2018.25%202.08579%2018.25%202.5V15.5C18.25%2015.9142%2017.9142%2016.25%2017.5%2016.25H6.5C5.26293%2016.25%204.25%2017.2576%204.25%2018.5C4.25%2018.9142%203.91421%2019.25%203.5%2019.25C3.08579%2019.25%202.75%2018.9142%202.75%2018.5V5.5C2.75%205.49993%202.75%205.5%203.5%205.5C4.25%205.5%204.25%205.49993%204.25%205.5V15.5017C4.87779%2015.0296%205.65755%2014.75%206.5%2014.75H16.75V3.25H6.5Z'%20fill='%233B5695'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M20.5%202.75C20.9142%202.75%2021.25%203.08579%2021.25%203.5V21.5C21.25%2021.9142%2020.9142%2022.25%2020.5%2022.25H6.5C4.42893%2022.25%202.75%2020.5711%202.75%2018.5C2.75%2016.4289%204.42893%2014.75%206.5%2014.75H17.4995C17.4996%2014.75%2017.5%2014.75%2017.5%2015.5C17.5%2016.25%2017.5001%2016.25%2017.5%2016.25H6.5C5.25736%2016.25%204.25%2017.2574%204.25%2018.5C4.25%2019.7426%205.25736%2020.75%206.5%2020.75H19.75V3.5C19.75%203.08579%2020.0858%202.75%2020.5%202.75ZM18.25%2015.5C18.25%2015.9142%2017.9142%2016.25%2017.5%2016.25V15.5L17.4995%2014.75C17.9137%2014.75%2018.25%2015.0858%2018.25%2015.5Z'%20fill='%233B5695'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M6.25%2018.5C6.25%2018.0858%206.58579%2017.75%207%2017.75H17C17.4142%2017.75%2017.75%2018.0858%2017.75%2018.5C17.75%2018.9142%2017.4142%2019.25%2017%2019.25H7C6.58579%2019.25%206.25%2018.9142%206.25%2018.5Z'%20fill='%233B5695'/%3e%3c/svg%3e", _n = "data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M2.467%202.47236C2.75841%202.17799%203.23328%202.17559%203.52764%202.467L8.52765%207.41675C8.82201%207.70816%208.82441%208.18303%208.533%208.4774C8.24159%208.77176%207.76672%208.77416%207.47235%208.48275L2.47236%203.533C2.17799%203.24159%202.17559%202.76672%202.467%202.47236Z'%20fill='%233B5695'/%3e%3cpath%20d='M8.533%2015.4724C8.82441%2015.7667%208.82201%2016.2416%208.52765%2016.533L3.52765%2021.4828C3.23328%2021.7742%202.75841%2021.7718%202.467%2021.4774C2.17559%2021.183%202.17799%2020.7082%202.47236%2020.4167L7.47235%2015.467C7.76672%2015.1756%208.24159%2015.178%208.533%2015.4724Z'%20fill='%233B5695'/%3e%3cpath%20d='M15.52%2015.4697C15.8129%2015.1768%2016.2877%2015.1768%2016.5806%2015.4697L21.5304%2020.4194C21.8233%2020.7123%2021.8233%2021.1872%2021.5304%2021.4801C21.2375%2021.773%2020.7626%2021.773%2020.4697%2021.4801L15.52%2016.5303C15.2271%2016.2374%2015.2271%2015.7626%2015.52%2015.4697Z'%20fill='%233B5695'/%3e%3cpath%20d='M21.4801%202.46967C21.773%202.76256%2021.773%203.23744%2021.4801%203.53033L16.5303%208.48008C16.2374%208.77297%2015.7626%208.77297%2015.4697%208.48008C15.1768%208.18719%2015.1768%207.71231%2015.4697%207.41942L20.4194%202.46967C20.7123%202.17678%2021.1872%202.17678%2021.4801%202.46967Z'%20fill='%233B5695'/%3e%3cpath%20d='M15.75%203C15.75%202.58579%2016.0858%202.25%2016.5%202.25H21C21.4142%202.25%2021.75%202.58579%2021.75%203V7.5C21.75%207.91421%2021.4142%208.25%2021%208.25C20.5858%208.25%2020.25%207.91421%2020.25%207.5V3.75H16.5C16.0858%203.75%2015.75%203.41421%2015.75%203Z'%20fill='%233B5695'/%3e%3cpath%20d='M21%2015.75C21.4142%2015.75%2021.75%2016.0858%2021.75%2016.5V21C21.75%2021.4142%2021.4142%2021.75%2021%2021.75H16.5C16.0858%2021.75%2015.75%2021.4142%2015.75%2021C15.75%2020.5858%2016.0858%2020.25%2016.5%2020.25H20.25V16.5C20.25%2016.0858%2020.5858%2015.75%2021%2015.75Z'%20fill='%233B5695'/%3e%3cpath%20d='M3%2015.75C3.41421%2015.75%203.75%2016.0858%203.75%2016.5V20.25H7.5C7.91421%2020.25%208.25%2020.5858%208.25%2021C8.25%2021.4142%207.91421%2021.75%207.5%2021.75H3C2.58579%2021.75%202.25%2021.4142%202.25%2021V16.5C2.25%2016.0858%202.58579%2015.75%203%2015.75Z'%20fill='%233B5695'/%3e%3cpath%20d='M2.25%203C2.25%202.58579%202.58579%202.25%203%202.25H7.5C7.91421%202.25%208.25%202.58579%208.25%203C8.25%203.41421%207.91421%203.75%207.5%203.75H3.75V7.5C3.75%207.91421%203.41421%208.25%203%208.25C2.58579%208.25%202.25%207.91421%202.25%207.5V3Z'%20fill='%233B5695'/%3e%3c/svg%3e", xn = "data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M9.12596%201.63869C9.46935%201.54364%209.83221%201.70329%209.99413%202.02068C10.3672%202.75191%2011.1261%203.25%2012%203.25C12.8739%203.25%2013.6328%202.75191%2014.0059%202.02068C14.1678%201.70329%2014.5307%201.54364%2014.874%201.63869C16.5585%202.10497%2018.0759%202.9704%2019.3184%204.12574C19.5611%204.35137%2019.6269%204.70948%2019.4804%205.00666C19.3331%205.30535%2019.25%205.6419%2019.25%206C19.25%207.24263%2020.2574%208.25%2021.5%208.25L21.5314%208.24977C21.8629%208.24504%2022.1583%208.45859%2022.2576%208.77495C22.5777%209.79397%2022.75%2010.8776%2022.75%2012C22.75%2012.7408%2022.6749%2013.4649%2022.5318%2014.1648C22.4548%2014.5411%2022.1059%2014.7985%2021.7237%2014.7609C21.6504%2014.7537%2021.5758%2014.75%2021.5%2014.75C20.2574%2014.75%2019.25%2015.7574%2019.25%2017C19.25%2017.5531%2019.4486%2018.0579%2019.7793%2018.4498C20.027%2018.7434%2020.0128%2019.1767%2019.7465%2019.4535C18.4777%2020.7719%2016.8745%2021.7678%2015.0721%2022.3044C14.6807%2022.4209%2014.2681%2022.2029%2014.1437%2021.814C13.8535%2020.906%2013.0024%2020.25%2012%2020.25C10.9976%2020.25%2010.1465%2020.906%209.85629%2021.814C9.73195%2022.2029%209.31927%2022.4209%208.92789%2022.3044C7.12545%2021.7678%205.52229%2020.7719%204.25353%2019.4535C3.98716%2019.1767%203.97299%2018.7434%204.22072%2018.4498C4.55139%2018.0579%204.75%2017.5531%204.75%2017C4.75%2015.7574%203.74264%2014.75%202.5%2014.75C2.42423%2014.75%202.34963%2014.7537%202.27634%2014.7609C1.89406%2014.7985%201.54519%2014.5411%201.46821%2014.1648C1.32505%2013.4649%201.25%2012.7408%201.25%2012C1.25%2010.8776%201.42227%209.79398%201.74236%208.77494C1.84173%208.45859%202.13705%208.24504%202.4686%208.24977L2.5%208.25C3.74264%208.25%204.75%207.24263%204.75%206C4.75%205.6419%204.66689%205.30535%204.51962%205.00666C4.3731%204.70948%204.43894%204.35137%204.68159%204.12574C5.92411%202.9704%207.44153%202.10497%209.12596%201.63869ZM6.08277%204.88991C6.19152%205.24123%206.25%205.61424%206.25%206C6.25%207.88945%204.85261%209.45253%203.03493%209.71213C2.84898%2010.4432%202.75%2011.2096%202.75%2012C2.75%2012.4294%202.77921%2012.8516%202.83567%2013.2648C4.74948%2013.4346%206.25%2015.0421%206.25%2017C6.25%2017.6669%206.0754%2018.2941%205.76971%2018.8372C6.62645%2019.6184%207.63002%2020.2404%208.73362%2020.657C9.37706%2019.5189%2010.598%2018.75%2012%2018.75C13.402%2018.75%2014.6229%2019.5189%2015.2664%2020.657C16.37%2020.2404%2017.3735%2019.6184%2018.2303%2018.8372C17.9246%2018.2941%2017.75%2017.6669%2017.75%2017C17.75%2015.0421%2019.2505%2013.4346%2021.1643%2013.2648C21.2208%2012.8516%2021.25%2012.4294%2021.25%2012C21.25%2011.2096%2021.151%2010.4432%2020.9651%209.71213C19.1474%209.45252%2017.75%207.88945%2017.75%206C17.75%205.61424%2017.8085%205.24123%2017.9172%204.88991C17.0618%204.1771%2016.0762%203.61614%2015.0018%203.24775C14.3184%204.15897%2013.2287%204.75%2012%204.75C10.7713%204.75%209.68158%204.15897%208.99819%203.24775C7.92382%203.61614%206.93823%204.1771%206.08277%204.88991Z'%20fill='%233B5695'/%3e%3cpath%20d='M7.75%2012C7.75%209.65278%209.65279%207.75%2012%207.75C14.3472%207.75%2016.25%209.65278%2016.25%2012C16.25%2014.3472%2014.3472%2016.25%2012%2016.25C9.65279%2016.25%207.75%2014.3472%207.75%2012ZM12%209.25C10.4812%209.25%209.25%2010.4812%209.25%2012C9.25%2013.5188%2010.4812%2014.75%2012%2014.75C13.5188%2014.75%2014.75%2013.5188%2014.75%2012C14.75%2010.4812%2013.5188%209.25%2012%209.25Z'%20fill='%233B5695'/%3e%3c/svg%3e", yn = { class: "flex justify-between" }, wn = /* @__PURE__ */ g("div", { class: "flex flex-row" }, [
3
+ /* @__PURE__ */ g("img", {
4
+ src: bn,
5
+ alt: "Vue logo",
6
+ class: "w-24"
7
+ })
8
+ ], -1), En = { class: "flex" }, Sn = /* @__PURE__ */ g("img", {
9
+ src: Cn,
10
+ alt: "Reader",
11
+ class: "w-7"
12
+ }, null, -1), On = [
13
+ Sn
14
+ ], $n = /* @__PURE__ */ g("img", {
15
+ src: _n,
16
+ alt: "Full screen",
17
+ class: "w-7"
18
+ }, null, -1), In = [
19
+ $n
20
+ ], Ln = /* @__PURE__ */ g("img", {
21
+ src: xn,
22
+ alt: "Setting",
23
+ class: "w-7"
24
+ }, null, -1), Tn = [
25
+ Ln
26
+ ], Vn = {
27
+ __name: "Header",
28
+ emits: ["settings", "fullScreen", "reader"],
29
+ setup(e, { emit: o }) {
30
+ const t = o;
31
+ return (n, l) => (w(), O("div", yn, [
32
+ wn,
33
+ g("div", En, [
34
+ g("button", {
35
+ class: "btn btn-ghost btn-circle",
36
+ onClick: l[0] || (l[0] = (r) => t("reader"))
37
+ }, On),
38
+ g("button", {
39
+ class: "btn btn-ghost btn-circle",
40
+ onClick: l[1] || (l[1] = (r) => t("fullScreen"))
41
+ }, In),
42
+ g("button", {
43
+ class: "btn btn-ghost btn-circle",
44
+ onClick: l[2] || (l[2] = (r) => t("settings"))
45
+ }, Tn)
46
+ ])
47
+ ]));
48
+ }
49
+ };
50
+ function ye(e, o, t) {
3
51
  let n = t.initialDeps ?? [], l;
4
52
  return () => {
5
53
  var r, i, s, a;
6
54
  let u;
7
55
  t.key && ((r = t.debug) != null && r.call(t)) && (u = Date.now());
8
56
  const v = e();
9
- if (!(v.length !== n.length || v.some((m, w) => n[w] !== m)))
57
+ if (!(v.length !== n.length || v.some((m, p) => n[p] !== m)))
10
58
  return l;
11
59
  n = v;
12
- let b;
13
- if (t.key && ((i = t.debug) != null && i.call(t)) && (b = Date.now()), l = o(...v), t.key && ((s = t.debug) != null && s.call(t))) {
14
- const m = Math.round((Date.now() - u) * 100) / 100, w = Math.round((Date.now() - b) * 100) / 100, $ = w / 16, M = (E, O) => {
15
- for (E = String(E); E.length < O; )
16
- E = " " + E;
17
- return E;
60
+ let h;
61
+ if (t.key && ((i = t.debug) != null && i.call(t)) && (h = Date.now()), l = o(...v), t.key && ((s = t.debug) != null && s.call(t))) {
62
+ const m = Math.round((Date.now() - u) * 100) / 100, p = Math.round((Date.now() - h) * 100) / 100, $ = p / 16, N = (L, I) => {
63
+ for (L = String(L); L.length < I; )
64
+ L = " " + L;
65
+ return L;
18
66
  };
19
67
  console.info(
20
- `%c⏱ ${M(w, 5)} /${M(m, 5)} ms`,
68
+ `%c⏱ ${N(p, 5)} /${N(m, 5)} ms`,
21
69
  `
22
70
  font-size: .6rem;
23
71
  font-weight: bold;
@@ -31,22 +79,22 @@ function _e(e, o, t) {
31
79
  return (a = t == null ? void 0 : t.onChange) == null || a.call(t, l), l;
32
80
  };
33
81
  }
34
- function Ue(e, o) {
82
+ function We(e, o) {
35
83
  if (e === void 0)
36
84
  throw new Error("Unexpected undefined");
37
85
  return e;
38
86
  }
39
- const hn = (e, o) => Math.abs(e - o) < 1, mn = (e, o, t) => {
87
+ const Pn = (e, o) => Math.abs(e - o) < 1, Mn = (e, o, t) => {
40
88
  let n;
41
89
  return function(...l) {
42
90
  e.clearTimeout(n), n = e.setTimeout(() => o.apply(this, l), t);
43
91
  };
44
- }, gn = (e) => e, bn = (e) => {
92
+ }, kn = (e) => e, Rn = (e) => {
45
93
  const o = Math.max(e.startIndex - e.overscan, 0), t = Math.min(e.endIndex + e.overscan, e.count - 1), n = [];
46
94
  for (let l = o; l <= t; l++)
47
95
  n.push(l);
48
96
  return n;
49
- }, yn = (e, o) => {
97
+ }, Nn = (e, o) => {
50
98
  const t = e.scrollElement;
51
99
  if (!t)
52
100
  return;
@@ -76,7 +124,7 @@ const hn = (e, o) => Math.abs(e - o) < 1, mn = (e, o, t) => {
76
124
  };
77
125
  }, ut = {
78
126
  passive: !0
79
- }, _n = typeof window > "u" ? !0 : "onscrollend" in window, wn = (e, o) => {
127
+ }, Dn = typeof window > "u" ? !0 : "onscrollend" in window, An = (e, o) => {
80
128
  const t = e.scrollElement;
81
129
  if (!t)
82
130
  return;
@@ -84,8 +132,8 @@ const hn = (e, o) => Math.abs(e - o) < 1, mn = (e, o, t) => {
84
132
  if (!n)
85
133
  return;
86
134
  let l = 0;
87
- const r = _n ? () => {
88
- } : mn(
135
+ const r = Dn ? () => {
136
+ } : Mn(
89
137
  n,
90
138
  () => {
91
139
  o(l, !1);
@@ -97,7 +145,7 @@ const hn = (e, o) => Math.abs(e - o) < 1, mn = (e, o, t) => {
97
145
  return a(), t.addEventListener("scroll", s, ut), t.addEventListener("scrollend", a, ut), () => {
98
146
  t.removeEventListener("scroll", s), t.removeEventListener("scrollend", a);
99
147
  };
100
- }, xn = (e, o, t) => {
148
+ }, Fn = (e, o, t) => {
101
149
  if (o != null && o.borderBoxSize) {
102
150
  const n = o.borderBoxSize[0];
103
151
  if (n)
@@ -108,7 +156,7 @@ const hn = (e, o) => Math.abs(e - o) < 1, mn = (e, o, t) => {
108
156
  return Math.round(
109
157
  e.getBoundingClientRect()[t.options.horizontal ? "width" : "height"]
110
158
  );
111
- }, Sn = (e, {
159
+ }, jn = (e, {
112
160
  adjustments: o = 0,
113
161
  behavior: t
114
162
  }, n) => {
@@ -119,7 +167,7 @@ const hn = (e, o) => Math.abs(e - o) < 1, mn = (e, o, t) => {
119
167
  behavior: t
120
168
  });
121
169
  };
122
- class On {
170
+ class Bn {
123
171
  constructor(o) {
124
172
  this.unsubs = [], this.scrollElement = null, this.targetWindow = null, this.isScrolling = !1, this.scrollToIndexTimeoutId = null, this.measurementsCache = [], this.itemSizeCache = /* @__PURE__ */ new Map(), this.pendingMeasuredCacheIndexes = [], this.scrollRect = null, this.scrollOffset = null, this.scrollDirection = null, this.scrollAdjustments = 0, this.elementsCache = /* @__PURE__ */ new Map(), this.observer = /* @__PURE__ */ (() => {
125
173
  let t = null;
@@ -154,11 +202,11 @@ class On {
154
202
  scrollPaddingStart: 0,
155
203
  scrollPaddingEnd: 0,
156
204
  horizontal: !1,
157
- getItemKey: gn,
158
- rangeExtractor: bn,
205
+ getItemKey: kn,
206
+ rangeExtractor: Rn,
159
207
  onChange: () => {
160
208
  },
161
- measureElement: xn,
209
+ measureElement: Fn,
162
210
  initialRect: { width: 0, height: 0 },
163
211
  scrollMargin: 0,
164
212
  gap: 0,
@@ -216,7 +264,7 @@ class On {
216
264
  break;
217
265
  }
218
266
  return r.size === this.options.lanes ? Array.from(r.values()).sort((i, s) => i.end === s.end ? i.index - s.index : i.end - s.end)[0] : void 0;
219
- }, this.getMeasurementOptions = _e(
267
+ }, this.getMeasurementOptions = ye(
220
268
  () => [
221
269
  this.options.count,
222
270
  this.options.paddingStart,
@@ -234,7 +282,7 @@ class On {
234
282
  {
235
283
  key: !1
236
284
  }
237
- ), this.getMeasurements = _e(
285
+ ), this.getMeasurements = ye(
238
286
  () => [this.getMeasurementOptions(), this.itemSizeCache],
239
287
  ({ count: t, paddingStart: n, scrollMargin: l, getItemKey: r, enabled: i }, s) => {
240
288
  var a;
@@ -247,27 +295,27 @@ class On {
247
295
  this.pendingMeasuredCacheIndexes = [];
248
296
  const v = this.measurementsCache.slice(0, u);
249
297
  for (let c = u; c < t; c++) {
250
- let b = (a = this.measurementsCache[c]) == null ? void 0 : a.measureElement;
251
- b || (b = (A) => {
252
- const g = r(c), T = this.elementsCache.get(g);
298
+ let h = (a = this.measurementsCache[c]) == null ? void 0 : a.measureElement;
299
+ h || (h = (A) => {
300
+ const _ = r(c), P = this.elementsCache.get(_);
253
301
  if (!A) {
254
- T && (this.observer.unobserve(T), this.elementsCache.delete(g));
302
+ P && (this.observer.unobserve(P), this.elementsCache.delete(_));
255
303
  return;
256
304
  }
257
- T !== A && (T && this.observer.unobserve(T), this.observer.observe(A), this.elementsCache.set(g, A)), A.isConnected && this.resizeItem(
305
+ P !== A && (P && this.observer.unobserve(P), this.observer.observe(A), this.elementsCache.set(_, A)), A.isConnected && this.resizeItem(
258
306
  c,
259
307
  this.options.measureElement(A, void 0, this)
260
308
  );
261
309
  });
262
- const m = r(c), w = this.options.lanes === 1 ? v[c - 1] : this.getFurthestMeasurement(v, c), $ = w ? w.end + this.options.gap : n + l, M = s.get(m), E = typeof M == "number" ? M : this.options.estimateSize(c), O = $ + E, D = w ? w.lane : c % this.options.lanes;
310
+ const m = r(c), p = this.options.lanes === 1 ? v[c - 1] : this.getFurthestMeasurement(v, c), $ = p ? p.end + this.options.gap : n + l, N = s.get(m), L = typeof N == "number" ? N : this.options.estimateSize(c), I = $ + L, R = p ? p.lane : c % this.options.lanes;
263
311
  v[c] = {
264
312
  index: c,
265
313
  start: $,
266
- size: E,
267
- end: O,
314
+ size: L,
315
+ end: I,
268
316
  key: m,
269
- lane: D,
270
- measureElement: b
317
+ lane: R,
318
+ measureElement: h
271
319
  };
272
320
  }
273
321
  return this.measurementsCache = v, v;
@@ -276,9 +324,9 @@ class On {
276
324
  key: process.env.NODE_ENV !== "production" && "getMeasurements",
277
325
  debug: () => this.options.debug
278
326
  }
279
- ), this.calculateRange = _e(
327
+ ), this.calculateRange = ye(
280
328
  () => [this.getMeasurements(), this.getSize(), this.getScrollOffset()],
281
- (t, n, l) => this.range = t.length > 0 && n > 0 ? En({
329
+ (t, n, l) => this.range = t.length > 0 && n > 0 ? Hn({
282
330
  measurements: t,
283
331
  outerSize: n,
284
332
  scrollOffset: l
@@ -287,7 +335,7 @@ class On {
287
335
  key: process.env.NODE_ENV !== "production" && "calculateRange",
288
336
  debug: () => this.options.debug
289
337
  }
290
- ), this.getIndexes = _e(
338
+ ), this.getIndexes = ye(
291
339
  () => [
292
340
  this.options.rangeExtractor,
293
341
  this.calculateRange(),
@@ -330,7 +378,7 @@ class On {
330
378
  })), this.pendingMeasuredCacheIndexes.push(l.index), this.itemSizeCache = new Map(this.itemSizeCache.set(l.key, n)), this.notify(!0, !1));
331
379
  }, this.measureElement = (t) => {
332
380
  t && this._measureElement(t, void 0);
333
- }, this.getVirtualItems = _e(
381
+ }, this.getVirtualItems = ye(
334
382
  () => [this.getIndexes(), this.getMeasurements()],
335
383
  (t, n) => {
336
384
  const l = [];
@@ -347,11 +395,11 @@ class On {
347
395
  ), this.getVirtualItemForOffset = (t) => {
348
396
  const n = this.getMeasurements();
349
397
  if (n.length !== 0)
350
- return Ue(
351
- n[Pt(
398
+ return We(
399
+ n[Vt(
352
400
  0,
353
401
  n.length - 1,
354
- (l) => Ue(n[l]).start,
402
+ (l) => We(n[l]).start,
355
403
  t
356
404
  )]
357
405
  );
@@ -395,10 +443,10 @@ class On {
395
443
  if (this.scrollToIndexTimeoutId = null, this.elementsCache.has(
396
444
  this.options.getItemKey(t)
397
445
  )) {
398
- const [u] = Ue(
446
+ const [u] = We(
399
447
  this.getOffsetForIndex(t, s)
400
448
  );
401
- hn(u, this.getScrollOffset()) || this.scrollToIndex(t, { align: s, behavior: l });
449
+ Pn(u, this.getScrollOffset()) || this.scrollToIndex(t, { align: s, behavior: l });
402
450
  } else
403
451
  this.scrollToIndex(t, { align: s, behavior: l });
404
452
  }));
@@ -427,7 +475,7 @@ class On {
427
475
  }, this.setOptions(o);
428
476
  }
429
477
  }
430
- const Pt = (e, o, t, n) => {
478
+ const Vt = (e, o, t, n) => {
431
479
  for (; e <= o; ) {
432
480
  const l = (e + o) / 2 | 0, r = t(l);
433
481
  if (r < n)
@@ -439,65 +487,65 @@ const Pt = (e, o, t, n) => {
439
487
  }
440
488
  return e > 0 ? e - 1 : 0;
441
489
  };
442
- function En({
490
+ function Hn({
443
491
  measurements: e,
444
492
  outerSize: o,
445
493
  scrollOffset: t
446
494
  }) {
447
- const n = e.length - 1, r = Pt(0, n, (s) => e[s].start, t);
495
+ const n = e.length - 1, r = Vt(0, n, (s) => e[s].start, t);
448
496
  let i = r;
449
497
  for (; i < n && e[i].end < t + o; )
450
498
  i++;
451
499
  return { startIndex: r, endIndex: i };
452
500
  }
453
- function In(e) {
454
- const o = new On(R(e)), t = an(o), n = o._didMount();
455
- return j(
456
- () => R(e).getScrollElement(),
501
+ function zn(e) {
502
+ const o = new Bn(T(e)), t = cn(o), n = o._didMount();
503
+ return F(
504
+ () => T(e).getScrollElement(),
457
505
  (l) => {
458
506
  l && o._willUpdate();
459
507
  },
460
508
  {
461
509
  immediate: !0
462
510
  }
463
- ), j(
464
- () => R(e),
511
+ ), F(
512
+ () => T(e),
465
513
  (l) => {
466
514
  o.setOptions({
467
515
  ...l,
468
516
  onChange: (r, i) => {
469
517
  var s;
470
- rt(t), (s = l.onChange) == null || s.call(l, r, i);
518
+ it(t), (s = l.onChange) == null || s.call(l, r, i);
471
519
  }
472
- }), o._willUpdate(), rt(t);
520
+ }), o._willUpdate(), it(t);
473
521
  },
474
522
  {
475
523
  immediate: !0
476
524
  }
477
- ), Ye(n), t;
478
- }
479
- function $n(e) {
480
- return In(
481
- _(() => ({
482
- observeElementRect: yn,
483
- observeElementOffset: wn,
484
- scrollToFn: Sn,
485
- ...R(e)
525
+ ), Xe(n), t;
526
+ }
527
+ function Un(e) {
528
+ return zn(
529
+ y(() => ({
530
+ observeElementRect: Nn,
531
+ observeElementOffset: An,
532
+ scrollToFn: jn,
533
+ ...T(e)
486
534
  }))
487
535
  );
488
536
  }
489
- function Cn(e, o, t) {
490
- let n = S(t == null ? void 0 : t.value), l = _(() => e.value !== void 0);
491
- return [_(() => l.value ? e.value : n.value), function(r) {
537
+ function Zn(e, o, t) {
538
+ let n = E(t == null ? void 0 : t.value), l = y(() => e.value !== void 0);
539
+ return [y(() => l.value ? e.value : n.value), function(r) {
492
540
  return l.value || (n.value = r), o == null ? void 0 : o(r);
493
541
  }];
494
542
  }
495
- function Tn(e) {
543
+ function Wn(e) {
496
544
  typeof queueMicrotask == "function" ? queueMicrotask(e) : Promise.resolve().then(e).catch((o) => setTimeout(() => {
497
545
  throw o;
498
546
  }));
499
547
  }
500
- function Le() {
548
+ function De() {
501
549
  let e = [], o = { addEventListener(t, n, l, r) {
502
550
  return t.addEventListener(n, l, r), o.add(() => t.removeEventListener(n, l, r));
503
551
  }, requestAnimationFrame(...t) {
@@ -512,7 +560,7 @@ function Le() {
512
560
  o.add(() => clearTimeout(n));
513
561
  }, microTask(...t) {
514
562
  let n = { current: !0 };
515
- return Tn(() => {
563
+ return Wn(() => {
516
564
  n.current && t[0]();
517
565
  }), o.add(() => {
518
566
  n.current = !1;
@@ -523,7 +571,7 @@ function Le() {
523
571
  Object.assign(t.style, { [n]: r });
524
572
  });
525
573
  }, group(t) {
526
- let n = Le();
574
+ let n = De();
527
575
  return t(n), this.add(() => n.dispose());
528
576
  }, add(t) {
529
577
  return e.push(t), () => {
@@ -535,36 +583,36 @@ function Le() {
535
583
  } };
536
584
  return o;
537
585
  }
538
- function Pn() {
539
- let e = Le();
540
- return St(() => e.dispose()), e;
586
+ function Gn() {
587
+ let e = De();
588
+ return wt(() => e.dispose()), e;
541
589
  }
542
- function Rn() {
543
- let e = Pn();
590
+ function qn() {
591
+ let e = Gn();
544
592
  return (o) => {
545
593
  e.dispose(), e.nextFrame(o);
546
594
  };
547
595
  }
548
- let kn = Symbol("headlessui.useid"), Nn = 0;
596
+ let Jn = Symbol("headlessui.useid"), Kn = 0;
549
597
  function Te() {
550
- return Ce(kn, () => `${++Nn}`)();
598
+ return Le(Jn, () => `${++Kn}`)();
551
599
  }
552
- function k(e) {
600
+ function M(e) {
553
601
  var o;
554
602
  if (e == null || e.value == null) return null;
555
603
  let t = (o = e.value.$el) != null ? o : e.value;
556
604
  return t instanceof Node ? t : null;
557
605
  }
558
- function te(e, o, ...t) {
606
+ function le(e, o, ...t) {
559
607
  if (e in o) {
560
608
  let l = o[e];
561
609
  return typeof l == "function" ? l(...t) : l;
562
610
  }
563
611
  let n = new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(o).map((l) => `"${l}"`).join(", ")}.`);
564
- throw Error.captureStackTrace && Error.captureStackTrace(n, te), n;
612
+ throw Error.captureStackTrace && Error.captureStackTrace(n, le), n;
565
613
  }
566
- var Vn = Object.defineProperty, Dn = (e, o, t) => o in e ? Vn(e, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[o] = t, ct = (e, o, t) => (Dn(e, typeof o != "symbol" ? o + "" : o, t), t);
567
- let Ln = class {
614
+ var Yn = Object.defineProperty, Qn = (e, o, t) => o in e ? Yn(e, o, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[o] = t, ct = (e, o, t) => (Qn(e, typeof o != "symbol" ? o + "" : o, t), t);
615
+ let Xn = class {
568
616
  constructor() {
569
617
  ct(this, "current", this.detect()), ct(this, "currentId", 0);
570
618
  }
@@ -586,21 +634,21 @@ let Ln = class {
586
634
  detect() {
587
635
  return typeof window > "u" || typeof document > "u" ? "server" : "client";
588
636
  }
589
- }, et = new Ln();
590
- function tt(e) {
591
- if (et.isServer) return null;
637
+ }, nt = new Xn();
638
+ function ot(e) {
639
+ if (nt.isServer) return null;
592
640
  if (e instanceof Node) return e.ownerDocument;
593
641
  if (e != null && e.hasOwnProperty("value")) {
594
- let o = k(e);
642
+ let o = M(e);
595
643
  if (o) return o.ownerDocument;
596
644
  }
597
645
  return document;
598
646
  }
599
647
  let dt = ["[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(",");
600
- var Mn = ((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))(Mn || {}), An = ((e) => (e[e.Error = 0] = "Error", e[e.Overflow = 1] = "Overflow", e[e.Success = 2] = "Success", e[e.Underflow = 3] = "Underflow", e))(An || {}), jn = ((e) => (e[e.Previous = -1] = "Previous", e[e.Next = 1] = "Next", e))(jn || {}), Rt = ((e) => (e[e.Strict = 0] = "Strict", e[e.Loose = 1] = "Loose", e))(Rt || {});
601
- function Fn(e, o = 0) {
648
+ var eo = ((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))(eo || {}), to = ((e) => (e[e.Error = 0] = "Error", e[e.Overflow = 1] = "Overflow", e[e.Success = 2] = "Success", e[e.Underflow = 3] = "Underflow", e))(to || {}), no = ((e) => (e[e.Previous = -1] = "Previous", e[e.Next = 1] = "Next", e))(no || {}), Pt = ((e) => (e[e.Strict = 0] = "Strict", e[e.Loose = 1] = "Loose", e))(Pt || {});
649
+ function oo(e, o = 0) {
602
650
  var t;
603
- return e === ((t = tt(e)) == null ? void 0 : t.body) ? !1 : te(o, { 0() {
651
+ return e === ((t = ot(e)) == null ? void 0 : t.body) ? !1 : le(o, { 0() {
604
652
  return e.matches(dt);
605
653
  }, 1() {
606
654
  let n = e;
@@ -611,13 +659,13 @@ function Fn(e, o = 0) {
611
659
  return !1;
612
660
  } });
613
661
  }
614
- var zn = ((e) => (e[e.Keyboard = 0] = "Keyboard", e[e.Mouse = 1] = "Mouse", e))(zn || {});
662
+ var lo = ((e) => (e[e.Keyboard = 0] = "Keyboard", e[e.Mouse = 1] = "Mouse", e))(lo || {});
615
663
  typeof window < "u" && typeof document < "u" && (document.addEventListener("keydown", (e) => {
616
664
  e.metaKey || e.altKey || e.ctrlKey || (document.documentElement.dataset.headlessuiFocusVisible = "");
617
665
  }, !0), document.addEventListener("click", (e) => {
618
666
  e.detail === 1 ? delete document.documentElement.dataset.headlessuiFocusVisible : e.detail === 0 && (document.documentElement.dataset.headlessuiFocusVisible = "");
619
667
  }, !0));
620
- function Bn(e, o = (t) => t) {
668
+ function so(e, o = (t) => t) {
621
669
  return e.slice().sort((t, n) => {
622
670
  let l = o(t), r = o(n);
623
671
  if (l === null || r === null) return 0;
@@ -625,26 +673,26 @@ function Bn(e, o = (t) => t) {
625
673
  return i & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : i & Node.DOCUMENT_POSITION_PRECEDING ? 1 : 0;
626
674
  });
627
675
  }
628
- function Un() {
676
+ function ro() {
629
677
  return /iPhone/gi.test(window.navigator.platform) || /Mac/gi.test(window.navigator.platform) && window.navigator.maxTouchPoints > 0;
630
678
  }
631
- function Hn() {
679
+ function io() {
632
680
  return /Android/gi.test(window.navigator.userAgent);
633
681
  }
634
- function kt() {
635
- return Un() || Hn();
682
+ function Mt() {
683
+ return ro() || io();
636
684
  }
637
- function Re(e, o, t) {
638
- et.isServer || le((n) => {
685
+ function Pe(e, o, t) {
686
+ nt.isServer || ie((n) => {
639
687
  document.addEventListener(e, o, t), n(() => document.removeEventListener(e, o, t));
640
688
  });
641
689
  }
642
- function Wn(e, o, t) {
643
- et.isServer || le((n) => {
690
+ function ao(e, o, t) {
691
+ nt.isServer || ie((n) => {
644
692
  window.addEventListener(e, o, t), n(() => window.removeEventListener(e, o, t));
645
693
  });
646
694
  }
647
- function Gn(e, o, t = _(() => !0)) {
695
+ function uo(e, o, t = y(() => !0)) {
648
696
  function n(r, i) {
649
697
  if (!t.value || r.defaultPrevented) return;
650
698
  let s = i(r);
@@ -654,41 +702,41 @@ function Gn(e, o, t = _(() => !0)) {
654
702
  }(e);
655
703
  for (let u of a) {
656
704
  if (u === null) continue;
657
- let v = u instanceof HTMLElement ? u : k(u);
705
+ let v = u instanceof HTMLElement ? u : M(u);
658
706
  if (v != null && v.contains(s) || r.composed && r.composedPath().includes(v)) return;
659
707
  }
660
- return !Fn(s, Rt.Loose) && s.tabIndex !== -1 && r.preventDefault(), o(r, s);
708
+ return !oo(s, Pt.Loose) && s.tabIndex !== -1 && r.preventDefault(), o(r, s);
661
709
  }
662
- let l = S(null);
663
- Re("pointerdown", (r) => {
710
+ let l = E(null);
711
+ Pe("pointerdown", (r) => {
664
712
  var i, s;
665
713
  t.value && (l.value = ((s = (i = r.composedPath) == null ? void 0 : i.call(r)) == null ? void 0 : s[0]) || r.target);
666
- }, !0), Re("mousedown", (r) => {
714
+ }, !0), Pe("mousedown", (r) => {
667
715
  var i, s;
668
716
  t.value && (l.value = ((s = (i = r.composedPath) == null ? void 0 : i.call(r)) == null ? void 0 : s[0]) || r.target);
669
- }, !0), Re("click", (r) => {
670
- kt() || l.value && (n(r, () => l.value), l.value = null);
671
- }, !0), Re("touchend", (r) => n(r, () => r.target instanceof HTMLElement ? r.target : null), !0), Wn("blur", (r) => n(r, () => window.document.activeElement instanceof HTMLIFrameElement ? window.document.activeElement : null), !0);
717
+ }, !0), Pe("click", (r) => {
718
+ Mt() || l.value && (n(r, () => l.value), l.value = null);
719
+ }, !0), Pe("touchend", (r) => n(r, () => r.target instanceof HTMLElement ? r.target : null), !0), ao("blur", (r) => n(r, () => window.document.activeElement instanceof HTMLIFrameElement ? window.document.activeElement : null), !0);
672
720
  }
673
721
  function ft(e, o) {
674
722
  if (e) return e;
675
723
  let t = o ?? "button";
676
724
  if (typeof t == "string" && t.toLowerCase() === "button") return "button";
677
725
  }
678
- function qn(e, o) {
679
- let t = S(ft(e.value.type, e.value.as));
680
- return de(() => {
726
+ function co(e, o) {
727
+ let t = E(ft(e.value.type, e.value.as));
728
+ return ve(() => {
681
729
  t.value = ft(e.value.type, e.value.as);
682
- }), le(() => {
730
+ }), ie(() => {
683
731
  var n;
684
- t.value || k(o) && k(o) instanceof HTMLButtonElement && !((n = k(o)) != null && n.hasAttribute("type")) && (t.value = "button");
732
+ t.value || M(o) && M(o) instanceof HTMLButtonElement && !((n = M(o)) != null && n.hasAttribute("type")) && (t.value = "button");
685
733
  }), t;
686
734
  }
687
735
  function vt(e) {
688
736
  return [e.screenX, e.screenY];
689
737
  }
690
- function Jn() {
691
- let e = S([-1, -1]);
738
+ function fo() {
739
+ let e = E([-1, -1]);
692
740
  return { wasMoved(o) {
693
741
  let t = vt(o);
694
742
  return e.value[0] === t[0] && e.value[1] === t[1] ? !1 : (e.value = t, !0);
@@ -696,58 +744,58 @@ function Jn() {
696
744
  e.value = vt(o);
697
745
  } };
698
746
  }
699
- function Kn({ container: e, accept: o, walk: t, enabled: n }) {
700
- le(() => {
747
+ function vo({ container: e, accept: o, walk: t, enabled: n }) {
748
+ ie(() => {
701
749
  let l = e.value;
702
750
  if (!l || n !== void 0 && !n.value) return;
703
- let r = tt(e);
751
+ let r = ot(e);
704
752
  if (!r) return;
705
753
  let i = Object.assign((a) => o(a), { acceptNode: o }), s = r.createTreeWalker(l, NodeFilter.SHOW_ELEMENT, i, !1);
706
754
  for (; s.nextNode(); ) t(s.currentNode);
707
755
  });
708
756
  }
709
- var Ee = ((e) => (e[e.None = 0] = "None", e[e.RenderStrategy = 1] = "RenderStrategy", e[e.Static = 2] = "Static", e))(Ee || {}), Yn = ((e) => (e[e.Unmount = 0] = "Unmount", e[e.Hidden = 1] = "Hidden", e))(Yn || {});
710
- function fe({ visible: e = !0, features: o = 0, ourProps: t, theirProps: n, ...l }) {
757
+ var Oe = ((e) => (e[e.None = 0] = "None", e[e.RenderStrategy = 1] = "RenderStrategy", e[e.Static = 2] = "Static", e))(Oe || {}), po = ((e) => (e[e.Unmount = 0] = "Unmount", e[e.Hidden = 1] = "Hidden", e))(po || {});
758
+ function pe({ visible: e = !0, features: o = 0, ourProps: t, theirProps: n, ...l }) {
711
759
  var r;
712
- let i = Vt(n, t), s = Object.assign(l, { props: i });
713
- if (e || o & 2 && i.static) return He(s);
760
+ let i = Rt(n, t), s = Object.assign(l, { props: i });
761
+ if (e || o & 2 && i.static) return Ge(s);
714
762
  if (o & 1) {
715
763
  let a = (r = i.unmount) == null || r ? 0 : 1;
716
- return te(a, { 0() {
764
+ return le(a, { 0() {
717
765
  return null;
718
766
  }, 1() {
719
- return He({ ...l, props: { ...i, hidden: !0, style: { display: "none" } } });
767
+ return Ge({ ...l, props: { ...i, hidden: !0, style: { display: "none" } } });
720
768
  } });
721
769
  }
722
- return He(s);
770
+ return Ge(s);
723
771
  }
724
- function He({ props: e, attrs: o, slots: t, slot: n, name: l }) {
772
+ function Ge({ props: e, attrs: o, slots: t, slot: n, name: l }) {
725
773
  var r, i;
726
774
  let { as: s, ...a } = je(e, ["unmount", "static"]), u = (r = t.default) == null ? void 0 : r.call(t, n), v = {};
727
775
  if (n) {
728
- let c = !1, b = [];
729
- for (let [m, w] of Object.entries(n)) typeof w == "boolean" && (c = !0), w === !0 && b.push(m);
730
- c && (v["data-headlessui-state"] = b.join(" "));
776
+ let c = !1, h = [];
777
+ for (let [m, p] of Object.entries(n)) typeof p == "boolean" && (c = !0), p === !0 && h.push(m);
778
+ c && (v["data-headlessui-state"] = h.join(" "));
731
779
  }
732
780
  if (s === "template") {
733
- if (u = Nt(u ?? []), Object.keys(a).length > 0 || Object.keys(o).length > 0) {
734
- let [c, ...b] = u ?? [];
735
- if (!Zn(c) || b.length > 0) throw new Error(['Passing props on "template"!', "", `The current component <${l} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(a).concat(Object.keys(o)).map(($) => $.trim()).filter(($, M, E) => E.indexOf($) === M).sort(($, M) => $.localeCompare(M)).map(($) => ` - ${$}`).join(`
781
+ if (u = kt(u ?? []), Object.keys(a).length > 0 || Object.keys(o).length > 0) {
782
+ let [c, ...h] = u ?? [];
783
+ if (!mo(c) || h.length > 0) throw new Error(['Passing props on "template"!', "", `The current component <${l} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(a).concat(Object.keys(o)).map(($) => $.trim()).filter(($, N, L) => L.indexOf($) === N).sort(($, N) => $.localeCompare(N)).map(($) => ` - ${$}`).join(`
736
784
  `), "", "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(($) => ` - ${$}`).join(`
737
785
  `)].join(`
738
786
  `));
739
- let m = Vt((i = c.props) != null ? i : {}, a, v), w = Ot(c, m, !0);
740
- for (let $ in m) $.startsWith("on") && (w.props || (w.props = {}), w.props[$] = m[$]);
741
- return w;
787
+ let m = Rt((i = c.props) != null ? i : {}, a, v), p = Et(c, m, !0);
788
+ for (let $ in m) $.startsWith("on") && (p.props || (p.props = {}), p.props[$] = m[$]);
789
+ return p;
742
790
  }
743
791
  return Array.isArray(u) && u.length === 1 ? u[0] : u;
744
792
  }
745
- return Oe(s, Object.assign({}, a, v), { default: () => u });
793
+ return Se(s, Object.assign({}, a, v), { default: () => u });
746
794
  }
747
- function Nt(e) {
748
- return e.flatMap((o) => o.type === X ? Nt(o.children) : [o]);
795
+ function kt(e) {
796
+ return e.flatMap((o) => o.type === W ? kt(o.children) : [o]);
749
797
  }
750
- function Vt(...e) {
798
+ function Rt(...e) {
751
799
  if (e.length === 0) return {};
752
800
  if (e.length === 1) return e[0];
753
801
  let o = {}, t = {};
@@ -762,7 +810,7 @@ function Vt(...e) {
762
810
  } });
763
811
  return o;
764
812
  }
765
- function Qn(e) {
813
+ function ho(e) {
766
814
  let o = Object.assign({}, e);
767
815
  for (let t in o) o[t] === void 0 && delete o[t];
768
816
  return o;
@@ -772,42 +820,42 @@ function je(e, o = []) {
772
820
  for (let n of o) n in t && delete t[n];
773
821
  return t;
774
822
  }
775
- function Zn(e) {
823
+ function mo(e) {
776
824
  return e == null ? !1 : typeof e.type == "string" || typeof e.type == "object" || typeof e.type == "function";
777
825
  }
778
- var Dt = ((e) => (e[e.None = 1] = "None", e[e.Focusable = 2] = "Focusable", e[e.Hidden = 4] = "Hidden", e))(Dt || {});
779
- let Xn = se({ name: "Hidden", props: { as: { type: [Object, String], default: "div" }, features: { type: Number, default: 1 } }, setup(e, { slots: o, attrs: t }) {
826
+ var Nt = ((e) => (e[e.None = 1] = "None", e[e.Focusable = 2] = "Focusable", e[e.Hidden = 4] = "Hidden", e))(Nt || {});
827
+ let go = ae({ name: "Hidden", props: { as: { type: [Object, String], default: "div" }, features: { type: Number, default: 1 } }, setup(e, { slots: o, attrs: t }) {
780
828
  return () => {
781
829
  var n;
782
830
  let { features: l, ...r } = e, i = { "aria-hidden": (l & 2) === 2 ? !0 : (n = r["aria-hidden"]) != null ? n : void 0, hidden: (l & 4) === 4 ? !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", ...(l & 4) === 4 && (l & 2) !== 2 && { display: "none" } } };
783
- return fe({ ourProps: i, theirProps: r, slot: {}, attrs: t, slots: o, name: "Hidden" });
831
+ return pe({ ourProps: i, theirProps: r, slot: {}, attrs: t, slots: o, name: "Hidden" });
784
832
  };
785
- } }), Lt = Symbol("Context");
786
- var Ie = ((e) => (e[e.Open = 1] = "Open", e[e.Closed = 2] = "Closed", e[e.Closing = 4] = "Closing", e[e.Opening = 8] = "Opening", e))(Ie || {});
787
- function eo() {
788
- return Ce(Lt, null);
833
+ } }), Dt = Symbol("Context");
834
+ var $e = ((e) => (e[e.Open = 1] = "Open", e[e.Closed = 2] = "Closed", e[e.Closing = 4] = "Closing", e[e.Opening = 8] = "Opening", e))($e || {});
835
+ function bo() {
836
+ return Le(Dt, null);
789
837
  }
790
- function to(e) {
791
- Qe(Lt, e);
838
+ function Co(e) {
839
+ et(Dt, e);
792
840
  }
793
- var W = ((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))(W || {}), Mt = ((e) => (e[e.Left = 0] = "Left", e[e.Right = 2] = "Right", e))(Mt || {});
794
- function no(e) {
841
+ var Z = ((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))(Z || {}), At = ((e) => (e[e.Left = 0] = "Left", e[e.Right = 2] = "Right", e))(At || {});
842
+ function _o(e) {
795
843
  function o() {
796
844
  document.readyState !== "loading" && (e(), document.removeEventListener("DOMContentLoaded", o));
797
845
  }
798
846
  typeof window < "u" && typeof document < "u" && (document.addEventListener("DOMContentLoaded", o), o());
799
847
  }
800
- let ie = [];
801
- no(() => {
848
+ let ce = [];
849
+ _o(() => {
802
850
  function e(o) {
803
- o.target instanceof HTMLElement && o.target !== document.body && ie[0] !== o.target && (ie.unshift(o.target), ie = ie.filter((t) => t != null && t.isConnected), ie.splice(10));
851
+ o.target instanceof HTMLElement && o.target !== document.body && ce[0] !== o.target && (ce.unshift(o.target), ce = ce.filter((t) => t != null && t.isConnected), ce.splice(10));
804
852
  }
805
853
  window.addEventListener("click", e, { capture: !0 }), window.addEventListener("mousedown", e, { capture: !0 }), window.addEventListener("focus", e, { capture: !0 }), document.body.addEventListener("click", e, { capture: !0 }), document.body.addEventListener("mousedown", e, { capture: !0 }), document.body.addEventListener("focus", e, { capture: !0 });
806
854
  });
807
- function oo(e) {
855
+ function xo(e) {
808
856
  throw new Error("Unexpected object: " + e);
809
857
  }
810
- var B = ((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))(B || {});
858
+ var z = ((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))(z || {});
811
859
  function pt(e, o) {
812
860
  let t = o.resolveItems();
813
861
  if (t.length <= 0) return null;
@@ -837,94 +885,94 @@ function pt(e, o) {
837
885
  case 5:
838
886
  return null;
839
887
  default:
840
- oo(e);
888
+ xo(e);
841
889
  }
842
890
  }
843
- function At(e = {}, o = null, t = []) {
844
- for (let [n, l] of Object.entries(e)) Ft(t, jt(o, n), l);
891
+ function Ft(e = {}, o = null, t = []) {
892
+ for (let [n, l] of Object.entries(e)) Bt(t, jt(o, n), l);
845
893
  return t;
846
894
  }
847
895
  function jt(e, o) {
848
896
  return e ? e + "[" + o + "]" : o;
849
897
  }
850
- function Ft(e, o, t) {
851
- if (Array.isArray(t)) for (let [n, l] of t.entries()) Ft(e, jt(o, n.toString()), l);
852
- else t instanceof Date ? e.push([o, t.toISOString()]) : typeof t == "boolean" ? e.push([o, t ? "1" : "0"]) : typeof t == "string" ? e.push([o, t]) : typeof t == "number" ? e.push([o, `${t}`]) : t == null ? e.push([o, ""]) : At(t, o, e);
898
+ function Bt(e, o, t) {
899
+ if (Array.isArray(t)) for (let [n, l] of t.entries()) Bt(e, jt(o, n.toString()), l);
900
+ else t instanceof Date ? e.push([o, t.toISOString()]) : typeof t == "boolean" ? e.push([o, t ? "1" : "0"]) : typeof t == "string" ? e.push([o, t]) : typeof t == "number" ? e.push([o, `${t}`]) : t == null ? e.push([o, ""]) : Ft(t, o, e);
853
901
  }
854
- function lo(e, o) {
902
+ function yo(e, o) {
855
903
  return e === o;
856
904
  }
857
- var so = ((e) => (e[e.Open = 0] = "Open", e[e.Closed = 1] = "Closed", e))(so || {}), ro = ((e) => (e[e.Single = 0] = "Single", e[e.Multi = 1] = "Multi", e))(ro || {}), io = ((e) => (e[e.Pointer = 0] = "Pointer", e[e.Focus = 1] = "Focus", e[e.Other = 2] = "Other", e))(io || {});
858
- let zt = Symbol("ComboboxContext");
859
- function ve(e) {
860
- let o = Ce(zt, null);
905
+ var wo = ((e) => (e[e.Open = 0] = "Open", e[e.Closed = 1] = "Closed", e))(wo || {}), Eo = ((e) => (e[e.Single = 0] = "Single", e[e.Multi = 1] = "Multi", e))(Eo || {}), So = ((e) => (e[e.Pointer = 0] = "Pointer", e[e.Focus = 1] = "Focus", e[e.Other = 2] = "Other", e))(So || {});
906
+ let Ht = Symbol("ComboboxContext");
907
+ function he(e) {
908
+ let o = Le(Ht, null);
861
909
  if (o === null) {
862
910
  let t = new Error(`<${e} /> is missing a parent <Combobox /> component.`);
863
- throw Error.captureStackTrace && Error.captureStackTrace(t, ve), t;
911
+ throw Error.captureStackTrace && Error.captureStackTrace(t, he), t;
864
912
  }
865
913
  return o;
866
914
  }
867
- let Bt = Symbol("VirtualContext"), ao = se({ name: "VirtualProvider", setup(e, { slots: o }) {
868
- let t = ve("VirtualProvider"), n = _(() => {
869
- let s = k(t.optionsRef);
915
+ let zt = Symbol("VirtualContext"), Oo = ae({ name: "VirtualProvider", setup(e, { slots: o }) {
916
+ let t = he("VirtualProvider"), n = y(() => {
917
+ let s = M(t.optionsRef);
870
918
  if (!s) return { start: 0, end: 0 };
871
919
  let a = window.getComputedStyle(s);
872
920
  return { start: parseFloat(a.paddingBlockStart || a.paddingTop), end: parseFloat(a.paddingBlockEnd || a.paddingBottom) };
873
- }), l = $n(_(() => ({ scrollPaddingStart: n.value.start, scrollPaddingEnd: n.value.end, count: t.virtual.value.options.length, estimateSize() {
921
+ }), l = Un(y(() => ({ scrollPaddingStart: n.value.start, scrollPaddingEnd: n.value.end, count: t.virtual.value.options.length, estimateSize() {
874
922
  return 40;
875
923
  }, getScrollElement() {
876
- return k(t.optionsRef);
877
- }, overscan: 12 }))), r = _(() => {
924
+ return M(t.optionsRef);
925
+ }, overscan: 12 }))), r = y(() => {
878
926
  var s;
879
927
  return (s = t.virtual.value) == null ? void 0 : s.options;
880
- }), i = S(0);
881
- return j([r], () => {
928
+ }), i = E(0);
929
+ return F([r], () => {
882
930
  i.value += 1;
883
- }), Qe(Bt, t.virtual.value ? l : null), () => [Oe("div", { style: { position: "relative", width: "100%", height: `${l.value.getTotalSize()}px` }, ref: (s) => {
931
+ }), et(zt, t.virtual.value ? l : null), () => [Se("div", { style: { position: "relative", width: "100%", height: `${l.value.getTotalSize()}px` }, ref: (s) => {
884
932
  if (s) {
885
933
  if (typeof process < "u" && process.env.JEST_WORKER_ID !== void 0 || t.activationTrigger.value === 0) return;
886
934
  t.activeOptionIndex.value !== null && t.virtual.value.options.length > t.activeOptionIndex.value && l.value.scrollToIndex(t.activeOptionIndex.value);
887
935
  }
888
- } }, l.value.getVirtualItems().map((s) => Ot(o.default({ option: t.virtual.value.options[s.index], open: t.comboboxState.value === 0 })[0], { key: `${i.value}-${s.index}`, "data-index": s.index, "aria-setsize": t.virtual.value.options.length, "aria-posinset": s.index + 1, style: { position: "absolute", top: 0, left: 0, transform: `translateY(${s.start}px)`, overflowAnchor: "none" } })))];
889
- } }), uo = se({ name: "Combobox", emits: { "update:modelValue": (e) => !0 }, props: { as: { type: [Object, String], default: "template" }, disabled: { type: [Boolean], default: !1 }, by: { type: [String, Function], nullable: !0, default: null }, 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 }, nullable: { type: Boolean, default: !1 }, multiple: { type: [Boolean], default: !1 }, immediate: { type: [Boolean], default: !1 }, virtual: { type: Object, default: null } }, inheritAttrs: !1, setup(e, { slots: o, attrs: t, emit: n }) {
890
- let l = S(1), r = S(null), i = S(null), s = S(null), a = S(null), u = S({ static: !1, hold: !1 }), v = S([]), c = S(null), b = S(2), m = S(!1);
891
- function w(d = (f) => f) {
892
- let f = c.value !== null ? v.value[c.value] : null, y = d(v.value.slice()), x = y.length > 0 && y[0].dataRef.order.value !== null ? y.sort((L, G) => L.dataRef.order.value - G.dataRef.order.value) : Bn(y, (L) => k(L.dataRef.domRef)), N = f ? x.indexOf(f) : null;
893
- return N === -1 && (N = null), { options: x, activeOptionIndex: N };
894
- }
895
- let $ = _(() => e.multiple ? 1 : 0), M = _(() => e.nullable), [E, O] = Cn(_(() => e.modelValue), (d) => n("update:modelValue", d), _(() => e.defaultValue)), D = _(() => E.value === void 0 ? te($.value, { 1: [], 0: void 0 }) : E.value), A = null, g = null;
896
- function T(d) {
897
- return te($.value, { 0() {
898
- return O == null ? void 0 : O(d);
936
+ } }, l.value.getVirtualItems().map((s) => Et(o.default({ option: t.virtual.value.options[s.index], open: t.comboboxState.value === 0 })[0], { key: `${i.value}-${s.index}`, "data-index": s.index, "aria-setsize": t.virtual.value.options.length, "aria-posinset": s.index + 1, style: { position: "absolute", top: 0, left: 0, transform: `translateY(${s.start}px)`, overflowAnchor: "none" } })))];
937
+ } }), $o = ae({ name: "Combobox", emits: { "update:modelValue": (e) => !0 }, props: { as: { type: [Object, String], default: "template" }, disabled: { type: [Boolean], default: !1 }, by: { type: [String, Function], nullable: !0, default: null }, 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 }, nullable: { type: Boolean, default: !1 }, multiple: { type: [Boolean], default: !1 }, immediate: { type: [Boolean], default: !1 }, virtual: { type: Object, default: null } }, inheritAttrs: !1, setup(e, { slots: o, attrs: t, emit: n }) {
938
+ let l = E(1), r = E(null), i = E(null), s = E(null), a = E(null), u = E({ static: !1, hold: !1 }), v = E([]), c = E(null), h = E(2), m = E(!1);
939
+ function p(d = (f) => f) {
940
+ let f = c.value !== null ? v.value[c.value] : null, x = d(v.value.slice()), S = x.length > 0 && x[0].dataRef.order.value !== null ? x.sort((D, G) => D.dataRef.order.value - G.dataRef.order.value) : so(x, (D) => M(D.dataRef.domRef)), k = f ? S.indexOf(f) : null;
941
+ return k === -1 && (k = null), { options: S, activeOptionIndex: k };
942
+ }
943
+ let $ = y(() => e.multiple ? 1 : 0), N = y(() => e.nullable), [L, I] = Zn(y(() => e.modelValue), (d) => n("update:modelValue", d), y(() => e.defaultValue)), R = y(() => L.value === void 0 ? le($.value, { 1: [], 0: void 0 }) : L.value), A = null, _ = null;
944
+ function P(d) {
945
+ return le($.value, { 0() {
946
+ return I == null ? void 0 : I(d);
899
947
  }, 1: () => {
900
- let f = K(p.value.value).slice(), y = K(d), x = f.findIndex((N) => p.compare(y, K(N)));
901
- return x === -1 ? f.push(y) : f.splice(x, 1), O == null ? void 0 : O(f);
948
+ let f = K(b.value.value).slice(), x = K(d), S = f.findIndex((k) => b.compare(x, K(k)));
949
+ return S === -1 ? f.push(x) : f.splice(S, 1), I == null ? void 0 : I(f);
902
950
  } });
903
951
  }
904
- let h = _(() => {
952
+ let C = y(() => {
905
953
  });
906
- j([h], ([d], [f]) => {
907
- if (p.virtual.value && d && f && c.value !== null) {
908
- let y = d.indexOf(f[c.value]);
909
- y !== -1 ? c.value = y : c.value = null;
954
+ F([C], ([d], [f]) => {
955
+ if (b.virtual.value && d && f && c.value !== null) {
956
+ let x = d.indexOf(f[c.value]);
957
+ x !== -1 ? c.value = x : c.value = null;
910
958
  }
911
959
  });
912
- let p = { comboboxState: l, value: D, mode: $, compare(d, f) {
960
+ let b = { comboboxState: l, value: R, mode: $, compare(d, f) {
913
961
  if (typeof e.by == "string") {
914
- let y = e.by;
915
- return (d == null ? void 0 : d[y]) === (f == null ? void 0 : f[y]);
962
+ let x = e.by;
963
+ return (d == null ? void 0 : d[x]) === (f == null ? void 0 : f[x]);
916
964
  }
917
- return e.by === null ? lo(d, f) : e.by(d, f);
965
+ return e.by === null ? yo(d, f) : e.by(d, f);
918
966
  }, calculateIndex(d) {
919
- return p.virtual.value ? e.by === null ? p.virtual.value.options.indexOf(d) : p.virtual.value.options.findIndex((f) => p.compare(f, d)) : v.value.findIndex((f) => p.compare(f.dataRef.value, d));
920
- }, defaultValue: _(() => e.defaultValue), nullable: M, immediate: _(() => !1), virtual: _(() => null), inputRef: i, labelRef: r, buttonRef: s, optionsRef: a, disabled: _(() => e.disabled), options: v, change(d) {
921
- O(d);
922
- }, activeOptionIndex: _(() => {
923
- if (m.value && c.value === null && (p.virtual.value ? p.virtual.value.options.length > 0 : v.value.length > 0)) {
924
- if (p.virtual.value) {
925
- let f = p.virtual.value.options.findIndex((y) => {
926
- var x;
927
- return !((x = p.virtual.value) != null && x.disabled(y));
967
+ return b.virtual.value ? e.by === null ? b.virtual.value.options.indexOf(d) : b.virtual.value.options.findIndex((f) => b.compare(f, d)) : v.value.findIndex((f) => b.compare(f.dataRef.value, d));
968
+ }, defaultValue: y(() => e.defaultValue), nullable: N, immediate: y(() => !1), virtual: y(() => null), inputRef: i, labelRef: r, buttonRef: s, optionsRef: a, disabled: y(() => e.disabled), options: v, change(d) {
969
+ I(d);
970
+ }, activeOptionIndex: y(() => {
971
+ if (m.value && c.value === null && (b.virtual.value ? b.virtual.value.options.length > 0 : v.value.length > 0)) {
972
+ if (b.virtual.value) {
973
+ let f = b.virtual.value.options.findIndex((x) => {
974
+ var S;
975
+ return !((S = b.virtual.value) != null && S.disabled(x));
928
976
  });
929
977
  if (f !== -1) return f;
930
978
  }
@@ -932,274 +980,274 @@ let Bt = Symbol("VirtualContext"), ao = se({ name: "VirtualProvider", setup(e, {
932
980
  if (d !== -1) return d;
933
981
  }
934
982
  return c.value;
935
- }), activationTrigger: b, optionsPropsRef: u, closeCombobox() {
983
+ }), activationTrigger: h, optionsPropsRef: u, closeCombobox() {
936
984
  m.value = !1, !e.disabled && l.value !== 1 && (l.value = 1, c.value = null);
937
985
  }, openCombobox() {
938
986
  if (m.value = !0, !e.disabled && l.value !== 0) {
939
- if (p.value.value) {
940
- let d = p.calculateIndex(p.value.value);
987
+ if (b.value.value) {
988
+ let d = b.calculateIndex(b.value.value);
941
989
  d !== -1 && (c.value = d);
942
990
  }
943
991
  l.value = 0;
944
992
  }
945
993
  }, setActivationTrigger(d) {
946
- b.value = d;
947
- }, goToOption(d, f, y) {
994
+ h.value = d;
995
+ }, goToOption(d, f, x) {
948
996
  m.value = !1, A !== null && cancelAnimationFrame(A), A = requestAnimationFrame(() => {
949
997
  if (e.disabled || a.value && !u.value.static && l.value === 1) return;
950
- if (p.virtual.value) {
951
- c.value = d === B.Specific ? f : pt({ focus: d }, { resolveItems: () => p.virtual.value.options, resolveActiveIndex: () => {
952
- var L, G;
953
- return (G = (L = p.activeOptionIndex.value) != null ? L : p.virtual.value.options.findIndex((q) => {
954
- var F;
955
- return !((F = p.virtual.value) != null && F.disabled(q));
998
+ if (b.virtual.value) {
999
+ c.value = d === z.Specific ? f : pt({ focus: d }, { resolveItems: () => b.virtual.value.options, resolveActiveIndex: () => {
1000
+ var D, G;
1001
+ return (G = (D = b.activeOptionIndex.value) != null ? D : b.virtual.value.options.findIndex((q) => {
1002
+ var j;
1003
+ return !((j = b.virtual.value) != null && j.disabled(q));
956
1004
  })) != null ? G : null;
957
- }, resolveDisabled: (L) => p.virtual.value.disabled(L), resolveId() {
1005
+ }, resolveDisabled: (D) => b.virtual.value.disabled(D), resolveId() {
958
1006
  throw new Error("Function not implemented.");
959
- } }), b.value = y ?? 2;
1007
+ } }), h.value = x ?? 2;
960
1008
  return;
961
1009
  }
962
- let x = w();
963
- if (x.activeOptionIndex === null) {
964
- let L = x.options.findIndex((G) => !G.dataRef.disabled);
965
- L !== -1 && (x.activeOptionIndex = L);
1010
+ let S = p();
1011
+ if (S.activeOptionIndex === null) {
1012
+ let D = S.options.findIndex((G) => !G.dataRef.disabled);
1013
+ D !== -1 && (S.activeOptionIndex = D);
966
1014
  }
967
- let N = d === B.Specific ? f : pt({ focus: d }, { resolveItems: () => x.options, resolveActiveIndex: () => x.activeOptionIndex, resolveId: (L) => L.id, resolveDisabled: (L) => L.dataRef.disabled });
968
- c.value = N, b.value = y ?? 2, v.value = x.options;
1015
+ let k = d === z.Specific ? f : pt({ focus: d }, { resolveItems: () => S.options, resolveActiveIndex: () => S.activeOptionIndex, resolveId: (D) => D.id, resolveDisabled: (D) => D.dataRef.disabled });
1016
+ c.value = k, h.value = x ?? 2, v.value = S.options;
969
1017
  });
970
1018
  }, selectOption(d) {
971
- let f = v.value.find((x) => x.id === d);
1019
+ let f = v.value.find((S) => S.id === d);
972
1020
  if (!f) return;
973
- let { dataRef: y } = f;
974
- T(y.value);
1021
+ let { dataRef: x } = f;
1022
+ P(x.value);
975
1023
  }, selectActiveOption() {
976
- if (p.activeOptionIndex.value !== null) {
977
- if (p.virtual.value) T(p.virtual.value.options[p.activeOptionIndex.value]);
1024
+ if (b.activeOptionIndex.value !== null) {
1025
+ if (b.virtual.value) P(b.virtual.value.options[b.activeOptionIndex.value]);
978
1026
  else {
979
- let { dataRef: d } = v.value[p.activeOptionIndex.value];
980
- T(d.value);
1027
+ let { dataRef: d } = v.value[b.activeOptionIndex.value];
1028
+ P(d.value);
981
1029
  }
982
- p.goToOption(B.Specific, p.activeOptionIndex.value);
1030
+ b.goToOption(z.Specific, b.activeOptionIndex.value);
983
1031
  }
984
1032
  }, registerOption(d, f) {
985
- let y = Et({ id: d, dataRef: f });
986
- if (p.virtual.value) {
987
- v.value.push(y);
1033
+ let x = St({ id: d, dataRef: f });
1034
+ if (b.virtual.value) {
1035
+ v.value.push(x);
988
1036
  return;
989
1037
  }
990
- g && cancelAnimationFrame(g);
991
- let x = w((N) => (N.push(y), N));
992
- c.value === null && p.isSelected(f.value.value) && (x.activeOptionIndex = x.options.indexOf(y)), v.value = x.options, c.value = x.activeOptionIndex, b.value = 2, x.options.some((N) => !k(N.dataRef.domRef)) && (g = requestAnimationFrame(() => {
993
- let N = w();
994
- v.value = N.options, c.value = N.activeOptionIndex;
1038
+ _ && cancelAnimationFrame(_);
1039
+ let S = p((k) => (k.push(x), k));
1040
+ c.value === null && b.isSelected(f.value.value) && (S.activeOptionIndex = S.options.indexOf(x)), v.value = S.options, c.value = S.activeOptionIndex, h.value = 2, S.options.some((k) => !M(k.dataRef.domRef)) && (_ = requestAnimationFrame(() => {
1041
+ let k = p();
1042
+ v.value = k.options, c.value = k.activeOptionIndex;
995
1043
  }));
996
1044
  }, unregisterOption(d, f) {
997
- if (A !== null && cancelAnimationFrame(A), f && (m.value = !0), p.virtual.value) {
998
- v.value = v.value.filter((x) => x.id !== d);
1045
+ if (A !== null && cancelAnimationFrame(A), f && (m.value = !0), b.virtual.value) {
1046
+ v.value = v.value.filter((S) => S.id !== d);
999
1047
  return;
1000
1048
  }
1001
- let y = w((x) => {
1002
- let N = x.findIndex((L) => L.id === d);
1003
- return N !== -1 && x.splice(N, 1), x;
1049
+ let x = p((S) => {
1050
+ let k = S.findIndex((D) => D.id === d);
1051
+ return k !== -1 && S.splice(k, 1), S;
1004
1052
  });
1005
- v.value = y.options, c.value = y.activeOptionIndex, b.value = 2;
1053
+ v.value = x.options, c.value = x.activeOptionIndex, h.value = 2;
1006
1054
  }, isSelected(d) {
1007
- return te($.value, { 0: () => p.compare(K(p.value.value), K(d)), 1: () => K(p.value.value).some((f) => p.compare(K(f), K(d))) });
1055
+ return le($.value, { 0: () => b.compare(K(b.value.value), K(d)), 1: () => K(b.value.value).some((f) => b.compare(K(f), K(d))) });
1008
1056
  }, isActive(d) {
1009
- return c.value === p.calculateIndex(d);
1057
+ return c.value === b.calculateIndex(d);
1010
1058
  } };
1011
- Gn([i, s, a], () => p.closeCombobox(), _(() => l.value === 0)), Qe(zt, p), to(_(() => te(l.value, { 0: Ie.Open, 1: Ie.Closed })));
1012
- let C = _(() => {
1059
+ uo([i, s, a], () => b.closeCombobox(), y(() => l.value === 0)), et(Ht, b), Co(y(() => le(l.value, { 0: $e.Open, 1: $e.Closed })));
1060
+ let V = y(() => {
1013
1061
  var d;
1014
- return (d = k(i)) == null ? void 0 : d.closest("form");
1062
+ return (d = M(i)) == null ? void 0 : d.closest("form");
1015
1063
  });
1016
- return de(() => {
1017
- j([C], () => {
1018
- if (!C.value || e.defaultValue === void 0) return;
1064
+ return ve(() => {
1065
+ F([V], () => {
1066
+ if (!V.value || e.defaultValue === void 0) return;
1019
1067
  function d() {
1020
- p.change(e.defaultValue);
1068
+ b.change(e.defaultValue);
1021
1069
  }
1022
- return C.value.addEventListener("reset", d), () => {
1070
+ return V.value.addEventListener("reset", d), () => {
1023
1071
  var f;
1024
- (f = C.value) == null || f.removeEventListener("reset", d);
1072
+ (f = V.value) == null || f.removeEventListener("reset", d);
1025
1073
  };
1026
1074
  }, { immediate: !0 });
1027
1075
  }), () => {
1028
- var d, f, y;
1029
- let { name: x, disabled: N, form: L, ...G } = e, q = { open: l.value === 0, disabled: N, activeIndex: p.activeOptionIndex.value, activeOption: p.activeOptionIndex.value === null ? null : p.virtual.value ? p.virtual.value.options[(d = p.activeOptionIndex.value) != null ? d : 0] : (y = (f = p.options.value[p.activeOptionIndex.value]) == null ? void 0 : f.dataRef.value) != null ? y : null, value: D.value };
1030
- return Oe(X, [...x != null && D.value != null ? At({ [x]: D.value }).map(([F, rn]) => Oe(Xn, Qn({ features: Dt.Hidden, key: F, as: "input", type: "hidden", hidden: !0, readOnly: !0, form: L, disabled: N, name: F, value: rn }))) : [], fe({ theirProps: { ...t, ...je(G, ["by", "defaultValue", "immediate", "modelValue", "multiple", "nullable", "onUpdate:modelValue", "virtual"]) }, ourProps: {}, slot: q, slots: o, attrs: t, name: "Combobox" })]);
1076
+ var d, f, x;
1077
+ let { name: S, disabled: k, form: D, ...G } = e, q = { open: l.value === 0, disabled: k, activeIndex: b.activeOptionIndex.value, activeOption: b.activeOptionIndex.value === null ? null : b.virtual.value ? b.virtual.value.options[(d = b.activeOptionIndex.value) != null ? d : 0] : (x = (f = b.options.value[b.activeOptionIndex.value]) == null ? void 0 : f.dataRef.value) != null ? x : null, value: R.value };
1078
+ return Se(W, [...S != null && R.value != null ? Ft({ [S]: R.value }).map(([j, un]) => Se(go, ho({ features: Nt.Hidden, key: j, as: "input", type: "hidden", hidden: !0, readOnly: !0, form: D, disabled: k, name: j, value: un }))) : [], pe({ theirProps: { ...t, ...je(G, ["by", "defaultValue", "immediate", "modelValue", "multiple", "nullable", "onUpdate:modelValue", "virtual"]) }, ourProps: {}, slot: q, slots: o, attrs: t, name: "Combobox" })]);
1031
1079
  };
1032
1080
  } });
1033
- se({ name: "ComboboxLabel", props: { as: { type: [Object, String], default: "label" }, id: { type: String, default: null } }, setup(e, { attrs: o, slots: t }) {
1081
+ ae({ name: "ComboboxLabel", props: { as: { type: [Object, String], default: "label" }, id: { type: String, default: null } }, setup(e, { attrs: o, slots: t }) {
1034
1082
  var n;
1035
- let l = (n = e.id) != null ? n : `headlessui-combobox-label-${Te()}`, r = ve("ComboboxLabel");
1083
+ let l = (n = e.id) != null ? n : `headlessui-combobox-label-${Te()}`, r = he("ComboboxLabel");
1036
1084
  function i() {
1037
1085
  var s;
1038
- (s = k(r.inputRef)) == null || s.focus({ preventScroll: !0 });
1086
+ (s = M(r.inputRef)) == null || s.focus({ preventScroll: !0 });
1039
1087
  }
1040
1088
  return () => {
1041
1089
  let s = { open: r.comboboxState.value === 0, disabled: r.disabled.value }, { ...a } = e, u = { id: l, ref: r.labelRef, onClick: i };
1042
- return fe({ ourProps: u, theirProps: a, slot: s, attrs: o, slots: t, name: "ComboboxLabel" });
1090
+ return pe({ ourProps: u, theirProps: a, slot: s, attrs: o, slots: t, name: "ComboboxLabel" });
1043
1091
  };
1044
1092
  } });
1045
- let co = se({ name: "ComboboxButton", props: { as: { type: [Object, String], default: "button" }, id: { type: String, default: null } }, setup(e, { attrs: o, slots: t, expose: n }) {
1093
+ let Io = ae({ name: "ComboboxButton", props: { as: { type: [Object, String], default: "button" }, id: { type: String, default: null } }, setup(e, { attrs: o, slots: t, expose: n }) {
1046
1094
  var l;
1047
- let r = (l = e.id) != null ? l : `headlessui-combobox-button-${Te()}`, i = ve("ComboboxButton");
1095
+ let r = (l = e.id) != null ? l : `headlessui-combobox-button-${Te()}`, i = he("ComboboxButton");
1048
1096
  n({ el: i.buttonRef, $el: i.buttonRef });
1049
1097
  function s(v) {
1050
- i.disabled.value || (i.comboboxState.value === 0 ? i.closeCombobox() : (v.preventDefault(), i.openCombobox()), Q(() => {
1098
+ i.disabled.value || (i.comboboxState.value === 0 ? i.closeCombobox() : (v.preventDefault(), i.openCombobox()), te(() => {
1051
1099
  var c;
1052
- return (c = k(i.inputRef)) == null ? void 0 : c.focus({ preventScroll: !0 });
1100
+ return (c = M(i.inputRef)) == null ? void 0 : c.focus({ preventScroll: !0 });
1053
1101
  }));
1054
1102
  }
1055
1103
  function a(v) {
1056
1104
  switch (v.key) {
1057
- case W.ArrowDown:
1058
- v.preventDefault(), v.stopPropagation(), i.comboboxState.value === 1 && i.openCombobox(), Q(() => {
1105
+ case Z.ArrowDown:
1106
+ v.preventDefault(), v.stopPropagation(), i.comboboxState.value === 1 && i.openCombobox(), te(() => {
1059
1107
  var c;
1060
1108
  return (c = i.inputRef.value) == null ? void 0 : c.focus({ preventScroll: !0 });
1061
1109
  });
1062
1110
  return;
1063
- case W.ArrowUp:
1064
- v.preventDefault(), v.stopPropagation(), i.comboboxState.value === 1 && (i.openCombobox(), Q(() => {
1065
- i.value.value || i.goToOption(B.Last);
1066
- })), Q(() => {
1111
+ case Z.ArrowUp:
1112
+ v.preventDefault(), v.stopPropagation(), i.comboboxState.value === 1 && (i.openCombobox(), te(() => {
1113
+ i.value.value || i.goToOption(z.Last);
1114
+ })), te(() => {
1067
1115
  var c;
1068
1116
  return (c = i.inputRef.value) == null ? void 0 : c.focus({ preventScroll: !0 });
1069
1117
  });
1070
1118
  return;
1071
- case W.Escape:
1119
+ case Z.Escape:
1072
1120
  if (i.comboboxState.value !== 0) return;
1073
- v.preventDefault(), i.optionsRef.value && !i.optionsPropsRef.value.static && v.stopPropagation(), i.closeCombobox(), Q(() => {
1121
+ v.preventDefault(), i.optionsRef.value && !i.optionsPropsRef.value.static && v.stopPropagation(), i.closeCombobox(), te(() => {
1074
1122
  var c;
1075
1123
  return (c = i.inputRef.value) == null ? void 0 : c.focus({ preventScroll: !0 });
1076
1124
  });
1077
1125
  return;
1078
1126
  }
1079
1127
  }
1080
- let u = qn(_(() => ({ as: e.as, type: o.type })), i.buttonRef);
1128
+ let u = co(y(() => ({ as: e.as, type: o.type })), i.buttonRef);
1081
1129
  return () => {
1082
1130
  var v, c;
1083
- let b = { open: i.comboboxState.value === 0, disabled: i.disabled.value, value: i.value.value }, { ...m } = e, w = { ref: i.buttonRef, id: r, type: u.value, tabindex: "-1", "aria-haspopup": "listbox", "aria-controls": (v = k(i.optionsRef)) == null ? void 0 : v.id, "aria-expanded": i.comboboxState.value === 0, "aria-labelledby": i.labelRef.value ? [(c = k(i.labelRef)) == null ? void 0 : c.id, r].join(" ") : void 0, disabled: i.disabled.value === !0 ? !0 : void 0, onKeydown: a, onClick: s };
1084
- return fe({ ourProps: w, theirProps: m, slot: b, attrs: o, slots: t, name: "ComboboxButton" });
1131
+ let h = { open: i.comboboxState.value === 0, disabled: i.disabled.value, value: i.value.value }, { ...m } = e, p = { ref: i.buttonRef, id: r, type: u.value, tabindex: "-1", "aria-haspopup": "listbox", "aria-controls": (v = M(i.optionsRef)) == null ? void 0 : v.id, "aria-expanded": i.comboboxState.value === 0, "aria-labelledby": i.labelRef.value ? [(c = M(i.labelRef)) == null ? void 0 : c.id, r].join(" ") : void 0, disabled: i.disabled.value === !0 ? !0 : void 0, onKeydown: a, onClick: s };
1132
+ return pe({ ourProps: p, theirProps: m, slot: h, attrs: o, slots: t, name: "ComboboxButton" });
1085
1133
  };
1086
- } }), fo = se({ name: "ComboboxInput", props: { as: { type: [Object, String], default: "input" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, displayValue: { type: Function }, defaultValue: { type: String, default: void 0 }, id: { type: String, default: null } }, emits: { change: (e) => !0 }, setup(e, { emit: o, attrs: t, slots: n, expose: l }) {
1134
+ } }), Lo = ae({ name: "ComboboxInput", props: { as: { type: [Object, String], default: "input" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, displayValue: { type: Function }, defaultValue: { type: String, default: void 0 }, id: { type: String, default: null } }, emits: { change: (e) => !0 }, setup(e, { emit: o, attrs: t, slots: n, expose: l }) {
1087
1135
  var r;
1088
- let i = (r = e.id) != null ? r : `headlessui-combobox-input-${Te()}`, s = ve("ComboboxInput"), a = _(() => tt(k(s.inputRef))), u = { value: !1 };
1136
+ let i = (r = e.id) != null ? r : `headlessui-combobox-input-${Te()}`, s = he("ComboboxInput"), a = y(() => ot(M(s.inputRef))), u = { value: !1 };
1089
1137
  l({ el: s.inputRef, $el: s.inputRef });
1090
1138
  function v() {
1091
1139
  s.change(null);
1092
- let g = k(s.optionsRef);
1093
- g && (g.scrollTop = 0), s.goToOption(B.Nothing);
1140
+ let _ = M(s.optionsRef);
1141
+ _ && (_.scrollTop = 0), s.goToOption(z.Nothing);
1094
1142
  }
1095
- let c = _(() => {
1096
- var g;
1097
- let T = s.value.value;
1098
- return k(s.inputRef) ? typeof e.displayValue < "u" && T !== void 0 ? (g = e.displayValue(T)) != null ? g : "" : typeof T == "string" ? T : "" : "";
1143
+ let c = y(() => {
1144
+ var _;
1145
+ let P = s.value.value;
1146
+ return M(s.inputRef) ? typeof e.displayValue < "u" && P !== void 0 ? (_ = e.displayValue(P)) != null ? _ : "" : typeof P == "string" ? P : "" : "";
1099
1147
  });
1100
- de(() => {
1101
- j([c, s.comboboxState, a], ([g, T], [h, p]) => {
1148
+ ve(() => {
1149
+ F([c, s.comboboxState, a], ([_, P], [C, b]) => {
1102
1150
  if (u.value) return;
1103
- let C = k(s.inputRef);
1104
- C && ((p === 0 && T === 1 || g !== h) && (C.value = g), requestAnimationFrame(() => {
1151
+ let V = M(s.inputRef);
1152
+ V && ((b === 0 && P === 1 || _ !== C) && (V.value = _), requestAnimationFrame(() => {
1105
1153
  var d;
1106
- if (u.value || !C || ((d = a.value) == null ? void 0 : d.activeElement) !== C) return;
1107
- let { selectionStart: f, selectionEnd: y } = C;
1108
- Math.abs((y ?? 0) - (f ?? 0)) === 0 && f === 0 && C.setSelectionRange(C.value.length, C.value.length);
1154
+ if (u.value || !V || ((d = a.value) == null ? void 0 : d.activeElement) !== V) return;
1155
+ let { selectionStart: f, selectionEnd: x } = V;
1156
+ Math.abs((x ?? 0) - (f ?? 0)) === 0 && f === 0 && V.setSelectionRange(V.value.length, V.value.length);
1109
1157
  }));
1110
- }, { immediate: !0 }), j([s.comboboxState], ([g], [T]) => {
1111
- if (g === 0 && T === 1) {
1158
+ }, { immediate: !0 }), F([s.comboboxState], ([_], [P]) => {
1159
+ if (_ === 0 && P === 1) {
1112
1160
  if (u.value) return;
1113
- let h = k(s.inputRef);
1114
- if (!h) return;
1115
- let p = h.value, { selectionStart: C, selectionEnd: d, selectionDirection: f } = h;
1116
- h.value = "", h.value = p, f !== null ? h.setSelectionRange(C, d, f) : h.setSelectionRange(C, d);
1161
+ let C = M(s.inputRef);
1162
+ if (!C) return;
1163
+ let b = C.value, { selectionStart: V, selectionEnd: d, selectionDirection: f } = C;
1164
+ C.value = "", C.value = b, f !== null ? C.setSelectionRange(V, d, f) : C.setSelectionRange(V, d);
1117
1165
  }
1118
1166
  });
1119
1167
  });
1120
- let b = S(!1);
1168
+ let h = E(!1);
1121
1169
  function m() {
1122
- b.value = !0;
1170
+ h.value = !0;
1123
1171
  }
1124
- function w() {
1125
- Le().nextFrame(() => {
1126
- b.value = !1;
1172
+ function p() {
1173
+ De().nextFrame(() => {
1174
+ h.value = !1;
1127
1175
  });
1128
1176
  }
1129
- let $ = Rn();
1130
- function M(g) {
1177
+ let $ = qn();
1178
+ function N(_) {
1131
1179
  switch (u.value = !0, $(() => {
1132
1180
  u.value = !1;
1133
- }), g.key) {
1134
- case W.Enter:
1135
- if (u.value = !1, s.comboboxState.value !== 0 || b.value) return;
1136
- if (g.preventDefault(), g.stopPropagation(), s.activeOptionIndex.value === null) {
1181
+ }), _.key) {
1182
+ case Z.Enter:
1183
+ if (u.value = !1, s.comboboxState.value !== 0 || h.value) return;
1184
+ if (_.preventDefault(), _.stopPropagation(), s.activeOptionIndex.value === null) {
1137
1185
  s.closeCombobox();
1138
1186
  return;
1139
1187
  }
1140
1188
  s.selectActiveOption(), s.mode.value === 0 && s.closeCombobox();
1141
1189
  break;
1142
- case W.ArrowDown:
1143
- return u.value = !1, g.preventDefault(), g.stopPropagation(), te(s.comboboxState.value, { 0: () => s.goToOption(B.Next), 1: () => s.openCombobox() });
1144
- case W.ArrowUp:
1145
- return u.value = !1, g.preventDefault(), g.stopPropagation(), te(s.comboboxState.value, { 0: () => s.goToOption(B.Previous), 1: () => {
1146
- s.openCombobox(), Q(() => {
1147
- s.value.value || s.goToOption(B.Last);
1190
+ case Z.ArrowDown:
1191
+ return u.value = !1, _.preventDefault(), _.stopPropagation(), le(s.comboboxState.value, { 0: () => s.goToOption(z.Next), 1: () => s.openCombobox() });
1192
+ case Z.ArrowUp:
1193
+ return u.value = !1, _.preventDefault(), _.stopPropagation(), le(s.comboboxState.value, { 0: () => s.goToOption(z.Previous), 1: () => {
1194
+ s.openCombobox(), te(() => {
1195
+ s.value.value || s.goToOption(z.Last);
1148
1196
  });
1149
1197
  } });
1150
- case W.Home:
1151
- if (g.shiftKey) break;
1152
- return u.value = !1, g.preventDefault(), g.stopPropagation(), s.goToOption(B.First);
1153
- case W.PageUp:
1154
- return u.value = !1, g.preventDefault(), g.stopPropagation(), s.goToOption(B.First);
1155
- case W.End:
1156
- if (g.shiftKey) break;
1157
- return u.value = !1, g.preventDefault(), g.stopPropagation(), s.goToOption(B.Last);
1158
- case W.PageDown:
1159
- return u.value = !1, g.preventDefault(), g.stopPropagation(), s.goToOption(B.Last);
1160
- case W.Escape:
1198
+ case Z.Home:
1199
+ if (_.shiftKey) break;
1200
+ return u.value = !1, _.preventDefault(), _.stopPropagation(), s.goToOption(z.First);
1201
+ case Z.PageUp:
1202
+ return u.value = !1, _.preventDefault(), _.stopPropagation(), s.goToOption(z.First);
1203
+ case Z.End:
1204
+ if (_.shiftKey) break;
1205
+ return u.value = !1, _.preventDefault(), _.stopPropagation(), s.goToOption(z.Last);
1206
+ case Z.PageDown:
1207
+ return u.value = !1, _.preventDefault(), _.stopPropagation(), s.goToOption(z.Last);
1208
+ case Z.Escape:
1161
1209
  if (u.value = !1, s.comboboxState.value !== 0) return;
1162
- g.preventDefault(), s.optionsRef.value && !s.optionsPropsRef.value.static && g.stopPropagation(), s.nullable.value && s.mode.value === 0 && s.value.value === null && v(), s.closeCombobox();
1210
+ _.preventDefault(), s.optionsRef.value && !s.optionsPropsRef.value.static && _.stopPropagation(), s.nullable.value && s.mode.value === 0 && s.value.value === null && v(), s.closeCombobox();
1163
1211
  break;
1164
- case W.Tab:
1212
+ case Z.Tab:
1165
1213
  if (u.value = !1, s.comboboxState.value !== 0) return;
1166
1214
  s.mode.value === 0 && s.activationTrigger.value !== 1 && s.selectActiveOption(), s.closeCombobox();
1167
1215
  break;
1168
1216
  }
1169
1217
  }
1170
- function E(g) {
1171
- o("change", g), s.nullable.value && s.mode.value === 0 && g.target.value === "" && v(), s.openCombobox();
1218
+ function L(_) {
1219
+ o("change", _), s.nullable.value && s.mode.value === 0 && _.target.value === "" && v(), s.openCombobox();
1172
1220
  }
1173
- function O(g) {
1174
- var T, h, p;
1175
- let C = (T = g.relatedTarget) != null ? T : ie.find((d) => d !== g.currentTarget);
1176
- if (u.value = !1, !((h = k(s.optionsRef)) != null && h.contains(C)) && !((p = k(s.buttonRef)) != null && p.contains(C)) && s.comboboxState.value === 0) return g.preventDefault(), s.mode.value === 0 && (s.nullable.value && s.value.value === null ? v() : s.activationTrigger.value !== 1 && s.selectActiveOption()), s.closeCombobox();
1221
+ function I(_) {
1222
+ var P, C, b;
1223
+ let V = (P = _.relatedTarget) != null ? P : ce.find((d) => d !== _.currentTarget);
1224
+ if (u.value = !1, !((C = M(s.optionsRef)) != null && C.contains(V)) && !((b = M(s.buttonRef)) != null && b.contains(V)) && s.comboboxState.value === 0) return _.preventDefault(), s.mode.value === 0 && (s.nullable.value && s.value.value === null ? v() : s.activationTrigger.value !== 1 && s.selectActiveOption()), s.closeCombobox();
1177
1225
  }
1178
- function D(g) {
1179
- var T, h, p;
1180
- let C = (T = g.relatedTarget) != null ? T : ie.find((d) => d !== g.currentTarget);
1181
- (h = k(s.buttonRef)) != null && h.contains(C) || (p = k(s.optionsRef)) != null && p.contains(C) || s.disabled.value || s.immediate.value && s.comboboxState.value !== 0 && (s.openCombobox(), Le().nextFrame(() => {
1226
+ function R(_) {
1227
+ var P, C, b;
1228
+ let V = (P = _.relatedTarget) != null ? P : ce.find((d) => d !== _.currentTarget);
1229
+ (C = M(s.buttonRef)) != null && C.contains(V) || (b = M(s.optionsRef)) != null && b.contains(V) || s.disabled.value || s.immediate.value && s.comboboxState.value !== 0 && (s.openCombobox(), De().nextFrame(() => {
1182
1230
  s.setActivationTrigger(1);
1183
1231
  }));
1184
1232
  }
1185
- let A = _(() => {
1186
- var g, T, h, p;
1187
- return (p = (h = (T = e.defaultValue) != null ? T : s.defaultValue.value !== void 0 ? (g = e.displayValue) == null ? void 0 : g.call(e, s.defaultValue.value) : null) != null ? h : s.defaultValue.value) != null ? p : "";
1233
+ let A = y(() => {
1234
+ var _, P, C, b;
1235
+ return (b = (C = (P = e.defaultValue) != null ? P : s.defaultValue.value !== void 0 ? (_ = e.displayValue) == null ? void 0 : _.call(e, s.defaultValue.value) : null) != null ? C : s.defaultValue.value) != null ? b : "";
1188
1236
  });
1189
1237
  return () => {
1190
- var g, T, h, p, C, d, f;
1191
- let y = { open: s.comboboxState.value === 0 }, { displayValue: x, onChange: N, ...L } = e, G = { "aria-controls": (g = s.optionsRef.value) == null ? void 0 : g.id, "aria-expanded": s.comboboxState.value === 0, "aria-activedescendant": s.activeOptionIndex.value === null ? void 0 : s.virtual.value ? (T = s.options.value.find((q) => !s.virtual.value.disabled(q.dataRef.value) && s.compare(q.dataRef.value, s.virtual.value.options[s.activeOptionIndex.value]))) == null ? void 0 : T.id : (h = s.options.value[s.activeOptionIndex.value]) == null ? void 0 : h.id, "aria-labelledby": (d = (p = k(s.labelRef)) == null ? void 0 : p.id) != null ? d : (C = k(s.buttonRef)) == null ? void 0 : C.id, "aria-autocomplete": "list", id: i, onCompositionstart: m, onCompositionend: w, onKeydown: M, onInput: E, onFocus: D, onBlur: O, role: "combobox", type: (f = t.type) != null ? f : "text", tabIndex: 0, ref: s.inputRef, defaultValue: A.value, disabled: s.disabled.value === !0 ? !0 : void 0 };
1192
- return fe({ ourProps: G, theirProps: L, slot: y, attrs: t, slots: n, features: Ee.RenderStrategy | Ee.Static, name: "ComboboxInput" });
1238
+ var _, P, C, b, V, d, f;
1239
+ let x = { open: s.comboboxState.value === 0 }, { displayValue: S, onChange: k, ...D } = e, G = { "aria-controls": (_ = s.optionsRef.value) == null ? void 0 : _.id, "aria-expanded": s.comboboxState.value === 0, "aria-activedescendant": s.activeOptionIndex.value === null ? void 0 : s.virtual.value ? (P = s.options.value.find((q) => !s.virtual.value.disabled(q.dataRef.value) && s.compare(q.dataRef.value, s.virtual.value.options[s.activeOptionIndex.value]))) == null ? void 0 : P.id : (C = s.options.value[s.activeOptionIndex.value]) == null ? void 0 : C.id, "aria-labelledby": (d = (b = M(s.labelRef)) == null ? void 0 : b.id) != null ? d : (V = M(s.buttonRef)) == null ? void 0 : V.id, "aria-autocomplete": "list", id: i, onCompositionstart: m, onCompositionend: p, onKeydown: N, onInput: L, onFocus: R, onBlur: I, role: "combobox", type: (f = t.type) != null ? f : "text", tabIndex: 0, ref: s.inputRef, defaultValue: A.value, disabled: s.disabled.value === !0 ? !0 : void 0 };
1240
+ return pe({ ourProps: G, theirProps: D, slot: x, attrs: t, slots: n, features: Oe.RenderStrategy | Oe.Static, name: "ComboboxInput" });
1193
1241
  };
1194
- } }), vo = se({ name: "ComboboxOptions", props: { as: { type: [Object, String], default: "ul" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, hold: { type: [Boolean], default: !1 } }, setup(e, { attrs: o, slots: t, expose: n }) {
1195
- let l = ve("ComboboxOptions"), r = `headlessui-combobox-options-${Te()}`;
1196
- n({ el: l.optionsRef, $el: l.optionsRef }), le(() => {
1242
+ } }), To = ae({ name: "ComboboxOptions", props: { as: { type: [Object, String], default: "ul" }, static: { type: Boolean, default: !1 }, unmount: { type: Boolean, default: !0 }, hold: { type: [Boolean], default: !1 } }, setup(e, { attrs: o, slots: t, expose: n }) {
1243
+ let l = he("ComboboxOptions"), r = `headlessui-combobox-options-${Te()}`;
1244
+ n({ el: l.optionsRef, $el: l.optionsRef }), ie(() => {
1197
1245
  l.optionsPropsRef.value.static = e.static;
1198
- }), le(() => {
1246
+ }), ie(() => {
1199
1247
  l.optionsPropsRef.value.hold = e.hold;
1200
1248
  });
1201
- let i = eo(), s = _(() => i !== null ? (i.value & Ie.Open) === Ie.Open : l.comboboxState.value === 0);
1202
- Kn({ container: _(() => k(l.optionsRef)), enabled: _(() => l.comboboxState.value === 0), accept(u) {
1249
+ let i = bo(), s = y(() => i !== null ? (i.value & $e.Open) === $e.Open : l.comboboxState.value === 0);
1250
+ vo({ container: y(() => M(l.optionsRef)), enabled: y(() => l.comboboxState.value === 0), accept(u) {
1203
1251
  return u.getAttribute("role") === "option" ? NodeFilter.FILTER_REJECT : u.hasAttribute("role") ? NodeFilter.FILTER_SKIP : NodeFilter.FILTER_ACCEPT;
1204
1252
  }, walk(u) {
1205
1253
  u.setAttribute("role", "none");
@@ -1209,74 +1257,104 @@ let co = se({ name: "ComboboxButton", props: { as: { type: [Object, String], def
1209
1257
  }
1210
1258
  return () => {
1211
1259
  var u, v, c;
1212
- let b = { open: l.comboboxState.value === 0 }, m = { "aria-labelledby": (c = (u = k(l.labelRef)) == null ? void 0 : u.id) != null ? c : (v = k(l.buttonRef)) == null ? void 0 : v.id, id: r, ref: l.optionsRef, role: "listbox", "aria-multiselectable": l.mode.value === 1 ? !0 : void 0, onMousedown: a }, w = je(e, ["hold"]);
1213
- return fe({ ourProps: m, theirProps: w, slot: b, attrs: o, slots: l.virtual.value && l.comboboxState.value === 0 ? { ...t, default: () => [Oe(ao, {}, t.default)] } : t, features: Ee.RenderStrategy | Ee.Static, visible: s.value, name: "ComboboxOptions" });
1260
+ let h = { open: l.comboboxState.value === 0 }, m = { "aria-labelledby": (c = (u = M(l.labelRef)) == null ? void 0 : u.id) != null ? c : (v = M(l.buttonRef)) == null ? void 0 : v.id, id: r, ref: l.optionsRef, role: "listbox", "aria-multiselectable": l.mode.value === 1 ? !0 : void 0, onMousedown: a }, p = je(e, ["hold"]);
1261
+ return pe({ ourProps: m, theirProps: p, slot: h, attrs: o, slots: l.virtual.value && l.comboboxState.value === 0 ? { ...t, default: () => [Se(Oo, {}, t.default)] } : t, features: Oe.RenderStrategy | Oe.Static, visible: s.value, name: "ComboboxOptions" });
1214
1262
  };
1215
- } }), po = se({ name: "ComboboxOption", props: { as: { type: [Object, String], default: "li" }, value: { type: [Object, String, Number, Boolean] }, disabled: { type: Boolean, default: !1 }, order: { type: [Number], default: null } }, setup(e, { slots: o, attrs: t, expose: n }) {
1216
- let l = ve("ComboboxOption"), r = `headlessui-combobox-option-${Te()}`, i = S(null), s = _(() => e.disabled);
1263
+ } }), Vo = ae({ name: "ComboboxOption", props: { as: { type: [Object, String], default: "li" }, value: { type: [Object, String, Number, Boolean] }, disabled: { type: Boolean, default: !1 }, order: { type: [Number], default: null } }, setup(e, { slots: o, attrs: t, expose: n }) {
1264
+ let l = he("ComboboxOption"), r = `headlessui-combobox-option-${Te()}`, i = E(null), s = y(() => e.disabled);
1217
1265
  n({ el: i, $el: i });
1218
- let a = _(() => {
1219
- var O;
1220
- return l.virtual.value ? l.activeOptionIndex.value === l.calculateIndex(e.value) : l.activeOptionIndex.value === null ? !1 : ((O = l.options.value[l.activeOptionIndex.value]) == null ? void 0 : O.id) === r;
1221
- }), u = _(() => l.isSelected(e.value)), v = Ce(Bt, null), c = _(() => ({ disabled: e.disabled, value: e.value, domRef: i, order: _(() => e.order) }));
1222
- de(() => l.registerOption(r, c)), St(() => l.unregisterOption(r, a.value)), le(() => {
1223
- let O = k(i);
1224
- O && (v == null || v.value.measureElement(O));
1225
- }), le(() => {
1226
- l.comboboxState.value === 0 && a.value && (l.virtual.value || l.activationTrigger.value !== 0 && Q(() => {
1227
- var O, D;
1228
- return (D = (O = k(i)) == null ? void 0 : O.scrollIntoView) == null ? void 0 : D.call(O, { block: "nearest" });
1266
+ let a = y(() => {
1267
+ var I;
1268
+ return l.virtual.value ? l.activeOptionIndex.value === l.calculateIndex(e.value) : l.activeOptionIndex.value === null ? !1 : ((I = l.options.value[l.activeOptionIndex.value]) == null ? void 0 : I.id) === r;
1269
+ }), u = y(() => l.isSelected(e.value)), v = Le(zt, null), c = y(() => ({ disabled: e.disabled, value: e.value, domRef: i, order: y(() => e.order) }));
1270
+ ve(() => l.registerOption(r, c)), wt(() => l.unregisterOption(r, a.value)), ie(() => {
1271
+ let I = M(i);
1272
+ I && (v == null || v.value.measureElement(I));
1273
+ }), ie(() => {
1274
+ l.comboboxState.value === 0 && a.value && (l.virtual.value || l.activationTrigger.value !== 0 && te(() => {
1275
+ var I, R;
1276
+ return (R = (I = M(i)) == null ? void 0 : I.scrollIntoView) == null ? void 0 : R.call(I, { block: "nearest" });
1229
1277
  }));
1230
1278
  });
1231
- function b(O) {
1232
- O.preventDefault(), O.button === Mt.Left && (s.value || (l.selectOption(r), kt() || requestAnimationFrame(() => {
1233
- var D;
1234
- return (D = k(l.inputRef)) == null ? void 0 : D.focus({ preventScroll: !0 });
1279
+ function h(I) {
1280
+ I.preventDefault(), I.button === At.Left && (s.value || (l.selectOption(r), Mt() || requestAnimationFrame(() => {
1281
+ var R;
1282
+ return (R = M(l.inputRef)) == null ? void 0 : R.focus({ preventScroll: !0 });
1235
1283
  }), l.mode.value === 0 && l.closeCombobox()));
1236
1284
  }
1237
1285
  function m() {
1238
- var O;
1239
- if (e.disabled || (O = l.virtual.value) != null && O.disabled(e.value)) return l.goToOption(B.Nothing);
1240
- let D = l.calculateIndex(e.value);
1241
- l.goToOption(B.Specific, D);
1242
- }
1243
- let w = Jn();
1244
- function $(O) {
1245
- w.update(O);
1246
- }
1247
- function M(O) {
1248
- var D;
1249
- if (!w.wasMoved(O) || e.disabled || (D = l.virtual.value) != null && D.disabled(e.value) || a.value) return;
1286
+ var I;
1287
+ if (e.disabled || (I = l.virtual.value) != null && I.disabled(e.value)) return l.goToOption(z.Nothing);
1288
+ let R = l.calculateIndex(e.value);
1289
+ l.goToOption(z.Specific, R);
1290
+ }
1291
+ let p = fo();
1292
+ function $(I) {
1293
+ p.update(I);
1294
+ }
1295
+ function N(I) {
1296
+ var R;
1297
+ if (!p.wasMoved(I) || e.disabled || (R = l.virtual.value) != null && R.disabled(e.value) || a.value) return;
1250
1298
  let A = l.calculateIndex(e.value);
1251
- l.goToOption(B.Specific, A, 0);
1299
+ l.goToOption(z.Specific, A, 0);
1252
1300
  }
1253
- function E(O) {
1254
- var D;
1255
- w.wasMoved(O) && (e.disabled || (D = l.virtual.value) != null && D.disabled(e.value) || a.value && (l.optionsPropsRef.value.hold || l.goToOption(B.Nothing)));
1301
+ function L(I) {
1302
+ var R;
1303
+ p.wasMoved(I) && (e.disabled || (R = l.virtual.value) != null && R.disabled(e.value) || a.value && (l.optionsPropsRef.value.hold || l.goToOption(z.Nothing)));
1256
1304
  }
1257
1305
  return () => {
1258
- let { disabled: O } = e, D = { active: a.value, selected: u.value, disabled: O }, A = { id: r, ref: i, role: "option", tabIndex: O === !0 ? void 0 : -1, "aria-disabled": O === !0 ? !0 : void 0, "aria-selected": u.value, disabled: void 0, onMousedown: b, onFocus: m, onPointerenter: $, onMouseenter: $, onPointermove: M, onMousemove: M, onPointerleave: E, onMouseleave: E }, g = je(e, ["order", "value"]);
1259
- return fe({ ourProps: A, theirProps: g, slot: D, attrs: t, slots: o, name: "ComboboxOption" });
1306
+ let { disabled: I } = e, R = { active: a.value, selected: u.value, disabled: I }, A = { id: r, ref: i, role: "option", tabIndex: I === !0 ? void 0 : -1, "aria-disabled": I === !0 ? !0 : void 0, "aria-selected": u.value, disabled: void 0, onMousedown: h, onFocus: m, onPointerenter: $, onMouseenter: $, onPointermove: N, onMousemove: N, onPointerleave: L, onMouseleave: L }, _ = je(e, ["order", "value"]);
1307
+ return pe({ ourProps: A, theirProps: _, slot: R, attrs: t, slots: o, name: "ComboboxOption" });
1260
1308
  };
1261
1309
  } });
1262
- function ho(e, o) {
1263
- return P(), V("svg", {
1310
+ function Po(e, o) {
1311
+ return w(), O("svg", {
1312
+ xmlns: "http://www.w3.org/2000/svg",
1313
+ viewBox: "0 0 20 20",
1314
+ fill: "currentColor",
1315
+ "aria-hidden": "true",
1316
+ "data-slot": "icon"
1317
+ }, [
1318
+ g("path", {
1319
+ "fill-rule": "evenodd",
1320
+ d: "M5.22 8.22a.75.75 0 0 1 1.06 0L10 11.94l3.72-3.72a.75.75 0 1 1 1.06 1.06l-4.25 4.25a.75.75 0 0 1-1.06 0L5.22 9.28a.75.75 0 0 1 0-1.06Z",
1321
+ "clip-rule": "evenodd"
1322
+ })
1323
+ ]);
1324
+ }
1325
+ function Mo(e, o) {
1326
+ return w(), O("svg", {
1264
1327
  xmlns: "http://www.w3.org/2000/svg",
1265
1328
  viewBox: "0 0 20 20",
1266
1329
  fill: "currentColor",
1267
1330
  "aria-hidden": "true",
1268
1331
  "data-slot": "icon"
1269
1332
  }, [
1270
- I("path", {
1333
+ g("path", {
1271
1334
  "fill-rule": "evenodd",
1272
1335
  d: "M10.53 3.47a.75.75 0 0 0-1.06 0L6.22 6.72a.75.75 0 0 0 1.06 1.06L10 5.06l2.72 2.72a.75.75 0 1 0 1.06-1.06l-3.25-3.25Zm-4.31 9.81 3.25 3.25a.75.75 0 0 0 1.06 0l3.25-3.25a.75.75 0 1 0-1.06-1.06L10 14.94l-2.72-2.72a.75.75 0 0 0-1.06 1.06Z",
1273
1336
  "clip-rule": "evenodd"
1274
1337
  })
1275
1338
  ]);
1276
1339
  }
1340
+ function ko(e, o) {
1341
+ return w(), O("svg", {
1342
+ xmlns: "http://www.w3.org/2000/svg",
1343
+ viewBox: "0 0 20 20",
1344
+ fill: "currentColor",
1345
+ "aria-hidden": "true",
1346
+ "data-slot": "icon"
1347
+ }, [
1348
+ g("path", {
1349
+ "fill-rule": "evenodd",
1350
+ d: "M9.47 6.47a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 1 1-1.06 1.06L10 8.06l-3.72 3.72a.75.75 0 0 1-1.06-1.06l4.25-4.25Z",
1351
+ "clip-rule": "evenodd"
1352
+ })
1353
+ ]);
1354
+ }
1277
1355
  const ht = {
1278
1356
  __name: "Select",
1279
- props: /* @__PURE__ */ un({
1357
+ props: /* @__PURE__ */ dn({
1280
1358
  languages: {
1281
1359
  type: Object,
1282
1360
  required: !0
@@ -1287,53 +1365,54 @@ const ht = {
1287
1365
  }),
1288
1366
  emits: ["update:modelValue"],
1289
1367
  setup(e) {
1290
- const o = e, t = cn(e, "modelValue"), n = S(""), l = S(null), r = _(() => Object.entries(o.languages).filter(
1368
+ const o = e, t = fn(e, "modelValue"), n = E(""), l = E(null), r = y(() => Object.entries(o.languages).filter(
1291
1369
  ([, s]) => s.toLowerCase().includes(n.value.toLowerCase())
1292
1370
  )), i = (s) => {
1293
1371
  s.target.value = "", n.value = "", l.value && l.value.$el.click();
1294
1372
  };
1295
- return (s, a) => (P(), xe(R(uo), {
1373
+ return (s, a) => (w(), X(T($o), {
1296
1374
  modelValue: t.value,
1297
- "onUpdate:modelValue": a[2] || (a[2] = (u) => t.value = u),
1375
+ "onUpdate:modelValue": a[3] || (a[3] = (u) => t.value = u),
1298
1376
  as: "div",
1299
1377
  class: "relative mt-1"
1300
1378
  }, {
1301
- default: Pe(() => [
1302
- H(R(fo), {
1303
- class: "w-full border border-gray-300 rounded-md py-2 pl-3 pr-10 text-sm leading-5 focus:ring-1 focus:ring-indigo-500 focus:border-indigo-500",
1379
+ default: Ve(() => [
1380
+ H(T(Lo), {
1381
+ class: "w-full bg-white border border-gray-300 rounded py-2.5 pl-3 pr-10 text-sm text-gray-800 font-medium focus:outline-none focus:ring-0.5 focus:ring-gray-400 focus:border-gray-400",
1304
1382
  onChange: a[0] || (a[0] = (u) => n.value = u.target.value),
1305
1383
  displayValue: (u) => e.languages[u],
1306
1384
  onFocus: a[1] || (a[1] = (u) => i(u))
1307
1385
  }, null, 8, ["displayValue"]),
1308
- H(R(co), {
1386
+ H(T(Io), {
1309
1387
  ref_key: "btnSelect",
1310
1388
  ref: l,
1311
1389
  class: "absolute inset-y-0 right-0 flex items-center pr-2"
1312
1390
  }, {
1313
- default: Pe(() => [
1314
- H(R(ho), {
1391
+ default: Ve(() => [
1392
+ H(T(Mo), {
1315
1393
  class: "h-5 w-5 text-gray-400",
1316
- "aria-hidden": "true"
1394
+ "aria-hidden": "true",
1395
+ onClick: a[2] || (a[2] = (u) => i(u))
1317
1396
  })
1318
1397
  ]),
1319
1398
  _: 1
1320
1399
  }, 512),
1321
- H(R(vo), { class: "absolute mt-1 max-h-60 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm z-50" }, {
1322
- default: Pe(() => [
1323
- (P(!0), V(X, null, ge(r.value, ([u, v]) => (P(), xe(R(po), {
1400
+ H(T(To), { class: "absolute mt-1 max-h-60 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm z-50" }, {
1401
+ default: Ve(() => [
1402
+ (w(!0), O(W, null, se(r.value, ([u, v]) => (w(), X(T(Vo), {
1324
1403
  key: u,
1325
1404
  value: u
1326
1405
  }, {
1327
- default: Pe(({ active: c, selected: b }) => [
1328
- I("li", {
1329
- class: it([
1406
+ default: Ve(({ active: c, selected: h }) => [
1407
+ g("li", {
1408
+ class: _e([
1330
1409
  "relative cursor-default select-none py-2 pl-3 pr-9",
1331
- c ? "bg-[#3B5695] text-white" : "text-gray-900"
1410
+ c ? "bg-[#3B5695] text-white" : "text-textCustom"
1332
1411
  ])
1333
1412
  }, [
1334
- I("span", {
1335
- class: it(["block truncate", b && "font-semibold"])
1336
- }, ne(v), 3)
1413
+ g("span", {
1414
+ class: _e(["block truncate", h && "font-semibold"])
1415
+ }, ee(v), 3)
1337
1416
  ], 2)
1338
1417
  ]),
1339
1418
  _: 2
@@ -1345,37 +1424,19 @@ const ht = {
1345
1424
  _: 1
1346
1425
  }, 8, ["modelValue"]));
1347
1426
  }
1348
- }, mo = { key: 0 }, go = /* @__PURE__ */ I("svg", {
1349
- xmlns: "http://www.w3.org/2000/svg",
1350
- class: "h-6 w-6",
1351
- fill: "none",
1352
- viewBox: "0 0 24 24",
1353
- stroke: "currentColor"
1354
- }, [
1355
- /* @__PURE__ */ I("path", {
1356
- "stroke-linecap": "round",
1357
- "stroke-linejoin": "round",
1358
- "stroke-width": "2",
1359
- d: "M13 7l5 5m0 0l-5 5m5-5H6"
1360
- })
1361
- ], -1), bo = [
1362
- go
1363
- ], yo = /* @__PURE__ */ I("svg", {
1364
- xmlns: "http://www.w3.org/2000/svg",
1365
- class: "h-6 w-6",
1366
- fill: "none",
1367
- viewBox: "0 0 24 24",
1368
- stroke: "currentColor"
1369
- }, [
1370
- /* @__PURE__ */ I("path", {
1371
- "stroke-linecap": "round",
1372
- "stroke-linejoin": "round",
1373
- "stroke-width": "2",
1374
- d: "M8 7h12m0 0l-4-4m4 4l-4 4m0 6H4m0 0l4 4m-4-4l4-4"
1375
- })
1376
- ], -1), _o = [
1377
- yo
1378
- ], wo = {
1427
+ }, Ut = "data:image/svg+xml,%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M3.68688%202.3131C3.88214%202.50837%203.88214%202.82495%203.68688%203.02021L2.04043%204.66666L3.68688%206.3131C3.88214%206.50837%203.88214%206.82495%203.68688%207.02021C3.49162%207.21547%203.17504%207.21547%202.97977%207.02021L0.979775%205.02021C0.784513%204.82495%200.784513%204.50837%200.979775%204.3131L2.97977%202.3131C3.17504%202.11784%203.49162%202.11784%203.68688%202.3131Z'%20fill='%237E7E7E'/%3e%3cpath%20d='M12.3131%208.97977C12.5084%208.78451%2012.825%208.78451%2013.0202%208.97977L15.0202%2010.9798C15.2155%2011.175%2015.2155%2011.4916%2015.0202%2011.6869L13.0202%2013.6869C12.825%2013.8821%2012.5084%2013.8821%2012.3131%2013.6869C12.1178%2013.4916%2012.1178%2013.175%2012.3131%2012.9798L13.9596%2011.3333L12.3131%209.68688C12.1178%209.49161%2012.1178%209.17503%2012.3131%208.97977Z'%20fill='%237E7E7E'/%3e%3cpath%20d='M0.833328%204.66666C0.833328%204.39051%201.05719%204.16666%201.33333%204.16666H14.6667C14.9428%204.16666%2015.1667%204.39051%2015.1667%204.66666C15.1667%204.9428%2014.9428%205.16666%2014.6667%205.16666H1.33333C1.05719%205.16666%200.833328%204.9428%200.833328%204.66666Z'%20fill='%237E7E7E'/%3e%3cpath%20d='M0.833328%2011.3333C0.833328%2011.0572%201.05719%2010.8333%201.33333%2010.8333H14.6667C14.9428%2010.8333%2015.1667%2011.0572%2015.1667%2011.3333C15.1667%2011.6095%2014.9428%2011.8333%2014.6667%2011.8333H1.33333C1.05719%2011.8333%200.833328%2011.6095%200.833328%2011.3333Z'%20fill='%237E7E7E'/%3e%3c/svg%3e", Ro = { key: 0 }, No = /* @__PURE__ */ g("img", {
1428
+ src: Ut,
1429
+ alt: "swap",
1430
+ class: "w-4"
1431
+ }, null, -1), Do = [
1432
+ No
1433
+ ], Ao = /* @__PURE__ */ g("img", {
1434
+ src: Ut,
1435
+ alt: "swap",
1436
+ class: "w-4"
1437
+ }, null, -1), Fo = [
1438
+ Ao
1439
+ ], jo = {
1379
1440
  __name: "SwapBtn",
1380
1441
  props: {
1381
1442
  isBidirect: {
@@ -1386,39 +1447,39 @@ const ht = {
1386
1447
  emits: ["swap"],
1387
1448
  setup(e, { emit: o }) {
1388
1449
  const t = o;
1389
- return (n, l) => e.isBidirect ? (P(), V("button", {
1450
+ return (n, l) => e.isBidirect ? (w(), O("button", {
1390
1451
  key: 1,
1391
1452
  onClick: l[0] || (l[0] = (r) => t("swap"))
1392
- }, _o)) : (P(), V("button", mo, bo));
1453
+ }, Fo)) : (w(), O("button", Ro, Do));
1393
1454
  }
1394
1455
  };
1395
- var Ut = !1;
1396
- function ke(e, o, t) {
1456
+ var Zt = !1;
1457
+ function Me(e, o, t) {
1397
1458
  return Array.isArray(e) ? (e.length = Math.max(e.length, o), e.splice(o, 1, t), t) : (e[o] = t, t);
1398
1459
  }
1399
- function We(e, o) {
1460
+ function qe(e, o) {
1400
1461
  if (Array.isArray(e)) {
1401
1462
  e.splice(o, 1);
1402
1463
  return;
1403
1464
  }
1404
1465
  delete e[o];
1405
1466
  }
1406
- function xo() {
1407
- return Ht().__VUE_DEVTOOLS_GLOBAL_HOOK__;
1467
+ function Bo() {
1468
+ return Wt().__VUE_DEVTOOLS_GLOBAL_HOOK__;
1408
1469
  }
1409
- function Ht() {
1470
+ function Wt() {
1410
1471
  return typeof navigator < "u" && typeof window < "u" ? window : typeof globalThis < "u" ? globalThis : {};
1411
1472
  }
1412
- const So = typeof Proxy == "function", Oo = "devtools-plugin:setup", Eo = "plugin:settings:set";
1413
- let pe, Ge;
1414
- function Io() {
1473
+ const Ho = typeof Proxy == "function", zo = "devtools-plugin:setup", Uo = "plugin:settings:set";
1474
+ let ge, Je;
1475
+ function Zo() {
1415
1476
  var e;
1416
- return pe !== void 0 || (typeof window < "u" && window.performance ? (pe = !0, Ge = window.performance) : typeof globalThis < "u" && (!((e = globalThis.perf_hooks) === null || e === void 0) && e.performance) ? (pe = !0, Ge = globalThis.perf_hooks.performance) : pe = !1), pe;
1477
+ return ge !== void 0 || (typeof window < "u" && window.performance ? (ge = !0, Je = window.performance) : typeof globalThis < "u" && (!((e = globalThis.perf_hooks) === null || e === void 0) && e.performance) ? (ge = !0, Je = globalThis.perf_hooks.performance) : ge = !1), ge;
1417
1478
  }
1418
- function $o() {
1419
- return Io() ? Ge.now() : Date.now();
1479
+ function Wo() {
1480
+ return Zo() ? Je.now() : Date.now();
1420
1481
  }
1421
- class Co {
1482
+ class Go {
1422
1483
  constructor(o, t) {
1423
1484
  this.target = null, this.targetQueue = [], this.onQueue = [], this.plugin = o, this.hook = t;
1424
1485
  const n = {};
@@ -1446,9 +1507,9 @@ class Co {
1446
1507
  r = i;
1447
1508
  },
1448
1509
  now() {
1449
- return $o();
1510
+ return Wo();
1450
1511
  }
1451
- }, t && t.on(Eo, (i, s) => {
1512
+ }, t && t.on(Uo, (i, s) => {
1452
1513
  i === this.plugin.id && this.fallbacks.setSettings(s);
1453
1514
  }), this.proxiedOn = new Proxy({}, {
1454
1515
  get: (i, s) => this.target ? this.target.on[s] : (...a) => {
@@ -1480,12 +1541,12 @@ class Co {
1480
1541
  t.resolve(await this.target[t.method](...t.args));
1481
1542
  }
1482
1543
  }
1483
- function Wt(e, o) {
1484
- const t = e, n = Ht(), l = xo(), r = So && t.enableEarlyProxy;
1544
+ function Gt(e, o) {
1545
+ const t = e, n = Wt(), l = Bo(), r = Ho && t.enableEarlyProxy;
1485
1546
  if (l && (n.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !r))
1486
- l.emit(Oo, e, o);
1547
+ l.emit(zo, e, o);
1487
1548
  else {
1488
- const i = r ? new Co(t, l) : null;
1549
+ const i = r ? new Go(t, l) : null;
1489
1550
  (n.__VUE_DEVTOOLS_PLUGINS__ = n.__VUE_DEVTOOLS_PLUGINS__ || []).push({
1490
1551
  pluginDescriptor: t,
1491
1552
  setupFn: o,
@@ -1499,30 +1560,30 @@ function Wt(e, o) {
1499
1560
  * @license MIT
1500
1561
  */
1501
1562
  let we;
1502
- const $e = (e) => we = e, Gt = process.env.NODE_ENV !== "production" ? Symbol("pinia") : (
1563
+ const Ie = (e) => we = e, qt = process.env.NODE_ENV !== "production" ? Symbol("pinia") : (
1503
1564
  /* istanbul ignore next */
1504
1565
  Symbol()
1505
1566
  );
1506
- function ce(e) {
1567
+ function fe(e) {
1507
1568
  return e && typeof e == "object" && Object.prototype.toString.call(e) === "[object Object]" && typeof e.toJSON != "function";
1508
1569
  }
1509
- var Z;
1570
+ var ne;
1510
1571
  (function(e) {
1511
1572
  e.direct = "direct", e.patchObject = "patch object", e.patchFunction = "patch function";
1512
- })(Z || (Z = {}));
1513
- const Fe = typeof window < "u", Se = (process.env.NODE_ENV !== "production" || !1) && process.env.NODE_ENV !== "test" && Fe, mt = typeof window == "object" && window.window === window ? window : typeof self == "object" && self.self === self ? self : typeof global == "object" && global.global === global ? global : typeof globalThis == "object" ? globalThis : { HTMLElement: null };
1514
- function To(e, { autoBom: o = !1 } = {}) {
1573
+ })(ne || (ne = {}));
1574
+ const Be = typeof window < "u", Ee = (process.env.NODE_ENV !== "production" || !1) && process.env.NODE_ENV !== "test" && Be, mt = typeof window == "object" && window.window === window ? window : typeof self == "object" && self.self === self ? self : typeof global == "object" && global.global === global ? global : typeof globalThis == "object" ? globalThis : { HTMLElement: null };
1575
+ function qo(e, { autoBom: o = !1 } = {}) {
1515
1576
  return o && /^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type) ? new Blob(["\uFEFF", e], { type: e.type }) : e;
1516
1577
  }
1517
- function nt(e, o, t) {
1578
+ function lt(e, o, t) {
1518
1579
  const n = new XMLHttpRequest();
1519
1580
  n.open("GET", e), n.responseType = "blob", n.onload = function() {
1520
- Kt(n.response, o, t);
1581
+ Yt(n.response, o, t);
1521
1582
  }, n.onerror = function() {
1522
1583
  console.error("could not download file");
1523
1584
  }, n.send();
1524
1585
  }
1525
- function qt(e) {
1586
+ function Jt(e) {
1526
1587
  const o = new XMLHttpRequest();
1527
1588
  o.open("HEAD", e, !1);
1528
1589
  try {
@@ -1531,7 +1592,7 @@ function qt(e) {
1531
1592
  }
1532
1593
  return o.status >= 200 && o.status <= 299;
1533
1594
  }
1534
- function Ne(e) {
1595
+ function ke(e) {
1535
1596
  try {
1536
1597
  e.dispatchEvent(new MouseEvent("click"));
1537
1598
  } catch {
@@ -1539,43 +1600,43 @@ function Ne(e) {
1539
1600
  t.initMouseEvent("click", !0, !0, window, 0, 0, 0, 80, 20, !1, !1, !1, !1, 0, null), e.dispatchEvent(t);
1540
1601
  }
1541
1602
  }
1542
- const Ve = typeof navigator == "object" ? navigator : { userAgent: "" }, Jt = /Macintosh/.test(Ve.userAgent) && /AppleWebKit/.test(Ve.userAgent) && !/Safari/.test(Ve.userAgent), Kt = Fe ? (
1603
+ const Re = typeof navigator == "object" ? navigator : { userAgent: "" }, Kt = /Macintosh/.test(Re.userAgent) && /AppleWebKit/.test(Re.userAgent) && !/Safari/.test(Re.userAgent), Yt = Be ? (
1543
1604
  // Use download attribute first if possible (#193 Lumia mobile) unless this is a macOS WebView or mini program
1544
- typeof HTMLAnchorElement < "u" && "download" in HTMLAnchorElement.prototype && !Jt ? Po : (
1605
+ typeof HTMLAnchorElement < "u" && "download" in HTMLAnchorElement.prototype && !Kt ? Jo : (
1545
1606
  // Use msSaveOrOpenBlob as a second approach
1546
- "msSaveOrOpenBlob" in Ve ? Ro : (
1607
+ "msSaveOrOpenBlob" in Re ? Ko : (
1547
1608
  // Fallback to using FileReader and a popup
1548
- ko
1609
+ Yo
1549
1610
  )
1550
1611
  )
1551
1612
  ) : () => {
1552
1613
  };
1553
- function Po(e, o = "download", t) {
1614
+ function Jo(e, o = "download", t) {
1554
1615
  const n = document.createElement("a");
1555
- n.download = o, n.rel = "noopener", typeof e == "string" ? (n.href = e, n.origin !== location.origin ? qt(n.href) ? nt(e, o, t) : (n.target = "_blank", Ne(n)) : Ne(n)) : (n.href = URL.createObjectURL(e), setTimeout(function() {
1616
+ n.download = o, n.rel = "noopener", typeof e == "string" ? (n.href = e, n.origin !== location.origin ? Jt(n.href) ? lt(e, o, t) : (n.target = "_blank", ke(n)) : ke(n)) : (n.href = URL.createObjectURL(e), setTimeout(function() {
1556
1617
  URL.revokeObjectURL(n.href);
1557
1618
  }, 4e4), setTimeout(function() {
1558
- Ne(n);
1619
+ ke(n);
1559
1620
  }, 0));
1560
1621
  }
1561
- function Ro(e, o = "download", t) {
1622
+ function Ko(e, o = "download", t) {
1562
1623
  if (typeof e == "string")
1563
- if (qt(e))
1564
- nt(e, o, t);
1624
+ if (Jt(e))
1625
+ lt(e, o, t);
1565
1626
  else {
1566
1627
  const n = document.createElement("a");
1567
1628
  n.href = e, n.target = "_blank", setTimeout(function() {
1568
- Ne(n);
1629
+ ke(n);
1569
1630
  });
1570
1631
  }
1571
1632
  else
1572
- navigator.msSaveOrOpenBlob(To(e, t), o);
1633
+ navigator.msSaveOrOpenBlob(qo(e, t), o);
1573
1634
  }
1574
- function ko(e, o, t, n) {
1635
+ function Yo(e, o, t, n) {
1575
1636
  if (n = n || open("", "_blank"), n && (n.document.title = n.document.body.innerText = "downloading..."), typeof e == "string")
1576
- return nt(e, o, t);
1637
+ return lt(e, o, t);
1577
1638
  const l = e.type === "application/octet-stream", r = /constructor/i.test(String(mt.HTMLElement)) || "safari" in mt, i = /CriOS\/[\d]+/.test(navigator.userAgent);
1578
- if ((i || l && r || Jt) && typeof FileReader < "u") {
1639
+ if ((i || l && r || Kt) && typeof FileReader < "u") {
1579
1640
  const s = new FileReader();
1580
1641
  s.onloadend = function() {
1581
1642
  let a = s.result;
@@ -1590,77 +1651,77 @@ function ko(e, o, t, n) {
1590
1651
  }, 4e4);
1591
1652
  }
1592
1653
  }
1593
- function z(e, o) {
1654
+ function B(e, o) {
1594
1655
  const t = "🍍 " + e;
1595
1656
  typeof __VUE_DEVTOOLS_TOAST__ == "function" ? __VUE_DEVTOOLS_TOAST__(t, o) : o === "error" ? console.error(t) : o === "warn" ? console.warn(t) : console.log(t);
1596
1657
  }
1597
- function ot(e) {
1658
+ function st(e) {
1598
1659
  return "_a" in e && "install" in e;
1599
1660
  }
1600
- function Yt() {
1661
+ function Qt() {
1601
1662
  if (!("clipboard" in navigator))
1602
- return z("Your browser doesn't support the Clipboard API", "error"), !0;
1663
+ return B("Your browser doesn't support the Clipboard API", "error"), !0;
1603
1664
  }
1604
- function Qt(e) {
1605
- return e instanceof Error && e.message.toLowerCase().includes("document is not focused") ? (z('You need to activate the "Emulate a focused page" setting in the "Rendering" panel of devtools.', "warn"), !0) : !1;
1665
+ function Xt(e) {
1666
+ return e instanceof Error && e.message.toLowerCase().includes("document is not focused") ? (B('You need to activate the "Emulate a focused page" setting in the "Rendering" panel of devtools.', "warn"), !0) : !1;
1606
1667
  }
1607
- async function No(e) {
1608
- if (!Yt())
1668
+ async function Qo(e) {
1669
+ if (!Qt())
1609
1670
  try {
1610
- await navigator.clipboard.writeText(JSON.stringify(e.state.value)), z("Global state copied to clipboard.");
1671
+ await navigator.clipboard.writeText(JSON.stringify(e.state.value)), B("Global state copied to clipboard.");
1611
1672
  } catch (o) {
1612
- if (Qt(o))
1673
+ if (Xt(o))
1613
1674
  return;
1614
- z("Failed to serialize the state. Check the console for more details.", "error"), console.error(o);
1675
+ B("Failed to serialize the state. Check the console for more details.", "error"), console.error(o);
1615
1676
  }
1616
1677
  }
1617
- async function Vo(e) {
1618
- if (!Yt())
1678
+ async function Xo(e) {
1679
+ if (!Qt())
1619
1680
  try {
1620
- Zt(e, JSON.parse(await navigator.clipboard.readText())), z("Global state pasted from clipboard.");
1681
+ en(e, JSON.parse(await navigator.clipboard.readText())), B("Global state pasted from clipboard.");
1621
1682
  } catch (o) {
1622
- if (Qt(o))
1683
+ if (Xt(o))
1623
1684
  return;
1624
- z("Failed to deserialize the state from clipboard. Check the console for more details.", "error"), console.error(o);
1685
+ B("Failed to deserialize the state from clipboard. Check the console for more details.", "error"), console.error(o);
1625
1686
  }
1626
1687
  }
1627
- async function Do(e) {
1688
+ async function e2(e) {
1628
1689
  try {
1629
- Kt(new Blob([JSON.stringify(e.state.value)], {
1690
+ Yt(new Blob([JSON.stringify(e.state.value)], {
1630
1691
  type: "text/plain;charset=utf-8"
1631
1692
  }), "pinia-state.json");
1632
1693
  } catch (o) {
1633
- z("Failed to export the state as JSON. Check the console for more details.", "error"), console.error(o);
1694
+ B("Failed to export the state as JSON. Check the console for more details.", "error"), console.error(o);
1634
1695
  }
1635
1696
  }
1636
- let ee;
1637
- function Lo() {
1638
- ee || (ee = document.createElement("input"), ee.type = "file", ee.accept = ".json");
1697
+ let oe;
1698
+ function t2() {
1699
+ oe || (oe = document.createElement("input"), oe.type = "file", oe.accept = ".json");
1639
1700
  function e() {
1640
1701
  return new Promise((o, t) => {
1641
- ee.onchange = async () => {
1642
- const n = ee.files;
1702
+ oe.onchange = async () => {
1703
+ const n = oe.files;
1643
1704
  if (!n)
1644
1705
  return o(null);
1645
1706
  const l = n.item(0);
1646
1707
  return o(l ? { text: await l.text(), file: l } : null);
1647
- }, ee.oncancel = () => o(null), ee.onerror = t, ee.click();
1708
+ }, oe.oncancel = () => o(null), oe.onerror = t, oe.click();
1648
1709
  });
1649
1710
  }
1650
1711
  return e;
1651
1712
  }
1652
- async function Mo(e) {
1713
+ async function n2(e) {
1653
1714
  try {
1654
- const t = await Lo()();
1715
+ const t = await t2()();
1655
1716
  if (!t)
1656
1717
  return;
1657
1718
  const { text: n, file: l } = t;
1658
- Zt(e, JSON.parse(n)), z(`Global state imported from "${l.name}".`);
1719
+ en(e, JSON.parse(n)), B(`Global state imported from "${l.name}".`);
1659
1720
  } catch (o) {
1660
- z("Failed to import the state from JSON. Check the console for more details.", "error"), console.error(o);
1721
+ B("Failed to import the state from JSON. Check the console for more details.", "error"), console.error(o);
1661
1722
  }
1662
1723
  }
1663
- function Zt(e, o) {
1724
+ function en(e, o) {
1664
1725
  for (const t in o) {
1665
1726
  const n = e.state.value[t];
1666
1727
  n ? Object.assign(n, o[t]) : e.state.value[t] = o[t];
@@ -1673,18 +1734,18 @@ function Y(e) {
1673
1734
  }
1674
1735
  };
1675
1736
  }
1676
- const Xt = "🍍 Pinia (root)", qe = "_root";
1677
- function Ao(e) {
1678
- return ot(e) ? {
1679
- id: qe,
1680
- label: Xt
1737
+ const tn = "🍍 Pinia (root)", Ke = "_root";
1738
+ function o2(e) {
1739
+ return st(e) ? {
1740
+ id: Ke,
1741
+ label: tn
1681
1742
  } : {
1682
1743
  id: e.$id,
1683
1744
  label: e.$id
1684
1745
  };
1685
1746
  }
1686
- function jo(e) {
1687
- if (ot(e)) {
1747
+ function l2(e) {
1748
+ if (st(e)) {
1688
1749
  const t = Array.from(e._s.keys()), n = e._s;
1689
1750
  return {
1690
1751
  state: t.map((r) => ({
@@ -1719,7 +1780,7 @@ function jo(e) {
1719
1780
  value: e[t]
1720
1781
  }))), o;
1721
1782
  }
1722
- function Fo(e) {
1783
+ function s2(e) {
1723
1784
  return e ? Array.isArray(e) ? e.reduce((o, t) => (o.keys.push(t.key), o.operations.push(t.type), o.oldValue[t.key] = t.oldValue, o.newValue[t.key] = t.newValue, o), {
1724
1785
  oldValue: {},
1725
1786
  keys: [],
@@ -1732,32 +1793,32 @@ function Fo(e) {
1732
1793
  newValue: e.newValue
1733
1794
  } : {};
1734
1795
  }
1735
- function zo(e) {
1796
+ function r2(e) {
1736
1797
  switch (e) {
1737
- case Z.direct:
1798
+ case ne.direct:
1738
1799
  return "mutation";
1739
- case Z.patchFunction:
1800
+ case ne.patchFunction:
1740
1801
  return "$patch";
1741
- case Z.patchObject:
1802
+ case ne.patchObject:
1742
1803
  return "$patch";
1743
1804
  default:
1744
1805
  return "unknown";
1745
1806
  }
1746
1807
  }
1747
- let me = !0;
1748
- const De = [], re = "pinia:mutations", U = "pinia", { assign: Bo } = Object, Me = (e) => "🍍 " + e;
1749
- function Uo(e, o) {
1750
- Wt({
1808
+ let Ce = !0;
1809
+ const Ne = [], ue = "pinia:mutations", U = "pinia", { assign: i2 } = Object, Ae = (e) => "🍍 " + e;
1810
+ function a2(e, o) {
1811
+ Gt({
1751
1812
  id: "dev.esm.pinia",
1752
1813
  label: "Pinia 🍍",
1753
1814
  logo: "https://pinia.vuejs.org/logo.svg",
1754
1815
  packageName: "pinia",
1755
1816
  homepage: "https://pinia.vuejs.org",
1756
- componentStateTypes: De,
1817
+ componentStateTypes: Ne,
1757
1818
  app: e
1758
1819
  }, (t) => {
1759
- typeof t.now != "function" && z("You seem to be using an outdated version of Vue Devtools. Are you still using the Beta release instead of the stable one? You can find the links at https://devtools.vuejs.org/guide/installation.html."), t.addTimelineLayer({
1760
- id: re,
1820
+ typeof t.now != "function" && B("You seem to be using an outdated version of Vue Devtools. Are you still using the Beta release instead of the stable one? You can find the links at https://devtools.vuejs.org/guide/installation.html."), t.addTimelineLayer({
1821
+ id: ue,
1761
1822
  label: "Pinia 🍍",
1762
1823
  color: 15064968
1763
1824
  }), t.addInspector({
@@ -1769,28 +1830,28 @@ function Uo(e, o) {
1769
1830
  {
1770
1831
  icon: "content_copy",
1771
1832
  action: () => {
1772
- No(o);
1833
+ Qo(o);
1773
1834
  },
1774
1835
  tooltip: "Serialize and copy the state"
1775
1836
  },
1776
1837
  {
1777
1838
  icon: "content_paste",
1778
1839
  action: async () => {
1779
- await Vo(o), t.sendInspectorTree(U), t.sendInspectorState(U);
1840
+ await Xo(o), t.sendInspectorTree(U), t.sendInspectorState(U);
1780
1841
  },
1781
1842
  tooltip: "Replace the state with the content of your clipboard"
1782
1843
  },
1783
1844
  {
1784
1845
  icon: "save",
1785
1846
  action: () => {
1786
- Do(o);
1847
+ e2(o);
1787
1848
  },
1788
1849
  tooltip: "Save the state as a JSON file"
1789
1850
  },
1790
1851
  {
1791
1852
  icon: "folder_open",
1792
1853
  action: async () => {
1793
- await Mo(o), t.sendInspectorTree(U), t.sendInspectorState(U);
1854
+ await n2(o), t.sendInspectorTree(U), t.sendInspectorState(U);
1794
1855
  },
1795
1856
  tooltip: "Import the state from a JSON file"
1796
1857
  }
@@ -1801,7 +1862,7 @@ function Uo(e, o) {
1801
1862
  tooltip: 'Reset the state (with "$reset")',
1802
1863
  action: (n) => {
1803
1864
  const l = o._s.get(n);
1804
- l ? typeof l.$reset != "function" ? z(`Cannot reset "${n}" store because it doesn't have a "$reset" method implemented.`, "warn") : (l.$reset(), z(`Store "${n}" reset.`)) : z(`Cannot reset "${n}" store because it wasn't found.`, "warn");
1865
+ l ? typeof l.$reset != "function" ? B(`Cannot reset "${n}" store because it doesn't have a "$reset" method implemented.`, "warn") : (l.$reset(), B(`Store "${n}" reset.`)) : B(`Cannot reset "${n}" store because it wasn't found.`, "warn");
1805
1866
  }
1806
1867
  }
1807
1868
  ]
@@ -1811,7 +1872,7 @@ function Uo(e, o) {
1811
1872
  const i = n.componentInstance.proxy._pStores;
1812
1873
  Object.values(i).forEach((s) => {
1813
1874
  n.instanceData.state.push({
1814
- type: Me(s.$id),
1875
+ type: Ae(s.$id),
1815
1876
  key: "state",
1816
1877
  editable: !0,
1817
1878
  value: s._isOptionsAPI ? {
@@ -1830,7 +1891,7 @@ function Uo(e, o) {
1830
1891
  Object.keys(s.$state).reduce((a, u) => (a[u] = s.$state[u], a), {})
1831
1892
  )
1832
1893
  }), s._getters && s._getters.length && n.instanceData.state.push({
1833
- type: Me(s.$id),
1894
+ type: Ae(s.$id),
1834
1895
  key: "getters",
1835
1896
  editable: !1,
1836
1897
  value: s._getters.reduce((a, u) => {
@@ -1847,46 +1908,46 @@ function Uo(e, o) {
1847
1908
  }), t.on.getInspectorTree((n) => {
1848
1909
  if (n.app === e && n.inspectorId === U) {
1849
1910
  let l = [o];
1850
- l = l.concat(Array.from(o._s.values())), n.rootNodes = (n.filter ? l.filter((r) => "$id" in r ? r.$id.toLowerCase().includes(n.filter.toLowerCase()) : Xt.toLowerCase().includes(n.filter.toLowerCase())) : l).map(Ao);
1911
+ l = l.concat(Array.from(o._s.values())), n.rootNodes = (n.filter ? l.filter((r) => "$id" in r ? r.$id.toLowerCase().includes(n.filter.toLowerCase()) : tn.toLowerCase().includes(n.filter.toLowerCase())) : l).map(o2);
1851
1912
  }
1852
1913
  }), t.on.getInspectorState((n) => {
1853
1914
  if (n.app === e && n.inspectorId === U) {
1854
- const l = n.nodeId === qe ? o : o._s.get(n.nodeId);
1915
+ const l = n.nodeId === Ke ? o : o._s.get(n.nodeId);
1855
1916
  if (!l)
1856
1917
  return;
1857
- l && (n.state = jo(l));
1918
+ l && (n.state = l2(l));
1858
1919
  }
1859
1920
  }), t.on.editInspectorState((n, l) => {
1860
1921
  if (n.app === e && n.inspectorId === U) {
1861
- const r = n.nodeId === qe ? o : o._s.get(n.nodeId);
1922
+ const r = n.nodeId === Ke ? o : o._s.get(n.nodeId);
1862
1923
  if (!r)
1863
- return z(`store "${n.nodeId}" not found`, "error");
1924
+ return B(`store "${n.nodeId}" not found`, "error");
1864
1925
  const { path: i } = n;
1865
- ot(r) ? i.unshift("state") : (i.length !== 1 || !r._customProperties.has(i[0]) || i[0] in r.$state) && i.unshift("$state"), me = !1, n.set(r, i, n.state.value), me = !0;
1926
+ st(r) ? i.unshift("state") : (i.length !== 1 || !r._customProperties.has(i[0]) || i[0] in r.$state) && i.unshift("$state"), Ce = !1, n.set(r, i, n.state.value), Ce = !0;
1866
1927
  }
1867
1928
  }), t.on.editComponentState((n) => {
1868
1929
  if (n.type.startsWith("🍍")) {
1869
1930
  const l = n.type.replace(/^🍍\s*/, ""), r = o._s.get(l);
1870
1931
  if (!r)
1871
- return z(`store "${l}" not found`, "error");
1932
+ return B(`store "${l}" not found`, "error");
1872
1933
  const { path: i } = n;
1873
1934
  if (i[0] !== "state")
1874
- return z(`Invalid path for store "${l}":
1935
+ return B(`Invalid path for store "${l}":
1875
1936
  ${i}
1876
1937
  Only state can be modified.`);
1877
- i[0] = "$state", me = !1, n.set(r, i, n.state.value), me = !0;
1938
+ i[0] = "$state", Ce = !1, n.set(r, i, n.state.value), Ce = !0;
1878
1939
  }
1879
1940
  });
1880
1941
  });
1881
1942
  }
1882
- function Ho(e, o) {
1883
- De.includes(Me(o.$id)) || De.push(Me(o.$id)), Wt({
1943
+ function u2(e, o) {
1944
+ Ne.includes(Ae(o.$id)) || Ne.push(Ae(o.$id)), Gt({
1884
1945
  id: "dev.esm.pinia",
1885
1946
  label: "Pinia 🍍",
1886
1947
  logo: "https://pinia.vuejs.org/logo.svg",
1887
1948
  packageName: "pinia",
1888
1949
  homepage: "https://pinia.vuejs.org",
1889
- componentStateTypes: De,
1950
+ componentStateTypes: Ne,
1890
1951
  app: e,
1891
1952
  settings: {
1892
1953
  logStoreChanges: {
@@ -1903,9 +1964,9 @@ function Ho(e, o) {
1903
1964
  }, (t) => {
1904
1965
  const n = typeof t.now == "function" ? t.now.bind(t) : Date.now;
1905
1966
  o.$onAction(({ after: i, onError: s, name: a, args: u }) => {
1906
- const v = en++;
1967
+ const v = nn++;
1907
1968
  t.addTimelineEvent({
1908
- layerId: re,
1969
+ layerId: ue,
1909
1970
  event: {
1910
1971
  time: n(),
1911
1972
  title: "🛫 " + a,
@@ -1918,8 +1979,8 @@ function Ho(e, o) {
1918
1979
  groupId: v
1919
1980
  }
1920
1981
  }), i((c) => {
1921
- oe = void 0, t.addTimelineEvent({
1922
- layerId: re,
1982
+ re = void 0, t.addTimelineEvent({
1983
+ layerId: ue,
1923
1984
  event: {
1924
1985
  time: n(),
1925
1986
  title: "🛬 " + a,
@@ -1934,8 +1995,8 @@ function Ho(e, o) {
1934
1995
  }
1935
1996
  });
1936
1997
  }), s((c) => {
1937
- oe = void 0, t.addTimelineEvent({
1938
- layerId: re,
1998
+ re = void 0, t.addTimelineEvent({
1999
+ layerId: ue,
1939
2000
  event: {
1940
2001
  time: n(),
1941
2002
  logType: "error",
@@ -1952,9 +2013,9 @@ function Ho(e, o) {
1952
2013
  });
1953
2014
  });
1954
2015
  }, !0), o._customProperties.forEach((i) => {
1955
- j(() => R(o[i]), (s, a) => {
1956
- t.notifyComponentUpdate(), t.sendInspectorState(U), me && t.addTimelineEvent({
1957
- layerId: re,
2016
+ F(() => T(o[i]), (s, a) => {
2017
+ t.notifyComponentUpdate(), t.sendInspectorState(U), Ce && t.addTimelineEvent({
2018
+ layerId: ue,
1958
2019
  event: {
1959
2020
  time: n(),
1960
2021
  title: "Change",
@@ -1963,20 +2024,20 @@ function Ho(e, o) {
1963
2024
  newValue: s,
1964
2025
  oldValue: a
1965
2026
  },
1966
- groupId: oe
2027
+ groupId: re
1967
2028
  }
1968
2029
  });
1969
2030
  }, { deep: !0 });
1970
2031
  }), o.$subscribe(({ events: i, type: s }, a) => {
1971
- if (t.notifyComponentUpdate(), t.sendInspectorState(U), !me)
2032
+ if (t.notifyComponentUpdate(), t.sendInspectorState(U), !Ce)
1972
2033
  return;
1973
2034
  const u = {
1974
2035
  time: n(),
1975
- title: zo(s),
1976
- data: Bo({ store: Y(o.$id) }, Fo(i)),
1977
- groupId: oe
2036
+ title: r2(s),
2037
+ data: i2({ store: Y(o.$id) }, s2(i)),
2038
+ groupId: re
1978
2039
  };
1979
- s === Z.patchFunction ? u.subtitle = "⤵️" : s === Z.patchObject ? u.subtitle = "🧩" : i && !Array.isArray(i) && (u.subtitle = i.type), i && (u.data["rawEvent(s)"] = {
2040
+ s === ne.patchFunction ? u.subtitle = "⤵️" : s === ne.patchObject ? u.subtitle = "🧩" : i && !Array.isArray(i) && (u.subtitle = i.type), i && (u.data["rawEvent(s)"] = {
1980
2041
  _custom: {
1981
2042
  display: "DebuggerEvent",
1982
2043
  type: "object",
@@ -1984,14 +2045,14 @@ function Ho(e, o) {
1984
2045
  value: i
1985
2046
  }
1986
2047
  }), t.addTimelineEvent({
1987
- layerId: re,
2048
+ layerId: ue,
1988
2049
  event: u
1989
2050
  });
1990
2051
  }, { detached: !0, flush: "sync" });
1991
2052
  const l = o._hotUpdate;
1992
- o._hotUpdate = ae((i) => {
2053
+ o._hotUpdate = de((i) => {
1993
2054
  l(i), t.addTimelineEvent({
1994
- layerId: re,
2055
+ layerId: ue,
1995
2056
  event: {
1996
2057
  time: n(),
1997
2058
  title: "🔥 " + o.$id,
@@ -2005,50 +2066,50 @@ function Ho(e, o) {
2005
2066
  });
2006
2067
  const { $dispose: r } = o;
2007
2068
  o.$dispose = () => {
2008
- r(), t.notifyComponentUpdate(), t.sendInspectorTree(U), t.sendInspectorState(U), t.getSettings().logStoreChanges && z(`Disposed "${o.$id}" store 🗑`);
2009
- }, t.notifyComponentUpdate(), t.sendInspectorTree(U), t.sendInspectorState(U), t.getSettings().logStoreChanges && z(`"${o.$id}" store installed 🆕`);
2069
+ r(), t.notifyComponentUpdate(), t.sendInspectorTree(U), t.sendInspectorState(U), t.getSettings().logStoreChanges && B(`Disposed "${o.$id}" store 🗑`);
2070
+ }, t.notifyComponentUpdate(), t.sendInspectorTree(U), t.sendInspectorState(U), t.getSettings().logStoreChanges && B(`"${o.$id}" store installed 🆕`);
2010
2071
  });
2011
2072
  }
2012
- let en = 0, oe;
2073
+ let nn = 0, re;
2013
2074
  function gt(e, o, t) {
2014
2075
  const n = o.reduce((l, r) => (l[r] = K(e)[r], l), {});
2015
2076
  for (const l in n)
2016
2077
  e[l] = function() {
2017
- const r = en, i = t ? new Proxy(e, {
2078
+ const r = nn, i = t ? new Proxy(e, {
2018
2079
  get(...a) {
2019
- return oe = r, Reflect.get(...a);
2080
+ return re = r, Reflect.get(...a);
2020
2081
  },
2021
2082
  set(...a) {
2022
- return oe = r, Reflect.set(...a);
2083
+ return re = r, Reflect.set(...a);
2023
2084
  }
2024
2085
  }) : e;
2025
- oe = r;
2086
+ re = r;
2026
2087
  const s = n[l].apply(i, arguments);
2027
- return oe = void 0, s;
2088
+ return re = void 0, s;
2028
2089
  };
2029
2090
  }
2030
- function Wo({ app: e, store: o, options: t }) {
2091
+ function c2({ app: e, store: o, options: t }) {
2031
2092
  if (o.$id.startsWith("__hot:"))
2032
2093
  return;
2033
2094
  o._isOptionsAPI = !!t.state, gt(o, Object.keys(t.actions), o._isOptionsAPI);
2034
2095
  const n = o._hotUpdate;
2035
2096
  K(o)._hotUpdate = function(l) {
2036
2097
  n.apply(this, arguments), gt(o, Object.keys(l._hmrPayload.actions), !!o._isOptionsAPI);
2037
- }, Ho(
2098
+ }, u2(
2038
2099
  e,
2039
2100
  // FIXME: is there a way to allow the assignment from Store<Id, S, G, A> to StoreGeneric?
2040
2101
  o
2041
2102
  );
2042
2103
  }
2043
- function Go() {
2044
- const e = It(!0), o = e.run(() => S({}));
2104
+ function d2() {
2105
+ const e = Ot(!0), o = e.run(() => E({}));
2045
2106
  let t = [], n = [];
2046
- const l = ae({
2107
+ const l = de({
2047
2108
  install(r) {
2048
- $e(l), l._a = r, r.provide(Gt, l), r.config.globalProperties.$pinia = l, Se && Uo(r, l), n.forEach((i) => t.push(i)), n = [];
2109
+ Ie(l), l._a = r, r.provide(qt, l), r.config.globalProperties.$pinia = l, Ee && a2(r, l), n.forEach((i) => t.push(i)), n = [];
2049
2110
  },
2050
2111
  use(r) {
2051
- return !this._a && !Ut ? n.push(r) : t.push(r), this;
2112
+ return !this._a && !Zt ? n.push(r) : t.push(r), this;
2052
2113
  },
2053
2114
  _p: t,
2054
2115
  // it's actually undefined here
@@ -2058,54 +2119,54 @@ function Go() {
2058
2119
  _s: /* @__PURE__ */ new Map(),
2059
2120
  state: o
2060
2121
  });
2061
- return Se && typeof Proxy < "u" && l.use(Wo), l;
2122
+ return Ee && typeof Proxy < "u" && l.use(c2), l;
2062
2123
  }
2063
- function tn(e, o) {
2124
+ function on(e, o) {
2064
2125
  for (const t in o) {
2065
2126
  const n = o[t];
2066
2127
  if (!(t in e))
2067
2128
  continue;
2068
2129
  const l = e[t];
2069
- ce(l) && ce(n) && !be(n) && !Ze(n) ? e[t] = tn(l, n) : e[t] = n;
2130
+ fe(l) && fe(n) && !xe(n) && !tt(n) ? e[t] = on(l, n) : e[t] = n;
2070
2131
  }
2071
2132
  return e;
2072
2133
  }
2073
- const nn = () => {
2134
+ const ln = () => {
2074
2135
  };
2075
- function bt(e, o, t, n = nn) {
2136
+ function bt(e, o, t, n = ln) {
2076
2137
  e.push(o);
2077
2138
  const l = () => {
2078
2139
  const r = e.indexOf(o);
2079
2140
  r > -1 && (e.splice(r, 1), n());
2080
2141
  };
2081
- return !t && Ct() && Ye(l), l;
2142
+ return !t && It() && Xe(l), l;
2082
2143
  }
2083
- function he(e, ...o) {
2144
+ function be(e, ...o) {
2084
2145
  e.slice().forEach((t) => {
2085
2146
  t(...o);
2086
2147
  });
2087
2148
  }
2088
- const qo = (e) => e();
2089
- function Je(e, o) {
2149
+ const f2 = (e) => e();
2150
+ function Ye(e, o) {
2090
2151
  e instanceof Map && o instanceof Map && o.forEach((t, n) => e.set(n, t)), e instanceof Set && o instanceof Set && o.forEach(e.add, e);
2091
2152
  for (const t in o) {
2092
2153
  if (!o.hasOwnProperty(t))
2093
2154
  continue;
2094
2155
  const n = o[t], l = e[t];
2095
- ce(l) && ce(n) && e.hasOwnProperty(t) && !be(n) && !Ze(n) ? e[t] = Je(l, n) : e[t] = n;
2156
+ fe(l) && fe(n) && e.hasOwnProperty(t) && !xe(n) && !tt(n) ? e[t] = Ye(l, n) : e[t] = n;
2096
2157
  }
2097
2158
  return e;
2098
2159
  }
2099
- const Jo = process.env.NODE_ENV !== "production" ? Symbol("pinia:skipHydration") : (
2160
+ const v2 = process.env.NODE_ENV !== "production" ? Symbol("pinia:skipHydration") : (
2100
2161
  /* istanbul ignore next */
2101
2162
  Symbol()
2102
2163
  );
2103
- function Ko(e) {
2104
- return !ce(e) || !e.hasOwnProperty(Jo);
2164
+ function p2(e) {
2165
+ return !fe(e) || !e.hasOwnProperty(v2);
2105
2166
  }
2106
2167
  const { assign: J } = Object;
2107
- function yt(e) {
2108
- return !!(be(e) && e.effect);
2168
+ function Ct(e) {
2169
+ return !!(xe(e) && e.effect);
2109
2170
  }
2110
2171
  function _t(e, o, t, n) {
2111
2172
  const { state: l, actions: r, getters: i } = o, s = t.state.value[e];
@@ -2114,17 +2175,17 @@ function _t(e, o, t, n) {
2114
2175
  !s && (process.env.NODE_ENV === "production" || !n) && (t.state.value[e] = l ? l() : {});
2115
2176
  const v = process.env.NODE_ENV !== "production" && n ? (
2116
2177
  // use ref() to unwrap refs inside state TODO: check if this is still necessary
2117
- at(S(l ? l() : {}).value)
2178
+ at(E(l ? l() : {}).value)
2118
2179
  ) : at(t.state.value[e]);
2119
- return J(v, r, Object.keys(i || {}).reduce((c, b) => (process.env.NODE_ENV !== "production" && b in v && console.warn(`[🍍]: A getter cannot have the same name as another state property. Rename one of them. Found with "${b}" in store "${e}".`), c[b] = ae(_(() => {
2120
- $e(t);
2180
+ return J(v, r, Object.keys(i || {}).reduce((c, h) => (process.env.NODE_ENV !== "production" && h in v && console.warn(`[🍍]: A getter cannot have the same name as another state property. Rename one of them. Found with "${h}" in store "${e}".`), c[h] = de(y(() => {
2181
+ Ie(t);
2121
2182
  const m = t._s.get(e);
2122
- return i[b].call(m, m);
2183
+ return i[h].call(m, m);
2123
2184
  })), c), {}));
2124
2185
  }
2125
- return a = Ke(e, u, o, t, n, !0), a;
2186
+ return a = Qe(e, u, o, t, n, !0), a;
2126
2187
  }
2127
- function Ke(e, o, t = {}, n, l, r) {
2188
+ function Qe(e, o, t = {}, n, l, r) {
2128
2189
  let i;
2129
2190
  const s = J({ actions: {} }, t);
2130
2191
  if (process.env.NODE_ENV !== "production" && !n._e.active)
@@ -2133,157 +2194,157 @@ function Ke(e, o, t = {}, n, l, r) {
2133
2194
  deep: !0
2134
2195
  // flush: 'post',
2135
2196
  };
2136
- process.env.NODE_ENV !== "production" && !Ut && (a.onTrigger = (d) => {
2137
- u ? m = d : u == !1 && !h._hotUpdating && (Array.isArray(m) ? m.push(d) : console.error("🍍 debuggerEvents should be an array. This is most likely an internal Pinia bug."));
2197
+ process.env.NODE_ENV !== "production" && !Zt && (a.onTrigger = (d) => {
2198
+ u ? m = d : u == !1 && !C._hotUpdating && (Array.isArray(m) ? m.push(d) : console.error("🍍 debuggerEvents should be an array. This is most likely an internal Pinia bug."));
2138
2199
  });
2139
- let u, v, c = [], b = [], m;
2140
- const w = n.state.value[e];
2141
- !r && !w && (process.env.NODE_ENV === "production" || !l) && (n.state.value[e] = {});
2142
- const $ = S({});
2143
- let M;
2144
- function E(d) {
2200
+ let u, v, c = [], h = [], m;
2201
+ const p = n.state.value[e];
2202
+ !r && !p && (process.env.NODE_ENV === "production" || !l) && (n.state.value[e] = {});
2203
+ const $ = E({});
2204
+ let N;
2205
+ function L(d) {
2145
2206
  let f;
2146
2207
  u = v = !1, process.env.NODE_ENV !== "production" && (m = []), typeof d == "function" ? (d(n.state.value[e]), f = {
2147
- type: Z.patchFunction,
2208
+ type: ne.patchFunction,
2148
2209
  storeId: e,
2149
2210
  events: m
2150
- }) : (Je(n.state.value[e], d), f = {
2151
- type: Z.patchObject,
2211
+ }) : (Ye(n.state.value[e], d), f = {
2212
+ type: ne.patchObject,
2152
2213
  payload: d,
2153
2214
  storeId: e,
2154
2215
  events: m
2155
2216
  });
2156
- const y = M = Symbol();
2157
- Q().then(() => {
2158
- M === y && (u = !0);
2159
- }), v = !0, he(c, f, n.state.value[e]);
2160
- }
2161
- const O = r ? function() {
2162
- const { state: f } = t, y = f ? f() : {};
2163
- this.$patch((x) => {
2164
- J(x, y);
2217
+ const x = N = Symbol();
2218
+ te().then(() => {
2219
+ N === x && (u = !0);
2220
+ }), v = !0, be(c, f, n.state.value[e]);
2221
+ }
2222
+ const I = r ? function() {
2223
+ const { state: f } = t, x = f ? f() : {};
2224
+ this.$patch((S) => {
2225
+ J(S, x);
2165
2226
  });
2166
2227
  } : (
2167
2228
  /* istanbul ignore next */
2168
2229
  process.env.NODE_ENV !== "production" ? () => {
2169
2230
  throw new Error(`🍍: Store "${e}" is built using the setup syntax and does not implement $reset().`);
2170
- } : nn
2231
+ } : ln
2171
2232
  );
2172
- function D() {
2173
- i.stop(), c = [], b = [], n._s.delete(e);
2233
+ function R() {
2234
+ i.stop(), c = [], h = [], n._s.delete(e);
2174
2235
  }
2175
2236
  function A(d, f) {
2176
2237
  return function() {
2177
- $e(n);
2178
- const y = Array.from(arguments), x = [], N = [];
2179
- function L(F) {
2180
- x.push(F);
2238
+ Ie(n);
2239
+ const x = Array.from(arguments), S = [], k = [];
2240
+ function D(j) {
2241
+ S.push(j);
2181
2242
  }
2182
- function G(F) {
2183
- N.push(F);
2243
+ function G(j) {
2244
+ k.push(j);
2184
2245
  }
2185
- he(b, {
2186
- args: y,
2246
+ be(h, {
2247
+ args: x,
2187
2248
  name: d,
2188
- store: h,
2189
- after: L,
2249
+ store: C,
2250
+ after: D,
2190
2251
  onError: G
2191
2252
  });
2192
2253
  let q;
2193
2254
  try {
2194
- q = f.apply(this && this.$id === e ? this : h, y);
2195
- } catch (F) {
2196
- throw he(N, F), F;
2255
+ q = f.apply(this && this.$id === e ? this : C, x);
2256
+ } catch (j) {
2257
+ throw be(k, j), j;
2197
2258
  }
2198
- return q instanceof Promise ? q.then((F) => (he(x, F), F)).catch((F) => (he(N, F), Promise.reject(F))) : (he(x, q), q);
2259
+ return q instanceof Promise ? q.then((j) => (be(S, j), j)).catch((j) => (be(k, j), Promise.reject(j))) : (be(S, q), q);
2199
2260
  };
2200
2261
  }
2201
- const g = /* @__PURE__ */ ae({
2262
+ const _ = /* @__PURE__ */ de({
2202
2263
  actions: {},
2203
2264
  getters: {},
2204
2265
  state: [],
2205
2266
  hotState: $
2206
- }), T = {
2267
+ }), P = {
2207
2268
  _p: n,
2208
2269
  // _s: scope,
2209
2270
  $id: e,
2210
- $onAction: bt.bind(null, b),
2211
- $patch: E,
2212
- $reset: O,
2271
+ $onAction: bt.bind(null, h),
2272
+ $patch: L,
2273
+ $reset: I,
2213
2274
  $subscribe(d, f = {}) {
2214
- const y = bt(c, d, f.detached, () => x()), x = i.run(() => j(() => n.state.value[e], (N) => {
2275
+ const x = bt(c, d, f.detached, () => S()), S = i.run(() => F(() => n.state.value[e], (k) => {
2215
2276
  (f.flush === "sync" ? v : u) && d({
2216
2277
  storeId: e,
2217
- type: Z.direct,
2278
+ type: ne.direct,
2218
2279
  events: m
2219
- }, N);
2280
+ }, k);
2220
2281
  }, J({}, a, f)));
2221
- return y;
2282
+ return x;
2222
2283
  },
2223
- $dispose: D
2224
- }, h = Et(process.env.NODE_ENV !== "production" || Se ? J(
2284
+ $dispose: R
2285
+ }, C = St(process.env.NODE_ENV !== "production" || Ee ? J(
2225
2286
  {
2226
- _hmrPayload: g,
2227
- _customProperties: ae(/* @__PURE__ */ new Set())
2287
+ _hmrPayload: _,
2288
+ _customProperties: de(/* @__PURE__ */ new Set())
2228
2289
  // devtools custom properties
2229
2290
  },
2230
- T
2291
+ P
2231
2292
  // must be added later
2232
2293
  // setupStore
2233
- ) : T);
2234
- n._s.set(e, h);
2235
- const C = (n._a && n._a.runWithContext || qo)(() => n._e.run(() => (i = It()).run(o)));
2236
- for (const d in C) {
2237
- const f = C[d];
2238
- if (be(f) && !yt(f) || Ze(f))
2239
- process.env.NODE_ENV !== "production" && l ? ke($.value, d, Be(C, d)) : r || (w && Ko(f) && (be(f) ? f.value = w[d] : Je(f, w[d])), n.state.value[e][d] = f), process.env.NODE_ENV !== "production" && g.state.push(d);
2294
+ ) : P);
2295
+ n._s.set(e, C);
2296
+ const V = (n._a && n._a.runWithContext || f2)(() => n._e.run(() => (i = Ot()).run(o)));
2297
+ for (const d in V) {
2298
+ const f = V[d];
2299
+ if (xe(f) && !Ct(f) || tt(f))
2300
+ process.env.NODE_ENV !== "production" && l ? Me($.value, d, Ze(V, d)) : r || (p && p2(f) && (xe(f) ? f.value = p[d] : Ye(f, p[d])), n.state.value[e][d] = f), process.env.NODE_ENV !== "production" && _.state.push(d);
2240
2301
  else if (typeof f == "function") {
2241
- const y = process.env.NODE_ENV !== "production" && l ? f : A(d, f);
2242
- C[d] = y, process.env.NODE_ENV !== "production" && (g.actions[d] = f), s.actions[d] = f;
2243
- } else process.env.NODE_ENV !== "production" && yt(f) && (g.getters[d] = r ? (
2302
+ const x = process.env.NODE_ENV !== "production" && l ? f : A(d, f);
2303
+ V[d] = x, process.env.NODE_ENV !== "production" && (_.actions[d] = f), s.actions[d] = f;
2304
+ } else process.env.NODE_ENV !== "production" && Ct(f) && (_.getters[d] = r ? (
2244
2305
  // @ts-expect-error
2245
2306
  t.getters[d]
2246
- ) : f, Fe && (C._getters || // @ts-expect-error: same
2247
- (C._getters = ae([]))).push(d));
2307
+ ) : f, Be && (V._getters || // @ts-expect-error: same
2308
+ (V._getters = de([]))).push(d));
2248
2309
  }
2249
- if (J(h, C), J(K(h), C), Object.defineProperty(h, "$state", {
2310
+ if (J(C, V), J(K(C), V), Object.defineProperty(C, "$state", {
2250
2311
  get: () => process.env.NODE_ENV !== "production" && l ? $.value : n.state.value[e],
2251
2312
  set: (d) => {
2252
2313
  if (process.env.NODE_ENV !== "production" && l)
2253
2314
  throw new Error("cannot set hotState");
2254
- E((f) => {
2315
+ L((f) => {
2255
2316
  J(f, d);
2256
2317
  });
2257
2318
  }
2258
- }), process.env.NODE_ENV !== "production" && (h._hotUpdate = ae((d) => {
2259
- h._hotUpdating = !0, d._hmrPayload.state.forEach((f) => {
2260
- if (f in h.$state) {
2261
- const y = d.$state[f], x = h.$state[f];
2262
- typeof y == "object" && ce(y) && ce(x) ? tn(y, x) : d.$state[f] = x;
2319
+ }), process.env.NODE_ENV !== "production" && (C._hotUpdate = de((d) => {
2320
+ C._hotUpdating = !0, d._hmrPayload.state.forEach((f) => {
2321
+ if (f in C.$state) {
2322
+ const x = d.$state[f], S = C.$state[f];
2323
+ typeof x == "object" && fe(x) && fe(S) ? on(x, S) : d.$state[f] = S;
2263
2324
  }
2264
- ke(h, f, Be(d.$state, f));
2265
- }), Object.keys(h.$state).forEach((f) => {
2266
- f in d.$state || We(h, f);
2267
- }), u = !1, v = !1, n.state.value[e] = Be(d._hmrPayload, "hotState"), v = !0, Q().then(() => {
2325
+ Me(C, f, Ze(d.$state, f));
2326
+ }), Object.keys(C.$state).forEach((f) => {
2327
+ f in d.$state || qe(C, f);
2328
+ }), u = !1, v = !1, n.state.value[e] = Ze(d._hmrPayload, "hotState"), v = !0, te().then(() => {
2268
2329
  u = !0;
2269
2330
  });
2270
2331
  for (const f in d._hmrPayload.actions) {
2271
- const y = d[f];
2272
- ke(h, f, A(f, y));
2332
+ const x = d[f];
2333
+ Me(C, f, A(f, x));
2273
2334
  }
2274
2335
  for (const f in d._hmrPayload.getters) {
2275
- const y = d._hmrPayload.getters[f], x = r ? (
2336
+ const x = d._hmrPayload.getters[f], S = r ? (
2276
2337
  // special handling of options api
2277
- _(() => ($e(n), y.call(h, h)))
2278
- ) : y;
2279
- ke(h, f, x);
2338
+ y(() => (Ie(n), x.call(C, C)))
2339
+ ) : x;
2340
+ Me(C, f, S);
2280
2341
  }
2281
- Object.keys(h._hmrPayload.getters).forEach((f) => {
2282
- f in d._hmrPayload.getters || We(h, f);
2283
- }), Object.keys(h._hmrPayload.actions).forEach((f) => {
2284
- f in d._hmrPayload.actions || We(h, f);
2285
- }), h._hmrPayload = d._hmrPayload, h._getters = d._getters, h._hotUpdating = !1;
2286
- })), Se) {
2342
+ Object.keys(C._hmrPayload.getters).forEach((f) => {
2343
+ f in d._hmrPayload.getters || qe(C, f);
2344
+ }), Object.keys(C._hmrPayload.actions).forEach((f) => {
2345
+ f in d._hmrPayload.actions || qe(C, f);
2346
+ }), C._hmrPayload = d._hmrPayload, C._getters = d._getters, C._hotUpdating = !1;
2347
+ })), Ee) {
2287
2348
  const d = {
2288
2349
  writable: !0,
2289
2350
  configurable: !0,
@@ -2291,30 +2352,30 @@ function Ke(e, o, t = {}, n, l, r) {
2291
2352
  enumerable: !1
2292
2353
  };
2293
2354
  ["_p", "_hmrPayload", "_getters", "_customProperties"].forEach((f) => {
2294
- Object.defineProperty(h, f, J({ value: h[f] }, d));
2355
+ Object.defineProperty(C, f, J({ value: C[f] }, d));
2295
2356
  });
2296
2357
  }
2297
2358
  return n._p.forEach((d) => {
2298
- if (Se) {
2359
+ if (Ee) {
2299
2360
  const f = i.run(() => d({
2300
- store: h,
2361
+ store: C,
2301
2362
  app: n._a,
2302
2363
  pinia: n,
2303
2364
  options: s
2304
2365
  }));
2305
- Object.keys(f || {}).forEach((y) => h._customProperties.add(y)), J(h, f);
2366
+ Object.keys(f || {}).forEach((x) => C._customProperties.add(x)), J(C, f);
2306
2367
  } else
2307
- J(h, i.run(() => d({
2308
- store: h,
2368
+ J(C, i.run(() => d({
2369
+ store: C,
2309
2370
  app: n._a,
2310
2371
  pinia: n,
2311
2372
  options: s
2312
2373
  })));
2313
- }), process.env.NODE_ENV !== "production" && h.$state && typeof h.$state == "object" && typeof h.$state.constructor == "function" && !h.$state.constructor.toString().includes("[native code]") && console.warn(`[🍍]: The "state" must be a plain object. It cannot be
2374
+ }), process.env.NODE_ENV !== "production" && C.$state && typeof C.$state == "object" && typeof C.$state.constructor == "function" && !C.$state.constructor.toString().includes("[native code]") && console.warn(`[🍍]: The "state" must be a plain object. It cannot be
2314
2375
  state: () => new MyClass()
2315
- Found in store "${h.$id}".`), w && r && t.hydrate && t.hydrate(h.$state, w), u = !0, v = !0, h;
2376
+ Found in store "${C.$id}".`), p && r && t.hydrate && t.hydrate(C.$state, p), u = !0, v = !0, C;
2316
2377
  }
2317
- function lt(e, o, t) {
2378
+ function rt(e, o, t) {
2318
2379
  let n, l;
2319
2380
  const r = typeof o == "function";
2320
2381
  if (typeof e == "string")
@@ -2322,24 +2383,24 @@ function lt(e, o, t) {
2322
2383
  else if (l = e, n = e.id, process.env.NODE_ENV !== "production" && typeof n != "string")
2323
2384
  throw new Error('[🍍]: "defineStore()" must be passed a store id as its first argument.');
2324
2385
  function i(s, a) {
2325
- const u = dn();
2386
+ const u = vn();
2326
2387
  if (s = // in test mode, ignore the argument provided as we can always retrieve a
2327
2388
  // pinia instance with getActivePinia()
2328
- (process.env.NODE_ENV === "test" && we && we._testing ? null : s) || (u ? Ce(Gt, null) : null), s && $e(s), process.env.NODE_ENV !== "production" && !we)
2389
+ (process.env.NODE_ENV === "test" && we && we._testing ? null : s) || (u ? Le(qt, null) : null), s && Ie(s), process.env.NODE_ENV !== "production" && !we)
2329
2390
  throw new Error(`[🍍]: "getActivePinia()" was called but there was no active Pinia. Are you trying to use a store before calling "app.use(pinia)"?
2330
2391
  See https://pinia.vuejs.org/core-concepts/outside-component-usage.html for help.
2331
2392
  This will fail in production.`);
2332
- s = we, s._s.has(n) || (r ? Ke(n, o, l, s) : _t(n, l, s), process.env.NODE_ENV !== "production" && (i._pinia = s));
2393
+ s = we, s._s.has(n) || (r ? Qe(n, o, l, s) : _t(n, l, s), process.env.NODE_ENV !== "production" && (i._pinia = s));
2333
2394
  const v = s._s.get(n);
2334
2395
  if (process.env.NODE_ENV !== "production" && a) {
2335
- const c = "__hot:" + n, b = r ? Ke(c, o, l, s, !0) : _t(c, J({}, l), s, !0);
2336
- a._hotUpdate(b), delete s.state.value[c], s._s.delete(c);
2396
+ const c = "__hot:" + n, h = r ? Qe(c, o, l, s, !0) : _t(c, J({}, l), s, !0);
2397
+ a._hotUpdate(h), delete s.state.value[c], s._s.delete(c);
2337
2398
  }
2338
- if (process.env.NODE_ENV !== "production" && Fe) {
2399
+ if (process.env.NODE_ENV !== "production" && Be) {
2339
2400
  const c = $t();
2340
2401
  if (c && c.proxy && // avoid adding stores that are just built for hot module replacement
2341
2402
  !a) {
2342
- const b = c.proxy, m = "_pStores" in b ? b._pStores : b._pStores = {};
2403
+ const h = c.proxy, m = "_pStores" in h ? h._pStores : h._pStores = {};
2343
2404
  m[n] = v;
2344
2405
  }
2345
2406
  }
@@ -2347,11 +2408,11 @@ This will fail in production.`);
2347
2408
  }
2348
2409
  return i.$id = n, i;
2349
2410
  }
2350
- const st = lt("language", () => {
2351
- const e = S("auto"), o = S("en"), t = S({
2411
+ const He = rt("language", () => {
2412
+ const e = E("auto"), o = E("en"), t = E({
2352
2413
  src: [],
2353
2414
  target: []
2354
- }), n = _(() => t.value.src[e.value]), l = _(() => t.value.target[o.value]);
2415
+ }), n = y(() => t.value.src[e.value]), l = y(() => t.value.target[o.value]);
2355
2416
  function r(a, u) {
2356
2417
  e.value = a == null ? void 0 : a.src, o.value = a == null ? void 0 : a.target, t.value = u;
2357
2418
  }
@@ -2364,37 +2425,37 @@ const st = lt("language", () => {
2364
2425
  return t.value.src[a] || t.value.target[a];
2365
2426
  }
2366
2427
  return { languages: t, src: e, target: o, srcLabel: n, targetLabel: l, init: r, swap: i, getLabel: s };
2367
- }), Yo = {
2428
+ }), h2 = {
2368
2429
  key: 0,
2369
- class: "flex flex-row"
2370
- }, Qo = {
2430
+ class: "flex"
2431
+ }, m2 = {
2371
2432
  __name: "Selects",
2372
2433
  setup(e) {
2373
- const o = st();
2434
+ const o = He();
2374
2435
  function t() {
2375
2436
  o.swap();
2376
2437
  }
2377
- return (n, l) => R(o).languages ? (P(), V("div", Yo, [
2438
+ return (n, l) => T(o).languages ? (w(), O("div", h2, [
2378
2439
  H(ht, {
2379
- modelValue: R(o).src,
2380
- "onUpdate:modelValue": l[0] || (l[0] = (r) => R(o).src = r),
2381
- languages: R(o).languages.src,
2440
+ modelValue: T(o).src,
2441
+ "onUpdate:modelValue": l[0] || (l[0] = (r) => T(o).src = r),
2442
+ languages: T(o).languages.src,
2382
2443
  class: "grow"
2383
2444
  }, null, 8, ["modelValue", "languages"]),
2384
- H(wo, {
2385
- isBidirect: R(o).src !== "auto",
2386
- class: "grow-0",
2445
+ H(jo, {
2446
+ isBidirect: T(o).src !== "auto",
2447
+ class: "grow-0 mx-3",
2387
2448
  onSwap: t
2388
2449
  }, null, 8, ["isBidirect"]),
2389
2450
  H(ht, {
2390
- modelValue: R(o).target,
2391
- "onUpdate:modelValue": l[1] || (l[1] = (r) => R(o).target = r),
2392
- languages: R(o).languages.target,
2451
+ modelValue: T(o).target,
2452
+ "onUpdate:modelValue": l[1] || (l[1] = (r) => T(o).target = r),
2453
+ languages: T(o).languages.target,
2393
2454
  class: "grow"
2394
2455
  }, null, 8, ["modelValue", "languages"])
2395
- ])) : ue("", !0);
2456
+ ])) : Q("", !0);
2396
2457
  }
2397
- }, Zo = {
2458
+ }, g2 = {
2398
2459
  INPUT_MAX_LENGTH: 5e3,
2399
2460
  INPUT_DEBOUNCE: 500
2400
2461
  }, ze = (e, o) => {
@@ -2402,76 +2463,68 @@ const st = lt("language", () => {
2402
2463
  for (const [n, l] of o)
2403
2464
  t[n] = l;
2404
2465
  return t;
2405
- }, Xo = {}, el = { class: "mr-2 loading loading-dots loading-xs" };
2406
- function tl(e, o) {
2407
- return P(), V("span", el);
2408
- }
2409
- const nl = /* @__PURE__ */ ze(Xo, [["render", tl]]);
2410
- function ol(e, { volume: o = 1, playbackRate: t = 1, soundEnabled: n = !0, interrupt: l = !1, autoplay: r = !1, onload: i, ...s } = {}) {
2411
- const a = S(null), u = S(!1), v = S(null), c = S(null);
2412
- function b() {
2413
- var E;
2414
- typeof i == "function" && i.call(this), v.value = (v.value || ((E = c.value) == null ? void 0 : E.duration()) || 0) * 1e3, r === !0 && (u.value = !0);
2415
- }
2416
- return de(async () => {
2417
- const E = await import("./howler-DJIW9wc6.js").then((O) => O.h);
2418
- a.value = E.default.Howl, c.value = new a.value({
2419
- src: R(e),
2420
- volume: R(o),
2421
- rate: R(t),
2422
- onload: b,
2466
+ }, b2 = {}, C2 = { class: "mr-2 loading loading-dots loading-xs" };
2467
+ function _2(e, o) {
2468
+ return w(), O("span", C2);
2469
+ }
2470
+ const x2 = /* @__PURE__ */ ze(b2, [["render", _2]]), y2 = "data:image/svg+xml,%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M2.33325%204.66667H3.51125C3.82693%204.6667%204.13239%204.55473%204.37325%204.35067L6.83392%202.26667C6.99592%202.12953%207.19374%202.04156%207.40407%202.01312C7.61441%201.98468%207.82849%202.01696%208.02109%202.10615C8.21369%202.19534%208.37678%202.33772%208.49114%202.51652C8.60551%202.69532%208.66638%202.90309%208.66659%203.11534V12.8847C8.66649%2013.097%208.60565%2013.305%208.49125%2013.4839C8.37685%2013.6628%208.21367%2013.8053%208.02094%2013.8945C7.82822%2013.9837%207.614%2014.0159%207.40356%2013.9874C7.19312%2013.9588%206.99523%2013.8707%206.83325%2013.7333L4.37325%2011.6487C4.13229%2011.4449%203.82685%2011.3331%203.51125%2011.3333H2.33325C2.06804%2011.3333%201.81368%2011.228%201.62615%2011.0404C1.43861%2010.8529%201.33325%2010.5986%201.33325%2010.3333V5.66667C1.33325%205.40145%201.43861%205.1471%201.62615%204.95956C1.81368%204.77203%202.06804%204.66667%202.33325%204.66667ZM11.1779%2011.18C11.5969%2010.763%2011.9294%2010.2674%2012.1562%209.72156C12.3831%209.17572%2012.4999%208.59044%2012.4999%207.99934C12.4999%207.40823%2012.3831%206.82295%2012.1562%206.27711C11.9294%205.73127%2011.5969%205.23564%2011.1779%204.81867C11.1317%204.77098%2011.0765%204.73297%2011.0155%204.70686C10.9544%204.68075%2010.8888%204.66705%2010.8224%204.66657C10.756%204.66609%2010.6902%204.67883%2010.6288%204.70406C10.5674%204.72929%2010.5116%204.76649%2010.4647%204.8135C10.4179%204.86051%2010.3808%204.91639%2010.3558%204.97787C10.3307%205.03935%2010.3181%205.10521%2010.3188%205.17159C10.3195%205.23798%2010.3334%205.30357%2010.3597%205.36453C10.3859%205.42549%2010.4241%205.48061%2010.4719%205.52667C10.7977%205.85079%2011.0562%206.23609%2011.2326%206.66043C11.409%207.08477%2011.4998%207.53979%2011.4998%207.99934C11.4998%208.45888%2011.409%208.9139%2011.2326%209.33824C11.0562%209.76258%2010.7977%2010.1479%2010.4719%2010.472C10.4241%2010.5181%2010.3859%2010.5732%2010.3597%2010.6341C10.3334%2010.6951%2010.3195%2010.7607%2010.3188%2010.8271C10.3181%2010.8935%2010.3307%2010.9593%2010.3558%2011.0208C10.3808%2011.0823%2010.4179%2011.1382%2010.4647%2011.1852C10.5116%2011.2322%2010.5674%2011.2694%2010.6288%2011.2946C10.6902%2011.3198%2010.756%2011.3326%2010.8224%2011.3321C10.8888%2011.3316%2010.9544%2011.3179%2011.0155%2011.2918C11.0765%2011.2657%2011.1317%2011.2277%2011.1779%2011.18ZM12.7113%2013.2127C12.6123%2013.2126%2012.5157%2013.1832%2012.4335%2013.1281C12.3513%2013.0731%2012.2873%2012.9949%2012.2495%2012.9035C12.2118%2012.8121%2012.202%2012.7115%2012.2214%2012.6146C12.2408%2012.5176%2012.2886%2012.4285%2012.3586%2012.3587C12.9317%2011.7866%2013.3865%2011.1071%2013.6967%2010.359C14.0069%209.61101%2014.1666%208.80915%2014.1666%207.99934C14.1666%207.18952%2014.0069%206.38766%2013.6967%205.63963C13.3865%204.8916%2012.9317%204.2121%2012.3586%203.64C12.3122%203.59351%2012.2754%203.53834%2012.2503%203.47764C12.2252%203.41693%2012.2124%203.35188%2012.2124%203.2862C12.2125%203.22052%2012.2255%203.15549%2012.2507%203.09483C12.2759%203.03417%2012.3128%202.97907%2012.3593%202.93267C12.4057%202.88627%2012.4609%202.84948%2012.5216%202.8244C12.5823%202.79932%2012.6474%202.78645%2012.7131%202.78651C12.7787%202.78657%2012.8438%202.79957%2012.9044%202.82476C12.9651%202.84995%2013.0202%202.88685%2013.0666%202.93334C13.7327%203.59825%2014.2612%204.38801%2014.6218%205.25741C14.9824%206.12681%2015.168%207.05879%2015.168%208C15.168%208.94122%2014.9824%209.87319%2014.6218%2010.7426C14.2612%2011.612%2013.7327%2012.4018%2013.0666%2013.0667C13.02%2013.1134%2012.9646%2013.1504%2012.9036%2013.1756C12.8426%2013.2007%2012.7772%2013.2129%2012.7113%2013.2127Z'%20fill='%233B5695'/%3e%3c/svg%3e", w2 = "data:image/svg+xml,%3csvg%20class='swap-on%20fill-current%20h-4%20w-4'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%3e%3cpath%20fill-rule='evenodd'%20d='M4.5%207.5a3%203%200%200%201%203-3h9a3%203%200%200%201%203%203v9a3%203%200%200%201-3%203h-9a3%203%200%200%201-3-3v-9Z'%20clip-rule='evenodd'%20fill='%238595BE'/%3e%3c/svg%3e";
2471
+ function E2(e, { volume: o = 1, playbackRate: t = 1, soundEnabled: n = !0, interrupt: l = !1, autoplay: r = !1, onload: i, ...s } = {}) {
2472
+ const a = E(null), u = E(!1), v = E(null), c = E(null);
2473
+ function h() {
2474
+ var L;
2475
+ typeof i == "function" && i.call(this), v.value = (v.value || ((L = c.value) == null ? void 0 : L.duration()) || 0) * 1e3, r === !0 && (u.value = !0);
2476
+ }
2477
+ return ve(async () => {
2478
+ const L = await import("./howler-DJIW9wc6.js").then((I) => I.h);
2479
+ a.value = L.default.Howl, c.value = new a.value({
2480
+ src: T(e),
2481
+ volume: T(o),
2482
+ rate: T(t),
2483
+ onload: h,
2423
2484
  ...s
2424
2485
  });
2425
- }), j(
2486
+ }), F(
2426
2487
  () => [e],
2427
2488
  () => {
2428
2489
  a.value && a.value && c && c.value && (c.value = new a.value({
2429
- src: R(e),
2430
- volume: R(o),
2431
- rate: R(t),
2432
- onload: b,
2490
+ src: T(e),
2491
+ volume: T(o),
2492
+ rate: T(t),
2493
+ onload: h,
2433
2494
  ...s
2434
2495
  }));
2435
2496
  }
2436
- ), j(
2437
- () => [R(o), R(t)],
2497
+ ), F(
2498
+ () => [T(o), T(t)],
2438
2499
  () => {
2439
- c.value && (c.value.volume(R(o)), c.value.rate(R(t)));
2500
+ c.value && (c.value.volume(T(o)), c.value.rate(T(t)));
2440
2501
  }
2441
2502
  ), {
2442
- play: (E) => {
2443
- typeof E > "u" && (E = {}), !(!c.value || !n && !E.forceSoundEnabled) && (l && c.value.stop(), E.playbackRate && c.value.rate(E.playbackRate), c.value.play(E.id), c.value.once("end", () => {
2503
+ play: (L) => {
2504
+ typeof L > "u" && (L = {}), !(!c.value || !n && !L.forceSoundEnabled) && (l && c.value.stop(), L.playbackRate && c.value.rate(L.playbackRate), c.value.play(L.id), c.value.once("end", () => {
2444
2505
  c.value && c.value && !c.value.playing() && (u.value = !1);
2445
2506
  }), u.value = !0);
2446
2507
  },
2447
2508
  sound: c,
2448
2509
  isPlaying: u,
2449
2510
  duration: v,
2450
- pause: (E) => {
2451
- c.value && (c.value.pause(typeof E == "number" ? E : void 0), u.value = !1);
2511
+ pause: (L) => {
2512
+ c.value && (c.value.pause(typeof L == "number" ? L : void 0), u.value = !1);
2452
2513
  },
2453
- stop: (E) => {
2454
- c.value && (c.value.stop(typeof E == "number" ? E : void 0), u.value = !1);
2514
+ stop: (L) => {
2515
+ c.value && (c.value.stop(typeof L == "number" ? L : void 0), u.value = !1);
2455
2516
  }
2456
2517
  };
2457
2518
  }
2458
- const ll = { class: "swap" }, sl = /* @__PURE__ */ I("svg", {
2459
- class: "swap-off fill-current h-4 w-4",
2460
- xmlns: "http://www.w3.org/2000/svg",
2461
- viewBox: "0 0 24 24"
2462
- }, [
2463
- /* @__PURE__ */ I("path", { d: "M14,3.23V5.29C16.89,6.15 19,8.83 19,12C19,15.17 16.89,17.84 14,18.7V20.77C18,19.86 21,16.28 21,12C21,7.72 18,4.14 14,3.23M16.5,12C16.5,10.23 15.5,8.71 14,7.97V16C15.5,15.29 16.5,13.76 16.5,12M3,9V15H7L12,20V4L7,9H3Z" })
2464
- ], -1), rl = /* @__PURE__ */ I("svg", {
2465
- class: "swap-on fill-current h-4 w-4",
2466
- xmlns: "http://www.w3.org/2000/svg",
2467
- viewBox: "0 0 24 24"
2468
- }, [
2469
- /* @__PURE__ */ I("path", {
2470
- "fill-rule": "evenodd",
2471
- d: "M4.5 7.5a3 3 0 0 1 3-3h9a3 3 0 0 1 3 3v9a3 3 0 0 1-3 3h-9a3 3 0 0 1-3-3v-9Z",
2472
- "clip-rule": "evenodd"
2473
- })
2474
- ], -1), il = {
2519
+ const S2 = {
2520
+ key: 0,
2521
+ src: y2,
2522
+ alt: "Play"
2523
+ }, O2 = {
2524
+ key: 1,
2525
+ src: w2,
2526
+ alt: "Stop"
2527
+ }, $2 = {
2475
2528
  __name: "SpeakBtn",
2476
2529
  props: {
2477
2530
  url: {
@@ -2480,8 +2533,8 @@ const ll = { class: "swap" }, sl = /* @__PURE__ */ I("svg", {
2480
2533
  }
2481
2534
  },
2482
2535
  setup(e) {
2483
- const o = e, { play: t, stop: n, isPlaying: l } = ol(o.url), r = S(!1);
2484
- j(
2536
+ const o = e, { play: t, stop: n, isPlaying: l } = E2(o.url), r = E(!1);
2537
+ F(
2485
2538
  () => l.value,
2486
2539
  (s) => {
2487
2540
  r.value = s;
@@ -2494,45 +2547,48 @@ const ll = { class: "swap" }, sl = /* @__PURE__ */ I("svg", {
2494
2547
  }
2495
2548
  t();
2496
2549
  }
2497
- return (s, a) => (P(), V("button", {
2550
+ return (s, a) => (w(), O("button", {
2498
2551
  class: "btn btn-xs btn-ghost btn-circle",
2499
- onClick: fn(i, ["prevent"])
2552
+ onClick: pn(i, ["prevent"])
2500
2553
  }, [
2501
- I("label", ll, [
2502
- Xe(I("input", {
2503
- "onUpdate:modelValue": a[0] || (a[0] = (u) => r.value = u),
2504
- type: "checkbox"
2505
- }, null, 512), [
2506
- [vn, r.value]
2507
- ]),
2508
- sl,
2509
- rl
2510
- ])
2554
+ T(l) ? (w(), O("img", O2)) : (w(), O("img", S2))
2511
2555
  ]));
2512
2556
  }
2513
- }, al = {}, ul = /* @__PURE__ */ I("svg", {
2514
- xmlns: "http://www.w3.org/2000/svg",
2515
- fill: "none",
2516
- viewBox: "0 0 24 24",
2517
- "stroke-width": "1.5",
2518
- stroke: "currentColor",
2519
- class: "w-5 h-5"
2520
- }, [
2521
- /* @__PURE__ */ I("path", {
2522
- "stroke-linecap": "round",
2523
- "stroke-linejoin": "round",
2524
- d: "m9.75 9.75 4.5 4.5m0-4.5-4.5 4.5M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"
2525
- })
2526
- ], -1), cl = [
2527
- ul
2557
+ }, I2 = "data:image/svg+xml,%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M3.19102%203.19102C3.44571%202.93633%203.85864%202.93633%204.11333%203.19102L12.809%2011.8867C13.0637%2012.1414%2013.0637%2012.5543%2012.809%2012.809C12.5543%2013.0637%2012.1414%2013.0637%2011.8867%2012.809L3.19102%204.11333C2.93633%203.85864%202.93633%203.44571%203.19102%203.19102Z'%20fill='%231A1F2A'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M12.809%203.19102C13.0637%203.44571%2013.0637%203.85864%2012.809%204.11333L4.11333%2012.809C3.85864%2013.0637%203.44571%2013.0637%203.19102%2012.809C2.93633%2012.5543%202.93633%2012.1414%203.19102%2011.8867L11.8867%203.19102C12.1414%202.93633%2012.5543%202.93633%2012.809%203.19102Z'%20fill='%231A1F2A'/%3e%3c/svg%3e", L2 = {}, T2 = { class: "btn btn-xs btn-circle btn-ghost" }, V2 = /* @__PURE__ */ g("img", {
2558
+ src: I2,
2559
+ alt: "Clear",
2560
+ class: "w-4"
2561
+ }, null, -1), P2 = [
2562
+ V2
2528
2563
  ];
2529
- function dl(e, o) {
2530
- return P(), V("button", {
2531
- class: "btn btn-xs btn-ghost btn-circle p-0",
2532
- onClick: o[0] || (o[0] = (...t) => e.onClick && e.onClick(...t))
2533
- }, cl);
2564
+ function M2(e, o) {
2565
+ return w(), O("button", T2, P2);
2534
2566
  }
2535
- const fl = /* @__PURE__ */ ze(al, [["render", dl]]), vl = { class: "flex flex-row rounded-t-lg bg-white border border-b-0 px-1 pr-1 pt-1 gap-1 items-center" }, pl = { class: "text-sm italic" }, hl = { key: 0 }, ml = /* @__PURE__ */ I("div", { class: "flex-grow" }, " ", -1), on = {
2567
+ const k2 = /* @__PURE__ */ ze(L2, [["render", M2]]), R2 = "data:image/svg+xml,%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M7.47207%201.31905C7.57125%201.12371%207.77589%201%208.00001%201C8.22413%201%208.42877%201.12367%208.52795%201.31905L10.3721%204.95175L14.4959%205.53427C14.7177%205.5656%2014.9019%205.7166%2014.9712%205.9238C15.0404%206.13101%2014.9827%206.35843%2014.8222%206.51049L11.8382%209.33816L12.5427%2013.3309C12.5806%2013.5456%2012.4897%2013.7626%2012.3084%2013.8906C12.1272%2014.0187%2011.8868%2014.0356%2011.6884%2013.9342L8.00004%2012.0491L4.31158%2013.9343C4.11323%2014.0356%203.87286%2014.0187%203.69157%2013.8907C3.51028%2013.7627%203.4195%2013.5457%203.45736%2013.3309L4.1618%209.33819L1.17781%206.51052C1.01735%206.35846%200.959571%206.13101%201.02884%205.92383C1.09807%205.71663%201.28232%205.56563%201.50409%205.53431L5.62787%204.95178L7.47207%201.31905Z'%20fill='%23FFC857'/%3e%3c/svg%3e", N2 = "data:image/svg+xml,%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M14.9491%205.89315C14.8278%205.53128%2014.5111%205.27252%2014.1226%205.21783L10.5264%204.7114L8.91813%201.55315C8.74435%201.21195%208.39257%201%207.99998%201C7.60739%201%207.25557%201.21195%207.08183%201.55315L5.47358%204.7114L1.8774%205.21783C1.48888%205.27252%201.17219%205.53128%201.05086%205.89315C0.929554%206.25501%201.02881%206.64477%201.30993%206.91038L3.91217%209.36871L3.29786%2012.8399C3.2315%2013.215%203.38755%2013.5868%203.7052%2013.8105C3.88128%2013.9344%204.08938%2014%204.30704%2014C4.47232%2014%204.63705%2013.9606%204.78341%2013.886L7.99995%2012.2471L11.2165%2013.886C11.3628%2013.9606%2011.5276%2014%2011.6929%2014C11.9106%2014%2012.1187%2013.9345%2012.2948%2013.8105C12.6124%2013.5868%2012.7685%2013.215%2012.7021%2012.84L12.0878%209.36871L14.6901%206.91035C14.9712%206.64477%2015.0704%206.25498%2014.9491%205.89315ZM14.0266%206.25082L11.2455%208.87813C11.1335%208.98392%2011.0824%209.13637%2011.1089%209.28575L11.7654%2012.9956C11.7701%2013.0226%2011.759%2013.0493%2011.7362%2013.0653C11.7202%2013.0766%2011.7038%2013.079%2011.6929%2013.079C11.6809%2013.079%2011.6694%2013.0762%2011.6587%2013.0708L8.22108%2011.3192C8.15189%2011.284%208.07593%2011.2663%207.99998%2011.2663C7.92402%2011.2663%207.84807%2011.284%207.77882%2011.3193L4.34118%2013.0708C4.33052%2013.0763%204.31904%2013.079%204.30701%2013.079C4.29611%2013.079%204.27969%2013.0767%204.26373%2013.0654C4.24092%2013.0494%204.22975%2013.0226%204.2345%2012.9957L4.89104%209.28584C4.91747%209.13646%204.86637%208.98401%204.75439%208.87822L1.97327%206.25091C1.95308%206.23184%201.94595%206.20383%201.95466%206.17786C1.9634%206.15185%201.98612%206.13326%202.01405%206.12933L5.85743%205.58807C6.0122%205.56626%206.14599%205.47208%206.21521%205.33616L7.93404%201.9608C7.94653%201.9363%207.97178%201.92107%207.99998%201.92107C8.02818%201.92107%208.05343%201.9363%208.06591%201.9608L9.78468%205.33607C9.85391%205.47199%209.9877%205.5662%2010.1425%205.58799L13.9859%206.12924C14.0138%206.1332%2014.0365%206.15176%2014.0452%206.17777C14.0539%206.20374%2014.0468%206.23175%2014.0266%206.25082Z'%20fill='%231A1F2A'/%3e%3c/svg%3e", D2 = { class: "btn btn-xs btn-circle btn-ghost" }, A2 = {
2568
+ key: 0,
2569
+ src: R2,
2570
+ alt: "Clear",
2571
+ class: "w-4"
2572
+ }, F2 = {
2573
+ key: 1,
2574
+ src: N2,
2575
+ alt: "Clear",
2576
+ class: "w-4"
2577
+ }, j2 = {
2578
+ __name: "FavoriteBtn",
2579
+ props: {
2580
+ isFilled: Boolean
2581
+ },
2582
+ setup(e) {
2583
+ const o = e;
2584
+ return (t, n) => (w(), O("button", D2, [
2585
+ o.isFilled ? (w(), O("img", A2)) : (w(), O("img", F2))
2586
+ ]));
2587
+ }
2588
+ }, B2 = { class: "flex flex-row rounded-t-lg bg-white border border-b-0 px-1 pr-1 pt-1 gap-1 items-center" }, H2 = { class: "text-sm text-gray-600" }, z2 = {
2589
+ key: 0,
2590
+ class: "italic"
2591
+ }, U2 = /* @__PURE__ */ g("div", { class: "flex-grow" }, null, -1), sn = {
2536
2592
  __name: "TranslationBtnGroup",
2537
2593
  props: {
2538
2594
  loading: {
@@ -2558,74 +2614,93 @@ const fl = /* @__PURE__ */ ze(al, [["render", dl]]), vl = { class: "flex flex-ro
2558
2614
  isClearBtn: {
2559
2615
  type: Boolean,
2560
2616
  default: !1
2617
+ },
2618
+ isFavoriteBtn: {
2619
+ type: Boolean,
2620
+ default: !1
2621
+ },
2622
+ isFavorite: {
2623
+ type: Boolean,
2624
+ default: !1
2625
+ },
2626
+ onFavorite: {
2627
+ type: Function,
2628
+ default: () => {
2629
+ }
2561
2630
  }
2562
2631
  },
2563
- emits: ["clear"],
2632
+ emits: ["clear", "favorite"],
2564
2633
  setup(e, { emit: o }) {
2565
2634
  const t = e, n = o;
2566
- return (l, r) => (P(), V("div", vl, [
2567
- t.tts ? (P(), xe(il, {
2635
+ return (l, r) => (w(), O("div", B2, [
2636
+ t.tts ? (w(), X($2, {
2568
2637
  key: 0,
2569
2638
  url: t.tts
2570
- }, null, 8, ["url"])) : ue("", !0),
2571
- I("div", pl, [
2572
- pn(ne(e.srcLabel) + " ", 1),
2573
- e.phonetic ? (P(), V("span", hl, "― " + ne(t.phonetic), 1)) : ue("", !0)
2639
+ }, null, 8, ["url"])) : Q("", !0),
2640
+ g("div", H2, [
2641
+ hn(ee(e.srcLabel) + " ", 1),
2642
+ e.phonetic ? (w(), O("span", z2, "- [" + ee(t.phonetic) + "]", 1)) : Q("", !0)
2574
2643
  ]),
2575
- ml,
2576
- t.loading ? (P(), xe(nl, { key: 1 })) : ue("", !0),
2577
- t.src && t.isClearBtn ? (P(), xe(fl, {
2644
+ U2,
2645
+ t.loading ? (w(), X(x2, { key: 1 })) : Q("", !0),
2646
+ t.src && t.isClearBtn ? (w(), X(k2, {
2578
2647
  key: 2,
2579
2648
  onClick: r[0] || (r[0] = (i) => n("clear"))
2580
- })) : ue("", !0)
2649
+ })) : Q("", !0),
2650
+ t.src && t.isFavoriteBtn ? (w(), X(j2, {
2651
+ key: 3,
2652
+ isFilled: t.isFavorite,
2653
+ onClick: r[1] || (r[1] = (i) => n("favorite"))
2654
+ }, null, 8, ["isFilled"])) : Q("", !0)
2581
2655
  ]));
2582
2656
  }
2583
- }, ye = lt("translation", () => {
2584
- const e = S(null), o = S(null), t = S({
2657
+ }, me = rt("translation", () => {
2658
+ const e = E(null), o = E(null), t = E({
2585
2659
  src: null,
2586
2660
  target: null
2587
- }), n = S(null), l = S([]), r = S([]), i = S([]), s = S({
2661
+ }), n = E(null), l = E([]), r = E([]), i = E([]), s = E([]), a = E({
2588
2662
  src: null,
2589
2663
  target: null
2590
- }), a = st(), u = _(() => a.getLabel(e.value)), v = _(() => a.getLabel(o.value));
2591
- function c(m) {
2592
- e.value = m.src, o.value = m.target, t.value = m.phonetic, n.value = m.result, l.value = m.dictionary, r.value = m.definitions, i.value = m.examples, s.value = m.tts;
2664
+ }), u = He(), v = y(() => u.getLabel(e.value)), c = y(() => u.getLabel(o.value));
2665
+ function h(p) {
2666
+ e.value = p.src, o.value = p.target, t.value = p.phonetic, n.value = p.result, l.value = p.dictionary, r.value = p.definitions, i.value = p.synonyms, s.value = p.examples, a.value = p.tts;
2593
2667
  }
2594
- function b() {
2668
+ function m() {
2595
2669
  e.value = null, o.value = null, t.value = {
2596
2670
  src: null,
2597
2671
  target: null
2598
- }, n.value = null, l.value = [], r.value = [], i.value = [], s.value = {
2672
+ }, n.value = null, l.value = [], r.value = [], i.value = [], s.value = [], a.value = {
2599
2673
  src: null,
2600
2674
  target: null
2601
2675
  };
2602
2676
  }
2603
2677
  return {
2604
2678
  src: e,
2605
- srcLabel: u,
2679
+ srcLabel: v,
2606
2680
  target: o,
2607
- targetLabel: v,
2681
+ targetLabel: c,
2608
2682
  phonetic: t,
2609
2683
  result: n,
2610
2684
  dictionary: l,
2611
2685
  definitions: r,
2612
- examples: i,
2613
- tts: s,
2614
- init: c,
2615
- reset: b
2686
+ synonyms: i,
2687
+ examples: s,
2688
+ tts: a,
2689
+ init: h,
2690
+ reset: m
2616
2691
  };
2617
2692
  });
2618
- function gl(e) {
2619
- return Ct() ? (Ye(e), !0) : !1;
2693
+ function Z2(e) {
2694
+ return It() ? (Xe(e), !0) : !1;
2620
2695
  }
2621
- function Ae(e) {
2622
- return typeof e == "function" ? e() : R(e);
2696
+ function Fe(e) {
2697
+ return typeof e == "function" ? e() : T(e);
2623
2698
  }
2624
- const bl = typeof window < "u" && typeof document < "u";
2699
+ const W2 = typeof window < "u" && typeof document < "u";
2625
2700
  typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
2626
- const wt = () => {
2701
+ const xt = () => {
2627
2702
  };
2628
- function yl(e, o) {
2703
+ function G2(e, o) {
2629
2704
  function t(...n) {
2630
2705
  return new Promise((l, r) => {
2631
2706
  Promise.resolve(e(() => o.apply(this, n), { fn: o, thisArg: this, args: n })).then(l).catch(r);
@@ -2633,13 +2708,13 @@ function yl(e, o) {
2633
2708
  }
2634
2709
  return t;
2635
2710
  }
2636
- function _l(e, o = {}) {
2637
- let t, n, l = wt;
2711
+ function q2(e, o = {}) {
2712
+ let t, n, l = xt;
2638
2713
  const r = (s) => {
2639
- clearTimeout(s), l(), l = wt;
2714
+ clearTimeout(s), l(), l = xt;
2640
2715
  };
2641
2716
  return (s) => {
2642
- const a = Ae(e), u = Ae(o.maxWait);
2717
+ const a = Fe(e), u = Fe(o.maxWait);
2643
2718
  return t && r(t), a <= 0 || u !== void 0 && u <= 0 ? (n && (r(n), n = null), Promise.resolve(s())) : new Promise((v, c) => {
2644
2719
  l = o.rejectOnCancel ? c : v, u && !n && (n = setTimeout(() => {
2645
2720
  t && r(t), n = null, v(s());
@@ -2649,72 +2724,72 @@ function _l(e, o = {}) {
2649
2724
  });
2650
2725
  };
2651
2726
  }
2652
- function wl(e, o = 200, t = {}) {
2653
- return yl(
2654
- _l(o, t),
2727
+ function J2(e, o = 200, t = {}) {
2728
+ return G2(
2729
+ q2(o, t),
2655
2730
  e
2656
2731
  );
2657
2732
  }
2658
- function xt(e) {
2733
+ function yt(e) {
2659
2734
  var o;
2660
- const t = Ae(e);
2735
+ const t = Fe(e);
2661
2736
  return (o = t == null ? void 0 : t.$el) != null ? o : t;
2662
2737
  }
2663
- const xl = bl ? window : void 0;
2664
- function Sl() {
2665
- const e = S(!1), o = $t();
2666
- return o && de(() => {
2738
+ const K2 = W2 ? window : void 0;
2739
+ function Y2() {
2740
+ const e = E(!1), o = $t();
2741
+ return o && ve(() => {
2667
2742
  e.value = !0;
2668
2743
  }, o), e;
2669
2744
  }
2670
- function Ol(e) {
2671
- const o = Sl();
2672
- return _(() => (o.value, !!e()));
2745
+ function Q2(e) {
2746
+ const o = Y2();
2747
+ return y(() => (o.value, !!e()));
2673
2748
  }
2674
- function El(e, o, t = {}) {
2675
- const { window: n = xl, ...l } = t;
2749
+ function X2(e, o, t = {}) {
2750
+ const { window: n = K2, ...l } = t;
2676
2751
  let r;
2677
- const i = Ol(() => n && "ResizeObserver" in n), s = () => {
2752
+ const i = Q2(() => n && "ResizeObserver" in n), s = () => {
2678
2753
  r && (r.disconnect(), r = void 0);
2679
- }, a = _(() => Array.isArray(e) ? e.map((c) => xt(c)) : [xt(e)]), u = j(
2754
+ }, a = y(() => Array.isArray(e) ? e.map((c) => yt(c)) : [yt(e)]), u = F(
2680
2755
  a,
2681
2756
  (c) => {
2682
2757
  if (s(), i.value && n) {
2683
2758
  r = new ResizeObserver(o);
2684
- for (const b of c)
2685
- b && r.observe(b, l);
2759
+ for (const h of c)
2760
+ h && r.observe(h, l);
2686
2761
  }
2687
2762
  },
2688
2763
  { immediate: !0, flush: "post" }
2689
2764
  ), v = () => {
2690
2765
  s(), u();
2691
2766
  };
2692
- return gl(v), {
2767
+ return Z2(v), {
2693
2768
  isSupported: i,
2694
2769
  stop: v
2695
2770
  };
2696
2771
  }
2697
- function ln(e) {
2772
+ function rn(e) {
2698
2773
  var o;
2699
- const t = S(e == null ? void 0 : e.element), n = S(e == null ? void 0 : e.input), l = (o = e == null ? void 0 : e.styleProp) != null ? o : "height", r = S(1);
2774
+ const t = E(e == null ? void 0 : e.element), n = E(e == null ? void 0 : e.input), l = (o = e == null ? void 0 : e.styleProp) != null ? o : "height", r = E(1);
2700
2775
  function i() {
2701
2776
  var s;
2702
2777
  if (!t.value)
2703
2778
  return;
2704
2779
  let a = "";
2705
- t.value.style[l] = "1px", r.value = (s = t.value) == null ? void 0 : s.scrollHeight, e != null && e.styleTarget ? Ae(e.styleTarget).style[l] = `${r.value}px` : a = `${r.value}px`, t.value.style[l] = a;
2780
+ t.value.style[l] = "1px", r.value = (s = t.value) == null ? void 0 : s.scrollHeight, e != null && e.styleTarget ? Fe(e.styleTarget).style[l] = `${r.value}px` : a = `${r.value}px`, t.value.style[l] = a;
2706
2781
  }
2707
- return j([n, t], () => Q(i), { immediate: !0 }), j(r, () => {
2782
+ return F([n, t], () => te(i), { immediate: !0 }), F(r, () => {
2708
2783
  var s;
2709
2784
  return (s = e == null ? void 0 : e.onResize) == null ? void 0 : s.call(e);
2710
- }), El(t, () => i()), e != null && e.watch && j(e.watch, i, { immediate: !0, deep: !0 }), {
2785
+ }), X2(t, () => i()), e != null && e.watch && F(e.watch, i, { immediate: !0, deep: !0 }), {
2711
2786
  textarea: t,
2712
2787
  input: n,
2713
2788
  triggerResize: i
2714
2789
  };
2715
2790
  }
2716
- const Il = {
2717
- __name: "Input",
2791
+ const el = {
2792
+ __name: "TranslationInput",
2718
2793
  props: {
2719
2794
  text: {
2720
2795
  type: String,
@@ -2723,16 +2798,16 @@ const Il = {
2723
2798
  },
2724
2799
  emits: ["change", "clear"],
2725
2800
  setup(e, { emit: o }) {
2726
- const t = ye(), l = S(e.text), r = _(() => t.src), i = _(() => t.srcLabel), s = _(() => {
2727
- var w;
2728
- return (w = t.phonetic) == null ? void 0 : w.src;
2729
- }), a = _(() => {
2730
- var w;
2731
- return (w = t.tts) == null ? void 0 : w.src;
2732
- }), { textarea: u } = ln({ input: l, styleProp: "minHeight" }), v = o, c = wl(() => {
2801
+ const t = me(), n = e, l = E(n.text), r = y(() => t.src), i = y(() => t.srcLabel), s = y(() => {
2802
+ var p;
2803
+ return (p = t.phonetic) == null ? void 0 : p.src;
2804
+ }), a = y(() => {
2805
+ var p;
2806
+ return (p = t.tts) == null ? void 0 : p.src;
2807
+ }), { textarea: u } = rn({ input: l, styleProp: "minHeight" }), v = o, c = J2(() => {
2733
2808
  v("change", l.value);
2734
- }, Zo.INPUT_DEBOUNCE);
2735
- function b() {
2809
+ }, g2.INPUT_DEBOUNCE);
2810
+ function h() {
2736
2811
  if (!l.value) {
2737
2812
  m();
2738
2813
  return;
@@ -2742,8 +2817,13 @@ const Il = {
2742
2817
  function m() {
2743
2818
  v("clear"), l.value = "", u.value.focus();
2744
2819
  }
2745
- return (w, $) => (P(), V(X, null, [
2746
- H(on, {
2820
+ return F(
2821
+ () => n.text,
2822
+ (p) => {
2823
+ l.value = p;
2824
+ }
2825
+ ), (p, $) => (w(), O(W, null, [
2826
+ H(sn, {
2747
2827
  src: r.value,
2748
2828
  srcLabel: i.value,
2749
2829
  tts: a.value,
@@ -2751,14 +2831,14 @@ const Il = {
2751
2831
  isClearBtn: !0,
2752
2832
  onClear: m
2753
2833
  }, null, 8, ["src", "srcLabel", "tts", "phonetic"]),
2754
- Xe(I("textarea", {
2834
+ Lt(g("textarea", {
2755
2835
  ref_key: "textarea",
2756
2836
  ref: u,
2757
- "onUpdate:modelValue": $[0] || ($[0] = (M) => l.value = M),
2758
- class: "w-full border border-t-0 rounded-b-lg outline-none outline-0 p-3 pt-0",
2837
+ "onUpdate:modelValue": $[0] || ($[0] = (N) => l.value = N),
2838
+ class: "w-full border rounded-b-md border-t-0 outline-none outline-0 px-3 pl-5 bg-white text-gray-800 font-semibold resize-none pb-3",
2759
2839
  autofocus: "",
2760
2840
  rows: "2",
2761
- onInput: b
2841
+ onInput: h
2762
2842
  }, null, 544), [
2763
2843
  [
2764
2844
  Tt,
@@ -2769,117 +2849,240 @@ const Il = {
2769
2849
  ])
2770
2850
  ], 64));
2771
2851
  }
2772
- }, $l = /* @__PURE__ */ ze(Il, [["__scopeId", "data-v-601b7a18"]]), sn = lt("loader", () => ({ loading: S(!1) })), Cl = {
2773
- __name: "Result",
2852
+ }, tl = /* @__PURE__ */ ze(el, [["__scopeId", "data-v-ef4399dd"]]), nl = "data:image/svg+xml,%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M13.2018%204.409H8.2373L7.46364%202H2.79867C2.35907%202%202%202.3595%202%202.7995V10.937C2%2011.376%202.36008%2011.7355%202.79867%2011.7355H7.79971L8.53636%2014H13.2013C13.6404%2014%2014%2013.6465%2014%2013.214V5.195C14%204.7625%2013.6404%204.409%2013.2018%204.409ZM5.3702%208.749C4.33499%208.749%203.49481%207.909%203.49481%206.874C3.49481%205.839%204.33499%204.999%205.3702%204.999C5.87631%204.999%206.3004%205.1865%206.62646%205.487L6.13136%205.963C5.9244%205.77181%205.65196%205.66729%205.3702%205.671C4.71757%205.671%204.18846%206.211%204.18846%206.8755C4.18846%207.54%204.71757%208.08%205.3697%208.08C6.12336%208.08%206.43492%207.54%206.46493%207.176L5.3707%207.175V6.533H7.12607C7.15107%206.648%207.17108%206.7615%207.17108%206.915C7.17108%207.9885%206.45393%208.7495%205.3697%208.7495L5.3702%208.749ZM13.7504%2013.214C13.7504%2013.509%2013.5044%2013.75%2013.2018%2013.75H8.76341L10.5883%2011.735H10.5908L10.2207%2010.584L10.2237%2010.5815C10.2237%2010.5815%2010.5078%2010.3375%2010.8623%209.9615C11.2184%2010.347%2011.6775%2010.811%2012.2716%2011.364L12.6572%2010.978C12.0211%2010.401%2011.555%209.943%2011.2119%209.5755C11.6715%209.032%2012.1381%208.348%2012.2366%207.722H13.2538V7.723H13.2548V7.253H10.9884V6.493H10.2527V7.253H9.15049L8.31432%204.648L8.31732%204.659H13.2018C13.5044%204.659%2013.7504%204.899%2013.7504%205.195V13.214ZM10.5078%209.5585C10.2397%209.8325%2010.0362%209.995%2010.0362%209.995L10.0322%209.997L9.30202%207.723H11.6845C11.531%208.265%2011.1904%208.777%2010.8588%209.175C10.2707%208.479%2010.2687%208.253%2010.2687%208.253H9.6576C9.6576%208.253%209.6826%208.5925%2010.5078%209.5585Z'%20fill='%237E7E7E'/%3e%3c/svg%3e", an = rt("loader", () => ({ loading: E(!1) })), ol = (e) => (mn("data-v-5a9dbf88"), e = e(), gn(), e), ll = { class: "flex flex-col" }, sl = /* @__PURE__ */ ol(() => /* @__PURE__ */ g("div", { class: "w-full flex align-item-center justify-end" }, [
2853
+ /* @__PURE__ */ g("span", { class: "text-sm" }, "Powered by Google Translate"),
2854
+ /* @__PURE__ */ g("img", {
2855
+ src: nl,
2856
+ alt: "Google",
2857
+ class: "h-5 ml-2"
2858
+ })
2859
+ ], -1)), rl = {
2860
+ __name: "TranslationResult",
2861
+ props: {
2862
+ isFavoriteFeatureEnabled: Boolean
2863
+ },
2774
2864
  setup(e) {
2775
- const o = ye(), t = _(() => o.result), n = _(() => o.target), l = _(() => o.targetLabel), r = _(() => {
2776
- var v;
2777
- return (v = o.phonetic) == null ? void 0 : v.target;
2778
- }), i = _(() => {
2779
- var v;
2780
- return (v = o.tts) == null ? void 0 : v.target;
2781
- }), s = sn(), { textarea: a, input: u } = ln({ input: t, styleProp: "minHeight" });
2782
- return (v, c) => (P(), V(X, null, [
2783
- H(on, {
2784
- loading: R(s).loading,
2785
- src: n.value,
2786
- srcLabel: l.value,
2787
- tts: i.value,
2788
- phonetic: r.value
2789
- }, null, 8, ["loading", "src", "srcLabel", "tts", "phonetic"]),
2790
- Xe(I("textarea", {
2791
- ref_key: "textarea",
2792
- ref: a,
2793
- "onUpdate:modelValue": c[0] || (c[0] = (b) => be(u) ? u.value = b : null),
2794
- class: "w-full border border-t-0 rounded-b-lg outline-none outline-0 p-3 pt-0",
2795
- readonly: "",
2796
- rows: "2",
2797
- spellcheck: "false"
2798
- }, null, 512), [
2799
- [Tt, R(u)]
2865
+ const o = me(), t = E(!1), n = y(() => o.result), l = y(() => o.target), r = y(() => o.targetLabel), i = y(() => {
2866
+ var h;
2867
+ return (h = o.phonetic) == null ? void 0 : h.target;
2868
+ }), s = y(() => {
2869
+ var h;
2870
+ return (h = o.tts) == null ? void 0 : h.target;
2871
+ }), a = e, u = an(), { textarea: v, input: c } = rn({ input: n, styleProp: "minHeight" });
2872
+ return (h, m) => (w(), O(W, null, [
2873
+ H(sn, {
2874
+ loading: T(u).loading,
2875
+ src: l.value,
2876
+ srcLabel: r.value,
2877
+ tts: s.value,
2878
+ isFavoriteBtn: a.isFavoriteFeatureEnabled,
2879
+ isFavorite: t.value,
2880
+ phonetic: i.value,
2881
+ onFavorite: m[0] || (m[0] = (p) => t.value = !t.value)
2882
+ }, null, 8, ["loading", "src", "srcLabel", "tts", "isFavoriteBtn", "isFavorite", "phonetic"]),
2883
+ g("div", ll, [
2884
+ Lt(g("textarea", {
2885
+ ref_key: "textarea",
2886
+ ref: v,
2887
+ "onUpdate:modelValue": m[1] || (m[1] = (p) => xe(c) ? c.value = p : null),
2888
+ class: "w-full border rounded-b-md border-t-0 outline-none outline-0 px-3 pl-5 bg-white text-gray-800 font-semibold resize-none pb-3",
2889
+ readonly: "",
2890
+ rows: "2",
2891
+ spellcheck: "false"
2892
+ }, null, 512), [
2893
+ [Tt, T(c)]
2894
+ ]),
2895
+ sl
2800
2896
  ])
2801
2897
  ], 64));
2802
2898
  }
2803
- }, Tl = /* @__PURE__ */ ze(Cl, [["__scopeId", "data-v-6c3a2370"]]), Pl = { class: "card border bg-white rounded-lg" }, Rl = { class: "card-body p-4" }, kl = /* @__PURE__ */ I("h2", { class: "card-title" }, "Translations", -1), Nl = { class: "capitalize font-bold" }, Vl = { class: "list-none list-inside" }, Dl = ["onClick"], Ll = { class: "italic" }, Ml = {
2804
- __name: "Dictionary",
2899
+ }, il = /* @__PURE__ */ ze(rl, [["__scopeId", "data-v-5a9dbf88"]]), al = { class: "btn btn-sm btn-circle btn-ghost" }, Ue = {
2900
+ __name: "ToggleBtn",
2901
+ props: {
2902
+ isExpanded: Boolean
2903
+ },
2805
2904
  setup(e) {
2806
- const o = ye(), t = _(() => o.dictionary);
2807
- return (n, l) => (P(), V("div", Pl, [
2808
- I("div", Rl, [
2809
- kl,
2810
- I("ul", null, [
2811
- (P(!0), V(X, null, ge(t.value, (r, i) => (P(), V("li", {
2812
- key: `${r.pos}-${i}`,
2813
- class: "mb-3"
2814
- }, [
2815
- I("h5", Nl, ne(r.pos), 1),
2816
- I("ul", Vl, [
2817
- (P(!0), V(X, null, ge(r.items, (s, a) => (P(), V("li", {
2818
- key: `${s.word}-${a}`
2819
- }, [
2820
- I("span", {
2821
- class: "badge badge-neutral text-white cursor-pointer",
2822
- onClick: (u) => n.translate(s.word)
2823
- }, ne(s.word), 9, Dl),
2824
- I("small", Ll, " ― " + ne(s.reverse_translation.join(", ")), 1)
2825
- ]))), 128))
2826
- ])
2827
- ]))), 128))
2828
- ])
2905
+ const o = e;
2906
+ return (t, n) => (w(), O("button", al, [
2907
+ o.isExpanded ? (w(), X(T(ko), {
2908
+ key: 0,
2909
+ class: "w-7 text-gray-400"
2910
+ })) : (w(), X(T(Po), {
2911
+ key: 1,
2912
+ class: "w-7 text-gray-400"
2913
+ }))
2914
+ ]));
2915
+ }
2916
+ }, ul = { class: "card border bg-white rounded-lg" }, cl = { class: "card-body px-4 py-2 gap-0" }, dl = { class: "flex justify-between items-center" }, fl = /* @__PURE__ */ g("h2", { class: "card-title text-base font-bold leading-6 text-textCustom" }, "Translations", -1), vl = { class: "capitalize text-base font-normal text-textSecondary mb-1" }, pl = { class: "list-none list-inside" }, hl = ["onClick"], ml = { class: "text-base font-normal text-gray-800 leading-4" }, gl = {
2917
+ __name: "Dictionary",
2918
+ emits: ["translate"],
2919
+ setup(e, { emit: o }) {
2920
+ const t = E(!0), n = me(), l = He(), r = y(() => n.dictionary), i = o, s = () => {
2921
+ t.value = !t.value;
2922
+ }, a = (u) => {
2923
+ const v = n.src, c = n.target;
2924
+ l.src = c, l.target = v, i("translate", u);
2925
+ };
2926
+ return (u, v) => (w(), O("div", ul, [
2927
+ g("div", cl, [
2928
+ g("div", dl, [
2929
+ fl,
2930
+ H(Ue, {
2931
+ isExpanded: t.value,
2932
+ onClick: s
2933
+ }, null, 8, ["isExpanded"])
2934
+ ]),
2935
+ g("div", {
2936
+ class: _e(["overflow-hidden transition-all duration-300 ease-in-out", t.value ? "max-h-[2000px] opacity-100" : "max-h-0 opacity-0"])
2937
+ }, [
2938
+ g("ul", null, [
2939
+ (w(!0), O(W, null, se(r.value, (c, h) => (w(), O("li", {
2940
+ key: `${c.pos}-${h}`,
2941
+ class: "mb-2"
2942
+ }, [
2943
+ g("h5", vl, ee(c.pos), 1),
2944
+ g("ul", pl, [
2945
+ (w(!0), O(W, null, se(c.items, (m, p) => (w(), O("li", {
2946
+ key: `${m.word}-${p}`
2947
+ }, [
2948
+ g("span", {
2949
+ class: "p-3 m-0.5 font-normal badge badge-ghost bg-primaryColor text-white cursor-pointer border-0 rounded-lg",
2950
+ onClick: ($) => a(m.word)
2951
+ }, ee(m.word), 9, hl),
2952
+ g("small", ml, " - " + ee(m.reverse_translation.join(", ")), 1)
2953
+ ]))), 128))
2954
+ ])
2955
+ ]))), 128))
2956
+ ])
2957
+ ], 2)
2829
2958
  ])
2830
2959
  ]));
2831
2960
  }
2832
- }, Al = { class: "card border bg-white rounded-lg" }, jl = { class: "card-body p-4" }, Fl = /* @__PURE__ */ I("h2", { class: "card-title font-bold" }, "Definitions", -1), zl = { class: "capitalize font-bold mb-0" }, Bl = { class: "list-decimal list-outside ml-5" }, Ul = /* @__PURE__ */ I("br", null, null, -1), Hl = {
2961
+ }, bl = { class: "card border bg-white rounded-lg" }, Cl = { class: "card-body px-4 py-2 gap-0" }, _l = { class: "flex justify-between items-center" }, xl = /* @__PURE__ */ g("h2", { class: "card-title text-base font-bold leading-6 text-textCustom" }, "Definitions", -1), yl = { class: "capitalize text-base font-normal text-textSecondary mb-1" }, wl = { class: "text-base text-textCustom list-decimal list-outside ml-5" }, El = /* @__PURE__ */ g("br", null, null, -1), Sl = {
2833
2962
  key: 0,
2834
2963
  class: "italic"
2835
- }, Wl = {
2964
+ }, Ol = {
2836
2965
  __name: "Definition",
2837
2966
  setup(e) {
2838
- const o = ye(), t = _(() => o.definitions);
2839
- return (n, l) => (P(), V("div", Al, [
2840
- I("div", jl, [
2841
- Fl,
2842
- I("ul", null, [
2843
- (P(!0), V(X, null, ge(t.value, (r, i) => (P(), V("li", {
2844
- key: `${r.pos}-${i}`,
2845
- class: "mb-3"
2846
- }, [
2847
- I("h5", zl, ne(r.pos), 1),
2848
- I("ul", Bl, [
2849
- (P(!0), V(X, null, ge(r.items, (s, a) => (P(), V("li", {
2850
- key: `${s.gloss}-${a}`,
2851
- class: "mb-1"
2852
- }, [
2853
- I("span", null, ne(s.gloss), 1),
2854
- Ul,
2855
- s.example ? (P(), V("small", Hl, '"' + ne(s.example) + '"', 1)) : ue("", !0)
2856
- ]))), 128))
2857
- ])
2858
- ]))), 128))
2859
- ])
2967
+ const o = E(!0), t = me(), n = y(() => t.definitions), l = () => {
2968
+ o.value = !o.value;
2969
+ };
2970
+ return (r, i) => (w(), O("div", bl, [
2971
+ g("div", Cl, [
2972
+ g("div", _l, [
2973
+ xl,
2974
+ H(Ue, {
2975
+ isExpanded: o.value,
2976
+ onClick: l
2977
+ }, null, 8, ["isExpanded"])
2978
+ ]),
2979
+ g("div", {
2980
+ class: _e(["overflow-hidden transition-all duration-300 ease-in-out", o.value ? "max-h-[2000px] opacity-100" : "max-h-0 opacity-0"])
2981
+ }, [
2982
+ g("ul", null, [
2983
+ (w(!0), O(W, null, se(n.value, (s, a) => (w(), O("li", {
2984
+ key: `${s.pos}-${a}`,
2985
+ class: "mb-2"
2986
+ }, [
2987
+ g("h5", yl, ee(s.pos), 1),
2988
+ g("ul", wl, [
2989
+ (w(!0), O(W, null, se(s.items, (u, v) => (w(), O("li", {
2990
+ key: `${u.gloss}-${v}`,
2991
+ class: "mb-1"
2992
+ }, [
2993
+ g("span", null, ee(u.gloss), 1),
2994
+ El,
2995
+ u.example ? (w(), O("small", Sl, '"' + ee(u.example) + '"', 1)) : Q("", !0)
2996
+ ]))), 128))
2997
+ ])
2998
+ ]))), 128))
2999
+ ])
3000
+ ], 2)
2860
3001
  ])
2861
3002
  ]));
2862
3003
  }
2863
- }, Gl = { class: "card border bg-white rounded-lg" }, ql = { class: "card-body p-4" }, Jl = /* @__PURE__ */ I("h2", { class: "card-title font-bold" }, "Examples", -1), Kl = { class: "list-disc list-outside ml-5" }, Yl = ["innerHTML"], Ql = {
3004
+ }, $l = { class: "card border bg-white rounded-lg" }, Il = { class: "card-body px-4 py-2 gap-0" }, Ll = { class: "flex justify-between items-center" }, Tl = /* @__PURE__ */ g("h2", { class: "card-title text-base font-bold leading-6 text-textCustom" }, "Examples", -1), Vl = { class: "text-textCustom list-decimal list-outside ml-7 mt-2" }, Pl = ["innerHTML"], Ml = {
2864
3005
  __name: "Example",
2865
3006
  setup(e) {
2866
- const o = ye(), t = _(() => o.examples);
2867
- return (n, l) => (P(), V("div", Gl, [
2868
- I("div", ql, [
2869
- Jl,
2870
- I("ul", Kl, [
2871
- (P(!0), V(X, null, ge(t.value, (r, i) => (P(), V("li", {
2872
- key: `${r.definition_id}-${i}`,
2873
- innerHTML: r
2874
- }, null, 8, Yl))), 128))
2875
- ])
3007
+ const o = E(!0), t = me(), n = y(() => t.examples), l = () => {
3008
+ o.value = !o.value;
3009
+ };
3010
+ return (r, i) => (w(), O("div", $l, [
3011
+ g("div", Il, [
3012
+ g("div", Ll, [
3013
+ Tl,
3014
+ H(Ue, {
3015
+ isExpanded: o.value,
3016
+ onClick: l
3017
+ }, null, 8, ["isExpanded"])
3018
+ ]),
3019
+ g("div", {
3020
+ class: _e(["overflow-hidden transition-all duration-300 ease-in-out", o.value ? "max-h-[1000px] opacity-100" : "max-h-0 opacity-0"])
3021
+ }, [
3022
+ g("ul", Vl, [
3023
+ (w(!0), O(W, null, se(n.value, (s, a) => (w(), O("li", {
3024
+ key: `${s.definition_id}-${a}`,
3025
+ innerHTML: s
3026
+ }, null, 8, Pl))), 128))
3027
+ ])
3028
+ ], 2)
2876
3029
  ])
2877
3030
  ]));
2878
3031
  }
2879
- }, Zl = { class: "p-2 bg-neutral-100" }, Xl = { class: "mt-2 grid grid-cols-1 md:grid-cols-2 gap-3" }, es = { class: "w-full" }, ts = { class: "w-full" }, ns = {
3032
+ }, kl = { class: "card border bg-white rounded-lg" }, Rl = { class: "card-body px-4 py-2 gap-0" }, Nl = { class: "flex justify-between items-center" }, Dl = /* @__PURE__ */ g("h2", { class: "card-title text-base font-bold leading-6 text-textCustom" }, "Synonyms", -1), Al = { class: "capitalize text-base font-normal text-textSecondary mb-1" }, Fl = { class: "list-none list-inside" }, jl = { class: "flex flex-wrap" }, Bl = ["onClick"], Hl = {
3033
+ __name: "Synonyms",
3034
+ emits: ["translate"],
3035
+ setup(e, { emit: o }) {
3036
+ const t = E(!0), n = me(), l = y(() => n.synonyms), r = o, i = () => {
3037
+ t.value = !t.value;
3038
+ }, s = (a) => {
3039
+ r("translate", a);
3040
+ };
3041
+ return (a, u) => (w(), O("div", kl, [
3042
+ g("div", Rl, [
3043
+ g("div", Nl, [
3044
+ Dl,
3045
+ H(Ue, {
3046
+ isExpanded: t.value,
3047
+ onClick: i
3048
+ }, null, 8, ["isExpanded"])
3049
+ ]),
3050
+ g("div", {
3051
+ class: _e(["overflow-hidden transition-all duration-300 ease-in-out", t.value ? "max-h-[2000px] opacity-100" : "max-h-0 opacity-0"])
3052
+ }, [
3053
+ g("ul", null, [
3054
+ (w(!0), O(W, null, se(l.value, (v, c) => (w(), O("li", {
3055
+ key: `${v.pos}-${c}`,
3056
+ class: "mb-2"
3057
+ }, [
3058
+ g("h5", Al, ee(v.pos), 1),
3059
+ g("ul", Fl, [
3060
+ (w(!0), O(W, null, se(v.items, (h, m) => (w(), O("li", {
3061
+ key: `${h.word}-${m}`,
3062
+ class: "mb-2"
3063
+ }, [
3064
+ g("div", jl, [
3065
+ (w(!0), O(W, null, se(h.synonym, (p, $) => (w(), O("span", {
3066
+ key: `${p}-${$}`,
3067
+ class: "p-3 m-0.5 ml-0 font-normal badge badge-ghost bg-primaryColor text-white cursor-pointer border-0 rounded-lg",
3068
+ onClick: (N) => s(p)
3069
+ }, ee(p), 9, Bl))), 128))
3070
+ ])
3071
+ ]))), 128))
3072
+ ])
3073
+ ]))), 128))
3074
+ ])
3075
+ ], 2)
3076
+ ])
3077
+ ]));
3078
+ }
3079
+ }, zl = { class: "bg-white min-h-screen flex flex-col" }, Ul = { class: "py-2 px-5 shadow-lg" }, Zl = { class: "px-5 flex-grow" }, Wl = { class: "flex flex-col lg:flex-row lg:gap-2" }, Gl = { class: "w-full lg:w-[calc(50%-1rem)] my-2" }, ql = /* @__PURE__ */ g("div", { class: "w-6 h-4 mx-auto hidden lg:block" }, null, -1), Jl = { class: "w-full lg:w-[calc(50%-1rem)] my-2" }, Kl = { class: "grid grid-cols-1 lg:grid-cols-3 gap-4" }, Yl = {
2880
3080
  key: 0,
2881
- class: "mt-3 grid grid-cols-1 md:grid-cols-3 gap-3"
2882
- }, ss = {
3081
+ class: "w-full my-4"
3082
+ }, Ql = /* @__PURE__ */ g("div", { class: "mt-auto py-5 px-5" }, [
3083
+ /* @__PURE__ */ g("span", { class: "block text-center text-gray-700" }, " The site is not affiliated with Google Translate "),
3084
+ /* @__PURE__ */ g("span", { class: "block text-center text-gray-700" }, "Since 2011")
3085
+ ], -1), ts = {
2883
3086
  __name: "Popup",
2884
3087
  props: {
2885
3088
  opt: {
@@ -2893,60 +3096,84 @@ const Il = {
2893
3096
  translation: {
2894
3097
  type: Object,
2895
3098
  default: null
3099
+ },
3100
+ isFavoriteFeatureEnabled: {
3101
+ type: Boolean,
3102
+ default: !1
2896
3103
  }
2897
3104
  },
2898
- emits: ["opt", "translate"],
3105
+ emits: ["opt", "translate", "reader", "settings", "fullscreen"],
2899
3106
  setup(e, { emit: o }) {
2900
- var b;
2901
- const t = Go(), n = ye(t), l = st(t), r = sn(t), i = e, s = o, a = S((b = i.translation) == null ? void 0 : b.text);
2902
- j(
3107
+ var h;
3108
+ const t = d2(), n = me(t), l = He(t), r = an(t), i = e, s = o, a = E((h = i.translation) == null ? void 0 : h.text);
3109
+ F(
2903
3110
  () => i.translation,
2904
3111
  (m) => {
2905
3112
  r.loading = !1, n.init(m);
2906
3113
  },
2907
3114
  { immediate: !0 }
2908
- ), j([() => i.opt, () => i.languages], ([m, w]) => {
2909
- l.init(m, w);
2910
- }), j([() => l.src, () => l.target], ([m, w]) => {
2911
- s("opt", { src: m, target: w }), a.value && c();
2912
- }), de(() => {
3115
+ ), F([() => i.opt, () => i.languages], ([m, p]) => {
3116
+ l.init(m, p);
3117
+ }), F([() => l.src, () => l.target], ([m, p]) => {
3118
+ s("opt", { src: m, target: p }), a.value && c(a.value);
3119
+ }), ve(() => {
2913
3120
  l.init(i.opt, i.languages);
2914
3121
  });
2915
3122
  function u() {
2916
3123
  a.value = "", n.reset();
2917
3124
  }
2918
3125
  function v(m) {
2919
- m && (a.value = m, c());
3126
+ m && c(m);
2920
3127
  }
2921
- function c() {
2922
- r.loading = !0, s("translate", {
3128
+ function c(m) {
3129
+ a.value = m, r.loading = !0, s("translate", {
2923
3130
  src: l.src,
2924
3131
  target: l.target,
2925
- text: a.value
3132
+ text: m
2926
3133
  });
2927
3134
  }
2928
- return (m, w) => (P(), V("div", Zl, [
2929
- H(Qo),
2930
- I("div", Xl, [
2931
- I("div", es, [
2932
- H($l, {
2933
- text: a.value,
2934
- onChange: v,
2935
- onClear: u
2936
- }, null, 8, ["text"])
3135
+ return (m, p) => (w(), O("div", zl, [
3136
+ g("div", Ul, [
3137
+ H(Vn, {
3138
+ onReader: p[0] || (p[0] = ($) => s("reader")),
3139
+ onSettings: p[1] || (p[1] = ($) => s("settings")),
3140
+ onFullScreen: p[2] || (p[2] = ($) => s("fullscreen"))
3141
+ })
3142
+ ]),
3143
+ g("div", Zl, [
3144
+ H(m2, { class: "my-4" }),
3145
+ g("div", Wl, [
3146
+ g("div", Gl, [
3147
+ H(tl, {
3148
+ text: a.value,
3149
+ onChange: v,
3150
+ onClear: u
3151
+ }, null, 8, ["text"])
3152
+ ]),
3153
+ ql,
3154
+ g("div", Jl, [
3155
+ H(il, { isFavoriteFeatureEnabled: e.isFavoriteFeatureEnabled }, null, 8, ["isFavoriteFeatureEnabled"])
3156
+ ])
3157
+ ]),
3158
+ g("div", Kl, [
3159
+ T(n).dictionary.length ? (w(), X(gl, {
3160
+ key: 0,
3161
+ onTranslate: c
3162
+ })) : Q("", !0),
3163
+ T(n).definitions.length ? (w(), X(Ol, { key: 1 })) : Q("", !0),
3164
+ T(n).synonyms.length ? (w(), X(Hl, {
3165
+ key: 2,
3166
+ onTranslate: c
3167
+ })) : Q("", !0)
2937
3168
  ]),
2938
- I("div", ts, [
2939
- H(Tl)
2940
- ])
3169
+ T(n).examples.length ? (w(), O("div", Yl, [
3170
+ H(Ml)
3171
+ ])) : Q("", !0)
2941
3172
  ]),
2942
- i.translation ? (P(), V("div", ns, [
2943
- H(Ml),
2944
- H(Wl),
2945
- H(Ql)
2946
- ])) : ue("", !0)
3173
+ Ql
2947
3174
  ]));
2948
3175
  }
2949
3176
  };
2950
3177
  export {
2951
- ss as default
3178
+ ts as default
2952
3179
  };