@ddict/popup 1.0.13 → 1.0.14
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.css +1 -1
- package/dist/popup.es.js +577 -585
- package/dist/popup.umd.js +7 -7
- package/package.json +1 -1
package/dist/popup.es.js
CHANGED
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
import { openBlock as y, createElementBlock as
|
|
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__ */
|
|
1
|
+
import { openBlock as y, createElementBlock as $, createElementVNode as C, computed as w, unref as k, shallowRef as dn, watch as z, triggerRef as rt, onScopeDispose as Xe, ref as S, onUnmounted as Et, inject as Te, watchEffect as re, onMounted as xe, cloneVNode as St, h as Se, Fragment as Z, defineComponent as ae, provide as et, reactive as Ot, nextTick as Q, toRaw as K, mergeModels as fn, useModel as pn, createBlock as ee, withCtx as Pe, createVNode as B, renderList as le, normalizeClass as Ce, toDisplayString as te, effectScope as $t, markRaw as de, hasInjectionContext as vn, getCurrentInstance as It, isRef as _e, isReactive as tt, toRef as Ze, getCurrentScope as Tt, toRefs as at, createCommentVNode as X, withModifiers as ut, createTextVNode as hn, withDirectives as Lt, vModelText as Pt, 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__ */ C("div", { class: "flex flex-row" }, [
|
|
3
|
+
/* @__PURE__ */ C("img", {
|
|
4
4
|
src: bn,
|
|
5
5
|
alt: "Vue logo",
|
|
6
6
|
class: "w-24"
|
|
7
7
|
})
|
|
8
|
-
], -1), En = { class: "flex" }, Sn = /* @__PURE__ */
|
|
8
|
+
], -1), En = { class: "flex" }, Sn = /* @__PURE__ */ C("img", {
|
|
9
9
|
src: Cn,
|
|
10
10
|
alt: "Reader",
|
|
11
11
|
class: "w-7"
|
|
12
12
|
}, null, -1), On = [
|
|
13
13
|
Sn
|
|
14
|
-
], $n = /* @__PURE__ */
|
|
14
|
+
], $n = /* @__PURE__ */ C("img", {
|
|
15
15
|
src: _n,
|
|
16
16
|
alt: "Full screen",
|
|
17
17
|
class: "w-7"
|
|
18
18
|
}, null, -1), In = [
|
|
19
19
|
$n
|
|
20
|
-
],
|
|
20
|
+
], Tn = /* @__PURE__ */ C("img", {
|
|
21
21
|
src: xn,
|
|
22
22
|
alt: "Setting",
|
|
23
23
|
class: "w-7"
|
|
24
|
-
}, null, -1),
|
|
25
|
-
|
|
26
|
-
],
|
|
24
|
+
}, null, -1), Ln = [
|
|
25
|
+
Tn
|
|
26
|
+
], Pn = {
|
|
27
27
|
__name: "Header",
|
|
28
28
|
emits: ["settings", "fullScreen", "reader"],
|
|
29
29
|
setup(e, { emit: o }) {
|
|
30
30
|
const t = o;
|
|
31
|
-
return (n, s) => (y(),
|
|
31
|
+
return (n, s) => (y(), $("div", yn, [
|
|
32
32
|
wn,
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
C("div", En, [
|
|
34
|
+
C("button", {
|
|
35
35
|
class: "btn btn-ghost btn-circle",
|
|
36
36
|
onClick: s[0] || (s[0] = (i) => t("reader"))
|
|
37
37
|
}, On),
|
|
38
|
-
|
|
38
|
+
C("button", {
|
|
39
39
|
class: "btn btn-ghost btn-circle md:hidden",
|
|
40
40
|
onClick: s[1] || (s[1] = (i) => t("fullScreen"))
|
|
41
41
|
}, In),
|
|
42
|
-
|
|
42
|
+
C("button", {
|
|
43
43
|
class: "btn btn-ghost btn-circle",
|
|
44
44
|
onClick: s[2] || (s[2] = (i) => t("settings"))
|
|
45
|
-
},
|
|
45
|
+
}, Ln)
|
|
46
46
|
])
|
|
47
47
|
]));
|
|
48
48
|
}
|
|
@@ -59,7 +59,7 @@ function ye(e, o, t) {
|
|
|
59
59
|
n = p;
|
|
60
60
|
let v;
|
|
61
61
|
if (t.key && ((r = t.debug) != null && r.call(t)) && (v = Date.now()), s = o(...p), t.key && ((l = t.debug) != null && l.call(t))) {
|
|
62
|
-
const h = Math.round((Date.now() - u) * 100) / 100, m = Math.round((Date.now() - v) * 100) / 100,
|
|
62
|
+
const h = Math.round((Date.now() - u) * 100) / 100, m = Math.round((Date.now() - v) * 100) / 100, O = m / 16, N = (R, I) => {
|
|
63
63
|
for (R = String(R); R.length < I; )
|
|
64
64
|
R = " " + R;
|
|
65
65
|
return R;
|
|
@@ -71,7 +71,7 @@ function ye(e, o, t) {
|
|
|
71
71
|
font-weight: bold;
|
|
72
72
|
color: hsl(${Math.max(
|
|
73
73
|
0,
|
|
74
|
-
Math.min(120 - 120 *
|
|
74
|
+
Math.min(120 - 120 * O, 120)
|
|
75
75
|
)}deg 100% 31%);`,
|
|
76
76
|
t == null ? void 0 : t.key
|
|
77
77
|
);
|
|
@@ -84,12 +84,12 @@ function We(e, o) {
|
|
|
84
84
|
throw new Error("Unexpected undefined");
|
|
85
85
|
return e;
|
|
86
86
|
}
|
|
87
|
-
const
|
|
87
|
+
const Vn = (e, o) => Math.abs(e - o) < 1, kn = (e, o, t) => {
|
|
88
88
|
let n;
|
|
89
89
|
return function(...s) {
|
|
90
90
|
e.clearTimeout(n), n = e.setTimeout(() => o.apply(this, s), t);
|
|
91
91
|
};
|
|
92
|
-
},
|
|
92
|
+
}, Mn = (e) => e, Rn = (e) => {
|
|
93
93
|
const o = Math.max(e.startIndex - e.overscan, 0), t = Math.min(e.endIndex + e.overscan, e.count - 1), n = [];
|
|
94
94
|
for (let s = o; s <= t; s++)
|
|
95
95
|
n.push(s);
|
|
@@ -122,7 +122,7 @@ const Pn = (e, o) => Math.abs(e - o) < 1, Mn = (e, o, t) => {
|
|
|
122
122
|
return i.observe(t, { box: "border-box" }), () => {
|
|
123
123
|
i.unobserve(t);
|
|
124
124
|
};
|
|
125
|
-
},
|
|
125
|
+
}, ct = {
|
|
126
126
|
passive: !0
|
|
127
127
|
}, An = typeof window > "u" ? !0 : "onscrollend" in window, Dn = (e, o) => {
|
|
128
128
|
const t = e.scrollElement;
|
|
@@ -133,7 +133,7 @@ const Pn = (e, o) => Math.abs(e - o) < 1, Mn = (e, o, t) => {
|
|
|
133
133
|
return;
|
|
134
134
|
let s = 0;
|
|
135
135
|
const i = An ? () => {
|
|
136
|
-
} :
|
|
136
|
+
} : kn(
|
|
137
137
|
n,
|
|
138
138
|
() => {
|
|
139
139
|
o(s, !1);
|
|
@@ -142,7 +142,7 @@ const Pn = (e, o) => Math.abs(e - o) < 1, Mn = (e, o, t) => {
|
|
|
142
142
|
), r = (u) => () => {
|
|
143
143
|
s = t[e.options.horizontal ? "scrollLeft" : "scrollTop"], i(), o(s, u);
|
|
144
144
|
}, l = r(!0), a = r(!1);
|
|
145
|
-
return a(), t.addEventListener("scroll", l,
|
|
145
|
+
return a(), t.addEventListener("scroll", l, ct), t.addEventListener("scrollend", a, ct), () => {
|
|
146
146
|
t.removeEventListener("scroll", l), t.removeEventListener("scrollend", a);
|
|
147
147
|
};
|
|
148
148
|
}, Fn = (e, o, t) => {
|
|
@@ -202,7 +202,7 @@ class Bn {
|
|
|
202
202
|
scrollPaddingStart: 0,
|
|
203
203
|
scrollPaddingEnd: 0,
|
|
204
204
|
horizontal: !1,
|
|
205
|
-
getItemKey:
|
|
205
|
+
getItemKey: Mn,
|
|
206
206
|
rangeExtractor: Rn,
|
|
207
207
|
onChange: () => {
|
|
208
208
|
},
|
|
@@ -297,24 +297,24 @@ class Bn {
|
|
|
297
297
|
for (let f = u; f < t; f++) {
|
|
298
298
|
let v = (a = this.measurementsCache[f]) == null ? void 0 : a.measureElement;
|
|
299
299
|
v || (v = (D) => {
|
|
300
|
-
const _ = i(f),
|
|
300
|
+
const _ = i(f), L = this.elementsCache.get(_);
|
|
301
301
|
if (!D) {
|
|
302
|
-
|
|
302
|
+
L && (this.observer.unobserve(L), this.elementsCache.delete(_));
|
|
303
303
|
return;
|
|
304
304
|
}
|
|
305
|
-
|
|
305
|
+
L !== D && (L && this.observer.unobserve(L), this.observer.observe(D), this.elementsCache.set(_, D)), D.isConnected && this.resizeItem(
|
|
306
306
|
f,
|
|
307
307
|
this.options.measureElement(D, void 0, this)
|
|
308
308
|
);
|
|
309
309
|
});
|
|
310
|
-
const h = i(f), m = this.options.lanes === 1 ? p[f - 1] : this.getFurthestMeasurement(p, f),
|
|
310
|
+
const h = i(f), m = this.options.lanes === 1 ? p[f - 1] : this.getFurthestMeasurement(p, f), O = m ? m.end + this.options.gap : n + s, N = l.get(h), R = typeof N == "number" ? N : this.options.estimateSize(f), I = O + R, M = m ? m.lane : f % this.options.lanes;
|
|
311
311
|
p[f] = {
|
|
312
312
|
index: f,
|
|
313
|
-
start:
|
|
313
|
+
start: O,
|
|
314
314
|
size: R,
|
|
315
315
|
end: I,
|
|
316
316
|
key: h,
|
|
317
|
-
lane:
|
|
317
|
+
lane: M,
|
|
318
318
|
measureElement: v
|
|
319
319
|
};
|
|
320
320
|
}
|
|
@@ -446,7 +446,7 @@ class Bn {
|
|
|
446
446
|
const [u] = We(
|
|
447
447
|
this.getOffsetForIndex(t, l)
|
|
448
448
|
);
|
|
449
|
-
|
|
449
|
+
Vn(u, this.getScrollOffset()) || this.scrollToIndex(t, { align: l, behavior: s });
|
|
450
450
|
} else
|
|
451
451
|
this.scrollToIndex(t, { align: l, behavior: s });
|
|
452
452
|
}));
|
|
@@ -499,17 +499,17 @@ function Hn({
|
|
|
499
499
|
return { startIndex: i, endIndex: r };
|
|
500
500
|
}
|
|
501
501
|
function zn(e) {
|
|
502
|
-
const o = new Bn(
|
|
503
|
-
return
|
|
504
|
-
() =>
|
|
502
|
+
const o = new Bn(k(e)), t = dn(o), n = o._didMount();
|
|
503
|
+
return z(
|
|
504
|
+
() => k(e).getScrollElement(),
|
|
505
505
|
(s) => {
|
|
506
506
|
s && o._willUpdate();
|
|
507
507
|
},
|
|
508
508
|
{
|
|
509
509
|
immediate: !0
|
|
510
510
|
}
|
|
511
|
-
),
|
|
512
|
-
() =>
|
|
511
|
+
), z(
|
|
512
|
+
() => k(e),
|
|
513
513
|
(s) => {
|
|
514
514
|
o.setOptions({
|
|
515
515
|
...s,
|
|
@@ -530,7 +530,7 @@ function Un(e) {
|
|
|
530
530
|
observeElementRect: Nn,
|
|
531
531
|
observeElementOffset: Dn,
|
|
532
532
|
scrollToFn: jn,
|
|
533
|
-
...
|
|
533
|
+
...k(e)
|
|
534
534
|
}))
|
|
535
535
|
);
|
|
536
536
|
}
|
|
@@ -585,7 +585,7 @@ function Ae() {
|
|
|
585
585
|
}
|
|
586
586
|
function Gn() {
|
|
587
587
|
let e = Ae();
|
|
588
|
-
return
|
|
588
|
+
return Et(() => e.dispose()), e;
|
|
589
589
|
}
|
|
590
590
|
function qn() {
|
|
591
591
|
let e = Gn();
|
|
@@ -594,10 +594,10 @@ function qn() {
|
|
|
594
594
|
};
|
|
595
595
|
}
|
|
596
596
|
let Jn = Symbol("headlessui.useid"), Kn = 0;
|
|
597
|
-
function
|
|
598
|
-
return
|
|
597
|
+
function Le() {
|
|
598
|
+
return Te(Jn, () => `${++Kn}`)();
|
|
599
599
|
}
|
|
600
|
-
function
|
|
600
|
+
function P(e) {
|
|
601
601
|
var o;
|
|
602
602
|
if (e == null || e.value == null) return null;
|
|
603
603
|
let t = (o = e.value.$el) != null ? o : e.value;
|
|
@@ -611,10 +611,10 @@ function se(e, o, ...t) {
|
|
|
611
611
|
let n = new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(o).map((s) => `"${s}"`).join(", ")}.`);
|
|
612
612
|
throw Error.captureStackTrace && Error.captureStackTrace(n, se), n;
|
|
613
613
|
}
|
|
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,
|
|
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, dt = (e, o, t) => (Qn(e, typeof o != "symbol" ? o + "" : o, t), t);
|
|
615
615
|
let Xn = class {
|
|
616
616
|
constructor() {
|
|
617
|
-
|
|
617
|
+
dt(this, "current", this.detect()), dt(this, "currentId", 0);
|
|
618
618
|
}
|
|
619
619
|
set(o) {
|
|
620
620
|
this.current !== o && (this.currentId = 0, this.current = o);
|
|
@@ -639,21 +639,21 @@ function ot(e) {
|
|
|
639
639
|
if (nt.isServer) return null;
|
|
640
640
|
if (e instanceof Node) return e.ownerDocument;
|
|
641
641
|
if (e != null && e.hasOwnProperty("value")) {
|
|
642
|
-
let o =
|
|
642
|
+
let o = P(e);
|
|
643
643
|
if (o) return o.ownerDocument;
|
|
644
644
|
}
|
|
645
645
|
return document;
|
|
646
646
|
}
|
|
647
|
-
let
|
|
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 || {}),
|
|
647
|
+
let ft = ["[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(",");
|
|
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 || {}), kt = ((e) => (e[e.Strict = 0] = "Strict", e[e.Loose = 1] = "Loose", e))(kt || {});
|
|
649
649
|
function oo(e, o = 0) {
|
|
650
650
|
var t;
|
|
651
651
|
return e === ((t = ot(e)) == null ? void 0 : t.body) ? !1 : se(o, { 0() {
|
|
652
|
-
return e.matches(
|
|
652
|
+
return e.matches(ft);
|
|
653
653
|
}, 1() {
|
|
654
654
|
let n = e;
|
|
655
655
|
for (; n !== null; ) {
|
|
656
|
-
if (n.matches(
|
|
656
|
+
if (n.matches(ft)) return !0;
|
|
657
657
|
n = n.parentElement;
|
|
658
658
|
}
|
|
659
659
|
return !1;
|
|
@@ -682,7 +682,7 @@ function ro() {
|
|
|
682
682
|
function Mt() {
|
|
683
683
|
return io() || ro();
|
|
684
684
|
}
|
|
685
|
-
function
|
|
685
|
+
function Ve(e, o, t) {
|
|
686
686
|
nt.isServer || re((n) => {
|
|
687
687
|
document.addEventListener(e, o, t), n(() => document.removeEventListener(e, o, t));
|
|
688
688
|
});
|
|
@@ -702,46 +702,46 @@ function uo(e, o, t = w(() => !0)) {
|
|
|
702
702
|
}(e);
|
|
703
703
|
for (let u of a) {
|
|
704
704
|
if (u === null) continue;
|
|
705
|
-
let p = u instanceof HTMLElement ? u :
|
|
705
|
+
let p = u instanceof HTMLElement ? u : P(u);
|
|
706
706
|
if (p != null && p.contains(l) || i.composed && i.composedPath().includes(p)) return;
|
|
707
707
|
}
|
|
708
|
-
return !oo(l,
|
|
708
|
+
return !oo(l, kt.Loose) && l.tabIndex !== -1 && i.preventDefault(), o(i, l);
|
|
709
709
|
}
|
|
710
710
|
let s = S(null);
|
|
711
|
-
|
|
711
|
+
Ve("pointerdown", (i) => {
|
|
712
712
|
var r, l;
|
|
713
713
|
t.value && (s.value = ((l = (r = i.composedPath) == null ? void 0 : r.call(i)) == null ? void 0 : l[0]) || i.target);
|
|
714
|
-
}, !0),
|
|
714
|
+
}, !0), Ve("mousedown", (i) => {
|
|
715
715
|
var r, l;
|
|
716
716
|
t.value && (s.value = ((l = (r = i.composedPath) == null ? void 0 : r.call(i)) == null ? void 0 : l[0]) || i.target);
|
|
717
|
-
}, !0),
|
|
717
|
+
}, !0), Ve("click", (i) => {
|
|
718
718
|
Mt() || s.value && (n(i, () => s.value), s.value = null);
|
|
719
|
-
}, !0),
|
|
719
|
+
}, !0), Ve("touchend", (i) => n(i, () => i.target instanceof HTMLElement ? i.target : null), !0), ao("blur", (i) => n(i, () => window.document.activeElement instanceof HTMLIFrameElement ? window.document.activeElement : null), !0);
|
|
720
720
|
}
|
|
721
|
-
function
|
|
721
|
+
function pt(e, o) {
|
|
722
722
|
if (e) return e;
|
|
723
723
|
let t = o ?? "button";
|
|
724
724
|
if (typeof t == "string" && t.toLowerCase() === "button") return "button";
|
|
725
725
|
}
|
|
726
726
|
function co(e, o) {
|
|
727
|
-
let t = S(
|
|
727
|
+
let t = S(pt(e.value.type, e.value.as));
|
|
728
728
|
return xe(() => {
|
|
729
|
-
t.value =
|
|
729
|
+
t.value = pt(e.value.type, e.value.as);
|
|
730
730
|
}), re(() => {
|
|
731
731
|
var n;
|
|
732
|
-
t.value ||
|
|
732
|
+
t.value || P(o) && P(o) instanceof HTMLButtonElement && !((n = P(o)) != null && n.hasAttribute("type")) && (t.value = "button");
|
|
733
733
|
}), t;
|
|
734
734
|
}
|
|
735
|
-
function
|
|
735
|
+
function vt(e) {
|
|
736
736
|
return [e.screenX, e.screenY];
|
|
737
737
|
}
|
|
738
738
|
function fo() {
|
|
739
739
|
let e = S([-1, -1]);
|
|
740
740
|
return { wasMoved(o) {
|
|
741
|
-
let t =
|
|
741
|
+
let t = vt(o);
|
|
742
742
|
return e.value[0] === t[0] && e.value[1] === t[1] ? !1 : (e.value = t, !0);
|
|
743
743
|
}, update(o) {
|
|
744
|
-
e.value =
|
|
744
|
+
e.value = vt(o);
|
|
745
745
|
} };
|
|
746
746
|
}
|
|
747
747
|
function po({ container: e, accept: o, walk: t, enabled: n }) {
|
|
@@ -757,7 +757,7 @@ function po({ container: e, accept: o, walk: t, enabled: n }) {
|
|
|
757
757
|
var Oe = ((e) => (e[e.None = 0] = "None", e[e.RenderStrategy = 1] = "RenderStrategy", e[e.Static = 2] = "Static", e))(Oe || {}), vo = ((e) => (e[e.Unmount = 0] = "Unmount", e[e.Hidden = 1] = "Hidden", e))(vo || {});
|
|
758
758
|
function pe({ visible: e = !0, features: o = 0, ourProps: t, theirProps: n, ...s }) {
|
|
759
759
|
var i;
|
|
760
|
-
let r =
|
|
760
|
+
let r = Nt(n, t), l = Object.assign(s, { props: r });
|
|
761
761
|
if (e || o & 2 && r.static) return Ge(l);
|
|
762
762
|
if (o & 1) {
|
|
763
763
|
let a = (i = r.unmount) == null || i ? 0 : 1;
|
|
@@ -778,24 +778,24 @@ function Ge({ props: e, attrs: o, slots: t, slot: n, name: s }) {
|
|
|
778
778
|
f && (p["data-headlessui-state"] = v.join(" "));
|
|
779
779
|
}
|
|
780
780
|
if (l === "template") {
|
|
781
|
-
if (u =
|
|
781
|
+
if (u = Rt(u ?? []), Object.keys(a).length > 0 || Object.keys(o).length > 0) {
|
|
782
782
|
let [f, ...v] = u ?? [];
|
|
783
|
-
if (!mo(f) || v.length > 0) throw new Error(['Passing props on "template"!', "", `The current component <${s} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(a).concat(Object.keys(o)).map((
|
|
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((
|
|
783
|
+
if (!mo(f) || v.length > 0) throw new Error(['Passing props on "template"!', "", `The current component <${s} /> is rendering a "template".`, "However we need to passthrough the following props:", Object.keys(a).concat(Object.keys(o)).map((O) => O.trim()).filter((O, N, R) => R.indexOf(O) === N).sort((O, N) => O.localeCompare(N)).map((O) => ` - ${O}`).join(`
|
|
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((O) => ` - ${O}`).join(`
|
|
785
785
|
`)].join(`
|
|
786
786
|
`));
|
|
787
|
-
let h =
|
|
788
|
-
for (let
|
|
787
|
+
let h = Nt((r = f.props) != null ? r : {}, a, p), m = St(f, h, !0);
|
|
788
|
+
for (let O in h) O.startsWith("on") && (m.props || (m.props = {}), m.props[O] = h[O]);
|
|
789
789
|
return m;
|
|
790
790
|
}
|
|
791
791
|
return Array.isArray(u) && u.length === 1 ? u[0] : u;
|
|
792
792
|
}
|
|
793
793
|
return Se(l, Object.assign({}, a, p), { default: () => u });
|
|
794
794
|
}
|
|
795
|
-
function
|
|
796
|
-
return e.flatMap((o) => o.type === Z ?
|
|
795
|
+
function Rt(e) {
|
|
796
|
+
return e.flatMap((o) => o.type === Z ? Rt(o.children) : [o]);
|
|
797
797
|
}
|
|
798
|
-
function
|
|
798
|
+
function Nt(...e) {
|
|
799
799
|
if (e.length === 0) return {};
|
|
800
800
|
if (e.length === 1) return e[0];
|
|
801
801
|
let o = {}, t = {};
|
|
@@ -823,22 +823,22 @@ function je(e, o = []) {
|
|
|
823
823
|
function mo(e) {
|
|
824
824
|
return e == null ? !1 : typeof e.type == "string" || typeof e.type == "object" || typeof e.type == "function";
|
|
825
825
|
}
|
|
826
|
-
var
|
|
826
|
+
var At = ((e) => (e[e.None = 1] = "None", e[e.Focusable = 2] = "Focusable", e[e.Hidden = 4] = "Hidden", e))(At || {});
|
|
827
827
|
let go = ae({ name: "Hidden", props: { as: { type: [Object, String], default: "div" }, features: { type: Number, default: 1 } }, setup(e, { slots: o, attrs: t }) {
|
|
828
828
|
return () => {
|
|
829
829
|
var n;
|
|
830
830
|
let { features: s, ...i } = e, r = { "aria-hidden": (s & 2) === 2 ? !0 : (n = i["aria-hidden"]) != null ? n : void 0, hidden: (s & 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", ...(s & 4) === 4 && (s & 2) !== 2 && { display: "none" } } };
|
|
831
831
|
return pe({ ourProps: r, theirProps: i, slot: {}, attrs: t, slots: o, name: "Hidden" });
|
|
832
832
|
};
|
|
833
|
-
} }),
|
|
833
|
+
} }), Dt = Symbol("Context");
|
|
834
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
835
|
function bo() {
|
|
836
|
-
return
|
|
836
|
+
return Te(Dt, null);
|
|
837
837
|
}
|
|
838
838
|
function Co(e) {
|
|
839
|
-
et(
|
|
839
|
+
et(Dt, e);
|
|
840
840
|
}
|
|
841
|
-
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 || {}),
|
|
841
|
+
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 || {}), Ft = ((e) => (e[e.Left = 0] = "Left", e[e.Right = 2] = "Right", e))(Ft || {});
|
|
842
842
|
function _o(e) {
|
|
843
843
|
function o() {
|
|
844
844
|
document.readyState !== "loading" && (e(), document.removeEventListener("DOMContentLoaded", o));
|
|
@@ -855,8 +855,8 @@ _o(() => {
|
|
|
855
855
|
function xo(e) {
|
|
856
856
|
throw new Error("Unexpected object: " + e);
|
|
857
857
|
}
|
|
858
|
-
var
|
|
859
|
-
function
|
|
858
|
+
var H = ((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))(H || {});
|
|
859
|
+
function ht(e, o) {
|
|
860
860
|
let t = o.resolveItems();
|
|
861
861
|
if (t.length <= 0) return null;
|
|
862
862
|
let n = o.resolveActiveIndex(), s = n ?? -1;
|
|
@@ -888,91 +888,91 @@ function vt(e, o) {
|
|
|
888
888
|
xo(e);
|
|
889
889
|
}
|
|
890
890
|
}
|
|
891
|
-
function
|
|
892
|
-
for (let [n, s] of Object.entries(e))
|
|
891
|
+
function jt(e = {}, o = null, t = []) {
|
|
892
|
+
for (let [n, s] of Object.entries(e)) Ht(t, Bt(o, n), s);
|
|
893
893
|
return t;
|
|
894
894
|
}
|
|
895
|
-
function
|
|
895
|
+
function Bt(e, o) {
|
|
896
896
|
return e ? e + "[" + o + "]" : o;
|
|
897
897
|
}
|
|
898
|
-
function
|
|
899
|
-
if (Array.isArray(t)) for (let [n, s] of t.entries())
|
|
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, ""]) :
|
|
898
|
+
function Ht(e, o, t) {
|
|
899
|
+
if (Array.isArray(t)) for (let [n, s] of t.entries()) Ht(e, Bt(o, n.toString()), s);
|
|
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, ""]) : jt(t, o, e);
|
|
901
901
|
}
|
|
902
902
|
function yo(e, o) {
|
|
903
903
|
return e === o;
|
|
904
904
|
}
|
|
905
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
|
|
906
|
+
let zt = Symbol("ComboboxContext");
|
|
907
907
|
function ve(e) {
|
|
908
|
-
let o =
|
|
908
|
+
let o = Te(zt, null);
|
|
909
909
|
if (o === null) {
|
|
910
910
|
let t = new Error(`<${e} /> is missing a parent <Combobox /> component.`);
|
|
911
911
|
throw Error.captureStackTrace && Error.captureStackTrace(t, ve), t;
|
|
912
912
|
}
|
|
913
913
|
return o;
|
|
914
914
|
}
|
|
915
|
-
let
|
|
915
|
+
let Ut = Symbol("VirtualContext"), Oo = ae({ name: "VirtualProvider", setup(e, { slots: o }) {
|
|
916
916
|
let t = ve("VirtualProvider"), n = w(() => {
|
|
917
|
-
let l =
|
|
917
|
+
let l = P(t.optionsRef);
|
|
918
918
|
if (!l) return { start: 0, end: 0 };
|
|
919
919
|
let a = window.getComputedStyle(l);
|
|
920
920
|
return { start: parseFloat(a.paddingBlockStart || a.paddingTop), end: parseFloat(a.paddingBlockEnd || a.paddingBottom) };
|
|
921
921
|
}), s = Un(w(() => ({ scrollPaddingStart: n.value.start, scrollPaddingEnd: n.value.end, count: t.virtual.value.options.length, estimateSize() {
|
|
922
922
|
return 40;
|
|
923
923
|
}, getScrollElement() {
|
|
924
|
-
return
|
|
924
|
+
return P(t.optionsRef);
|
|
925
925
|
}, overscan: 12 }))), i = w(() => {
|
|
926
926
|
var l;
|
|
927
927
|
return (l = t.virtual.value) == null ? void 0 : l.options;
|
|
928
928
|
}), r = S(0);
|
|
929
|
-
return
|
|
929
|
+
return z([i], () => {
|
|
930
930
|
r.value += 1;
|
|
931
|
-
}), et(
|
|
931
|
+
}), et(Ut, t.virtual.value ? s : null), () => [Se("div", { style: { position: "relative", width: "100%", height: `${s.value.getTotalSize()}px` }, ref: (l) => {
|
|
932
932
|
if (l) {
|
|
933
933
|
if (typeof process < "u" && process.env.JEST_WORKER_ID !== void 0 || t.activationTrigger.value === 0) return;
|
|
934
934
|
t.activeOptionIndex.value !== null && t.virtual.value.options.length > t.activeOptionIndex.value && s.value.scrollToIndex(t.activeOptionIndex.value);
|
|
935
935
|
}
|
|
936
|
-
} }, s.value.getVirtualItems().map((l) =>
|
|
936
|
+
} }, s.value.getVirtualItems().map((l) => St(o.default({ option: t.virtual.value.options[l.index], open: t.comboboxState.value === 0 })[0], { key: `${r.value}-${l.index}`, "data-index": l.index, "aria-setsize": t.virtual.value.options.length, "aria-posinset": l.index + 1, style: { position: "absolute", top: 0, left: 0, transform: `translateY(${l.start}px)`, overflowAnchor: "none" } })))];
|
|
937
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
938
|
let s = S(1), i = S(null), r = S(null), l = S(null), a = S(null), u = S({ static: !1, hold: !1 }), p = S([]), f = S(null), v = S(2), h = S(!1);
|
|
939
939
|
function m(c = (d) => d) {
|
|
940
|
-
let d = f.value !== null ? p.value[f.value] : null, x = c(p.value.slice()), E = x.length > 0 && x[0].dataRef.order.value !== null ? x.sort((A, G) => A.dataRef.order.value - G.dataRef.order.value) : lo(x, (A) =>
|
|
941
|
-
return
|
|
940
|
+
let d = f.value !== null ? p.value[f.value] : null, x = c(p.value.slice()), E = x.length > 0 && x[0].dataRef.order.value !== null ? x.sort((A, G) => A.dataRef.order.value - G.dataRef.order.value) : lo(x, (A) => P(A.dataRef.domRef)), V = d ? E.indexOf(d) : null;
|
|
941
|
+
return V === -1 && (V = null), { options: E, activeOptionIndex: V };
|
|
942
942
|
}
|
|
943
|
-
let
|
|
944
|
-
function
|
|
945
|
-
return se(
|
|
943
|
+
let O = w(() => e.multiple ? 1 : 0), N = w(() => e.nullable), [R, I] = Zn(w(() => e.modelValue), (c) => n("update:modelValue", c), w(() => e.defaultValue)), M = w(() => R.value === void 0 ? se(O.value, { 1: [], 0: void 0 }) : R.value), D = null, _ = null;
|
|
944
|
+
function L(c) {
|
|
945
|
+
return se(O.value, { 0() {
|
|
946
946
|
return I == null ? void 0 : I(c);
|
|
947
947
|
}, 1: () => {
|
|
948
|
-
let d = K(
|
|
948
|
+
let d = K(g.value.value).slice(), x = K(c), E = d.findIndex((V) => g.compare(x, K(V)));
|
|
949
949
|
return E === -1 ? d.push(x) : d.splice(E, 1), I == null ? void 0 : I(d);
|
|
950
950
|
} });
|
|
951
951
|
}
|
|
952
|
-
let
|
|
952
|
+
let b = w(() => {
|
|
953
953
|
});
|
|
954
|
-
|
|
955
|
-
if (
|
|
954
|
+
z([b], ([c], [d]) => {
|
|
955
|
+
if (g.virtual.value && c && d && f.value !== null) {
|
|
956
956
|
let x = c.indexOf(d[f.value]);
|
|
957
957
|
x !== -1 ? f.value = x : f.value = null;
|
|
958
958
|
}
|
|
959
959
|
});
|
|
960
|
-
let
|
|
960
|
+
let g = { comboboxState: s, value: M, mode: O, compare(c, d) {
|
|
961
961
|
if (typeof e.by == "string") {
|
|
962
962
|
let x = e.by;
|
|
963
963
|
return (c == null ? void 0 : c[x]) === (d == null ? void 0 : d[x]);
|
|
964
964
|
}
|
|
965
965
|
return e.by === null ? yo(c, d) : e.by(c, d);
|
|
966
966
|
}, calculateIndex(c) {
|
|
967
|
-
return
|
|
967
|
+
return g.virtual.value ? e.by === null ? g.virtual.value.options.indexOf(c) : g.virtual.value.options.findIndex((d) => g.compare(d, c)) : p.value.findIndex((d) => g.compare(d.dataRef.value, c));
|
|
968
968
|
}, defaultValue: w(() => e.defaultValue), nullable: N, immediate: w(() => !1), virtual: w(() => null), inputRef: r, labelRef: i, buttonRef: l, optionsRef: a, disabled: w(() => e.disabled), options: p, change(c) {
|
|
969
969
|
I(c);
|
|
970
970
|
}, activeOptionIndex: w(() => {
|
|
971
|
-
if (h.value && f.value === null && (
|
|
972
|
-
if (
|
|
973
|
-
let d =
|
|
971
|
+
if (h.value && f.value === null && (g.virtual.value ? g.virtual.value.options.length > 0 : p.value.length > 0)) {
|
|
972
|
+
if (g.virtual.value) {
|
|
973
|
+
let d = g.virtual.value.options.findIndex((x) => {
|
|
974
974
|
var E;
|
|
975
|
-
return !((E =
|
|
975
|
+
return !((E = g.virtual.value) != null && E.disabled(x));
|
|
976
976
|
});
|
|
977
977
|
if (d !== -1) return d;
|
|
978
978
|
}
|
|
@@ -984,8 +984,8 @@ let zt = Symbol("VirtualContext"), Oo = ae({ name: "VirtualProvider", setup(e, {
|
|
|
984
984
|
h.value = !1, !e.disabled && s.value !== 1 && (s.value = 1, f.value = null);
|
|
985
985
|
}, openCombobox() {
|
|
986
986
|
if (h.value = !0, !e.disabled && s.value !== 0) {
|
|
987
|
-
if (
|
|
988
|
-
let c =
|
|
987
|
+
if (g.value.value) {
|
|
988
|
+
let c = g.calculateIndex(g.value.value);
|
|
989
989
|
c !== -1 && (f.value = c);
|
|
990
990
|
}
|
|
991
991
|
s.value = 0;
|
|
@@ -995,14 +995,14 @@ let zt = Symbol("VirtualContext"), Oo = ae({ name: "VirtualProvider", setup(e, {
|
|
|
995
995
|
}, goToOption(c, d, x) {
|
|
996
996
|
h.value = !1, D !== null && cancelAnimationFrame(D), D = requestAnimationFrame(() => {
|
|
997
997
|
if (e.disabled || a.value && !u.value.static && s.value === 1) return;
|
|
998
|
-
if (
|
|
999
|
-
f.value = c ===
|
|
998
|
+
if (g.virtual.value) {
|
|
999
|
+
f.value = c === H.Specific ? d : ht({ focus: c }, { resolveItems: () => g.virtual.value.options, resolveActiveIndex: () => {
|
|
1000
1000
|
var A, G;
|
|
1001
|
-
return (G = (A =
|
|
1001
|
+
return (G = (A = g.activeOptionIndex.value) != null ? A : g.virtual.value.options.findIndex((q) => {
|
|
1002
1002
|
var F;
|
|
1003
|
-
return !((F =
|
|
1003
|
+
return !((F = g.virtual.value) != null && F.disabled(q));
|
|
1004
1004
|
})) != null ? G : null;
|
|
1005
|
-
}, resolveDisabled: (A) =>
|
|
1005
|
+
}, resolveDisabled: (A) => g.virtual.value.disabled(A), resolveId() {
|
|
1006
1006
|
throw new Error("Function not implemented.");
|
|
1007
1007
|
} }), v.value = x ?? 2;
|
|
1008
1008
|
return;
|
|
@@ -1012,78 +1012,78 @@ let zt = Symbol("VirtualContext"), Oo = ae({ name: "VirtualProvider", setup(e, {
|
|
|
1012
1012
|
let A = E.options.findIndex((G) => !G.dataRef.disabled);
|
|
1013
1013
|
A !== -1 && (E.activeOptionIndex = A);
|
|
1014
1014
|
}
|
|
1015
|
-
let
|
|
1016
|
-
f.value =
|
|
1015
|
+
let V = c === H.Specific ? d : ht({ focus: c }, { resolveItems: () => E.options, resolveActiveIndex: () => E.activeOptionIndex, resolveId: (A) => A.id, resolveDisabled: (A) => A.dataRef.disabled });
|
|
1016
|
+
f.value = V, v.value = x ?? 2, p.value = E.options;
|
|
1017
1017
|
});
|
|
1018
1018
|
}, selectOption(c) {
|
|
1019
1019
|
let d = p.value.find((E) => E.id === c);
|
|
1020
1020
|
if (!d) return;
|
|
1021
1021
|
let { dataRef: x } = d;
|
|
1022
|
-
|
|
1022
|
+
L(x.value);
|
|
1023
1023
|
}, selectActiveOption() {
|
|
1024
|
-
if (
|
|
1025
|
-
if (
|
|
1024
|
+
if (g.activeOptionIndex.value !== null) {
|
|
1025
|
+
if (g.virtual.value) L(g.virtual.value.options[g.activeOptionIndex.value]);
|
|
1026
1026
|
else {
|
|
1027
|
-
let { dataRef: c } = p.value[
|
|
1028
|
-
|
|
1027
|
+
let { dataRef: c } = p.value[g.activeOptionIndex.value];
|
|
1028
|
+
L(c.value);
|
|
1029
1029
|
}
|
|
1030
|
-
|
|
1030
|
+
g.goToOption(H.Specific, g.activeOptionIndex.value);
|
|
1031
1031
|
}
|
|
1032
1032
|
}, registerOption(c, d) {
|
|
1033
|
-
let x =
|
|
1034
|
-
if (
|
|
1033
|
+
let x = Ot({ id: c, dataRef: d });
|
|
1034
|
+
if (g.virtual.value) {
|
|
1035
1035
|
p.value.push(x);
|
|
1036
1036
|
return;
|
|
1037
1037
|
}
|
|
1038
1038
|
_ && cancelAnimationFrame(_);
|
|
1039
|
-
let E = m((
|
|
1040
|
-
f.value === null &&
|
|
1041
|
-
let
|
|
1042
|
-
p.value =
|
|
1039
|
+
let E = m((V) => (V.push(x), V));
|
|
1040
|
+
f.value === null && g.isSelected(d.value.value) && (E.activeOptionIndex = E.options.indexOf(x)), p.value = E.options, f.value = E.activeOptionIndex, v.value = 2, E.options.some((V) => !P(V.dataRef.domRef)) && (_ = requestAnimationFrame(() => {
|
|
1041
|
+
let V = m();
|
|
1042
|
+
p.value = V.options, f.value = V.activeOptionIndex;
|
|
1043
1043
|
}));
|
|
1044
1044
|
}, unregisterOption(c, d) {
|
|
1045
|
-
if (D !== null && cancelAnimationFrame(D), d && (h.value = !0),
|
|
1045
|
+
if (D !== null && cancelAnimationFrame(D), d && (h.value = !0), g.virtual.value) {
|
|
1046
1046
|
p.value = p.value.filter((E) => E.id !== c);
|
|
1047
1047
|
return;
|
|
1048
1048
|
}
|
|
1049
1049
|
let x = m((E) => {
|
|
1050
|
-
let
|
|
1051
|
-
return
|
|
1050
|
+
let V = E.findIndex((A) => A.id === c);
|
|
1051
|
+
return V !== -1 && E.splice(V, 1), E;
|
|
1052
1052
|
});
|
|
1053
1053
|
p.value = x.options, f.value = x.activeOptionIndex, v.value = 2;
|
|
1054
1054
|
}, isSelected(c) {
|
|
1055
|
-
return se(
|
|
1055
|
+
return se(O.value, { 0: () => g.compare(K(g.value.value), K(c)), 1: () => K(g.value.value).some((d) => g.compare(K(d), K(c))) });
|
|
1056
1056
|
}, isActive(c) {
|
|
1057
|
-
return f.value ===
|
|
1057
|
+
return f.value === g.calculateIndex(c);
|
|
1058
1058
|
} };
|
|
1059
|
-
uo([r, l, a], () =>
|
|
1060
|
-
let
|
|
1059
|
+
uo([r, l, a], () => g.closeCombobox(), w(() => s.value === 0)), et(zt, g), Co(w(() => se(s.value, { 0: $e.Open, 1: $e.Closed })));
|
|
1060
|
+
let T = w(() => {
|
|
1061
1061
|
var c;
|
|
1062
|
-
return (c =
|
|
1062
|
+
return (c = P(r)) == null ? void 0 : c.closest("form");
|
|
1063
1063
|
});
|
|
1064
1064
|
return xe(() => {
|
|
1065
|
-
|
|
1066
|
-
if (!
|
|
1065
|
+
z([T], () => {
|
|
1066
|
+
if (!T.value || e.defaultValue === void 0) return;
|
|
1067
1067
|
function c() {
|
|
1068
|
-
|
|
1068
|
+
g.change(e.defaultValue);
|
|
1069
1069
|
}
|
|
1070
|
-
return
|
|
1070
|
+
return T.value.addEventListener("reset", c), () => {
|
|
1071
1071
|
var d;
|
|
1072
|
-
(d =
|
|
1072
|
+
(d = T.value) == null || d.removeEventListener("reset", c);
|
|
1073
1073
|
};
|
|
1074
1074
|
}, { immediate: !0 });
|
|
1075
1075
|
}), () => {
|
|
1076
1076
|
var c, d, x;
|
|
1077
|
-
let { name: E, disabled:
|
|
1078
|
-
return Se(Z, [...E != null &&
|
|
1077
|
+
let { name: E, disabled: V, form: A, ...G } = e, q = { open: s.value === 0, disabled: V, activeIndex: g.activeOptionIndex.value, activeOption: g.activeOptionIndex.value === null ? null : g.virtual.value ? g.virtual.value.options[(c = g.activeOptionIndex.value) != null ? c : 0] : (x = (d = g.options.value[g.activeOptionIndex.value]) == null ? void 0 : d.dataRef.value) != null ? x : null, value: M.value };
|
|
1078
|
+
return Se(Z, [...E != null && M.value != null ? jt({ [E]: M.value }).map(([F, cn]) => Se(go, ho({ features: At.Hidden, key: F, as: "input", type: "hidden", hidden: !0, readOnly: !0, form: A, disabled: V, name: F, value: cn }))) : [], pe({ theirProps: { ...t, ...je(G, ["by", "defaultValue", "immediate", "modelValue", "multiple", "nullable", "onUpdate:modelValue", "virtual"]) }, ourProps: {}, slot: q, slots: o, attrs: t, name: "Combobox" })]);
|
|
1079
1079
|
};
|
|
1080
1080
|
} });
|
|
1081
1081
|
ae({ name: "ComboboxLabel", props: { as: { type: [Object, String], default: "label" }, id: { type: String, default: null } }, setup(e, { attrs: o, slots: t }) {
|
|
1082
1082
|
var n;
|
|
1083
|
-
let s = (n = e.id) != null ? n : `headlessui-combobox-label-${
|
|
1083
|
+
let s = (n = e.id) != null ? n : `headlessui-combobox-label-${Le()}`, i = ve("ComboboxLabel");
|
|
1084
1084
|
function r() {
|
|
1085
1085
|
var l;
|
|
1086
|
-
(l =
|
|
1086
|
+
(l = P(i.inputRef)) == null || l.focus({ preventScroll: !0 });
|
|
1087
1087
|
}
|
|
1088
1088
|
return () => {
|
|
1089
1089
|
let l = { open: i.comboboxState.value === 0, disabled: i.disabled.value }, { ...a } = e, u = { id: s, ref: i.labelRef, onClick: r };
|
|
@@ -1092,12 +1092,12 @@ ae({ name: "ComboboxLabel", props: { as: { type: [Object, String], default: "lab
|
|
|
1092
1092
|
} });
|
|
1093
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 }) {
|
|
1094
1094
|
var s;
|
|
1095
|
-
let i = (s = e.id) != null ? s : `headlessui-combobox-button-${
|
|
1095
|
+
let i = (s = e.id) != null ? s : `headlessui-combobox-button-${Le()}`, r = ve("ComboboxButton");
|
|
1096
1096
|
n({ el: r.buttonRef, $el: r.buttonRef });
|
|
1097
1097
|
function l(p) {
|
|
1098
1098
|
r.disabled.value || (r.comboboxState.value === 0 ? r.closeCombobox() : (p.preventDefault(), r.openCombobox()), Q(() => {
|
|
1099
1099
|
var f;
|
|
1100
|
-
return (f =
|
|
1100
|
+
return (f = P(r.inputRef)) == null ? void 0 : f.focus({ preventScroll: !0 });
|
|
1101
1101
|
}));
|
|
1102
1102
|
}
|
|
1103
1103
|
function a(p) {
|
|
@@ -1110,7 +1110,7 @@ let Io = ae({ name: "ComboboxButton", props: { as: { type: [Object, String], def
|
|
|
1110
1110
|
return;
|
|
1111
1111
|
case W.ArrowUp:
|
|
1112
1112
|
p.preventDefault(), p.stopPropagation(), r.comboboxState.value === 1 && (r.openCombobox(), Q(() => {
|
|
1113
|
-
r.value.value || r.goToOption(
|
|
1113
|
+
r.value.value || r.goToOption(H.Last);
|
|
1114
1114
|
})), Q(() => {
|
|
1115
1115
|
var f;
|
|
1116
1116
|
return (f = r.inputRef.value) == null ? void 0 : f.focus({ preventScroll: !0 });
|
|
@@ -1128,40 +1128,40 @@ let Io = ae({ name: "ComboboxButton", props: { as: { type: [Object, String], def
|
|
|
1128
1128
|
let u = co(w(() => ({ as: e.as, type: o.type })), r.buttonRef);
|
|
1129
1129
|
return () => {
|
|
1130
1130
|
var p, f;
|
|
1131
|
-
let v = { open: r.comboboxState.value === 0, disabled: r.disabled.value, value: r.value.value }, { ...h } = e, m = { ref: r.buttonRef, id: i, type: u.value, tabindex: "-1", "aria-haspopup": "listbox", "aria-controls": (p =
|
|
1131
|
+
let v = { open: r.comboboxState.value === 0, disabled: r.disabled.value, value: r.value.value }, { ...h } = e, m = { ref: r.buttonRef, id: i, type: u.value, tabindex: "-1", "aria-haspopup": "listbox", "aria-controls": (p = P(r.optionsRef)) == null ? void 0 : p.id, "aria-expanded": r.comboboxState.value === 0, "aria-labelledby": r.labelRef.value ? [(f = P(r.labelRef)) == null ? void 0 : f.id, i].join(" ") : void 0, disabled: r.disabled.value === !0 ? !0 : void 0, onKeydown: a, onClick: l };
|
|
1132
1132
|
return pe({ ourProps: m, theirProps: h, slot: v, attrs: o, slots: t, name: "ComboboxButton" });
|
|
1133
1133
|
};
|
|
1134
|
-
} }),
|
|
1134
|
+
} }), To = 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: s }) {
|
|
1135
1135
|
var i;
|
|
1136
|
-
let r = (i = e.id) != null ? i : `headlessui-combobox-input-${
|
|
1136
|
+
let r = (i = e.id) != null ? i : `headlessui-combobox-input-${Le()}`, l = ve("ComboboxInput"), a = w(() => ot(P(l.inputRef))), u = { value: !1 };
|
|
1137
1137
|
s({ el: l.inputRef, $el: l.inputRef });
|
|
1138
1138
|
function p() {
|
|
1139
1139
|
l.change(null);
|
|
1140
|
-
let _ =
|
|
1141
|
-
_ && (_.scrollTop = 0), l.goToOption(
|
|
1140
|
+
let _ = P(l.optionsRef);
|
|
1141
|
+
_ && (_.scrollTop = 0), l.goToOption(H.Nothing);
|
|
1142
1142
|
}
|
|
1143
1143
|
let f = w(() => {
|
|
1144
1144
|
var _;
|
|
1145
|
-
let
|
|
1146
|
-
return
|
|
1145
|
+
let L = l.value.value;
|
|
1146
|
+
return P(l.inputRef) ? typeof e.displayValue < "u" && L !== void 0 ? (_ = e.displayValue(L)) != null ? _ : "" : typeof L == "string" ? L : "" : "";
|
|
1147
1147
|
});
|
|
1148
1148
|
xe(() => {
|
|
1149
|
-
|
|
1149
|
+
z([f, l.comboboxState, a], ([_, L], [b, g]) => {
|
|
1150
1150
|
if (u.value) return;
|
|
1151
|
-
let
|
|
1152
|
-
|
|
1151
|
+
let T = P(l.inputRef);
|
|
1152
|
+
T && ((g === 0 && L === 1 || _ !== b) && (T.value = _), requestAnimationFrame(() => {
|
|
1153
1153
|
var c;
|
|
1154
|
-
if (u.value || !
|
|
1155
|
-
let { selectionStart: d, selectionEnd: x } =
|
|
1156
|
-
Math.abs((x ?? 0) - (d ?? 0)) === 0 && d === 0 &&
|
|
1154
|
+
if (u.value || !T || ((c = a.value) == null ? void 0 : c.activeElement) !== T) return;
|
|
1155
|
+
let { selectionStart: d, selectionEnd: x } = T;
|
|
1156
|
+
Math.abs((x ?? 0) - (d ?? 0)) === 0 && d === 0 && T.setSelectionRange(T.value.length, T.value.length);
|
|
1157
1157
|
}));
|
|
1158
|
-
}, { immediate: !0 }),
|
|
1159
|
-
if (_ === 0 &&
|
|
1158
|
+
}, { immediate: !0 }), z([l.comboboxState], ([_], [L]) => {
|
|
1159
|
+
if (_ === 0 && L === 1) {
|
|
1160
1160
|
if (u.value) return;
|
|
1161
|
-
let
|
|
1162
|
-
if (!
|
|
1163
|
-
let
|
|
1164
|
-
|
|
1161
|
+
let b = P(l.inputRef);
|
|
1162
|
+
if (!b) return;
|
|
1163
|
+
let g = b.value, { selectionStart: T, selectionEnd: c, selectionDirection: d } = b;
|
|
1164
|
+
b.value = "", b.value = g, d !== null ? b.setSelectionRange(T, c, d) : b.setSelectionRange(T, c);
|
|
1165
1165
|
}
|
|
1166
1166
|
});
|
|
1167
1167
|
});
|
|
@@ -1174,9 +1174,9 @@ let Io = ae({ name: "ComboboxButton", props: { as: { type: [Object, String], def
|
|
|
1174
1174
|
v.value = !1;
|
|
1175
1175
|
});
|
|
1176
1176
|
}
|
|
1177
|
-
let
|
|
1177
|
+
let O = qn();
|
|
1178
1178
|
function N(_) {
|
|
1179
|
-
switch (u.value = !0,
|
|
1179
|
+
switch (u.value = !0, O(() => {
|
|
1180
1180
|
u.value = !1;
|
|
1181
1181
|
}), _.key) {
|
|
1182
1182
|
case W.Enter:
|
|
@@ -1188,23 +1188,23 @@ let Io = ae({ name: "ComboboxButton", props: { as: { type: [Object, String], def
|
|
|
1188
1188
|
l.selectActiveOption(), l.mode.value === 0 && l.closeCombobox();
|
|
1189
1189
|
break;
|
|
1190
1190
|
case W.ArrowDown:
|
|
1191
|
-
return u.value = !1, _.preventDefault(), _.stopPropagation(), se(l.comboboxState.value, { 0: () => l.goToOption(
|
|
1191
|
+
return u.value = !1, _.preventDefault(), _.stopPropagation(), se(l.comboboxState.value, { 0: () => l.goToOption(H.Next), 1: () => l.openCombobox() });
|
|
1192
1192
|
case W.ArrowUp:
|
|
1193
|
-
return u.value = !1, _.preventDefault(), _.stopPropagation(), se(l.comboboxState.value, { 0: () => l.goToOption(
|
|
1193
|
+
return u.value = !1, _.preventDefault(), _.stopPropagation(), se(l.comboboxState.value, { 0: () => l.goToOption(H.Previous), 1: () => {
|
|
1194
1194
|
l.openCombobox(), Q(() => {
|
|
1195
|
-
l.value.value || l.goToOption(
|
|
1195
|
+
l.value.value || l.goToOption(H.Last);
|
|
1196
1196
|
});
|
|
1197
1197
|
} });
|
|
1198
1198
|
case W.Home:
|
|
1199
1199
|
if (_.shiftKey) break;
|
|
1200
|
-
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(
|
|
1200
|
+
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(H.First);
|
|
1201
1201
|
case W.PageUp:
|
|
1202
|
-
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(
|
|
1202
|
+
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(H.First);
|
|
1203
1203
|
case W.End:
|
|
1204
1204
|
if (_.shiftKey) break;
|
|
1205
|
-
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(
|
|
1205
|
+
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(H.Last);
|
|
1206
1206
|
case W.PageDown:
|
|
1207
|
-
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(
|
|
1207
|
+
return u.value = !1, _.preventDefault(), _.stopPropagation(), l.goToOption(H.Last);
|
|
1208
1208
|
case W.Escape:
|
|
1209
1209
|
if (u.value = !1, l.comboboxState.value !== 0) return;
|
|
1210
1210
|
_.preventDefault(), l.optionsRef.value && !l.optionsPropsRef.value.static && _.stopPropagation(), l.nullable.value && l.mode.value === 0 && l.value.value === null && p(), l.closeCombobox();
|
|
@@ -1219,35 +1219,35 @@ let Io = ae({ name: "ComboboxButton", props: { as: { type: [Object, String], def
|
|
|
1219
1219
|
o("change", _), l.nullable.value && l.mode.value === 0 && _.target.value === "" && p(), l.openCombobox();
|
|
1220
1220
|
}
|
|
1221
1221
|
function I(_) {
|
|
1222
|
-
var
|
|
1223
|
-
let
|
|
1224
|
-
if (u.value = !1, !((
|
|
1225
|
-
}
|
|
1226
|
-
function
|
|
1227
|
-
var
|
|
1228
|
-
let
|
|
1229
|
-
(
|
|
1222
|
+
var L, b, g;
|
|
1223
|
+
let T = (L = _.relatedTarget) != null ? L : ce.find((c) => c !== _.currentTarget);
|
|
1224
|
+
if (u.value = !1, !((b = P(l.optionsRef)) != null && b.contains(T)) && !((g = P(l.buttonRef)) != null && g.contains(T)) && l.comboboxState.value === 0) return _.preventDefault(), l.mode.value === 0 && (l.nullable.value && l.value.value === null ? p() : l.activationTrigger.value !== 1 && l.selectActiveOption()), l.closeCombobox();
|
|
1225
|
+
}
|
|
1226
|
+
function M(_) {
|
|
1227
|
+
var L, b, g;
|
|
1228
|
+
let T = (L = _.relatedTarget) != null ? L : ce.find((c) => c !== _.currentTarget);
|
|
1229
|
+
(b = P(l.buttonRef)) != null && b.contains(T) || (g = P(l.optionsRef)) != null && g.contains(T) || l.disabled.value || l.immediate.value && l.comboboxState.value !== 0 && (l.openCombobox(), Ae().nextFrame(() => {
|
|
1230
1230
|
l.setActivationTrigger(1);
|
|
1231
1231
|
}));
|
|
1232
1232
|
}
|
|
1233
1233
|
let D = w(() => {
|
|
1234
|
-
var _,
|
|
1235
|
-
return (
|
|
1234
|
+
var _, L, b, g;
|
|
1235
|
+
return (g = (b = (L = e.defaultValue) != null ? L : l.defaultValue.value !== void 0 ? (_ = e.displayValue) == null ? void 0 : _.call(e, l.defaultValue.value) : null) != null ? b : l.defaultValue.value) != null ? g : "";
|
|
1236
1236
|
});
|
|
1237
1237
|
return () => {
|
|
1238
|
-
var _,
|
|
1239
|
-
let x = { open: l.comboboxState.value === 0 }, { displayValue: E, onChange:
|
|
1238
|
+
var _, L, b, g, T, c, d;
|
|
1239
|
+
let x = { open: l.comboboxState.value === 0 }, { displayValue: E, onChange: V, ...A } = e, G = { "aria-controls": (_ = l.optionsRef.value) == null ? void 0 : _.id, "aria-expanded": l.comboboxState.value === 0, "aria-activedescendant": l.activeOptionIndex.value === null ? void 0 : l.virtual.value ? (L = l.options.value.find((q) => !l.virtual.value.disabled(q.dataRef.value) && l.compare(q.dataRef.value, l.virtual.value.options[l.activeOptionIndex.value]))) == null ? void 0 : L.id : (b = l.options.value[l.activeOptionIndex.value]) == null ? void 0 : b.id, "aria-labelledby": (c = (g = P(l.labelRef)) == null ? void 0 : g.id) != null ? c : (T = P(l.buttonRef)) == null ? void 0 : T.id, "aria-autocomplete": "list", id: r, onCompositionstart: h, onCompositionend: m, onKeydown: N, onInput: R, onFocus: M, onBlur: I, role: "combobox", type: (d = t.type) != null ? d : "text", tabIndex: 0, ref: l.inputRef, defaultValue: D.value, disabled: l.disabled.value === !0 ? !0 : void 0 };
|
|
1240
1240
|
return pe({ ourProps: G, theirProps: A, slot: x, attrs: t, slots: n, features: Oe.RenderStrategy | Oe.Static, name: "ComboboxInput" });
|
|
1241
1241
|
};
|
|
1242
|
-
} }),
|
|
1243
|
-
let s = ve("ComboboxOptions"), i = `headlessui-combobox-options-${
|
|
1242
|
+
} }), Lo = 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 s = ve("ComboboxOptions"), i = `headlessui-combobox-options-${Le()}`;
|
|
1244
1244
|
n({ el: s.optionsRef, $el: s.optionsRef }), re(() => {
|
|
1245
1245
|
s.optionsPropsRef.value.static = e.static;
|
|
1246
1246
|
}), re(() => {
|
|
1247
1247
|
s.optionsPropsRef.value.hold = e.hold;
|
|
1248
1248
|
});
|
|
1249
1249
|
let r = bo(), l = w(() => r !== null ? (r.value & $e.Open) === $e.Open : s.comboboxState.value === 0);
|
|
1250
|
-
po({ container: w(() =>
|
|
1250
|
+
po({ container: w(() => P(s.optionsRef)), enabled: w(() => s.comboboxState.value === 0), accept(u) {
|
|
1251
1251
|
return u.getAttribute("role") === "option" ? NodeFilter.FILTER_REJECT : u.hasAttribute("role") ? NodeFilter.FILTER_SKIP : NodeFilter.FILTER_ACCEPT;
|
|
1252
1252
|
}, walk(u) {
|
|
1253
1253
|
u.setAttribute("role", "none");
|
|
@@ -1257,104 +1257,104 @@ let Io = ae({ name: "ComboboxButton", props: { as: { type: [Object, String], def
|
|
|
1257
1257
|
}
|
|
1258
1258
|
return () => {
|
|
1259
1259
|
var u, p, f;
|
|
1260
|
-
let v = { open: s.comboboxState.value === 0 }, h = { "aria-labelledby": (f = (u =
|
|
1260
|
+
let v = { open: s.comboboxState.value === 0 }, h = { "aria-labelledby": (f = (u = P(s.labelRef)) == null ? void 0 : u.id) != null ? f : (p = P(s.buttonRef)) == null ? void 0 : p.id, id: i, ref: s.optionsRef, role: "listbox", "aria-multiselectable": s.mode.value === 1 ? !0 : void 0, onMousedown: a }, m = je(e, ["hold"]);
|
|
1261
1261
|
return pe({ ourProps: h, theirProps: m, slot: v, attrs: o, slots: s.virtual.value && s.comboboxState.value === 0 ? { ...t, default: () => [Se(Oo, {}, t.default)] } : t, features: Oe.RenderStrategy | Oe.Static, visible: l.value, name: "ComboboxOptions" });
|
|
1262
1262
|
};
|
|
1263
|
-
} }),
|
|
1264
|
-
let s = ve("ComboboxOption"), i = `headlessui-combobox-option-${
|
|
1263
|
+
} }), Po = 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 s = ve("ComboboxOption"), i = `headlessui-combobox-option-${Le()}`, r = S(null), l = w(() => e.disabled);
|
|
1265
1265
|
n({ el: r, $el: r });
|
|
1266
1266
|
let a = w(() => {
|
|
1267
1267
|
var I;
|
|
1268
1268
|
return s.virtual.value ? s.activeOptionIndex.value === s.calculateIndex(e.value) : s.activeOptionIndex.value === null ? !1 : ((I = s.options.value[s.activeOptionIndex.value]) == null ? void 0 : I.id) === i;
|
|
1269
|
-
}), u = w(() => s.isSelected(e.value)), p =
|
|
1270
|
-
xe(() => s.registerOption(i, f)),
|
|
1271
|
-
let I =
|
|
1269
|
+
}), u = w(() => s.isSelected(e.value)), p = Te(Ut, null), f = w(() => ({ disabled: e.disabled, value: e.value, domRef: r, order: w(() => e.order) }));
|
|
1270
|
+
xe(() => s.registerOption(i, f)), Et(() => s.unregisterOption(i, a.value)), re(() => {
|
|
1271
|
+
let I = P(r);
|
|
1272
1272
|
I && (p == null || p.value.measureElement(I));
|
|
1273
1273
|
}), re(() => {
|
|
1274
1274
|
s.comboboxState.value === 0 && a.value && (s.virtual.value || s.activationTrigger.value !== 0 && Q(() => {
|
|
1275
|
-
var I,
|
|
1276
|
-
return (
|
|
1275
|
+
var I, M;
|
|
1276
|
+
return (M = (I = P(r)) == null ? void 0 : I.scrollIntoView) == null ? void 0 : M.call(I, { block: "nearest" });
|
|
1277
1277
|
}));
|
|
1278
1278
|
});
|
|
1279
1279
|
function v(I) {
|
|
1280
|
-
I.preventDefault(), I.button ===
|
|
1281
|
-
var
|
|
1282
|
-
return (
|
|
1280
|
+
I.preventDefault(), I.button === Ft.Left && (l.value || (s.selectOption(i), Mt() || requestAnimationFrame(() => {
|
|
1281
|
+
var M;
|
|
1282
|
+
return (M = P(s.inputRef)) == null ? void 0 : M.focus({ preventScroll: !0 });
|
|
1283
1283
|
}), s.mode.value === 0 && s.closeCombobox()));
|
|
1284
1284
|
}
|
|
1285
1285
|
function h() {
|
|
1286
1286
|
var I;
|
|
1287
|
-
if (e.disabled || (I = s.virtual.value) != null && I.disabled(e.value)) return s.goToOption(
|
|
1288
|
-
let
|
|
1289
|
-
s.goToOption(
|
|
1287
|
+
if (e.disabled || (I = s.virtual.value) != null && I.disabled(e.value)) return s.goToOption(H.Nothing);
|
|
1288
|
+
let M = s.calculateIndex(e.value);
|
|
1289
|
+
s.goToOption(H.Specific, M);
|
|
1290
1290
|
}
|
|
1291
1291
|
let m = fo();
|
|
1292
|
-
function
|
|
1292
|
+
function O(I) {
|
|
1293
1293
|
m.update(I);
|
|
1294
1294
|
}
|
|
1295
1295
|
function N(I) {
|
|
1296
|
-
var
|
|
1297
|
-
if (!m.wasMoved(I) || e.disabled || (
|
|
1296
|
+
var M;
|
|
1297
|
+
if (!m.wasMoved(I) || e.disabled || (M = s.virtual.value) != null && M.disabled(e.value) || a.value) return;
|
|
1298
1298
|
let D = s.calculateIndex(e.value);
|
|
1299
|
-
s.goToOption(
|
|
1299
|
+
s.goToOption(H.Specific, D, 0);
|
|
1300
1300
|
}
|
|
1301
1301
|
function R(I) {
|
|
1302
|
-
var
|
|
1303
|
-
m.wasMoved(I) && (e.disabled || (
|
|
1302
|
+
var M;
|
|
1303
|
+
m.wasMoved(I) && (e.disabled || (M = s.virtual.value) != null && M.disabled(e.value) || a.value && (s.optionsPropsRef.value.hold || s.goToOption(H.Nothing)));
|
|
1304
1304
|
}
|
|
1305
1305
|
return () => {
|
|
1306
|
-
let { disabled: I } = e,
|
|
1307
|
-
return pe({ ourProps: D, theirProps: _, slot:
|
|
1306
|
+
let { disabled: I } = e, M = { active: a.value, selected: u.value, disabled: I }, D = { id: i, ref: r, role: "option", tabIndex: I === !0 ? void 0 : -1, "aria-disabled": I === !0 ? !0 : void 0, "aria-selected": u.value, disabled: void 0, onMousedown: v, onFocus: h, onPointerenter: O, onMouseenter: O, onPointermove: N, onMousemove: N, onPointerleave: R, onMouseleave: R }, _ = je(e, ["order", "value"]);
|
|
1307
|
+
return pe({ ourProps: D, theirProps: _, slot: M, attrs: t, slots: o, name: "ComboboxOption" });
|
|
1308
1308
|
};
|
|
1309
1309
|
} });
|
|
1310
|
-
function
|
|
1311
|
-
return y(),
|
|
1310
|
+
function Vo(e, o) {
|
|
1311
|
+
return y(), $("svg", {
|
|
1312
1312
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1313
1313
|
viewBox: "0 0 20 20",
|
|
1314
1314
|
fill: "currentColor",
|
|
1315
1315
|
"aria-hidden": "true",
|
|
1316
1316
|
"data-slot": "icon"
|
|
1317
1317
|
}, [
|
|
1318
|
-
|
|
1318
|
+
C("path", {
|
|
1319
1319
|
"fill-rule": "evenodd",
|
|
1320
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
1321
|
"clip-rule": "evenodd"
|
|
1322
1322
|
})
|
|
1323
1323
|
]);
|
|
1324
1324
|
}
|
|
1325
|
-
function
|
|
1326
|
-
return y(),
|
|
1325
|
+
function ko(e, o) {
|
|
1326
|
+
return y(), $("svg", {
|
|
1327
1327
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1328
1328
|
viewBox: "0 0 20 20",
|
|
1329
1329
|
fill: "currentColor",
|
|
1330
1330
|
"aria-hidden": "true",
|
|
1331
1331
|
"data-slot": "icon"
|
|
1332
1332
|
}, [
|
|
1333
|
-
|
|
1333
|
+
C("path", {
|
|
1334
1334
|
"fill-rule": "evenodd",
|
|
1335
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",
|
|
1336
1336
|
"clip-rule": "evenodd"
|
|
1337
1337
|
})
|
|
1338
1338
|
]);
|
|
1339
1339
|
}
|
|
1340
|
-
function
|
|
1341
|
-
return y(),
|
|
1340
|
+
function Mo(e, o) {
|
|
1341
|
+
return y(), $("svg", {
|
|
1342
1342
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1343
1343
|
viewBox: "0 0 20 20",
|
|
1344
1344
|
fill: "currentColor",
|
|
1345
1345
|
"aria-hidden": "true",
|
|
1346
1346
|
"data-slot": "icon"
|
|
1347
1347
|
}, [
|
|
1348
|
-
|
|
1348
|
+
C("path", {
|
|
1349
1349
|
"fill-rule": "evenodd",
|
|
1350
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
1351
|
"clip-rule": "evenodd"
|
|
1352
1352
|
})
|
|
1353
1353
|
]);
|
|
1354
1354
|
}
|
|
1355
|
-
const
|
|
1355
|
+
const mt = {
|
|
1356
1356
|
__name: "Select",
|
|
1357
|
-
props: /* @__PURE__ */
|
|
1357
|
+
props: /* @__PURE__ */ fn({
|
|
1358
1358
|
languages: {
|
|
1359
1359
|
type: Object,
|
|
1360
1360
|
required: !0
|
|
@@ -1365,31 +1365,31 @@ const ht = {
|
|
|
1365
1365
|
}),
|
|
1366
1366
|
emits: ["update:modelValue"],
|
|
1367
1367
|
setup(e) {
|
|
1368
|
-
const o = e, t =
|
|
1368
|
+
const o = e, t = pn(e, "modelValue"), n = S(""), s = S(null), i = w(() => Object.entries(o.languages).filter(
|
|
1369
1369
|
([, l]) => l.toLowerCase().includes(n.value.toLowerCase())
|
|
1370
1370
|
)), r = (l) => {
|
|
1371
1371
|
l.target.value = "", n.value = "", s.value && s.value.$el.click();
|
|
1372
1372
|
};
|
|
1373
|
-
return (l, a) => (y(), ee(
|
|
1373
|
+
return (l, a) => (y(), ee(k($o), {
|
|
1374
1374
|
modelValue: t.value,
|
|
1375
1375
|
"onUpdate:modelValue": a[3] || (a[3] = (u) => t.value = u),
|
|
1376
1376
|
as: "div",
|
|
1377
1377
|
class: "relative mt-1"
|
|
1378
1378
|
}, {
|
|
1379
|
-
default:
|
|
1380
|
-
B(
|
|
1379
|
+
default: Pe(() => [
|
|
1380
|
+
B(k(To), {
|
|
1381
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",
|
|
1382
1382
|
onChange: a[0] || (a[0] = (u) => n.value = u.target.value),
|
|
1383
1383
|
displayValue: (u) => e.languages[u],
|
|
1384
1384
|
onFocus: a[1] || (a[1] = (u) => r(u))
|
|
1385
1385
|
}, null, 8, ["displayValue"]),
|
|
1386
|
-
B(
|
|
1386
|
+
B(k(Io), {
|
|
1387
1387
|
ref_key: "btnSelect",
|
|
1388
1388
|
ref: s,
|
|
1389
1389
|
class: "absolute inset-y-0 right-0 flex items-center pr-2"
|
|
1390
1390
|
}, {
|
|
1391
|
-
default:
|
|
1392
|
-
B(
|
|
1391
|
+
default: Pe(() => [
|
|
1392
|
+
B(k(ko), {
|
|
1393
1393
|
class: "h-5 w-5 text-gray-400",
|
|
1394
1394
|
"aria-hidden": "true",
|
|
1395
1395
|
onClick: a[2] || (a[2] = (u) => r(u))
|
|
@@ -1397,20 +1397,20 @@ const ht = {
|
|
|
1397
1397
|
]),
|
|
1398
1398
|
_: 1
|
|
1399
1399
|
}, 512),
|
|
1400
|
-
B(
|
|
1401
|
-
default:
|
|
1402
|
-
(y(!0),
|
|
1400
|
+
B(k(Lo), { 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: Pe(() => [
|
|
1402
|
+
(y(!0), $(Z, null, le(i.value, ([u, p]) => (y(), ee(k(Po), {
|
|
1403
1403
|
key: u,
|
|
1404
1404
|
value: u
|
|
1405
1405
|
}, {
|
|
1406
|
-
default:
|
|
1407
|
-
|
|
1406
|
+
default: Pe(({ active: f, selected: v }) => [
|
|
1407
|
+
C("li", {
|
|
1408
1408
|
class: Ce([
|
|
1409
1409
|
"relative cursor-default select-none py-2 pl-3 pr-9",
|
|
1410
1410
|
f ? "bg-[#3B5695] text-white" : "text-textCustom"
|
|
1411
1411
|
])
|
|
1412
1412
|
}, [
|
|
1413
|
-
|
|
1413
|
+
C("span", {
|
|
1414
1414
|
class: Ce(["block truncate", v && "font-semibold"])
|
|
1415
1415
|
}, te(p), 3)
|
|
1416
1416
|
], 2)
|
|
@@ -1424,14 +1424,14 @@ const ht = {
|
|
|
1424
1424
|
_: 1
|
|
1425
1425
|
}, 8, ["modelValue"]));
|
|
1426
1426
|
}
|
|
1427
|
-
},
|
|
1428
|
-
src:
|
|
1427
|
+
}, Zt = "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__ */ C("img", {
|
|
1428
|
+
src: Zt,
|
|
1429
1429
|
alt: "swap",
|
|
1430
1430
|
class: "w-4"
|
|
1431
1431
|
}, null, -1), Ao = [
|
|
1432
1432
|
No
|
|
1433
|
-
], Do = /* @__PURE__ */
|
|
1434
|
-
src:
|
|
1433
|
+
], Do = /* @__PURE__ */ C("img", {
|
|
1434
|
+
src: Zt,
|
|
1435
1435
|
alt: "swap",
|
|
1436
1436
|
class: "w-4"
|
|
1437
1437
|
}, null, -1), Fo = [
|
|
@@ -1447,14 +1447,14 @@ const ht = {
|
|
|
1447
1447
|
emits: ["swap"],
|
|
1448
1448
|
setup(e, { emit: o }) {
|
|
1449
1449
|
const t = o;
|
|
1450
|
-
return (n, s) => e.isBidirect ? (y(),
|
|
1450
|
+
return (n, s) => e.isBidirect ? (y(), $("button", {
|
|
1451
1451
|
key: 1,
|
|
1452
1452
|
onClick: s[0] || (s[0] = (i) => t("swap"))
|
|
1453
|
-
}, Fo)) : (y(),
|
|
1453
|
+
}, Fo)) : (y(), $("button", Ro, Ao));
|
|
1454
1454
|
}
|
|
1455
1455
|
};
|
|
1456
|
-
var
|
|
1457
|
-
function
|
|
1456
|
+
var Wt = !1;
|
|
1457
|
+
function ke(e, o, t) {
|
|
1458
1458
|
return Array.isArray(e) ? (e.length = Math.max(e.length, o), e.splice(o, 1, t), t) : (e[o] = t, t);
|
|
1459
1459
|
}
|
|
1460
1460
|
function qe(e, o) {
|
|
@@ -1465,9 +1465,9 @@ function qe(e, o) {
|
|
|
1465
1465
|
delete e[o];
|
|
1466
1466
|
}
|
|
1467
1467
|
function Bo() {
|
|
1468
|
-
return
|
|
1468
|
+
return Gt().__VUE_DEVTOOLS_GLOBAL_HOOK__;
|
|
1469
1469
|
}
|
|
1470
|
-
function
|
|
1470
|
+
function Gt() {
|
|
1471
1471
|
return typeof navigator < "u" && typeof window < "u" ? window : typeof globalThis < "u" ? globalThis : {};
|
|
1472
1472
|
}
|
|
1473
1473
|
const Ho = typeof Proxy == "function", zo = "devtools-plugin:setup", Uo = "plugin:settings:set";
|
|
@@ -1541,8 +1541,8 @@ class Go {
|
|
|
1541
1541
|
t.resolve(await this.target[t.method](...t.args));
|
|
1542
1542
|
}
|
|
1543
1543
|
}
|
|
1544
|
-
function
|
|
1545
|
-
const t = e, n =
|
|
1544
|
+
function qt(e, o) {
|
|
1545
|
+
const t = e, n = Gt(), s = Bo(), i = Ho && t.enableEarlyProxy;
|
|
1546
1546
|
if (s && (n.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !i))
|
|
1547
1547
|
s.emit(zo, e, o);
|
|
1548
1548
|
else {
|
|
@@ -1560,7 +1560,7 @@ function Gt(e, o) {
|
|
|
1560
1560
|
* @license MIT
|
|
1561
1561
|
*/
|
|
1562
1562
|
let we;
|
|
1563
|
-
const Ie = (e) => we = e,
|
|
1563
|
+
const Ie = (e) => we = e, Jt = process.env.NODE_ENV !== "production" ? Symbol("pinia") : (
|
|
1564
1564
|
/* istanbul ignore next */
|
|
1565
1565
|
Symbol()
|
|
1566
1566
|
);
|
|
@@ -1571,19 +1571,19 @@ var ne;
|
|
|
1571
1571
|
(function(e) {
|
|
1572
1572
|
e.direct = "direct", e.patchObject = "patch object", e.patchFunction = "patch function";
|
|
1573
1573
|
})(ne || (ne = {}));
|
|
1574
|
-
const Be = typeof window < "u", Ee = (process.env.NODE_ENV !== "production" || !1) && process.env.NODE_ENV !== "test" && Be,
|
|
1574
|
+
const Be = typeof window < "u", Ee = (process.env.NODE_ENV !== "production" || !1) && process.env.NODE_ENV !== "test" && Be, gt = 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
1575
|
function qo(e, { autoBom: o = !1 } = {}) {
|
|
1576
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;
|
|
1577
1577
|
}
|
|
1578
1578
|
function st(e, o, t) {
|
|
1579
1579
|
const n = new XMLHttpRequest();
|
|
1580
1580
|
n.open("GET", e), n.responseType = "blob", n.onload = function() {
|
|
1581
|
-
|
|
1581
|
+
Qt(n.response, o, t);
|
|
1582
1582
|
}, n.onerror = function() {
|
|
1583
1583
|
console.error("could not download file");
|
|
1584
1584
|
}, n.send();
|
|
1585
1585
|
}
|
|
1586
|
-
function
|
|
1586
|
+
function Kt(e) {
|
|
1587
1587
|
const o = new XMLHttpRequest();
|
|
1588
1588
|
o.open("HEAD", e, !1);
|
|
1589
1589
|
try {
|
|
@@ -1592,7 +1592,7 @@ function Jt(e) {
|
|
|
1592
1592
|
}
|
|
1593
1593
|
return o.status >= 200 && o.status <= 299;
|
|
1594
1594
|
}
|
|
1595
|
-
function
|
|
1595
|
+
function Me(e) {
|
|
1596
1596
|
try {
|
|
1597
1597
|
e.dispatchEvent(new MouseEvent("click"));
|
|
1598
1598
|
} catch {
|
|
@@ -1600,9 +1600,9 @@ function ke(e) {
|
|
|
1600
1600
|
t.initMouseEvent("click", !0, !0, window, 0, 0, 0, 80, 20, !1, !1, !1, !1, 0, null), e.dispatchEvent(t);
|
|
1601
1601
|
}
|
|
1602
1602
|
}
|
|
1603
|
-
const Re = typeof navigator == "object" ? navigator : { userAgent: "" },
|
|
1603
|
+
const Re = typeof navigator == "object" ? navigator : { userAgent: "" }, Yt = /Macintosh/.test(Re.userAgent) && /AppleWebKit/.test(Re.userAgent) && !/Safari/.test(Re.userAgent), Qt = Be ? (
|
|
1604
1604
|
// Use download attribute first if possible (#193 Lumia mobile) unless this is a macOS WebView or mini program
|
|
1605
|
-
typeof HTMLAnchorElement < "u" && "download" in HTMLAnchorElement.prototype && !
|
|
1605
|
+
typeof HTMLAnchorElement < "u" && "download" in HTMLAnchorElement.prototype && !Yt ? Jo : (
|
|
1606
1606
|
// Use msSaveOrOpenBlob as a second approach
|
|
1607
1607
|
"msSaveOrOpenBlob" in Re ? Ko : (
|
|
1608
1608
|
// Fallback to using FileReader and a popup
|
|
@@ -1613,20 +1613,20 @@ const Re = typeof navigator == "object" ? navigator : { userAgent: "" }, Kt = /M
|
|
|
1613
1613
|
};
|
|
1614
1614
|
function Jo(e, o = "download", t) {
|
|
1615
1615
|
const n = document.createElement("a");
|
|
1616
|
-
n.download = o, n.rel = "noopener", typeof e == "string" ? (n.href = e, n.origin !== location.origin ?
|
|
1616
|
+
n.download = o, n.rel = "noopener", typeof e == "string" ? (n.href = e, n.origin !== location.origin ? Kt(n.href) ? st(e, o, t) : (n.target = "_blank", Me(n)) : Me(n)) : (n.href = URL.createObjectURL(e), setTimeout(function() {
|
|
1617
1617
|
URL.revokeObjectURL(n.href);
|
|
1618
1618
|
}, 4e4), setTimeout(function() {
|
|
1619
|
-
|
|
1619
|
+
Me(n);
|
|
1620
1620
|
}, 0));
|
|
1621
1621
|
}
|
|
1622
1622
|
function Ko(e, o = "download", t) {
|
|
1623
1623
|
if (typeof e == "string")
|
|
1624
|
-
if (
|
|
1624
|
+
if (Kt(e))
|
|
1625
1625
|
st(e, o, t);
|
|
1626
1626
|
else {
|
|
1627
1627
|
const n = document.createElement("a");
|
|
1628
1628
|
n.href = e, n.target = "_blank", setTimeout(function() {
|
|
1629
|
-
|
|
1629
|
+
Me(n);
|
|
1630
1630
|
});
|
|
1631
1631
|
}
|
|
1632
1632
|
else
|
|
@@ -1635,8 +1635,8 @@ function Ko(e, o = "download", t) {
|
|
|
1635
1635
|
function Yo(e, o, t, n) {
|
|
1636
1636
|
if (n = n || open("", "_blank"), n && (n.document.title = n.document.body.innerText = "downloading..."), typeof e == "string")
|
|
1637
1637
|
return st(e, o, t);
|
|
1638
|
-
const s = e.type === "application/octet-stream", i = /constructor/i.test(String(
|
|
1639
|
-
if ((r || s && i ||
|
|
1638
|
+
const s = e.type === "application/octet-stream", i = /constructor/i.test(String(gt.HTMLElement)) || "safari" in gt, r = /CriOS\/[\d]+/.test(navigator.userAgent);
|
|
1639
|
+
if ((r || s && i || Yt) && typeof FileReader < "u") {
|
|
1640
1640
|
const l = new FileReader();
|
|
1641
1641
|
l.onloadend = function() {
|
|
1642
1642
|
let a = l.result;
|
|
@@ -1658,36 +1658,36 @@ function j(e, o) {
|
|
|
1658
1658
|
function lt(e) {
|
|
1659
1659
|
return "_a" in e && "install" in e;
|
|
1660
1660
|
}
|
|
1661
|
-
function
|
|
1661
|
+
function Xt() {
|
|
1662
1662
|
if (!("clipboard" in navigator))
|
|
1663
1663
|
return j("Your browser doesn't support the Clipboard API", "error"), !0;
|
|
1664
1664
|
}
|
|
1665
|
-
function
|
|
1665
|
+
function en(e) {
|
|
1666
1666
|
return e instanceof Error && e.message.toLowerCase().includes("document is not focused") ? (j('You need to activate the "Emulate a focused page" setting in the "Rendering" panel of devtools.', "warn"), !0) : !1;
|
|
1667
1667
|
}
|
|
1668
1668
|
async function Qo(e) {
|
|
1669
|
-
if (!
|
|
1669
|
+
if (!Xt())
|
|
1670
1670
|
try {
|
|
1671
1671
|
await navigator.clipboard.writeText(JSON.stringify(e.state.value)), j("Global state copied to clipboard.");
|
|
1672
1672
|
} catch (o) {
|
|
1673
|
-
if (
|
|
1673
|
+
if (en(o))
|
|
1674
1674
|
return;
|
|
1675
1675
|
j("Failed to serialize the state. Check the console for more details.", "error"), console.error(o);
|
|
1676
1676
|
}
|
|
1677
1677
|
}
|
|
1678
1678
|
async function Xo(e) {
|
|
1679
|
-
if (!
|
|
1679
|
+
if (!Xt())
|
|
1680
1680
|
try {
|
|
1681
|
-
|
|
1681
|
+
tn(e, JSON.parse(await navigator.clipboard.readText())), j("Global state pasted from clipboard.");
|
|
1682
1682
|
} catch (o) {
|
|
1683
|
-
if (
|
|
1683
|
+
if (en(o))
|
|
1684
1684
|
return;
|
|
1685
1685
|
j("Failed to deserialize the state from clipboard. Check the console for more details.", "error"), console.error(o);
|
|
1686
1686
|
}
|
|
1687
1687
|
}
|
|
1688
|
-
async function
|
|
1688
|
+
async function es(e) {
|
|
1689
1689
|
try {
|
|
1690
|
-
|
|
1690
|
+
Qt(new Blob([JSON.stringify(e.state.value)], {
|
|
1691
1691
|
type: "text/plain;charset=utf-8"
|
|
1692
1692
|
}), "pinia-state.json");
|
|
1693
1693
|
} catch (o) {
|
|
@@ -1695,7 +1695,7 @@ async function e2(e) {
|
|
|
1695
1695
|
}
|
|
1696
1696
|
}
|
|
1697
1697
|
let oe;
|
|
1698
|
-
function
|
|
1698
|
+
function ts() {
|
|
1699
1699
|
oe || (oe = document.createElement("input"), oe.type = "file", oe.accept = ".json");
|
|
1700
1700
|
function e() {
|
|
1701
1701
|
return new Promise((o, t) => {
|
|
@@ -1710,18 +1710,18 @@ function t2() {
|
|
|
1710
1710
|
}
|
|
1711
1711
|
return e;
|
|
1712
1712
|
}
|
|
1713
|
-
async function
|
|
1713
|
+
async function ns(e) {
|
|
1714
1714
|
try {
|
|
1715
|
-
const t = await
|
|
1715
|
+
const t = await ts()();
|
|
1716
1716
|
if (!t)
|
|
1717
1717
|
return;
|
|
1718
1718
|
const { text: n, file: s } = t;
|
|
1719
|
-
|
|
1719
|
+
tn(e, JSON.parse(n)), j(`Global state imported from "${s.name}".`);
|
|
1720
1720
|
} catch (o) {
|
|
1721
1721
|
j("Failed to import the state from JSON. Check the console for more details.", "error"), console.error(o);
|
|
1722
1722
|
}
|
|
1723
1723
|
}
|
|
1724
|
-
function
|
|
1724
|
+
function tn(e, o) {
|
|
1725
1725
|
for (const t in o) {
|
|
1726
1726
|
const n = e.state.value[t];
|
|
1727
1727
|
n ? Object.assign(n, o[t]) : e.state.value[t] = o[t];
|
|
@@ -1734,17 +1734,17 @@ function Y(e) {
|
|
|
1734
1734
|
}
|
|
1735
1735
|
};
|
|
1736
1736
|
}
|
|
1737
|
-
const
|
|
1738
|
-
function
|
|
1737
|
+
const nn = "🍍 Pinia (root)", Ke = "_root";
|
|
1738
|
+
function os(e) {
|
|
1739
1739
|
return lt(e) ? {
|
|
1740
1740
|
id: Ke,
|
|
1741
|
-
label:
|
|
1741
|
+
label: nn
|
|
1742
1742
|
} : {
|
|
1743
1743
|
id: e.$id,
|
|
1744
1744
|
label: e.$id
|
|
1745
1745
|
};
|
|
1746
1746
|
}
|
|
1747
|
-
function
|
|
1747
|
+
function ss(e) {
|
|
1748
1748
|
if (lt(e)) {
|
|
1749
1749
|
const t = Array.from(e._s.keys()), n = e._s;
|
|
1750
1750
|
return {
|
|
@@ -1780,7 +1780,7 @@ function s2(e) {
|
|
|
1780
1780
|
value: e[t]
|
|
1781
1781
|
}))), o;
|
|
1782
1782
|
}
|
|
1783
|
-
function
|
|
1783
|
+
function ls(e) {
|
|
1784
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), {
|
|
1785
1785
|
oldValue: {},
|
|
1786
1786
|
keys: [],
|
|
@@ -1793,7 +1793,7 @@ function l2(e) {
|
|
|
1793
1793
|
newValue: e.newValue
|
|
1794
1794
|
} : {};
|
|
1795
1795
|
}
|
|
1796
|
-
function
|
|
1796
|
+
function is(e) {
|
|
1797
1797
|
switch (e) {
|
|
1798
1798
|
case ne.direct:
|
|
1799
1799
|
return "mutation";
|
|
@@ -1806,9 +1806,9 @@ function i2(e) {
|
|
|
1806
1806
|
}
|
|
1807
1807
|
}
|
|
1808
1808
|
let be = !0;
|
|
1809
|
-
const Ne = [], ue = "pinia:mutations", U = "pinia", { assign:
|
|
1810
|
-
function
|
|
1811
|
-
|
|
1809
|
+
const Ne = [], ue = "pinia:mutations", U = "pinia", { assign: rs } = Object, De = (e) => "🍍 " + e;
|
|
1810
|
+
function as(e, o) {
|
|
1811
|
+
qt({
|
|
1812
1812
|
id: "dev.esm.pinia",
|
|
1813
1813
|
label: "Pinia 🍍",
|
|
1814
1814
|
logo: "https://pinia.vuejs.org/logo.svg",
|
|
@@ -1844,14 +1844,14 @@ function a2(e, o) {
|
|
|
1844
1844
|
{
|
|
1845
1845
|
icon: "save",
|
|
1846
1846
|
action: () => {
|
|
1847
|
-
|
|
1847
|
+
es(o);
|
|
1848
1848
|
},
|
|
1849
1849
|
tooltip: "Save the state as a JSON file"
|
|
1850
1850
|
},
|
|
1851
1851
|
{
|
|
1852
1852
|
icon: "folder_open",
|
|
1853
1853
|
action: async () => {
|
|
1854
|
-
await
|
|
1854
|
+
await ns(o), t.sendInspectorTree(U), t.sendInspectorState(U);
|
|
1855
1855
|
},
|
|
1856
1856
|
tooltip: "Import the state from a JSON file"
|
|
1857
1857
|
}
|
|
@@ -1908,14 +1908,14 @@ function a2(e, o) {
|
|
|
1908
1908
|
}), t.on.getInspectorTree((n) => {
|
|
1909
1909
|
if (n.app === e && n.inspectorId === U) {
|
|
1910
1910
|
let s = [o];
|
|
1911
|
-
s = s.concat(Array.from(o._s.values())), n.rootNodes = (n.filter ? s.filter((i) => "$id" in i ? i.$id.toLowerCase().includes(n.filter.toLowerCase()) :
|
|
1911
|
+
s = s.concat(Array.from(o._s.values())), n.rootNodes = (n.filter ? s.filter((i) => "$id" in i ? i.$id.toLowerCase().includes(n.filter.toLowerCase()) : nn.toLowerCase().includes(n.filter.toLowerCase())) : s).map(os);
|
|
1912
1912
|
}
|
|
1913
1913
|
}), t.on.getInspectorState((n) => {
|
|
1914
1914
|
if (n.app === e && n.inspectorId === U) {
|
|
1915
1915
|
const s = n.nodeId === Ke ? o : o._s.get(n.nodeId);
|
|
1916
1916
|
if (!s)
|
|
1917
1917
|
return;
|
|
1918
|
-
s && (n.state =
|
|
1918
|
+
s && (n.state = ss(s));
|
|
1919
1919
|
}
|
|
1920
1920
|
}), t.on.editInspectorState((n, s) => {
|
|
1921
1921
|
if (n.app === e && n.inspectorId === U) {
|
|
@@ -1940,8 +1940,8 @@ Only state can be modified.`);
|
|
|
1940
1940
|
});
|
|
1941
1941
|
});
|
|
1942
1942
|
}
|
|
1943
|
-
function
|
|
1944
|
-
Ne.includes(De(o.$id)) || Ne.push(De(o.$id)),
|
|
1943
|
+
function us(e, o) {
|
|
1944
|
+
Ne.includes(De(o.$id)) || Ne.push(De(o.$id)), qt({
|
|
1945
1945
|
id: "dev.esm.pinia",
|
|
1946
1946
|
label: "Pinia 🍍",
|
|
1947
1947
|
logo: "https://pinia.vuejs.org/logo.svg",
|
|
@@ -1964,7 +1964,7 @@ function u2(e, o) {
|
|
|
1964
1964
|
}, (t) => {
|
|
1965
1965
|
const n = typeof t.now == "function" ? t.now.bind(t) : Date.now;
|
|
1966
1966
|
o.$onAction(({ after: r, onError: l, name: a, args: u }) => {
|
|
1967
|
-
const p =
|
|
1967
|
+
const p = on++;
|
|
1968
1968
|
t.addTimelineEvent({
|
|
1969
1969
|
layerId: ue,
|
|
1970
1970
|
event: {
|
|
@@ -2013,7 +2013,7 @@ function u2(e, o) {
|
|
|
2013
2013
|
});
|
|
2014
2014
|
});
|
|
2015
2015
|
}, !0), o._customProperties.forEach((r) => {
|
|
2016
|
-
|
|
2016
|
+
z(() => k(o[r]), (l, a) => {
|
|
2017
2017
|
t.notifyComponentUpdate(), t.sendInspectorState(U), be && t.addTimelineEvent({
|
|
2018
2018
|
layerId: ue,
|
|
2019
2019
|
event: {
|
|
@@ -2033,8 +2033,8 @@ function u2(e, o) {
|
|
|
2033
2033
|
return;
|
|
2034
2034
|
const u = {
|
|
2035
2035
|
time: n(),
|
|
2036
|
-
title:
|
|
2037
|
-
data:
|
|
2036
|
+
title: is(l),
|
|
2037
|
+
data: rs({ store: Y(o.$id) }, ls(r)),
|
|
2038
2038
|
groupId: ie
|
|
2039
2039
|
};
|
|
2040
2040
|
l === ne.patchFunction ? u.subtitle = "⤵️" : l === ne.patchObject ? u.subtitle = "🧩" : r && !Array.isArray(r) && (u.subtitle = r.type), r && (u.data["rawEvent(s)"] = {
|
|
@@ -2070,12 +2070,12 @@ function u2(e, o) {
|
|
|
2070
2070
|
}, t.notifyComponentUpdate(), t.sendInspectorTree(U), t.sendInspectorState(U), t.getSettings().logStoreChanges && j(`"${o.$id}" store installed 🆕`);
|
|
2071
2071
|
});
|
|
2072
2072
|
}
|
|
2073
|
-
let
|
|
2074
|
-
function
|
|
2073
|
+
let on = 0, ie;
|
|
2074
|
+
function bt(e, o, t) {
|
|
2075
2075
|
const n = o.reduce((s, i) => (s[i] = K(e)[i], s), {});
|
|
2076
2076
|
for (const s in n)
|
|
2077
2077
|
e[s] = function() {
|
|
2078
|
-
const i =
|
|
2078
|
+
const i = on, r = t ? new Proxy(e, {
|
|
2079
2079
|
get(...a) {
|
|
2080
2080
|
return ie = i, Reflect.get(...a);
|
|
2081
2081
|
},
|
|
@@ -2088,28 +2088,28 @@ function gt(e, o, t) {
|
|
|
2088
2088
|
return ie = void 0, l;
|
|
2089
2089
|
};
|
|
2090
2090
|
}
|
|
2091
|
-
function
|
|
2091
|
+
function cs({ app: e, store: o, options: t }) {
|
|
2092
2092
|
if (o.$id.startsWith("__hot:"))
|
|
2093
2093
|
return;
|
|
2094
|
-
o._isOptionsAPI = !!t.state,
|
|
2094
|
+
o._isOptionsAPI = !!t.state, bt(o, Object.keys(t.actions), o._isOptionsAPI);
|
|
2095
2095
|
const n = o._hotUpdate;
|
|
2096
2096
|
K(o)._hotUpdate = function(s) {
|
|
2097
|
-
n.apply(this, arguments),
|
|
2098
|
-
},
|
|
2097
|
+
n.apply(this, arguments), bt(o, Object.keys(s._hmrPayload.actions), !!o._isOptionsAPI);
|
|
2098
|
+
}, us(
|
|
2099
2099
|
e,
|
|
2100
2100
|
// FIXME: is there a way to allow the assignment from Store<Id, S, G, A> to StoreGeneric?
|
|
2101
2101
|
o
|
|
2102
2102
|
);
|
|
2103
2103
|
}
|
|
2104
|
-
function
|
|
2105
|
-
const e =
|
|
2104
|
+
function ds() {
|
|
2105
|
+
const e = $t(!0), o = e.run(() => S({}));
|
|
2106
2106
|
let t = [], n = [];
|
|
2107
2107
|
const s = de({
|
|
2108
2108
|
install(i) {
|
|
2109
|
-
Ie(s), s._a = i, i.provide(
|
|
2109
|
+
Ie(s), s._a = i, i.provide(Jt, s), i.config.globalProperties.$pinia = s, Ee && as(i, s), n.forEach((r) => t.push(r)), n = [];
|
|
2110
2110
|
},
|
|
2111
2111
|
use(i) {
|
|
2112
|
-
return !this._a && !
|
|
2112
|
+
return !this._a && !Wt ? n.push(i) : t.push(i), this;
|
|
2113
2113
|
},
|
|
2114
2114
|
_p: t,
|
|
2115
2115
|
// it's actually undefined here
|
|
@@ -2119,34 +2119,34 @@ function d2() {
|
|
|
2119
2119
|
_s: /* @__PURE__ */ new Map(),
|
|
2120
2120
|
state: o
|
|
2121
2121
|
});
|
|
2122
|
-
return Ee && typeof Proxy < "u" && s.use(
|
|
2122
|
+
return Ee && typeof Proxy < "u" && s.use(cs), s;
|
|
2123
2123
|
}
|
|
2124
|
-
function
|
|
2124
|
+
function sn(e, o) {
|
|
2125
2125
|
for (const t in o) {
|
|
2126
2126
|
const n = o[t];
|
|
2127
2127
|
if (!(t in e))
|
|
2128
2128
|
continue;
|
|
2129
2129
|
const s = e[t];
|
|
2130
|
-
fe(s) && fe(n) && !_e(n) && !tt(n) ? e[t] =
|
|
2130
|
+
fe(s) && fe(n) && !_e(n) && !tt(n) ? e[t] = sn(s, n) : e[t] = n;
|
|
2131
2131
|
}
|
|
2132
2132
|
return e;
|
|
2133
2133
|
}
|
|
2134
|
-
const
|
|
2134
|
+
const ln = () => {
|
|
2135
2135
|
};
|
|
2136
|
-
function
|
|
2136
|
+
function Ct(e, o, t, n = ln) {
|
|
2137
2137
|
e.push(o);
|
|
2138
2138
|
const s = () => {
|
|
2139
2139
|
const i = e.indexOf(o);
|
|
2140
2140
|
i > -1 && (e.splice(i, 1), n());
|
|
2141
2141
|
};
|
|
2142
|
-
return !t &&
|
|
2142
|
+
return !t && Tt() && Xe(s), s;
|
|
2143
2143
|
}
|
|
2144
2144
|
function ge(e, ...o) {
|
|
2145
2145
|
e.slice().forEach((t) => {
|
|
2146
2146
|
t(...o);
|
|
2147
2147
|
});
|
|
2148
2148
|
}
|
|
2149
|
-
const
|
|
2149
|
+
const fs = (e) => e();
|
|
2150
2150
|
function Ye(e, o) {
|
|
2151
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);
|
|
2152
2152
|
for (const t in o) {
|
|
@@ -2157,18 +2157,18 @@ function Ye(e, o) {
|
|
|
2157
2157
|
}
|
|
2158
2158
|
return e;
|
|
2159
2159
|
}
|
|
2160
|
-
const
|
|
2160
|
+
const ps = process.env.NODE_ENV !== "production" ? Symbol("pinia:skipHydration") : (
|
|
2161
2161
|
/* istanbul ignore next */
|
|
2162
2162
|
Symbol()
|
|
2163
2163
|
);
|
|
2164
|
-
function
|
|
2165
|
-
return !fe(e) || !e.hasOwnProperty(
|
|
2164
|
+
function vs(e) {
|
|
2165
|
+
return !fe(e) || !e.hasOwnProperty(ps);
|
|
2166
2166
|
}
|
|
2167
2167
|
const { assign: J } = Object;
|
|
2168
|
-
function
|
|
2168
|
+
function _t(e) {
|
|
2169
2169
|
return !!(_e(e) && e.effect);
|
|
2170
2170
|
}
|
|
2171
|
-
function
|
|
2171
|
+
function xt(e, o, t, n) {
|
|
2172
2172
|
const { state: s, actions: i, getters: r } = o, l = t.state.value[e];
|
|
2173
2173
|
let a;
|
|
2174
2174
|
function u() {
|
|
@@ -2194,13 +2194,13 @@ function Qe(e, o, t = {}, n, s, i) {
|
|
|
2194
2194
|
deep: !0
|
|
2195
2195
|
// flush: 'post',
|
|
2196
2196
|
};
|
|
2197
|
-
process.env.NODE_ENV !== "production" && !
|
|
2198
|
-
u ? h = c : u == !1 && !
|
|
2197
|
+
process.env.NODE_ENV !== "production" && !Wt && (a.onTrigger = (c) => {
|
|
2198
|
+
u ? h = c : u == !1 && !b._hotUpdating && (Array.isArray(h) ? h.push(c) : console.error("🍍 debuggerEvents should be an array. This is most likely an internal Pinia bug."));
|
|
2199
2199
|
});
|
|
2200
2200
|
let u, p, f = [], v = [], h;
|
|
2201
2201
|
const m = n.state.value[e];
|
|
2202
2202
|
!i && !m && (process.env.NODE_ENV === "production" || !s) && (n.state.value[e] = {});
|
|
2203
|
-
const
|
|
2203
|
+
const O = S({});
|
|
2204
2204
|
let N;
|
|
2205
2205
|
function R(c) {
|
|
2206
2206
|
let d;
|
|
@@ -2228,87 +2228,87 @@ function Qe(e, o, t = {}, n, s, i) {
|
|
|
2228
2228
|
/* istanbul ignore next */
|
|
2229
2229
|
process.env.NODE_ENV !== "production" ? () => {
|
|
2230
2230
|
throw new Error(`🍍: Store "${e}" is built using the setup syntax and does not implement $reset().`);
|
|
2231
|
-
} :
|
|
2231
|
+
} : ln
|
|
2232
2232
|
);
|
|
2233
|
-
function
|
|
2233
|
+
function M() {
|
|
2234
2234
|
r.stop(), f = [], v = [], n._s.delete(e);
|
|
2235
2235
|
}
|
|
2236
2236
|
function D(c, d) {
|
|
2237
2237
|
return function() {
|
|
2238
2238
|
Ie(n);
|
|
2239
|
-
const x = Array.from(arguments), E = [],
|
|
2239
|
+
const x = Array.from(arguments), E = [], V = [];
|
|
2240
2240
|
function A(F) {
|
|
2241
2241
|
E.push(F);
|
|
2242
2242
|
}
|
|
2243
2243
|
function G(F) {
|
|
2244
|
-
|
|
2244
|
+
V.push(F);
|
|
2245
2245
|
}
|
|
2246
2246
|
ge(v, {
|
|
2247
2247
|
args: x,
|
|
2248
2248
|
name: c,
|
|
2249
|
-
store:
|
|
2249
|
+
store: b,
|
|
2250
2250
|
after: A,
|
|
2251
2251
|
onError: G
|
|
2252
2252
|
});
|
|
2253
2253
|
let q;
|
|
2254
2254
|
try {
|
|
2255
|
-
q = d.apply(this && this.$id === e ? this :
|
|
2255
|
+
q = d.apply(this && this.$id === e ? this : b, x);
|
|
2256
2256
|
} catch (F) {
|
|
2257
|
-
throw ge(
|
|
2257
|
+
throw ge(V, F), F;
|
|
2258
2258
|
}
|
|
2259
|
-
return q instanceof Promise ? q.then((F) => (ge(E, F), F)).catch((F) => (ge(
|
|
2259
|
+
return q instanceof Promise ? q.then((F) => (ge(E, F), F)).catch((F) => (ge(V, F), Promise.reject(F))) : (ge(E, q), q);
|
|
2260
2260
|
};
|
|
2261
2261
|
}
|
|
2262
2262
|
const _ = /* @__PURE__ */ de({
|
|
2263
2263
|
actions: {},
|
|
2264
2264
|
getters: {},
|
|
2265
2265
|
state: [],
|
|
2266
|
-
hotState:
|
|
2267
|
-
}),
|
|
2266
|
+
hotState: O
|
|
2267
|
+
}), L = {
|
|
2268
2268
|
_p: n,
|
|
2269
2269
|
// _s: scope,
|
|
2270
2270
|
$id: e,
|
|
2271
|
-
$onAction:
|
|
2271
|
+
$onAction: Ct.bind(null, v),
|
|
2272
2272
|
$patch: R,
|
|
2273
2273
|
$reset: I,
|
|
2274
2274
|
$subscribe(c, d = {}) {
|
|
2275
|
-
const x =
|
|
2275
|
+
const x = Ct(f, c, d.detached, () => E()), E = r.run(() => z(() => n.state.value[e], (V) => {
|
|
2276
2276
|
(d.flush === "sync" ? p : u) && c({
|
|
2277
2277
|
storeId: e,
|
|
2278
2278
|
type: ne.direct,
|
|
2279
2279
|
events: h
|
|
2280
|
-
},
|
|
2280
|
+
}, V);
|
|
2281
2281
|
}, J({}, a, d)));
|
|
2282
2282
|
return x;
|
|
2283
2283
|
},
|
|
2284
|
-
$dispose:
|
|
2285
|
-
},
|
|
2284
|
+
$dispose: M
|
|
2285
|
+
}, b = Ot(process.env.NODE_ENV !== "production" || Ee ? J(
|
|
2286
2286
|
{
|
|
2287
2287
|
_hmrPayload: _,
|
|
2288
2288
|
_customProperties: de(/* @__PURE__ */ new Set())
|
|
2289
2289
|
// devtools custom properties
|
|
2290
2290
|
},
|
|
2291
|
-
|
|
2291
|
+
L
|
|
2292
2292
|
// must be added later
|
|
2293
2293
|
// setupStore
|
|
2294
|
-
) :
|
|
2295
|
-
n._s.set(e,
|
|
2296
|
-
const
|
|
2297
|
-
for (const c in
|
|
2298
|
-
const d =
|
|
2299
|
-
if (_e(d) && !
|
|
2300
|
-
process.env.NODE_ENV !== "production" && s ?
|
|
2294
|
+
) : L);
|
|
2295
|
+
n._s.set(e, b);
|
|
2296
|
+
const T = (n._a && n._a.runWithContext || fs)(() => n._e.run(() => (r = $t()).run(o)));
|
|
2297
|
+
for (const c in T) {
|
|
2298
|
+
const d = T[c];
|
|
2299
|
+
if (_e(d) && !_t(d) || tt(d))
|
|
2300
|
+
process.env.NODE_ENV !== "production" && s ? ke(O.value, c, Ze(T, c)) : i || (m && vs(d) && (_e(d) ? d.value = m[c] : Ye(d, m[c])), n.state.value[e][c] = d), process.env.NODE_ENV !== "production" && _.state.push(c);
|
|
2301
2301
|
else if (typeof d == "function") {
|
|
2302
2302
|
const x = process.env.NODE_ENV !== "production" && s ? d : D(c, d);
|
|
2303
|
-
|
|
2304
|
-
} else process.env.NODE_ENV !== "production" &&
|
|
2303
|
+
T[c] = x, process.env.NODE_ENV !== "production" && (_.actions[c] = d), l.actions[c] = d;
|
|
2304
|
+
} else process.env.NODE_ENV !== "production" && _t(d) && (_.getters[c] = i ? (
|
|
2305
2305
|
// @ts-expect-error
|
|
2306
2306
|
t.getters[c]
|
|
2307
|
-
) : d, Be && (
|
|
2308
|
-
(
|
|
2307
|
+
) : d, Be && (T._getters || // @ts-expect-error: same
|
|
2308
|
+
(T._getters = de([]))).push(c));
|
|
2309
2309
|
}
|
|
2310
|
-
if (J(
|
|
2311
|
-
get: () => process.env.NODE_ENV !== "production" && s ?
|
|
2310
|
+
if (J(b, T), J(K(b), T), Object.defineProperty(b, "$state", {
|
|
2311
|
+
get: () => process.env.NODE_ENV !== "production" && s ? O.value : n.state.value[e],
|
|
2312
2312
|
set: (c) => {
|
|
2313
2313
|
if (process.env.NODE_ENV !== "production" && s)
|
|
2314
2314
|
throw new Error("cannot set hotState");
|
|
@@ -2316,34 +2316,34 @@ function Qe(e, o, t = {}, n, s, i) {
|
|
|
2316
2316
|
J(d, c);
|
|
2317
2317
|
});
|
|
2318
2318
|
}
|
|
2319
|
-
}), process.env.NODE_ENV !== "production" && (
|
|
2320
|
-
|
|
2321
|
-
if (d in
|
|
2322
|
-
const x = c.$state[d], E =
|
|
2323
|
-
typeof x == "object" && fe(x) && fe(E) ?
|
|
2319
|
+
}), process.env.NODE_ENV !== "production" && (b._hotUpdate = de((c) => {
|
|
2320
|
+
b._hotUpdating = !0, c._hmrPayload.state.forEach((d) => {
|
|
2321
|
+
if (d in b.$state) {
|
|
2322
|
+
const x = c.$state[d], E = b.$state[d];
|
|
2323
|
+
typeof x == "object" && fe(x) && fe(E) ? sn(x, E) : c.$state[d] = E;
|
|
2324
2324
|
}
|
|
2325
|
-
|
|
2326
|
-
}), Object.keys(
|
|
2327
|
-
d in c.$state || qe(
|
|
2325
|
+
ke(b, d, Ze(c.$state, d));
|
|
2326
|
+
}), Object.keys(b.$state).forEach((d) => {
|
|
2327
|
+
d in c.$state || qe(b, d);
|
|
2328
2328
|
}), u = !1, p = !1, n.state.value[e] = Ze(c._hmrPayload, "hotState"), p = !0, Q().then(() => {
|
|
2329
2329
|
u = !0;
|
|
2330
2330
|
});
|
|
2331
2331
|
for (const d in c._hmrPayload.actions) {
|
|
2332
2332
|
const x = c[d];
|
|
2333
|
-
|
|
2333
|
+
ke(b, d, D(d, x));
|
|
2334
2334
|
}
|
|
2335
2335
|
for (const d in c._hmrPayload.getters) {
|
|
2336
2336
|
const x = c._hmrPayload.getters[d], E = i ? (
|
|
2337
2337
|
// special handling of options api
|
|
2338
|
-
w(() => (Ie(n), x.call(
|
|
2338
|
+
w(() => (Ie(n), x.call(b, b)))
|
|
2339
2339
|
) : x;
|
|
2340
|
-
|
|
2340
|
+
ke(b, d, E);
|
|
2341
2341
|
}
|
|
2342
|
-
Object.keys(
|
|
2343
|
-
d in c._hmrPayload.getters || qe(
|
|
2344
|
-
}), Object.keys(
|
|
2345
|
-
d in c._hmrPayload.actions || qe(
|
|
2346
|
-
}),
|
|
2342
|
+
Object.keys(b._hmrPayload.getters).forEach((d) => {
|
|
2343
|
+
d in c._hmrPayload.getters || qe(b, d);
|
|
2344
|
+
}), Object.keys(b._hmrPayload.actions).forEach((d) => {
|
|
2345
|
+
d in c._hmrPayload.actions || qe(b, d);
|
|
2346
|
+
}), b._hmrPayload = c._hmrPayload, b._getters = c._getters, b._hotUpdating = !1;
|
|
2347
2347
|
})), Ee) {
|
|
2348
2348
|
const c = {
|
|
2349
2349
|
writable: !0,
|
|
@@ -2352,28 +2352,28 @@ function Qe(e, o, t = {}, n, s, i) {
|
|
|
2352
2352
|
enumerable: !1
|
|
2353
2353
|
};
|
|
2354
2354
|
["_p", "_hmrPayload", "_getters", "_customProperties"].forEach((d) => {
|
|
2355
|
-
Object.defineProperty(
|
|
2355
|
+
Object.defineProperty(b, d, J({ value: b[d] }, c));
|
|
2356
2356
|
});
|
|
2357
2357
|
}
|
|
2358
2358
|
return n._p.forEach((c) => {
|
|
2359
2359
|
if (Ee) {
|
|
2360
2360
|
const d = r.run(() => c({
|
|
2361
|
-
store:
|
|
2361
|
+
store: b,
|
|
2362
2362
|
app: n._a,
|
|
2363
2363
|
pinia: n,
|
|
2364
2364
|
options: l
|
|
2365
2365
|
}));
|
|
2366
|
-
Object.keys(d || {}).forEach((x) =>
|
|
2366
|
+
Object.keys(d || {}).forEach((x) => b._customProperties.add(x)), J(b, d);
|
|
2367
2367
|
} else
|
|
2368
|
-
J(
|
|
2369
|
-
store:
|
|
2368
|
+
J(b, r.run(() => c({
|
|
2369
|
+
store: b,
|
|
2370
2370
|
app: n._a,
|
|
2371
2371
|
pinia: n,
|
|
2372
2372
|
options: l
|
|
2373
2373
|
})));
|
|
2374
|
-
}), process.env.NODE_ENV !== "production" &&
|
|
2374
|
+
}), process.env.NODE_ENV !== "production" && b.$state && typeof b.$state == "object" && typeof b.$state.constructor == "function" && !b.$state.constructor.toString().includes("[native code]") && console.warn(`[🍍]: The "state" must be a plain object. It cannot be
|
|
2375
2375
|
state: () => new MyClass()
|
|
2376
|
-
Found in store "${
|
|
2376
|
+
Found in store "${b.$id}".`), m && i && t.hydrate && t.hydrate(b.$state, m), u = !0, p = !0, b;
|
|
2377
2377
|
}
|
|
2378
2378
|
function it(e, o, t) {
|
|
2379
2379
|
let n, s;
|
|
@@ -2383,21 +2383,21 @@ function it(e, o, t) {
|
|
|
2383
2383
|
else if (s = e, n = e.id, process.env.NODE_ENV !== "production" && typeof n != "string")
|
|
2384
2384
|
throw new Error('[🍍]: "defineStore()" must be passed a store id as its first argument.');
|
|
2385
2385
|
function r(l, a) {
|
|
2386
|
-
const u =
|
|
2386
|
+
const u = vn();
|
|
2387
2387
|
if (l = // in test mode, ignore the argument provided as we can always retrieve a
|
|
2388
2388
|
// pinia instance with getActivePinia()
|
|
2389
|
-
(process.env.NODE_ENV === "test" && we && we._testing ? null : l) || (u ?
|
|
2389
|
+
(process.env.NODE_ENV === "test" && we && we._testing ? null : l) || (u ? Te(Jt, null) : null), l && Ie(l), process.env.NODE_ENV !== "production" && !we)
|
|
2390
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)"?
|
|
2391
2391
|
See https://pinia.vuejs.org/core-concepts/outside-component-usage.html for help.
|
|
2392
2392
|
This will fail in production.`);
|
|
2393
|
-
l = we, l._s.has(n) || (i ? Qe(n, o, s, l) :
|
|
2393
|
+
l = we, l._s.has(n) || (i ? Qe(n, o, s, l) : xt(n, s, l), process.env.NODE_ENV !== "production" && (r._pinia = l));
|
|
2394
2394
|
const p = l._s.get(n);
|
|
2395
2395
|
if (process.env.NODE_ENV !== "production" && a) {
|
|
2396
|
-
const f = "__hot:" + n, v = i ? Qe(f, o, s, l, !0) :
|
|
2396
|
+
const f = "__hot:" + n, v = i ? Qe(f, o, s, l, !0) : xt(f, J({}, s), l, !0);
|
|
2397
2397
|
a._hotUpdate(v), delete l.state.value[f], l._s.delete(f);
|
|
2398
2398
|
}
|
|
2399
2399
|
if (process.env.NODE_ENV !== "production" && Be) {
|
|
2400
|
-
const f =
|
|
2400
|
+
const f = It();
|
|
2401
2401
|
if (f && f.proxy && // avoid adding stores that are just built for hot module replacement
|
|
2402
2402
|
!a) {
|
|
2403
2403
|
const v = f.proxy, h = "_pStores" in v ? v._pStores : v._pStores = {};
|
|
@@ -2425,37 +2425,37 @@ const He = it("language", () => {
|
|
|
2425
2425
|
return t.value.src[a] || t.value.target[a];
|
|
2426
2426
|
}
|
|
2427
2427
|
return { languages: t, src: e, target: o, srcLabel: n, targetLabel: s, init: i, swap: r, getLabel: l };
|
|
2428
|
-
}),
|
|
2428
|
+
}), hs = {
|
|
2429
2429
|
key: 0,
|
|
2430
2430
|
class: "flex"
|
|
2431
|
-
},
|
|
2431
|
+
}, ms = {
|
|
2432
2432
|
__name: "Selects",
|
|
2433
2433
|
setup(e) {
|
|
2434
2434
|
const o = He();
|
|
2435
2435
|
function t() {
|
|
2436
2436
|
o.swap();
|
|
2437
2437
|
}
|
|
2438
|
-
return (n, s) =>
|
|
2439
|
-
B(
|
|
2440
|
-
modelValue:
|
|
2441
|
-
"onUpdate:modelValue": s[0] || (s[0] = (i) =>
|
|
2442
|
-
languages:
|
|
2438
|
+
return (n, s) => k(o).languages ? (y(), $("div", hs, [
|
|
2439
|
+
B(mt, {
|
|
2440
|
+
modelValue: k(o).src,
|
|
2441
|
+
"onUpdate:modelValue": s[0] || (s[0] = (i) => k(o).src = i),
|
|
2442
|
+
languages: k(o).languages.src,
|
|
2443
2443
|
class: "grow"
|
|
2444
2444
|
}, null, 8, ["modelValue", "languages"]),
|
|
2445
2445
|
B(jo, {
|
|
2446
|
-
isBidirect:
|
|
2446
|
+
isBidirect: k(o).src !== "auto",
|
|
2447
2447
|
class: "grow-0 mx-3",
|
|
2448
2448
|
onSwap: t
|
|
2449
2449
|
}, null, 8, ["isBidirect"]),
|
|
2450
|
-
B(
|
|
2451
|
-
modelValue:
|
|
2452
|
-
"onUpdate:modelValue": s[1] || (s[1] = (i) =>
|
|
2453
|
-
languages:
|
|
2450
|
+
B(mt, {
|
|
2451
|
+
modelValue: k(o).target,
|
|
2452
|
+
"onUpdate:modelValue": s[1] || (s[1] = (i) => k(o).target = i),
|
|
2453
|
+
languages: k(o).languages.target,
|
|
2454
2454
|
class: "grow"
|
|
2455
2455
|
}, null, 8, ["modelValue", "languages"])
|
|
2456
2456
|
])) : X("", !0);
|
|
2457
2457
|
}
|
|
2458
|
-
},
|
|
2458
|
+
}, gs = {
|
|
2459
2459
|
INPUT_MAX_LENGTH: 5e3,
|
|
2460
2460
|
INPUT_DEBOUNCE: 500
|
|
2461
2461
|
}, ze = (e, o) => {
|
|
@@ -2463,19 +2463,21 @@ const He = it("language", () => {
|
|
|
2463
2463
|
for (const [n, s] of o)
|
|
2464
2464
|
t[n] = s;
|
|
2465
2465
|
return t;
|
|
2466
|
-
},
|
|
2467
|
-
function
|
|
2468
|
-
return y(),
|
|
2466
|
+
}, bs = {}, Cs = { class: "mr-2 loading loading-dots loading-xs" };
|
|
2467
|
+
function _s(e, o) {
|
|
2468
|
+
return y(), $("span", Cs);
|
|
2469
2469
|
}
|
|
2470
|
-
const
|
|
2471
|
-
|
|
2472
|
-
src: y2,
|
|
2470
|
+
const xs = /* @__PURE__ */ ze(bs, [["render", _s]]), ys = "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", ws = "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", Es = /* @__PURE__ */ C("img", {
|
|
2471
|
+
src: ys,
|
|
2473
2472
|
alt: "Play"
|
|
2474
|
-
},
|
|
2475
|
-
|
|
2476
|
-
|
|
2473
|
+
}, null, -1), Ss = [
|
|
2474
|
+
Es
|
|
2475
|
+
], Os = /* @__PURE__ */ C("img", {
|
|
2476
|
+
src: ws,
|
|
2477
2477
|
alt: "Stop"
|
|
2478
|
-
},
|
|
2478
|
+
}, null, -1), $s = [
|
|
2479
|
+
Os
|
|
2480
|
+
], Is = {
|
|
2479
2481
|
__name: "SpeakBtn",
|
|
2480
2482
|
props: {
|
|
2481
2483
|
url: {
|
|
@@ -2484,61 +2486,62 @@ const x2 = /* @__PURE__ */ ze(b2, [["render", _2]]), y2 = "data:image/svg+xml,%3
|
|
|
2484
2486
|
}
|
|
2485
2487
|
},
|
|
2486
2488
|
setup(e) {
|
|
2487
|
-
const o = e, t = S(!1);
|
|
2488
|
-
let n = new Audio(o.url);
|
|
2489
|
-
H(
|
|
2490
|
-
() => o.url,
|
|
2491
|
-
(i) => {
|
|
2492
|
-
n = new Audio(i);
|
|
2493
|
-
}
|
|
2494
|
-
);
|
|
2489
|
+
const o = e, t = S(!1), n = new Audio();
|
|
2495
2490
|
function s() {
|
|
2496
|
-
|
|
2491
|
+
o.url && (n.src = o.url, t.value = !0, n.play().catch((r) => {
|
|
2492
|
+
console.error(r), t.value = !1;
|
|
2493
|
+
}));
|
|
2494
|
+
}
|
|
2495
|
+
function i() {
|
|
2496
|
+
n.pause(), n.currentTime = 0, t.value = !1;
|
|
2497
2497
|
}
|
|
2498
2498
|
return n.onended = () => {
|
|
2499
2499
|
t.value = !1;
|
|
2500
|
-
}, (
|
|
2500
|
+
}, (r, l) => t.value ? (y(), $("button", {
|
|
2501
|
+
key: 1,
|
|
2501
2502
|
class: "btn btn-xs btn-ghost btn-circle",
|
|
2502
|
-
onClick:
|
|
2503
|
-
},
|
|
2504
|
-
|
|
2505
|
-
|
|
2503
|
+
onClick: ut(i, ["prevent"])
|
|
2504
|
+
}, $s)) : (y(), $("button", {
|
|
2505
|
+
key: 0,
|
|
2506
|
+
class: "btn btn-xs btn-ghost btn-circle",
|
|
2507
|
+
onClick: ut(s, ["prevent"])
|
|
2508
|
+
}, Ss));
|
|
2506
2509
|
}
|
|
2507
|
-
},
|
|
2508
|
-
src:
|
|
2510
|
+
}, Ts = "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", Ls = {}, Ps = { class: "btn btn-xs btn-circle btn-ghost" }, Vs = /* @__PURE__ */ C("img", {
|
|
2511
|
+
src: Ts,
|
|
2509
2512
|
alt: "Clear",
|
|
2510
2513
|
class: "w-4"
|
|
2511
|
-
}, null, -1),
|
|
2512
|
-
|
|
2514
|
+
}, null, -1), ks = [
|
|
2515
|
+
Vs
|
|
2513
2516
|
];
|
|
2514
|
-
function
|
|
2515
|
-
return y(),
|
|
2517
|
+
function Ms(e, o) {
|
|
2518
|
+
return y(), $("button", Ps, ks);
|
|
2516
2519
|
}
|
|
2517
|
-
const
|
|
2520
|
+
const Rs = /* @__PURE__ */ ze(Ls, [["render", Ms]]), Ns = "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", As = "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", Ds = { class: "btn btn-xs btn-circle btn-ghost" }, Fs = {
|
|
2518
2521
|
key: 0,
|
|
2519
|
-
src:
|
|
2522
|
+
src: Ns,
|
|
2520
2523
|
alt: "Clear",
|
|
2521
2524
|
class: "w-4"
|
|
2522
|
-
},
|
|
2525
|
+
}, js = {
|
|
2523
2526
|
key: 1,
|
|
2524
|
-
src:
|
|
2527
|
+
src: As,
|
|
2525
2528
|
alt: "Clear",
|
|
2526
2529
|
class: "w-4"
|
|
2527
|
-
},
|
|
2530
|
+
}, Bs = {
|
|
2528
2531
|
__name: "FavoriteBtn",
|
|
2529
2532
|
props: {
|
|
2530
2533
|
isFilled: Boolean
|
|
2531
2534
|
},
|
|
2532
2535
|
setup(e) {
|
|
2533
2536
|
const o = e;
|
|
2534
|
-
return (t, n) => (y(),
|
|
2535
|
-
o.isFilled ? (y(),
|
|
2537
|
+
return (t, n) => (y(), $("button", Ds, [
|
|
2538
|
+
o.isFilled ? (y(), $("img", Fs)) : (y(), $("img", js))
|
|
2536
2539
|
]));
|
|
2537
2540
|
}
|
|
2538
|
-
},
|
|
2541
|
+
}, Hs = { class: "flex flex-row rounded-t-lg bg-white border border-b-0 px-1 pr-1 pt-1 gap-1 items-center" }, zs = { class: "text-sm text-gray-600" }, Us = {
|
|
2539
2542
|
key: 0,
|
|
2540
2543
|
class: "italic"
|
|
2541
|
-
},
|
|
2544
|
+
}, Zs = /* @__PURE__ */ C("div", { class: "flex-grow" }, null, -1), rn = {
|
|
2542
2545
|
__name: "TranslationBtnGroup",
|
|
2543
2546
|
props: {
|
|
2544
2547
|
loading: {
|
|
@@ -2582,22 +2585,22 @@ const M2 = /* @__PURE__ */ ze(I2, [["render", P2]]), k2 = "data:image/svg+xml,%3
|
|
|
2582
2585
|
emits: ["clear", "favorite"],
|
|
2583
2586
|
setup(e, { emit: o }) {
|
|
2584
2587
|
const t = e, n = o;
|
|
2585
|
-
return (s, i) => (y(),
|
|
2586
|
-
t.tts ? (y(), ee(
|
|
2588
|
+
return (s, i) => (y(), $("div", Hs, [
|
|
2589
|
+
t.tts ? (y(), ee(Is, {
|
|
2587
2590
|
key: 0,
|
|
2588
2591
|
url: t.tts
|
|
2589
2592
|
}, null, 8, ["url"])) : X("", !0),
|
|
2590
|
-
|
|
2593
|
+
C("div", zs, [
|
|
2591
2594
|
hn(te(e.srcLabel) + " ", 1),
|
|
2592
|
-
e.phonetic ? (y(),
|
|
2595
|
+
e.phonetic ? (y(), $("span", Us, "- [" + te(t.phonetic) + "]", 1)) : X("", !0)
|
|
2593
2596
|
]),
|
|
2594
|
-
|
|
2595
|
-
t.loading ? (y(), ee(
|
|
2596
|
-
t.src && t.isClearBtn ? (y(), ee(
|
|
2597
|
+
Zs,
|
|
2598
|
+
t.loading ? (y(), ee(xs, { key: 1 })) : X("", !0),
|
|
2599
|
+
t.src && t.isClearBtn ? (y(), ee(Rs, {
|
|
2597
2600
|
key: 2,
|
|
2598
2601
|
onClick: i[0] || (i[0] = (r) => n("clear"))
|
|
2599
2602
|
})) : X("", !0),
|
|
2600
|
-
t.src && t.isFavoriteBtn ? (y(), ee(
|
|
2603
|
+
t.src && t.isFavoriteBtn ? (y(), ee(Bs, {
|
|
2601
2604
|
key: 3,
|
|
2602
2605
|
isFilled: t.isFavorite,
|
|
2603
2606
|
onClick: i[1] || (i[1] = (r) => n("favorite"))
|
|
@@ -2640,17 +2643,17 @@ const M2 = /* @__PURE__ */ ze(I2, [["render", P2]]), k2 = "data:image/svg+xml,%3
|
|
|
2640
2643
|
reset: h
|
|
2641
2644
|
};
|
|
2642
2645
|
});
|
|
2643
|
-
function
|
|
2644
|
-
return
|
|
2646
|
+
function Ws(e) {
|
|
2647
|
+
return Tt() ? (Xe(e), !0) : !1;
|
|
2645
2648
|
}
|
|
2646
2649
|
function Fe(e) {
|
|
2647
|
-
return typeof e == "function" ? e() :
|
|
2650
|
+
return typeof e == "function" ? e() : k(e);
|
|
2648
2651
|
}
|
|
2649
|
-
const
|
|
2652
|
+
const Gs = typeof window < "u" && typeof document < "u";
|
|
2650
2653
|
typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
|
|
2651
|
-
const
|
|
2654
|
+
const yt = () => {
|
|
2652
2655
|
};
|
|
2653
|
-
function
|
|
2656
|
+
function qs(e, o) {
|
|
2654
2657
|
function t(...n) {
|
|
2655
2658
|
return new Promise((s, i) => {
|
|
2656
2659
|
Promise.resolve(e(() => o.apply(this, n), { fn: o, thisArg: this, args: n })).then(s).catch(i);
|
|
@@ -2658,10 +2661,10 @@ function W2(e, o) {
|
|
|
2658
2661
|
}
|
|
2659
2662
|
return t;
|
|
2660
2663
|
}
|
|
2661
|
-
function
|
|
2662
|
-
let t, n, s =
|
|
2664
|
+
function Js(e, o = {}) {
|
|
2665
|
+
let t, n, s = yt;
|
|
2663
2666
|
const i = (l) => {
|
|
2664
|
-
clearTimeout(l), s(), s =
|
|
2667
|
+
clearTimeout(l), s(), s = yt;
|
|
2665
2668
|
};
|
|
2666
2669
|
return (l) => {
|
|
2667
2670
|
const a = Fe(e), u = Fe(o.maxWait);
|
|
@@ -2674,34 +2677,34 @@ function G2(e, o = {}) {
|
|
|
2674
2677
|
});
|
|
2675
2678
|
};
|
|
2676
2679
|
}
|
|
2677
|
-
function
|
|
2678
|
-
return
|
|
2679
|
-
|
|
2680
|
+
function Ks(e, o = 200, t = {}) {
|
|
2681
|
+
return qs(
|
|
2682
|
+
Js(o, t),
|
|
2680
2683
|
e
|
|
2681
2684
|
);
|
|
2682
2685
|
}
|
|
2683
|
-
function
|
|
2686
|
+
function wt(e) {
|
|
2684
2687
|
var o;
|
|
2685
2688
|
const t = Fe(e);
|
|
2686
2689
|
return (o = t == null ? void 0 : t.$el) != null ? o : t;
|
|
2687
2690
|
}
|
|
2688
|
-
const
|
|
2689
|
-
function
|
|
2690
|
-
const e = S(!1), o =
|
|
2691
|
+
const Ys = Gs ? window : void 0;
|
|
2692
|
+
function Qs() {
|
|
2693
|
+
const e = S(!1), o = It();
|
|
2691
2694
|
return o && xe(() => {
|
|
2692
2695
|
e.value = !0;
|
|
2693
2696
|
}, o), e;
|
|
2694
2697
|
}
|
|
2695
|
-
function
|
|
2696
|
-
const o =
|
|
2698
|
+
function Xs(e) {
|
|
2699
|
+
const o = Qs();
|
|
2697
2700
|
return w(() => (o.value, !!e()));
|
|
2698
2701
|
}
|
|
2699
|
-
function
|
|
2700
|
-
const { window: n =
|
|
2702
|
+
function el(e, o, t = {}) {
|
|
2703
|
+
const { window: n = Ys, ...s } = t;
|
|
2701
2704
|
let i;
|
|
2702
|
-
const r =
|
|
2705
|
+
const r = Xs(() => n && "ResizeObserver" in n), l = () => {
|
|
2703
2706
|
i && (i.disconnect(), i = void 0);
|
|
2704
|
-
}, a = w(() => Array.isArray(e) ? e.map((f) =>
|
|
2707
|
+
}, a = w(() => Array.isArray(e) ? e.map((f) => wt(f)) : [wt(e)]), u = z(
|
|
2705
2708
|
a,
|
|
2706
2709
|
(f) => {
|
|
2707
2710
|
if (l(), r.value && n) {
|
|
@@ -2714,12 +2717,12 @@ function Q2(e, o, t = {}) {
|
|
|
2714
2717
|
), p = () => {
|
|
2715
2718
|
l(), u();
|
|
2716
2719
|
};
|
|
2717
|
-
return
|
|
2720
|
+
return Ws(p), {
|
|
2718
2721
|
isSupported: r,
|
|
2719
2722
|
stop: p
|
|
2720
2723
|
};
|
|
2721
2724
|
}
|
|
2722
|
-
function
|
|
2725
|
+
function an(e) {
|
|
2723
2726
|
var o;
|
|
2724
2727
|
const t = S(e == null ? void 0 : e.element), n = S(e == null ? void 0 : e.input), s = (o = e == null ? void 0 : e.styleProp) != null ? o : "height", i = S(1);
|
|
2725
2728
|
function r() {
|
|
@@ -2729,16 +2732,16 @@ function rn(e) {
|
|
|
2729
2732
|
let a = "";
|
|
2730
2733
|
t.value.style[s] = "1px", i.value = (l = t.value) == null ? void 0 : l.scrollHeight, e != null && e.styleTarget ? Fe(e.styleTarget).style[s] = `${i.value}px` : a = `${i.value}px`, t.value.style[s] = a;
|
|
2731
2734
|
}
|
|
2732
|
-
return
|
|
2735
|
+
return z([n, t], () => Q(r), { immediate: !0 }), z(i, () => {
|
|
2733
2736
|
var l;
|
|
2734
2737
|
return (l = e == null ? void 0 : e.onResize) == null ? void 0 : l.call(e);
|
|
2735
|
-
}),
|
|
2738
|
+
}), el(t, () => r()), e != null && e.watch && z(e.watch, r, { immediate: !0, deep: !0 }), {
|
|
2736
2739
|
textarea: t,
|
|
2737
2740
|
input: n,
|
|
2738
2741
|
triggerResize: r
|
|
2739
2742
|
};
|
|
2740
2743
|
}
|
|
2741
|
-
const
|
|
2744
|
+
const tl = {
|
|
2742
2745
|
__name: "TranslationInput",
|
|
2743
2746
|
props: {
|
|
2744
2747
|
text: {
|
|
@@ -2749,14 +2752,14 @@ const X2 = {
|
|
|
2749
2752
|
emits: ["change", "clear"],
|
|
2750
2753
|
setup(e, { emit: o }) {
|
|
2751
2754
|
const t = he(), n = e, s = S(""), i = w(() => t.src), r = w(() => t.srcLabel), l = w(() => {
|
|
2752
|
-
var
|
|
2753
|
-
return (
|
|
2755
|
+
var O;
|
|
2756
|
+
return (O = t.phonetic) == null ? void 0 : O.src;
|
|
2754
2757
|
}), a = w(() => {
|
|
2755
|
-
var
|
|
2756
|
-
return (
|
|
2757
|
-
}), { textarea: u } =
|
|
2758
|
+
var O;
|
|
2759
|
+
return (O = t.tts) == null ? void 0 : O.src;
|
|
2760
|
+
}), { textarea: u } = an({ input: s, styleProp: "minHeight" }), p = o, f = Ks(() => {
|
|
2758
2761
|
p("change", s.value);
|
|
2759
|
-
},
|
|
2762
|
+
}, gs.INPUT_DEBOUNCE);
|
|
2760
2763
|
function v() {
|
|
2761
2764
|
if (!s.value) {
|
|
2762
2765
|
h();
|
|
@@ -2770,13 +2773,13 @@ const X2 = {
|
|
|
2770
2773
|
async function m() {
|
|
2771
2774
|
await Q(), u.value.select();
|
|
2772
2775
|
}
|
|
2773
|
-
return
|
|
2776
|
+
return z(
|
|
2774
2777
|
() => n.text,
|
|
2775
|
-
(
|
|
2776
|
-
s.value !==
|
|
2778
|
+
(O) => {
|
|
2779
|
+
s.value !== O && m(), s.value = O;
|
|
2777
2780
|
}
|
|
2778
|
-
), (
|
|
2779
|
-
B(
|
|
2781
|
+
), (O, N) => (y(), $(Z, null, [
|
|
2782
|
+
B(rn, {
|
|
2780
2783
|
src: i.value,
|
|
2781
2784
|
srcLabel: r.value,
|
|
2782
2785
|
tts: a.value,
|
|
@@ -2784,7 +2787,7 @@ const X2 = {
|
|
|
2784
2787
|
isClearBtn: !0,
|
|
2785
2788
|
onClear: h
|
|
2786
2789
|
}, null, 8, ["src", "srcLabel", "tts", "phonetic"]),
|
|
2787
|
-
Lt(
|
|
2790
|
+
Lt(C("textarea", {
|
|
2788
2791
|
ref_key: "textarea",
|
|
2789
2792
|
ref: u,
|
|
2790
2793
|
"onUpdate:modelValue": N[0] || (N[0] = (R) => s.value = R),
|
|
@@ -2795,7 +2798,7 @@ const X2 = {
|
|
|
2795
2798
|
onFocus: m
|
|
2796
2799
|
}, null, 544), [
|
|
2797
2800
|
[
|
|
2798
|
-
|
|
2801
|
+
Pt,
|
|
2799
2802
|
s.value,
|
|
2800
2803
|
void 0,
|
|
2801
2804
|
{ trim: !0 }
|
|
@@ -2803,14 +2806,7 @@ const X2 = {
|
|
|
2803
2806
|
])
|
|
2804
2807
|
], 64));
|
|
2805
2808
|
}
|
|
2806
|
-
},
|
|
2807
|
-
/* @__PURE__ */ g("span", { class: "text-sm" }, "Powered by Google Translate"),
|
|
2808
|
-
/* @__PURE__ */ g("img", {
|
|
2809
|
-
src: ts,
|
|
2810
|
-
alt: "Google",
|
|
2811
|
-
class: "h-5 ml-2"
|
|
2812
|
-
})
|
|
2813
|
-
], -1)), ls = {
|
|
2809
|
+
}, nl = /* @__PURE__ */ ze(tl, [["__scopeId", "data-v-bfa5aec3"]]), un = it("loader", () => ({ loading: S(!1) })), ol = (e) => (mn("data-v-db8f3257"), e = e(), gn(), e), sl = { class: "flex flex-col" }, ll = /* @__PURE__ */ ol(() => /* @__PURE__ */ C("div", { class: "w-full flex align-item-center justify-end mt-2" }, null, -1)), il = {
|
|
2814
2810
|
__name: "TranslationResult",
|
|
2815
2811
|
props: {
|
|
2816
2812
|
isFavoriteFeatureEnabled: Boolean
|
|
@@ -2822,10 +2818,10 @@ const X2 = {
|
|
|
2822
2818
|
}), l = w(() => {
|
|
2823
2819
|
var v;
|
|
2824
2820
|
return (v = o.tts) == null ? void 0 : v.target;
|
|
2825
|
-
}), a = e, u =
|
|
2826
|
-
return (v, h) => (y(),
|
|
2827
|
-
B(
|
|
2828
|
-
loading:
|
|
2821
|
+
}), a = e, u = un(), { textarea: p, input: f } = an({ input: n, styleProp: "minHeight" });
|
|
2822
|
+
return (v, h) => (y(), $(Z, null, [
|
|
2823
|
+
B(rn, {
|
|
2824
|
+
loading: k(u).loading,
|
|
2829
2825
|
src: s.value,
|
|
2830
2826
|
srcLabel: i.value,
|
|
2831
2827
|
tts: l.value,
|
|
@@ -2834,8 +2830,8 @@ const X2 = {
|
|
|
2834
2830
|
phonetic: r.value,
|
|
2835
2831
|
onFavorite: h[0] || (h[0] = (m) => t.value = !t.value)
|
|
2836
2832
|
}, null, 8, ["loading", "src", "srcLabel", "tts", "isFavoriteBtn", "isFavorite", "phonetic"]),
|
|
2837
|
-
|
|
2838
|
-
Lt(
|
|
2833
|
+
C("div", sl, [
|
|
2834
|
+
Lt(C("textarea", {
|
|
2839
2835
|
ref_key: "textarea",
|
|
2840
2836
|
ref: p,
|
|
2841
2837
|
"onUpdate:modelValue": h[1] || (h[1] = (m) => _e(f) ? f.value = m : null),
|
|
@@ -2844,65 +2840,65 @@ const X2 = {
|
|
|
2844
2840
|
rows: "2",
|
|
2845
2841
|
spellcheck: "false"
|
|
2846
2842
|
}, null, 512), [
|
|
2847
|
-
[
|
|
2843
|
+
[Pt, k(f)]
|
|
2848
2844
|
]),
|
|
2849
|
-
|
|
2845
|
+
ll
|
|
2850
2846
|
])
|
|
2851
2847
|
], 64));
|
|
2852
2848
|
}
|
|
2853
|
-
},
|
|
2849
|
+
}, rl = /* @__PURE__ */ ze(il, [["__scopeId", "data-v-db8f3257"]]), al = { class: "btn btn-sm btn-circle btn-ghost" }, Ue = {
|
|
2854
2850
|
__name: "ToggleBtn",
|
|
2855
2851
|
props: {
|
|
2856
2852
|
isExpanded: Boolean
|
|
2857
2853
|
},
|
|
2858
2854
|
setup(e) {
|
|
2859
2855
|
const o = e;
|
|
2860
|
-
return (t, n) => (y(),
|
|
2861
|
-
o.isExpanded ? (y(), ee(
|
|
2856
|
+
return (t, n) => (y(), $("button", al, [
|
|
2857
|
+
o.isExpanded ? (y(), ee(k(Mo), {
|
|
2862
2858
|
key: 0,
|
|
2863
2859
|
class: "w-7 text-gray-400"
|
|
2864
|
-
})) : (y(), ee(
|
|
2860
|
+
})) : (y(), ee(k(Vo), {
|
|
2865
2861
|
key: 1,
|
|
2866
2862
|
class: "w-7 text-gray-400"
|
|
2867
2863
|
}))
|
|
2868
2864
|
]));
|
|
2869
2865
|
}
|
|
2870
|
-
},
|
|
2866
|
+
}, 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__ */ C("h2", { class: "card-title text-base font-bold leading-6 text-textCustom" }, "Translations", -1), pl = { class: "capitalize text-base font-normal text-textSecondary mb-1" }, vl = { class: "list-none list-inside" }, hl = ["onClick"], ml = { class: "text-base font-normal text-gray-800 leading-4" }, gl = {
|
|
2871
2867
|
__name: "Dictionary",
|
|
2872
2868
|
emits: ["translate"],
|
|
2873
2869
|
setup(e, { emit: o }) {
|
|
2874
2870
|
const t = S(!0), n = he(), s = He(), i = w(() => n.dictionary), r = o, l = () => {
|
|
2875
2871
|
t.value = !t.value;
|
|
2876
2872
|
}, a = (u) => {
|
|
2877
|
-
r("translate", u, n.target, n.src), s.src = n.target, s.target = n.src;
|
|
2873
|
+
r("translate", u, n.target, n.src), s.src = n.target, s.target = n.src, window.scrollTo(0, 0);
|
|
2878
2874
|
};
|
|
2879
|
-
return (u, p) => (y(),
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2875
|
+
return (u, p) => (y(), $("div", ul, [
|
|
2876
|
+
C("div", cl, [
|
|
2877
|
+
C("div", dl, [
|
|
2878
|
+
fl,
|
|
2883
2879
|
B(Ue, {
|
|
2884
2880
|
isExpanded: t.value,
|
|
2885
2881
|
onClick: l
|
|
2886
2882
|
}, null, 8, ["isExpanded"])
|
|
2887
2883
|
]),
|
|
2888
|
-
|
|
2884
|
+
C("div", {
|
|
2889
2885
|
class: Ce(["overflow-hidden transition-all duration-300 ease-in-out", t.value ? "max-h-[2000px] opacity-100" : "max-h-0 opacity-0"])
|
|
2890
2886
|
}, [
|
|
2891
|
-
|
|
2892
|
-
(y(!0),
|
|
2887
|
+
C("ul", null, [
|
|
2888
|
+
(y(!0), $(Z, null, le(i.value, (f, v) => (y(), $("li", {
|
|
2893
2889
|
key: `${f.pos}-${v}`,
|
|
2894
2890
|
class: "mb-2"
|
|
2895
2891
|
}, [
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
(y(!0),
|
|
2892
|
+
C("h5", pl, te(f.pos), 1),
|
|
2893
|
+
C("ul", vl, [
|
|
2894
|
+
(y(!0), $(Z, null, le(f.items, (h, m) => (y(), $("li", {
|
|
2899
2895
|
key: `${h.word}-${m}`
|
|
2900
2896
|
}, [
|
|
2901
|
-
|
|
2897
|
+
C("span", {
|
|
2902
2898
|
class: "p-3 m-0.5 font-normal badge badge-ghost bg-primaryColor text-white cursor-pointer border-0 rounded-lg",
|
|
2903
|
-
onClick: (
|
|
2904
|
-
}, te(h.word), 9,
|
|
2905
|
-
|
|
2899
|
+
onClick: (O) => a(h.word)
|
|
2900
|
+
}, te(h.word), 9, hl),
|
|
2901
|
+
C("small", ml, " - " + te(h.reverse_translation.join(", ")), 1)
|
|
2906
2902
|
]))), 128))
|
|
2907
2903
|
])
|
|
2908
2904
|
]))), 128))
|
|
@@ -2911,41 +2907,41 @@ const X2 = {
|
|
|
2911
2907
|
])
|
|
2912
2908
|
]));
|
|
2913
2909
|
}
|
|
2914
|
-
},
|
|
2910
|
+
}, 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__ */ C("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__ */ C("br", null, null, -1), Sl = {
|
|
2915
2911
|
key: 0,
|
|
2916
2912
|
class: "italic"
|
|
2917
|
-
},
|
|
2913
|
+
}, Ol = {
|
|
2918
2914
|
__name: "Definition",
|
|
2919
2915
|
setup(e) {
|
|
2920
2916
|
const o = S(!0), t = he(), n = w(() => t.definitions), s = () => {
|
|
2921
2917
|
o.value = !o.value;
|
|
2922
2918
|
};
|
|
2923
|
-
return (i, r) => (y(),
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2919
|
+
return (i, r) => (y(), $("div", bl, [
|
|
2920
|
+
C("div", Cl, [
|
|
2921
|
+
C("div", _l, [
|
|
2922
|
+
xl,
|
|
2927
2923
|
B(Ue, {
|
|
2928
2924
|
isExpanded: o.value,
|
|
2929
2925
|
onClick: s
|
|
2930
2926
|
}, null, 8, ["isExpanded"])
|
|
2931
2927
|
]),
|
|
2932
|
-
|
|
2928
|
+
C("div", {
|
|
2933
2929
|
class: Ce(["overflow-hidden transition-all duration-300 ease-in-out", o.value ? "max-h-[2000px] opacity-100" : "max-h-0 opacity-0"])
|
|
2934
2930
|
}, [
|
|
2935
|
-
|
|
2936
|
-
(y(!0),
|
|
2931
|
+
C("ul", null, [
|
|
2932
|
+
(y(!0), $(Z, null, le(n.value, (l, a) => (y(), $("li", {
|
|
2937
2933
|
key: `${l.pos}-${a}`,
|
|
2938
2934
|
class: "mb-2"
|
|
2939
2935
|
}, [
|
|
2940
|
-
|
|
2941
|
-
|
|
2942
|
-
(y(!0),
|
|
2936
|
+
C("h5", yl, te(l.pos), 1),
|
|
2937
|
+
C("ul", wl, [
|
|
2938
|
+
(y(!0), $(Z, null, le(l.items, (u, p) => (y(), $("li", {
|
|
2943
2939
|
key: `${u.gloss}-${p}`,
|
|
2944
2940
|
class: "mb-1"
|
|
2945
2941
|
}, [
|
|
2946
|
-
|
|
2947
|
-
|
|
2948
|
-
u.example ? (y(),
|
|
2942
|
+
C("span", null, te(u.gloss), 1),
|
|
2943
|
+
El,
|
|
2944
|
+
u.example ? (y(), $("small", Sl, '"' + te(u.example) + '"', 1)) : X("", !0)
|
|
2949
2945
|
]))), 128))
|
|
2950
2946
|
])
|
|
2951
2947
|
]))), 128))
|
|
@@ -2954,72 +2950,72 @@ const X2 = {
|
|
|
2954
2950
|
])
|
|
2955
2951
|
]));
|
|
2956
2952
|
}
|
|
2957
|
-
},
|
|
2953
|
+
}, $l = { class: "card border bg-white rounded-lg" }, Il = { class: "card-body px-4 py-2 gap-0" }, Tl = { class: "flex justify-between items-center" }, Ll = /* @__PURE__ */ C("h2", { class: "card-title text-base font-bold leading-6 text-textCustom" }, "Examples", -1), Pl = { class: "text-textCustom list-decimal list-outside ml-7 mt-2" }, Vl = ["innerHTML"], kl = {
|
|
2958
2954
|
__name: "Example",
|
|
2959
2955
|
setup(e) {
|
|
2960
2956
|
const o = S(!0), t = he(), n = w(() => t.examples), s = () => {
|
|
2961
2957
|
o.value = !o.value;
|
|
2962
2958
|
};
|
|
2963
|
-
return (i, r) => (y(),
|
|
2964
|
-
|
|
2965
|
-
|
|
2966
|
-
|
|
2959
|
+
return (i, r) => (y(), $("div", $l, [
|
|
2960
|
+
C("div", Il, [
|
|
2961
|
+
C("div", Tl, [
|
|
2962
|
+
Ll,
|
|
2967
2963
|
B(Ue, {
|
|
2968
2964
|
isExpanded: o.value,
|
|
2969
2965
|
onClick: s
|
|
2970
2966
|
}, null, 8, ["isExpanded"])
|
|
2971
2967
|
]),
|
|
2972
|
-
|
|
2968
|
+
C("div", {
|
|
2973
2969
|
class: Ce(["overflow-hidden transition-all duration-300 ease-in-out", o.value ? "max-h-[1000px] opacity-100" : "max-h-0 opacity-0"])
|
|
2974
2970
|
}, [
|
|
2975
|
-
|
|
2976
|
-
(y(!0),
|
|
2971
|
+
C("ul", Pl, [
|
|
2972
|
+
(y(!0), $(Z, null, le(n.value, (l, a) => (y(), $("li", {
|
|
2977
2973
|
key: `${l.definition_id}-${a}`,
|
|
2978
2974
|
innerHTML: l
|
|
2979
|
-
}, null, 8,
|
|
2975
|
+
}, null, 8, Vl))), 128))
|
|
2980
2976
|
])
|
|
2981
2977
|
], 2)
|
|
2982
2978
|
])
|
|
2983
2979
|
]));
|
|
2984
2980
|
}
|
|
2985
|
-
},
|
|
2981
|
+
}, Ml = { class: "card border bg-white rounded-lg" }, Rl = { class: "card-body px-4 py-2 gap-0" }, Nl = { class: "flex justify-between items-center" }, Al = /* @__PURE__ */ C("h2", { class: "card-title text-base font-bold leading-6 text-textCustom" }, "Synonyms", -1), Dl = { class: "capitalize text-base font-normal text-textSecondary mb-1" }, Fl = { class: "list-none list-inside" }, jl = { class: "flex flex-wrap" }, Bl = ["onClick"], Hl = {
|
|
2986
2982
|
__name: "Synonyms",
|
|
2987
2983
|
emits: ["translate"],
|
|
2988
2984
|
setup(e, { emit: o }) {
|
|
2989
2985
|
const t = S(!0), n = he(), s = w(() => n.synonyms), i = o, r = () => {
|
|
2990
2986
|
t.value = !t.value;
|
|
2991
2987
|
}, l = (a) => {
|
|
2992
|
-
i("translate", a);
|
|
2988
|
+
i("translate", a), window.scrollTo(0, 0);
|
|
2993
2989
|
};
|
|
2994
|
-
return (a, u) => (y(),
|
|
2995
|
-
|
|
2996
|
-
|
|
2997
|
-
|
|
2990
|
+
return (a, u) => (y(), $("div", Ml, [
|
|
2991
|
+
C("div", Rl, [
|
|
2992
|
+
C("div", Nl, [
|
|
2993
|
+
Al,
|
|
2998
2994
|
B(Ue, {
|
|
2999
2995
|
isExpanded: t.value,
|
|
3000
2996
|
onClick: r
|
|
3001
2997
|
}, null, 8, ["isExpanded"])
|
|
3002
2998
|
]),
|
|
3003
|
-
|
|
2999
|
+
C("div", {
|
|
3004
3000
|
class: Ce(["overflow-hidden transition-all duration-300 ease-in-out", t.value ? "max-h-[2000px] opacity-100" : "max-h-0 opacity-0"])
|
|
3005
3001
|
}, [
|
|
3006
|
-
|
|
3007
|
-
(y(!0),
|
|
3002
|
+
C("ul", null, [
|
|
3003
|
+
(y(!0), $(Z, null, le(s.value, (p, f) => (y(), $("li", {
|
|
3008
3004
|
key: `${p.pos}-${f}`,
|
|
3009
3005
|
class: "mb-2"
|
|
3010
3006
|
}, [
|
|
3011
|
-
|
|
3012
|
-
|
|
3013
|
-
(y(!0),
|
|
3007
|
+
C("h5", Dl, te(p.pos), 1),
|
|
3008
|
+
C("ul", Fl, [
|
|
3009
|
+
(y(!0), $(Z, null, le(p.items, (v, h) => (y(), $("li", {
|
|
3014
3010
|
key: `${v.word}-${h}`,
|
|
3015
3011
|
class: "mb-2"
|
|
3016
3012
|
}, [
|
|
3017
|
-
|
|
3018
|
-
(y(!0),
|
|
3019
|
-
key: `${m}-${
|
|
3013
|
+
C("div", jl, [
|
|
3014
|
+
(y(!0), $(Z, null, le(v.synonym, (m, O) => (y(), $("span", {
|
|
3015
|
+
key: `${m}-${O}`,
|
|
3020
3016
|
class: "p-3 m-0.5 ml-0 font-normal badge badge-ghost bg-primaryColor text-white cursor-pointer border-0 rounded-lg",
|
|
3021
3017
|
onClick: (N) => l(m)
|
|
3022
|
-
}, te(m), 9,
|
|
3018
|
+
}, te(m), 9, Bl))), 128))
|
|
3023
3019
|
])
|
|
3024
3020
|
]))), 128))
|
|
3025
3021
|
])
|
|
@@ -3029,16 +3025,13 @@ const X2 = {
|
|
|
3029
3025
|
])
|
|
3030
3026
|
]));
|
|
3031
3027
|
}
|
|
3032
|
-
},
|
|
3028
|
+
}, 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__ */ C("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 = {
|
|
3033
3029
|
key: 0,
|
|
3034
3030
|
class: "w-full my-4"
|
|
3035
|
-
},
|
|
3031
|
+
}, Ql = {
|
|
3036
3032
|
key: 1,
|
|
3037
3033
|
class: "text-textCustom italic font-medium"
|
|
3038
|
-
},
|
|
3039
|
-
/* @__PURE__ */ g("span", { class: "block text-center text-gray-700" }, " The site is not affiliated with Google Translate "),
|
|
3040
|
-
/* @__PURE__ */ g("span", { class: "block text-center text-gray-700" }, "Since 2011")
|
|
3041
|
-
], -1), tl = {
|
|
3034
|
+
}, t2 = {
|
|
3042
3035
|
__name: "Popup",
|
|
3043
3036
|
props: {
|
|
3044
3037
|
opt: {
|
|
@@ -3060,8 +3053,8 @@ const X2 = {
|
|
|
3060
3053
|
},
|
|
3061
3054
|
emits: ["opt", "translate", "reader", "settings", "fullscreen"],
|
|
3062
3055
|
setup(e, { emit: o }) {
|
|
3063
|
-
const t =
|
|
3064
|
-
|
|
3056
|
+
const t = ds(), n = he(t), s = He(t), i = un(t), r = e, l = o, a = S("");
|
|
3057
|
+
z(
|
|
3065
3058
|
() => r.translation,
|
|
3066
3059
|
(v) => {
|
|
3067
3060
|
try {
|
|
@@ -3071,9 +3064,9 @@ const X2 = {
|
|
|
3071
3064
|
}
|
|
3072
3065
|
},
|
|
3073
3066
|
{ immediate: !0 }
|
|
3074
|
-
),
|
|
3067
|
+
), z([() => r.opt, () => r.languages], ([v, h]) => {
|
|
3075
3068
|
s.init(v, h), f(a.value);
|
|
3076
|
-
}),
|
|
3069
|
+
}), z([() => s.src, () => s.target], ([v, h]) => {
|
|
3077
3070
|
l("opt", { src: v, target: h }), f(a.value);
|
|
3078
3071
|
}), xe(() => {
|
|
3079
3072
|
s.init(r.opt, r.languages);
|
|
@@ -3091,50 +3084,49 @@ const X2 = {
|
|
|
3091
3084
|
text: v
|
|
3092
3085
|
}));
|
|
3093
3086
|
}
|
|
3094
|
-
return (v, h) => (y(),
|
|
3095
|
-
|
|
3096
|
-
B(
|
|
3087
|
+
return (v, h) => (y(), $("div", zl, [
|
|
3088
|
+
C("div", Ul, [
|
|
3089
|
+
B(Pn, {
|
|
3097
3090
|
onReader: h[0] || (h[0] = (m) => l("reader")),
|
|
3098
3091
|
onSettings: h[1] || (h[1] = (m) => l("settings")),
|
|
3099
3092
|
onFullScreen: h[2] || (h[2] = (m) => l("fullscreen"))
|
|
3100
3093
|
})
|
|
3101
3094
|
]),
|
|
3102
|
-
|
|
3103
|
-
B(
|
|
3104
|
-
|
|
3105
|
-
|
|
3106
|
-
B(
|
|
3095
|
+
C("div", Zl, [
|
|
3096
|
+
B(ms, { class: "my-4" }),
|
|
3097
|
+
C("div", Wl, [
|
|
3098
|
+
C("div", Gl, [
|
|
3099
|
+
B(nl, {
|
|
3107
3100
|
text: a.value,
|
|
3108
3101
|
onChange: p,
|
|
3109
3102
|
onClear: u
|
|
3110
3103
|
}, null, 8, ["text"])
|
|
3111
3104
|
]),
|
|
3112
|
-
|
|
3113
|
-
|
|
3114
|
-
B(
|
|
3105
|
+
ql,
|
|
3106
|
+
C("div", Jl, [
|
|
3107
|
+
B(rl, { isFavoriteFeatureEnabled: e.isFavoriteFeatureEnabled }, null, 8, ["isFavoriteFeatureEnabled"])
|
|
3115
3108
|
])
|
|
3116
3109
|
]),
|
|
3117
|
-
r.translation ? (y(),
|
|
3118
|
-
|
|
3119
|
-
|
|
3110
|
+
r.translation ? (y(), $(Z, { key: 0 }, [
|
|
3111
|
+
C("div", Kl, [
|
|
3112
|
+
k(n).dictionary.length ? (y(), ee(gl, {
|
|
3120
3113
|
key: 0,
|
|
3121
3114
|
onTranslate: f
|
|
3122
3115
|
})) : X("", !0),
|
|
3123
|
-
|
|
3124
|
-
|
|
3116
|
+
k(n).definitions.length ? (y(), ee(Ol, { key: 1 })) : X("", !0),
|
|
3117
|
+
k(n).synonyms.length ? (y(), ee(Hl, {
|
|
3125
3118
|
key: 2,
|
|
3126
3119
|
onTranslate: f
|
|
3127
3120
|
})) : X("", !0)
|
|
3128
3121
|
]),
|
|
3129
|
-
|
|
3130
|
-
B(
|
|
3122
|
+
k(n).examples.length ? (y(), $("div", Yl, [
|
|
3123
|
+
B(kl)
|
|
3131
3124
|
])) : X("", !0)
|
|
3132
|
-
], 64)) : (y(),
|
|
3133
|
-
])
|
|
3134
|
-
Qs
|
|
3125
|
+
], 64)) : (y(), $("span", Ql, "Service unavailable"))
|
|
3126
|
+
])
|
|
3135
3127
|
]));
|
|
3136
3128
|
}
|
|
3137
3129
|
};
|
|
3138
3130
|
export {
|
|
3139
|
-
|
|
3131
|
+
t2 as default
|
|
3140
3132
|
};
|