{"version":3,"file":"BaseCheckout.vue_vue_type_script_setup_true_lang.475d2dac.js","sources":["../../node_modules/@vue/shared/dist/shared.esm-bundler.js","../../node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js","../../node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js","../../node_modules/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js","../../node_modules/@vue/compiler-core/dist/compiler-core.esm-bundler.js","../../node_modules/@vue/compiler-dom/dist/compiler-dom.esm-bundler.js","../../node_modules/vue/dist/vue.esm-bundler.js","../../node_modules/pinia/node_modules/vue-demi/lib/index.mjs","../../node_modules/pinia/dist/pinia.mjs","../../node_modules/@kyvg/vue3-notification/dist/index.es.js","../../virtual:svg-icons-register","../../node_modules/@intlify/shared/dist/shared.mjs","../../node_modules/@intlify/message-compiler/dist/message-compiler.esm-browser.js","../../node_modules/@intlify/core-base/dist/core-base.mjs","../../node_modules/vue-i18n/dist/vue-i18n.mjs","../../src/i18n.ts","../../node_modules/what-input/dist/what-input.js","../../src/helper/currency.ts","../../src/helper-functions.ts","../../src/eventbus.ts","../../src/helper/tracking-events.ts","../../node_modules/vanilla-lazyload/dist/lazyload.esm.js","../../src/lazyload.ts","../../node_modules/uuid/dist/esm-browser/rng.js","../../node_modules/uuid/dist/esm-browser/regex.js","../../node_modules/uuid/dist/esm-browser/validate.js","../../node_modules/uuid/dist/esm-browser/stringify.js","../../node_modules/uuid/dist/esm-browser/v4.js","../../node_modules/@vueuse/shared/index.mjs","../../node_modules/@vueuse/core/index.mjs","../../src/components/BaseSelect.vue","../../src/helper/api.ts","../../src/stores/cart.ts","../../src/assets/img/fallback-logo.svg","../../node_modules/@vuelidate/core/dist/index.mjs","../../node_modules/@vuelidate/validators/dist/index.mjs","../../src/helper/validators.ts","../../src/components/checkout/BaseShipmentSelect.vue","../../src/components/checkout/BaseCoupon.vue","../../src/components/checkout/BaseCart.vue","../../src/components/checkout/BaseCheckout.vue"],"sourcesContent":["/**\r\n * Make a map and return a function for checking if a key\r\n * is in that map.\r\n * IMPORTANT: all calls of this function must be prefixed with\r\n * \\/\\*#\\_\\_PURE\\_\\_\\*\\/\r\n * So that rollup can tree-shake them if necessary.\r\n */\r\nfunction makeMap(str, expectsLowerCase) {\r\n    const map = Object.create(null);\r\n    const list = str.split(',');\r\n    for (let i = 0; i < list.length; i++) {\r\n        map[list[i]] = true;\r\n    }\r\n    return expectsLowerCase ? val => !!map[val.toLowerCase()] : val => !!map[val];\r\n}\n\n/**\r\n * dev only flag -> name mapping\r\n */\r\nconst PatchFlagNames = {\r\n    [1 /* TEXT */]: `TEXT`,\r\n    [2 /* CLASS */]: `CLASS`,\r\n    [4 /* STYLE */]: `STYLE`,\r\n    [8 /* PROPS */]: `PROPS`,\r\n    [16 /* FULL_PROPS */]: `FULL_PROPS`,\r\n    [32 /* HYDRATE_EVENTS */]: `HYDRATE_EVENTS`,\r\n    [64 /* STABLE_FRAGMENT */]: `STABLE_FRAGMENT`,\r\n    [128 /* KEYED_FRAGMENT */]: `KEYED_FRAGMENT`,\r\n    [256 /* UNKEYED_FRAGMENT */]: `UNKEYED_FRAGMENT`,\r\n    [512 /* NEED_PATCH */]: `NEED_PATCH`,\r\n    [1024 /* DYNAMIC_SLOTS */]: `DYNAMIC_SLOTS`,\r\n    [2048 /* DEV_ROOT_FRAGMENT */]: `DEV_ROOT_FRAGMENT`,\r\n    [-1 /* HOISTED */]: `HOISTED`,\r\n    [-2 /* BAIL */]: `BAIL`\r\n};\n\n/**\r\n * Dev only\r\n */\r\nconst slotFlagsText = {\r\n    [1 /* STABLE */]: 'STABLE',\r\n    [2 /* DYNAMIC */]: 'DYNAMIC',\r\n    [3 /* FORWARDED */]: 'FORWARDED'\r\n};\n\nconst GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,' +\r\n    'decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,' +\r\n    'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';\r\nconst isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);\n\nconst range = 2;\r\nfunction generateCodeFrame(source, start = 0, end = source.length) {\r\n    // Split the content into individual lines but capture the newline sequence\r\n    // that separated each line. This is important because the actual sequence is\r\n    // needed to properly take into account the full line length for offset\r\n    // comparison\r\n    let lines = source.split(/(\\r?\\n)/);\r\n    // Separate the lines and newline sequences into separate arrays for easier referencing\r\n    const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);\r\n    lines = lines.filter((_, idx) => idx % 2 === 0);\r\n    let count = 0;\r\n    const res = [];\r\n    for (let i = 0; i < lines.length; i++) {\r\n        count +=\r\n            lines[i].length +\r\n                ((newlineSequences[i] && newlineSequences[i].length) || 0);\r\n        if (count >= start) {\r\n            for (let j = i - range; j <= i + range || end > count; j++) {\r\n                if (j < 0 || j >= lines.length)\r\n                    continue;\r\n                const line = j + 1;\r\n                res.push(`${line}${' '.repeat(Math.max(3 - String(line).length, 0))}|  ${lines[j]}`);\r\n                const lineLength = lines[j].length;\r\n                const newLineSeqLength = (newlineSequences[j] && newlineSequences[j].length) || 0;\r\n                if (j === i) {\r\n                    // push underline\r\n                    const pad = start - (count - (lineLength + newLineSeqLength));\r\n                    const length = Math.max(1, end > count ? lineLength - pad : end - start);\r\n                    res.push(`   |  ` + ' '.repeat(pad) + '^'.repeat(length));\r\n                }\r\n                else if (j > i) {\r\n                    if (end > count) {\r\n                        const length = Math.max(Math.min(end - count, lineLength), 1);\r\n                        res.push(`   |  ` + '^'.repeat(length));\r\n                    }\r\n                    count += lineLength + newLineSeqLength;\r\n                }\r\n            }\r\n            break;\r\n        }\r\n    }\r\n    return res.join('\\n');\r\n}\n\n/**\r\n * On the client we only need to offer special cases for boolean attributes that\r\n * have different names from their corresponding dom properties:\r\n * - itemscope -> N/A\r\n * - allowfullscreen -> allowFullscreen\r\n * - formnovalidate -> formNoValidate\r\n * - ismap -> isMap\r\n * - nomodule -> noModule\r\n * - novalidate -> noValidate\r\n * - readonly -> readOnly\r\n */\r\nconst specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;\r\nconst isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);\r\n/**\r\n * The full list is needed during SSR to produce the correct initial markup.\r\n */\r\nconst isBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs +\r\n    `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,` +\r\n    `loop,open,required,reversed,scoped,seamless,` +\r\n    `checked,muted,multiple,selected`);\r\n/**\r\n * Boolean attributes should be included if the value is truthy or ''.\r\n * e.g. `<select multiple>` compiles to `{ multiple: '' }`\r\n */\r\nfunction includeBooleanAttr(value) {\r\n    return !!value || value === '';\r\n}\r\nconst unsafeAttrCharRE = /[>/=\"'\\u0009\\u000a\\u000c\\u0020]/;\r\nconst attrValidationCache = {};\r\nfunction isSSRSafeAttrName(name) {\r\n    if (attrValidationCache.hasOwnProperty(name)) {\r\n        return attrValidationCache[name];\r\n    }\r\n    const isUnsafe = unsafeAttrCharRE.test(name);\r\n    if (isUnsafe) {\r\n        console.error(`unsafe attribute name: ${name}`);\r\n    }\r\n    return (attrValidationCache[name] = !isUnsafe);\r\n}\r\nconst propsToAttrMap = {\r\n    acceptCharset: 'accept-charset',\r\n    className: 'class',\r\n    htmlFor: 'for',\r\n    httpEquiv: 'http-equiv'\r\n};\r\n/**\r\n * CSS properties that accept plain numbers\r\n */\r\nconst isNoUnitNumericStyleProp = /*#__PURE__*/ makeMap(`animation-iteration-count,border-image-outset,border-image-slice,` +\r\n    `border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,` +\r\n    `columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,` +\r\n    `grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,` +\r\n    `grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,` +\r\n    `line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,` +\r\n    // SVG\r\n    `fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,` +\r\n    `stroke-miterlimit,stroke-opacity,stroke-width`);\r\n/**\r\n * Known attributes, this is used for stringification of runtime static nodes\r\n * so that we don't stringify bindings that cannot be set from HTML.\r\n * Don't also forget to allow `data-*` and `aria-*`!\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes\r\n */\r\nconst isKnownHtmlAttr = /*#__PURE__*/ makeMap(`accept,accept-charset,accesskey,action,align,allow,alt,async,` +\r\n    `autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,` +\r\n    `border,buffered,capture,challenge,charset,checked,cite,class,code,` +\r\n    `codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,` +\r\n    `coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,` +\r\n    `disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,` +\r\n    `formaction,formenctype,formmethod,formnovalidate,formtarget,headers,` +\r\n    `height,hidden,high,href,hreflang,http-equiv,icon,id,importance,integrity,` +\r\n    `ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,` +\r\n    `manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,` +\r\n    `open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,` +\r\n    `referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,` +\r\n    `selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,` +\r\n    `start,step,style,summary,tabindex,target,title,translate,type,usemap,` +\r\n    `value,width,wrap`);\r\n/**\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\r\n */\r\nconst isKnownSvgAttr = /*#__PURE__*/ makeMap(`xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,` +\r\n    `arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,` +\r\n    `baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,` +\r\n    `clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,` +\r\n    `color-interpolation-filters,color-profile,color-rendering,` +\r\n    `contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,` +\r\n    `descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,` +\r\n    `dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,` +\r\n    `fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,` +\r\n    `font-family,font-size,font-size-adjust,font-stretch,font-style,` +\r\n    `font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,` +\r\n    `glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,` +\r\n    `gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,` +\r\n    `horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,` +\r\n    `k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,` +\r\n    `lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,` +\r\n    `marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,` +\r\n    `mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,` +\r\n    `name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,` +\r\n    `overflow,overline-position,overline-thickness,panose-1,paint-order,path,` +\r\n    `pathLength,patternContentUnits,patternTransform,patternUnits,ping,` +\r\n    `pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,` +\r\n    `preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,` +\r\n    `rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,` +\r\n    `restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,` +\r\n    `specularConstant,specularExponent,speed,spreadMethod,startOffset,` +\r\n    `stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,` +\r\n    `strikethrough-position,strikethrough-thickness,string,stroke,` +\r\n    `stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,` +\r\n    `stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,` +\r\n    `systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,` +\r\n    `text-decoration,text-rendering,textLength,to,transform,transform-origin,` +\r\n    `type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,` +\r\n    `unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,` +\r\n    `v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,` +\r\n    `vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,` +\r\n    `writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,` +\r\n    `xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,` +\r\n    `xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`);\n\nfunction normalizeStyle(value) {\r\n    if (isArray(value)) {\r\n        const res = {};\r\n        for (let i = 0; i < value.length; i++) {\r\n            const item = value[i];\r\n            const normalized = isString(item)\r\n                ? parseStringStyle(item)\r\n                : normalizeStyle(item);\r\n            if (normalized) {\r\n                for (const key in normalized) {\r\n                    res[key] = normalized[key];\r\n                }\r\n            }\r\n        }\r\n        return res;\r\n    }\r\n    else if (isString(value)) {\r\n        return value;\r\n    }\r\n    else if (isObject(value)) {\r\n        return value;\r\n    }\r\n}\r\nconst listDelimiterRE = /;(?![^(]*\\))/g;\r\nconst propertyDelimiterRE = /:(.+)/;\r\nfunction parseStringStyle(cssText) {\r\n    const ret = {};\r\n    cssText.split(listDelimiterRE).forEach(item => {\r\n        if (item) {\r\n            const tmp = item.split(propertyDelimiterRE);\r\n            tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());\r\n        }\r\n    });\r\n    return ret;\r\n}\r\nfunction stringifyStyle(styles) {\r\n    let ret = '';\r\n    if (!styles || isString(styles)) {\r\n        return ret;\r\n    }\r\n    for (const key in styles) {\r\n        const value = styles[key];\r\n        const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);\r\n        if (isString(value) ||\r\n            (typeof value === 'number' && isNoUnitNumericStyleProp(normalizedKey))) {\r\n            // only render valid values\r\n            ret += `${normalizedKey}:${value};`;\r\n        }\r\n    }\r\n    return ret;\r\n}\r\nfunction normalizeClass(value) {\r\n    let res = '';\r\n    if (isString(value)) {\r\n        res = value;\r\n    }\r\n    else if (isArray(value)) {\r\n        for (let i = 0; i < value.length; i++) {\r\n            const normalized = normalizeClass(value[i]);\r\n            if (normalized) {\r\n                res += normalized + ' ';\r\n            }\r\n        }\r\n    }\r\n    else if (isObject(value)) {\r\n        for (const name in value) {\r\n            if (value[name]) {\r\n                res += name + ' ';\r\n            }\r\n        }\r\n    }\r\n    return res.trim();\r\n}\r\nfunction normalizeProps(props) {\r\n    if (!props)\r\n        return null;\r\n    let { class: klass, style } = props;\r\n    if (klass && !isString(klass)) {\r\n        props.class = normalizeClass(klass);\r\n    }\r\n    if (style) {\r\n        props.style = normalizeStyle(style);\r\n    }\r\n    return props;\r\n}\n\n// These tag configs are shared between compiler-dom and runtime-dom, so they\r\n// https://developer.mozilla.org/en-US/docs/Web/HTML/Element\r\nconst HTML_TAGS = 'html,body,base,head,link,meta,style,title,address,article,aside,footer,' +\r\n    'header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,' +\r\n    'figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,' +\r\n    'data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,' +\r\n    'time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,' +\r\n    'canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,' +\r\n    'th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,' +\r\n    'option,output,progress,select,textarea,details,dialog,menu,' +\r\n    'summary,template,blockquote,iframe,tfoot';\r\n// https://developer.mozilla.org/en-US/docs/Web/SVG/Element\r\nconst SVG_TAGS = 'svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,' +\r\n    'defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,' +\r\n    'feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,' +\r\n    'feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,' +\r\n    'feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,' +\r\n    'fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,' +\r\n    'foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,' +\r\n    'mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,' +\r\n    'polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,' +\r\n    'text,textPath,title,tspan,unknown,use,view';\r\nconst VOID_TAGS = 'area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr';\r\n/**\r\n * Compiler only.\r\n * Do NOT use in runtime code paths unless behind `(process.env.NODE_ENV !== 'production')` flag.\r\n */\r\nconst isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);\r\n/**\r\n * Compiler only.\r\n * Do NOT use in runtime code paths unless behind `(process.env.NODE_ENV !== 'production')` flag.\r\n */\r\nconst isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);\r\n/**\r\n * Compiler only.\r\n * Do NOT use in runtime code paths unless behind `(process.env.NODE_ENV !== 'production')` flag.\r\n */\r\nconst isVoidTag = /*#__PURE__*/ makeMap(VOID_TAGS);\n\nconst escapeRE = /[\"'&<>]/;\r\nfunction escapeHtml(string) {\r\n    const str = '' + string;\r\n    const match = escapeRE.exec(str);\r\n    if (!match) {\r\n        return str;\r\n    }\r\n    let html = '';\r\n    let escaped;\r\n    let index;\r\n    let lastIndex = 0;\r\n    for (index = match.index; index < str.length; index++) {\r\n        switch (str.charCodeAt(index)) {\r\n            case 34: // \"\r\n                escaped = '&quot;';\r\n                break;\r\n            case 38: // &\r\n                escaped = '&amp;';\r\n                break;\r\n            case 39: // '\r\n                escaped = '&#39;';\r\n                break;\r\n            case 60: // <\r\n                escaped = '&lt;';\r\n                break;\r\n            case 62: // >\r\n                escaped = '&gt;';\r\n                break;\r\n            default:\r\n                continue;\r\n        }\r\n        if (lastIndex !== index) {\r\n            html += str.slice(lastIndex, index);\r\n        }\r\n        lastIndex = index + 1;\r\n        html += escaped;\r\n    }\r\n    return lastIndex !== index ? html + str.slice(lastIndex, index) : html;\r\n}\r\n// https://www.w3.org/TR/html52/syntax.html#comments\r\nconst commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;\r\nfunction escapeHtmlComment(src) {\r\n    return src.replace(commentStripRE, '');\r\n}\n\nfunction looseCompareArrays(a, b) {\r\n    if (a.length !== b.length)\r\n        return false;\r\n    let equal = true;\r\n    for (let i = 0; equal && i < a.length; i++) {\r\n        equal = looseEqual(a[i], b[i]);\r\n    }\r\n    return equal;\r\n}\r\nfunction looseEqual(a, b) {\r\n    if (a === b)\r\n        return true;\r\n    let aValidType = isDate(a);\r\n    let bValidType = isDate(b);\r\n    if (aValidType || bValidType) {\r\n        return aValidType && bValidType ? a.getTime() === b.getTime() : false;\r\n    }\r\n    aValidType = isSymbol(a);\r\n    bValidType = isSymbol(b);\r\n    if (aValidType || bValidType) {\r\n        return a === b;\r\n    }\r\n    aValidType = isArray(a);\r\n    bValidType = isArray(b);\r\n    if (aValidType || bValidType) {\r\n        return aValidType && bValidType ? looseCompareArrays(a, b) : false;\r\n    }\r\n    aValidType = isObject(a);\r\n    bValidType = isObject(b);\r\n    if (aValidType || bValidType) {\r\n        /* istanbul ignore if: this if will probably never be called */\r\n        if (!aValidType || !bValidType) {\r\n            return false;\r\n        }\r\n        const aKeysCount = Object.keys(a).length;\r\n        const bKeysCount = Object.keys(b).length;\r\n        if (aKeysCount !== bKeysCount) {\r\n            return false;\r\n        }\r\n        for (const key in a) {\r\n            const aHasKey = a.hasOwnProperty(key);\r\n            const bHasKey = b.hasOwnProperty(key);\r\n            if ((aHasKey && !bHasKey) ||\r\n                (!aHasKey && bHasKey) ||\r\n                !looseEqual(a[key], b[key])) {\r\n                return false;\r\n            }\r\n        }\r\n    }\r\n    return String(a) === String(b);\r\n}\r\nfunction looseIndexOf(arr, val) {\r\n    return arr.findIndex(item => looseEqual(item, val));\r\n}\n\n/**\r\n * For converting {{ interpolation }} values to displayed strings.\r\n * @private\r\n */\r\nconst toDisplayString = (val) => {\r\n    return isString(val)\r\n        ? val\r\n        : val == null\r\n            ? ''\r\n            : isArray(val) ||\r\n                (isObject(val) &&\r\n                    (val.toString === objectToString || !isFunction(val.toString)))\r\n                ? JSON.stringify(val, replacer, 2)\r\n                : String(val);\r\n};\r\nconst replacer = (_key, val) => {\r\n    // can't use isRef here since @vue/shared has no deps\r\n    if (val && val.__v_isRef) {\r\n        return replacer(_key, val.value);\r\n    }\r\n    else if (isMap(val)) {\r\n        return {\r\n            [`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val]) => {\r\n                entries[`${key} =>`] = val;\r\n                return entries;\r\n            }, {})\r\n        };\r\n    }\r\n    else if (isSet(val)) {\r\n        return {\r\n            [`Set(${val.size})`]: [...val.values()]\r\n        };\r\n    }\r\n    else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {\r\n        return String(val);\r\n    }\r\n    return val;\r\n};\n\nconst EMPTY_OBJ = (process.env.NODE_ENV !== 'production')\r\n    ? Object.freeze({})\r\n    : {};\r\nconst EMPTY_ARR = (process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst NOOP = () => { };\r\n/**\r\n * Always return false.\r\n */\r\nconst NO = () => false;\r\nconst onRE = /^on[^a-z]/;\r\nconst isOn = (key) => onRE.test(key);\r\nconst isModelListener = (key) => key.startsWith('onUpdate:');\r\nconst extend = Object.assign;\r\nconst remove = (arr, el) => {\r\n    const i = arr.indexOf(el);\r\n    if (i > -1) {\r\n        arr.splice(i, 1);\r\n    }\r\n};\r\nconst hasOwnProperty = Object.prototype.hasOwnProperty;\r\nconst hasOwn = (val, key) => hasOwnProperty.call(val, key);\r\nconst isArray = Array.isArray;\r\nconst isMap = (val) => toTypeString(val) === '[object Map]';\r\nconst isSet = (val) => toTypeString(val) === '[object Set]';\r\nconst isDate = (val) => toTypeString(val) === '[object Date]';\r\nconst isFunction = (val) => typeof val === 'function';\r\nconst isString = (val) => typeof val === 'string';\r\nconst isSymbol = (val) => typeof val === 'symbol';\r\nconst isObject = (val) => val !== null && typeof val === 'object';\r\nconst isPromise = (val) => {\r\n    return isObject(val) && isFunction(val.then) && isFunction(val.catch);\r\n};\r\nconst objectToString = Object.prototype.toString;\r\nconst toTypeString = (value) => objectToString.call(value);\r\nconst toRawType = (value) => {\r\n    // extract \"RawType\" from strings like \"[object RawType]\"\r\n    return toTypeString(value).slice(8, -1);\r\n};\r\nconst isPlainObject = (val) => toTypeString(val) === '[object Object]';\r\nconst isIntegerKey = (key) => isString(key) &&\r\n    key !== 'NaN' &&\r\n    key[0] !== '-' &&\r\n    '' + parseInt(key, 10) === key;\r\nconst isReservedProp = /*#__PURE__*/ makeMap(\r\n// the leading comma is intentional so empty string \"\" is also included\r\n',key,ref,ref_for,ref_key,' +\r\n    'onVnodeBeforeMount,onVnodeMounted,' +\r\n    'onVnodeBeforeUpdate,onVnodeUpdated,' +\r\n    'onVnodeBeforeUnmount,onVnodeUnmounted');\r\nconst isBuiltInDirective = /*#__PURE__*/ makeMap('bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo');\r\nconst cacheStringFunction = (fn) => {\r\n    const cache = Object.create(null);\r\n    return ((str) => {\r\n        const hit = cache[str];\r\n        return hit || (cache[str] = fn(str));\r\n    });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n    return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\r\nconst hyphenateRE = /\\B([A-Z])/g;\r\n/**\r\n * @private\r\n */\r\nconst hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase());\r\n/**\r\n * @private\r\n */\r\nconst capitalize = cacheStringFunction((str) => str.charAt(0).toUpperCase() + str.slice(1));\r\n/**\r\n * @private\r\n */\r\nconst toHandlerKey = cacheStringFunction((str) => str ? `on${capitalize(str)}` : ``);\r\n// compare whether a value has changed, accounting for NaN.\r\nconst hasChanged = (value, oldValue) => !Object.is(value, oldValue);\r\nconst invokeArrayFns = (fns, arg) => {\r\n    for (let i = 0; i < fns.length; i++) {\r\n        fns[i](arg);\r\n    }\r\n};\r\nconst def = (obj, key, value) => {\r\n    Object.defineProperty(obj, key, {\r\n        configurable: true,\r\n        enumerable: false,\r\n        value\r\n    });\r\n};\r\nconst toNumber = (val) => {\r\n    const n = parseFloat(val);\r\n    return isNaN(n) ? val : n;\r\n};\r\nlet _globalThis;\r\nconst getGlobalThis = () => {\r\n    return (_globalThis ||\r\n        (_globalThis =\r\n            typeof globalThis !== 'undefined'\r\n                ? globalThis\r\n                : typeof self !== 'undefined'\r\n                    ? self\r\n                    : typeof window !== 'undefined'\r\n                        ? window\r\n                        : typeof global !== 'undefined'\r\n                            ? global\r\n                            : {}));\r\n};\r\nconst identRE = /^[_$a-zA-Z\\xA0-\\uFFFF][_$a-zA-Z0-9\\xA0-\\uFFFF]*$/;\r\nfunction genPropsAccessExp(name) {\r\n    return identRE.test(name)\r\n        ? `__props.${name}`\r\n        : `__props[${JSON.stringify(name)}]`;\r\n}\n\nexport { EMPTY_ARR, EMPTY_OBJ, NO, NOOP, PatchFlagNames, camelize, capitalize, def, escapeHtml, escapeHtmlComment, extend, genPropsAccessExp, generateCodeFrame, getGlobalThis, hasChanged, hasOwn, hyphenate, includeBooleanAttr, invokeArrayFns, isArray, isBooleanAttr, isBuiltInDirective, isDate, isFunction, isGloballyWhitelisted, isHTMLTag, isIntegerKey, isKnownHtmlAttr, isKnownSvgAttr, isMap, isModelListener, isNoUnitNumericStyleProp, isObject, isOn, isPlainObject, isPromise, isReservedProp, isSSRSafeAttrName, isSVGTag, isSet, isSpecialBooleanAttr, isString, isSymbol, isVoidTag, looseEqual, looseIndexOf, makeMap, normalizeClass, normalizeProps, normalizeStyle, objectToString, parseStringStyle, propsToAttrMap, remove, slotFlagsText, stringifyStyle, toDisplayString, toHandlerKey, toNumber, toRawType, toTypeString };\n","import { extend, isArray, isMap, isIntegerKey, hasOwn, isSymbol, isObject, hasChanged, makeMap, capitalize, toRawType, def, isFunction, NOOP } from '@vue/shared';\n\nfunction warn(msg, ...args) {\r\n    console.warn(`[Vue warn] ${msg}`, ...args);\r\n}\n\nlet activeEffectScope;\r\nclass EffectScope {\r\n    constructor(detached = false) {\r\n        /**\r\n         * @internal\r\n         */\r\n        this.active = true;\r\n        /**\r\n         * @internal\r\n         */\r\n        this.effects = [];\r\n        /**\r\n         * @internal\r\n         */\r\n        this.cleanups = [];\r\n        if (!detached && activeEffectScope) {\r\n            this.parent = activeEffectScope;\r\n            this.index =\r\n                (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(this) - 1;\r\n        }\r\n    }\r\n    run(fn) {\r\n        if (this.active) {\r\n            const currentEffectScope = activeEffectScope;\r\n            try {\r\n                activeEffectScope = this;\r\n                return fn();\r\n            }\r\n            finally {\r\n                activeEffectScope = currentEffectScope;\r\n            }\r\n        }\r\n        else if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`cannot run an inactive effect scope.`);\r\n        }\r\n    }\r\n    /**\r\n     * This should only be called on non-detached scopes\r\n     * @internal\r\n     */\r\n    on() {\r\n        activeEffectScope = this;\r\n    }\r\n    /**\r\n     * This should only be called on non-detached scopes\r\n     * @internal\r\n     */\r\n    off() {\r\n        activeEffectScope = this.parent;\r\n    }\r\n    stop(fromParent) {\r\n        if (this.active) {\r\n            let i, l;\r\n            for (i = 0, l = this.effects.length; i < l; i++) {\r\n                this.effects[i].stop();\r\n            }\r\n            for (i = 0, l = this.cleanups.length; i < l; i++) {\r\n                this.cleanups[i]();\r\n            }\r\n            if (this.scopes) {\r\n                for (i = 0, l = this.scopes.length; i < l; i++) {\r\n                    this.scopes[i].stop(true);\r\n                }\r\n            }\r\n            // nested scope, dereference from parent to avoid memory leaks\r\n            if (this.parent && !fromParent) {\r\n                // optimized O(1) removal\r\n                const last = this.parent.scopes.pop();\r\n                if (last && last !== this) {\r\n                    this.parent.scopes[this.index] = last;\r\n                    last.index = this.index;\r\n                }\r\n            }\r\n            this.active = false;\r\n        }\r\n    }\r\n}\r\nfunction effectScope(detached) {\r\n    return new EffectScope(detached);\r\n}\r\nfunction recordEffectScope(effect, scope = activeEffectScope) {\r\n    if (scope && scope.active) {\r\n        scope.effects.push(effect);\r\n    }\r\n}\r\nfunction getCurrentScope() {\r\n    return activeEffectScope;\r\n}\r\nfunction onScopeDispose(fn) {\r\n    if (activeEffectScope) {\r\n        activeEffectScope.cleanups.push(fn);\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        warn(`onScopeDispose() is called when there is no active effect scope` +\r\n            ` to be associated with.`);\r\n    }\r\n}\n\nconst createDep = (effects) => {\r\n    const dep = new Set(effects);\r\n    dep.w = 0;\r\n    dep.n = 0;\r\n    return dep;\r\n};\r\nconst wasTracked = (dep) => (dep.w & trackOpBit) > 0;\r\nconst newTracked = (dep) => (dep.n & trackOpBit) > 0;\r\nconst initDepMarkers = ({ deps }) => {\r\n    if (deps.length) {\r\n        for (let i = 0; i < deps.length; i++) {\r\n            deps[i].w |= trackOpBit; // set was tracked\r\n        }\r\n    }\r\n};\r\nconst finalizeDepMarkers = (effect) => {\r\n    const { deps } = effect;\r\n    if (deps.length) {\r\n        let ptr = 0;\r\n        for (let i = 0; i < deps.length; i++) {\r\n            const dep = deps[i];\r\n            if (wasTracked(dep) && !newTracked(dep)) {\r\n                dep.delete(effect);\r\n            }\r\n            else {\r\n                deps[ptr++] = dep;\r\n            }\r\n            // clear bits\r\n            dep.w &= ~trackOpBit;\r\n            dep.n &= ~trackOpBit;\r\n        }\r\n        deps.length = ptr;\r\n    }\r\n};\n\nconst targetMap = new WeakMap();\r\n// The number of effects currently being tracked recursively.\r\nlet effectTrackDepth = 0;\r\nlet trackOpBit = 1;\r\n/**\r\n * The bitwise track markers support at most 30 levels of recursion.\r\n * This value is chosen to enable modern JS engines to use a SMI on all platforms.\r\n * When recursion depth is greater, fall back to using a full cleanup.\r\n */\r\nconst maxMarkerBits = 30;\r\nlet activeEffect;\r\nconst ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'iterate' : '');\r\nconst MAP_KEY_ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'Map key iterate' : '');\r\nclass ReactiveEffect {\r\n    constructor(fn, scheduler = null, scope) {\r\n        this.fn = fn;\r\n        this.scheduler = scheduler;\r\n        this.active = true;\r\n        this.deps = [];\r\n        this.parent = undefined;\r\n        recordEffectScope(this, scope);\r\n    }\r\n    run() {\r\n        if (!this.active) {\r\n            return this.fn();\r\n        }\r\n        let parent = activeEffect;\r\n        let lastShouldTrack = shouldTrack;\r\n        while (parent) {\r\n            if (parent === this) {\r\n                return;\r\n            }\r\n            parent = parent.parent;\r\n        }\r\n        try {\r\n            this.parent = activeEffect;\r\n            activeEffect = this;\r\n            shouldTrack = true;\r\n            trackOpBit = 1 << ++effectTrackDepth;\r\n            if (effectTrackDepth <= maxMarkerBits) {\r\n                initDepMarkers(this);\r\n            }\r\n            else {\r\n                cleanupEffect(this);\r\n            }\r\n            return this.fn();\r\n        }\r\n        finally {\r\n            if (effectTrackDepth <= maxMarkerBits) {\r\n                finalizeDepMarkers(this);\r\n            }\r\n            trackOpBit = 1 << --effectTrackDepth;\r\n            activeEffect = this.parent;\r\n            shouldTrack = lastShouldTrack;\r\n            this.parent = undefined;\r\n            if (this.deferStop) {\r\n                this.stop();\r\n            }\r\n        }\r\n    }\r\n    stop() {\r\n        // stopped while running itself - defer the cleanup\r\n        if (activeEffect === this) {\r\n            this.deferStop = true;\r\n        }\r\n        else if (this.active) {\r\n            cleanupEffect(this);\r\n            if (this.onStop) {\r\n                this.onStop();\r\n            }\r\n            this.active = false;\r\n        }\r\n    }\r\n}\r\nfunction cleanupEffect(effect) {\r\n    const { deps } = effect;\r\n    if (deps.length) {\r\n        for (let i = 0; i < deps.length; i++) {\r\n            deps[i].delete(effect);\r\n        }\r\n        deps.length = 0;\r\n    }\r\n}\r\nfunction effect(fn, options) {\r\n    if (fn.effect) {\r\n        fn = fn.effect.fn;\r\n    }\r\n    const _effect = new ReactiveEffect(fn);\r\n    if (options) {\r\n        extend(_effect, options);\r\n        if (options.scope)\r\n            recordEffectScope(_effect, options.scope);\r\n    }\r\n    if (!options || !options.lazy) {\r\n        _effect.run();\r\n    }\r\n    const runner = _effect.run.bind(_effect);\r\n    runner.effect = _effect;\r\n    return runner;\r\n}\r\nfunction stop(runner) {\r\n    runner.effect.stop();\r\n}\r\nlet shouldTrack = true;\r\nconst trackStack = [];\r\nfunction pauseTracking() {\r\n    trackStack.push(shouldTrack);\r\n    shouldTrack = false;\r\n}\r\nfunction enableTracking() {\r\n    trackStack.push(shouldTrack);\r\n    shouldTrack = true;\r\n}\r\nfunction resetTracking() {\r\n    const last = trackStack.pop();\r\n    shouldTrack = last === undefined ? true : last;\r\n}\r\nfunction track(target, type, key) {\r\n    if (shouldTrack && activeEffect) {\r\n        let depsMap = targetMap.get(target);\r\n        if (!depsMap) {\r\n            targetMap.set(target, (depsMap = new Map()));\r\n        }\r\n        let dep = depsMap.get(key);\r\n        if (!dep) {\r\n            depsMap.set(key, (dep = createDep()));\r\n        }\r\n        const eventInfo = (process.env.NODE_ENV !== 'production')\r\n            ? { effect: activeEffect, target, type, key }\r\n            : undefined;\r\n        trackEffects(dep, eventInfo);\r\n    }\r\n}\r\nfunction trackEffects(dep, debuggerEventExtraInfo) {\r\n    let shouldTrack = false;\r\n    if (effectTrackDepth <= maxMarkerBits) {\r\n        if (!newTracked(dep)) {\r\n            dep.n |= trackOpBit; // set newly tracked\r\n            shouldTrack = !wasTracked(dep);\r\n        }\r\n    }\r\n    else {\r\n        // Full cleanup mode.\r\n        shouldTrack = !dep.has(activeEffect);\r\n    }\r\n    if (shouldTrack) {\r\n        dep.add(activeEffect);\r\n        activeEffect.deps.push(dep);\r\n        if ((process.env.NODE_ENV !== 'production') && activeEffect.onTrack) {\r\n            activeEffect.onTrack(Object.assign({ effect: activeEffect }, debuggerEventExtraInfo));\r\n        }\r\n    }\r\n}\r\nfunction trigger(target, type, key, newValue, oldValue, oldTarget) {\r\n    const depsMap = targetMap.get(target);\r\n    if (!depsMap) {\r\n        // never been tracked\r\n        return;\r\n    }\r\n    let deps = [];\r\n    if (type === \"clear\" /* CLEAR */) {\r\n        // collection being cleared\r\n        // trigger all effects for target\r\n        deps = [...depsMap.values()];\r\n    }\r\n    else if (key === 'length' && isArray(target)) {\r\n        depsMap.forEach((dep, key) => {\r\n            if (key === 'length' || key >= newValue) {\r\n                deps.push(dep);\r\n            }\r\n        });\r\n    }\r\n    else {\r\n        // schedule runs for SET | ADD | DELETE\r\n        if (key !== void 0) {\r\n            deps.push(depsMap.get(key));\r\n        }\r\n        // also run for iteration key on ADD | DELETE | Map.SET\r\n        switch (type) {\r\n            case \"add\" /* ADD */:\r\n                if (!isArray(target)) {\r\n                    deps.push(depsMap.get(ITERATE_KEY));\r\n                    if (isMap(target)) {\r\n                        deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n                    }\r\n                }\r\n                else if (isIntegerKey(key)) {\r\n                    // new index added to array -> length changes\r\n                    deps.push(depsMap.get('length'));\r\n                }\r\n                break;\r\n            case \"delete\" /* DELETE */:\r\n                if (!isArray(target)) {\r\n                    deps.push(depsMap.get(ITERATE_KEY));\r\n                    if (isMap(target)) {\r\n                        deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n                    }\r\n                }\r\n                break;\r\n            case \"set\" /* SET */:\r\n                if (isMap(target)) {\r\n                    deps.push(depsMap.get(ITERATE_KEY));\r\n                }\r\n                break;\r\n        }\r\n    }\r\n    const eventInfo = (process.env.NODE_ENV !== 'production')\r\n        ? { target, type, key, newValue, oldValue, oldTarget }\r\n        : undefined;\r\n    if (deps.length === 1) {\r\n        if (deps[0]) {\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                triggerEffects(deps[0], eventInfo);\r\n            }\r\n            else {\r\n                triggerEffects(deps[0]);\r\n            }\r\n        }\r\n    }\r\n    else {\r\n        const effects = [];\r\n        for (const dep of deps) {\r\n            if (dep) {\r\n                effects.push(...dep);\r\n            }\r\n        }\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            triggerEffects(createDep(effects), eventInfo);\r\n        }\r\n        else {\r\n            triggerEffects(createDep(effects));\r\n        }\r\n    }\r\n}\r\nfunction triggerEffects(dep, debuggerEventExtraInfo) {\r\n    // spread into array for stabilization\r\n    const effects = isArray(dep) ? dep : [...dep];\r\n    for (const effect of effects) {\r\n        if (effect.computed) {\r\n            triggerEffect(effect, debuggerEventExtraInfo);\r\n        }\r\n    }\r\n    for (const effect of effects) {\r\n        if (!effect.computed) {\r\n            triggerEffect(effect, debuggerEventExtraInfo);\r\n        }\r\n    }\r\n}\r\nfunction triggerEffect(effect, debuggerEventExtraInfo) {\r\n    if (effect !== activeEffect || effect.allowRecurse) {\r\n        if ((process.env.NODE_ENV !== 'production') && effect.onTrigger) {\r\n            effect.onTrigger(extend({ effect }, debuggerEventExtraInfo));\r\n        }\r\n        if (effect.scheduler) {\r\n            effect.scheduler();\r\n        }\r\n        else {\r\n            effect.run();\r\n        }\r\n    }\r\n}\n\nconst isNonTrackableKeys = /*#__PURE__*/ makeMap(`__proto__,__v_isRef,__isVue`);\r\nconst builtInSymbols = new Set(\r\n/*#__PURE__*/\r\nObject.getOwnPropertyNames(Symbol)\r\n    // ios10.x Object.getOwnPropertyNames(Symbol) can enumerate 'arguments' and 'caller'\r\n    // but accessing them on Symbol leads to TypeError because Symbol is a strict mode\r\n    // function\r\n    .filter(key => key !== 'arguments' && key !== 'caller')\r\n    .map(key => Symbol[key])\r\n    .filter(isSymbol));\r\nconst get = /*#__PURE__*/ createGetter();\r\nconst shallowGet = /*#__PURE__*/ createGetter(false, true);\r\nconst readonlyGet = /*#__PURE__*/ createGetter(true);\r\nconst shallowReadonlyGet = /*#__PURE__*/ createGetter(true, true);\r\nconst arrayInstrumentations = /*#__PURE__*/ createArrayInstrumentations();\r\nfunction createArrayInstrumentations() {\r\n    const instrumentations = {};\r\n    ['includes', 'indexOf', 'lastIndexOf'].forEach(key => {\r\n        instrumentations[key] = function (...args) {\r\n            const arr = toRaw(this);\r\n            for (let i = 0, l = this.length; i < l; i++) {\r\n                track(arr, \"get\" /* GET */, i + '');\r\n            }\r\n            // we run the method using the original args first (which may be reactive)\r\n            const res = arr[key](...args);\r\n            if (res === -1 || res === false) {\r\n                // if that didn't work, run it again using raw values.\r\n                return arr[key](...args.map(toRaw));\r\n            }\r\n            else {\r\n                return res;\r\n            }\r\n        };\r\n    });\r\n    ['push', 'pop', 'shift', 'unshift', 'splice'].forEach(key => {\r\n        instrumentations[key] = function (...args) {\r\n            pauseTracking();\r\n            const res = toRaw(this)[key].apply(this, args);\r\n            resetTracking();\r\n            return res;\r\n        };\r\n    });\r\n    return instrumentations;\r\n}\r\nfunction createGetter(isReadonly = false, shallow = false) {\r\n    return function get(target, key, receiver) {\r\n        if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n            return !isReadonly;\r\n        }\r\n        else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n            return isReadonly;\r\n        }\r\n        else if (key === \"__v_isShallow\" /* IS_SHALLOW */) {\r\n            return shallow;\r\n        }\r\n        else if (key === \"__v_raw\" /* RAW */ &&\r\n            receiver ===\r\n                (isReadonly\r\n                    ? shallow\r\n                        ? shallowReadonlyMap\r\n                        : readonlyMap\r\n                    : shallow\r\n                        ? shallowReactiveMap\r\n                        : reactiveMap).get(target)) {\r\n            return target;\r\n        }\r\n        const targetIsArray = isArray(target);\r\n        if (!isReadonly && targetIsArray && hasOwn(arrayInstrumentations, key)) {\r\n            return Reflect.get(arrayInstrumentations, key, receiver);\r\n        }\r\n        const res = Reflect.get(target, key, receiver);\r\n        if (isSymbol(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {\r\n            return res;\r\n        }\r\n        if (!isReadonly) {\r\n            track(target, \"get\" /* GET */, key);\r\n        }\r\n        if (shallow) {\r\n            return res;\r\n        }\r\n        if (isRef(res)) {\r\n            // ref unwrapping - skip unwrap for Array + integer key.\r\n            return targetIsArray && isIntegerKey(key) ? res : res.value;\r\n        }\r\n        if (isObject(res)) {\r\n            // Convert returned value into a proxy as well. we do the isObject check\r\n            // here to avoid invalid value warning. Also need to lazy access readonly\r\n            // and reactive here to avoid circular dependency.\r\n            return isReadonly ? readonly(res) : reactive(res);\r\n        }\r\n        return res;\r\n    };\r\n}\r\nconst set = /*#__PURE__*/ createSetter();\r\nconst shallowSet = /*#__PURE__*/ createSetter(true);\r\nfunction createSetter(shallow = false) {\r\n    return function set(target, key, value, receiver) {\r\n        let oldValue = target[key];\r\n        if (isReadonly(oldValue) && isRef(oldValue) && !isRef(value)) {\r\n            return false;\r\n        }\r\n        if (!shallow && !isReadonly(value)) {\r\n            if (!isShallow(value)) {\r\n                value = toRaw(value);\r\n                oldValue = toRaw(oldValue);\r\n            }\r\n            if (!isArray(target) && isRef(oldValue) && !isRef(value)) {\r\n                oldValue.value = value;\r\n                return true;\r\n            }\r\n        }\r\n        const hadKey = isArray(target) && isIntegerKey(key)\r\n            ? Number(key) < target.length\r\n            : hasOwn(target, key);\r\n        const result = Reflect.set(target, key, value, receiver);\r\n        // don't trigger if target is something up in the prototype chain of original\r\n        if (target === toRaw(receiver)) {\r\n            if (!hadKey) {\r\n                trigger(target, \"add\" /* ADD */, key, value);\r\n            }\r\n            else if (hasChanged(value, oldValue)) {\r\n                trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n            }\r\n        }\r\n        return result;\r\n    };\r\n}\r\nfunction deleteProperty(target, key) {\r\n    const hadKey = hasOwn(target, key);\r\n    const oldValue = target[key];\r\n    const result = Reflect.deleteProperty(target, key);\r\n    if (result && hadKey) {\r\n        trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n    }\r\n    return result;\r\n}\r\nfunction has(target, key) {\r\n    const result = Reflect.has(target, key);\r\n    if (!isSymbol(key) || !builtInSymbols.has(key)) {\r\n        track(target, \"has\" /* HAS */, key);\r\n    }\r\n    return result;\r\n}\r\nfunction ownKeys(target) {\r\n    track(target, \"iterate\" /* ITERATE */, isArray(target) ? 'length' : ITERATE_KEY);\r\n    return Reflect.ownKeys(target);\r\n}\r\nconst mutableHandlers = {\r\n    get,\r\n    set,\r\n    deleteProperty,\r\n    has,\r\n    ownKeys\r\n};\r\nconst readonlyHandlers = {\r\n    get: readonlyGet,\r\n    set(target, key) {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`Set operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n        }\r\n        return true;\r\n    },\r\n    deleteProperty(target, key) {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`Delete operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n        }\r\n        return true;\r\n    }\r\n};\r\nconst shallowReactiveHandlers = /*#__PURE__*/ extend({}, mutableHandlers, {\r\n    get: shallowGet,\r\n    set: shallowSet\r\n});\r\n// Props handlers are special in the sense that it should not unwrap top-level\r\n// refs (in order to allow refs to be explicitly passed down), but should\r\n// retain the reactivity of the normal readonly object.\r\nconst shallowReadonlyHandlers = /*#__PURE__*/ extend({}, readonlyHandlers, {\r\n    get: shallowReadonlyGet\r\n});\n\nconst toShallow = (value) => value;\r\nconst getProto = (v) => Reflect.getPrototypeOf(v);\r\nfunction get$1(target, key, isReadonly = false, isShallow = false) {\r\n    // #1772: readonly(reactive(Map)) should return readonly + reactive version\r\n    // of the value\r\n    target = target[\"__v_raw\" /* RAW */];\r\n    const rawTarget = toRaw(target);\r\n    const rawKey = toRaw(key);\r\n    if (!isReadonly) {\r\n        if (key !== rawKey) {\r\n            track(rawTarget, \"get\" /* GET */, key);\r\n        }\r\n        track(rawTarget, \"get\" /* GET */, rawKey);\r\n    }\r\n    const { has } = getProto(rawTarget);\r\n    const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n    if (has.call(rawTarget, key)) {\r\n        return wrap(target.get(key));\r\n    }\r\n    else if (has.call(rawTarget, rawKey)) {\r\n        return wrap(target.get(rawKey));\r\n    }\r\n    else if (target !== rawTarget) {\r\n        // #3602 readonly(reactive(Map))\r\n        // ensure that the nested reactive `Map` can do tracking for itself\r\n        target.get(key);\r\n    }\r\n}\r\nfunction has$1(key, isReadonly = false) {\r\n    const target = this[\"__v_raw\" /* RAW */];\r\n    const rawTarget = toRaw(target);\r\n    const rawKey = toRaw(key);\r\n    if (!isReadonly) {\r\n        if (key !== rawKey) {\r\n            track(rawTarget, \"has\" /* HAS */, key);\r\n        }\r\n        track(rawTarget, \"has\" /* HAS */, rawKey);\r\n    }\r\n    return key === rawKey\r\n        ? target.has(key)\r\n        : target.has(key) || target.has(rawKey);\r\n}\r\nfunction size(target, isReadonly = false) {\r\n    target = target[\"__v_raw\" /* RAW */];\r\n    !isReadonly && track(toRaw(target), \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n    return Reflect.get(target, 'size', target);\r\n}\r\nfunction add(value) {\r\n    value = toRaw(value);\r\n    const target = toRaw(this);\r\n    const proto = getProto(target);\r\n    const hadKey = proto.has.call(target, value);\r\n    if (!hadKey) {\r\n        target.add(value);\r\n        trigger(target, \"add\" /* ADD */, value, value);\r\n    }\r\n    return this;\r\n}\r\nfunction set$1(key, value) {\r\n    value = toRaw(value);\r\n    const target = toRaw(this);\r\n    const { has, get } = getProto(target);\r\n    let hadKey = has.call(target, key);\r\n    if (!hadKey) {\r\n        key = toRaw(key);\r\n        hadKey = has.call(target, key);\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        checkIdentityKeys(target, has, key);\r\n    }\r\n    const oldValue = get.call(target, key);\r\n    target.set(key, value);\r\n    if (!hadKey) {\r\n        trigger(target, \"add\" /* ADD */, key, value);\r\n    }\r\n    else if (hasChanged(value, oldValue)) {\r\n        trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n    }\r\n    return this;\r\n}\r\nfunction deleteEntry(key) {\r\n    const target = toRaw(this);\r\n    const { has, get } = getProto(target);\r\n    let hadKey = has.call(target, key);\r\n    if (!hadKey) {\r\n        key = toRaw(key);\r\n        hadKey = has.call(target, key);\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        checkIdentityKeys(target, has, key);\r\n    }\r\n    const oldValue = get ? get.call(target, key) : undefined;\r\n    // forward the operation before queueing reactions\r\n    const result = target.delete(key);\r\n    if (hadKey) {\r\n        trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n    }\r\n    return result;\r\n}\r\nfunction clear() {\r\n    const target = toRaw(this);\r\n    const hadItems = target.size !== 0;\r\n    const oldTarget = (process.env.NODE_ENV !== 'production')\r\n        ? isMap(target)\r\n            ? new Map(target)\r\n            : new Set(target)\r\n        : undefined;\r\n    // forward the operation before queueing reactions\r\n    const result = target.clear();\r\n    if (hadItems) {\r\n        trigger(target, \"clear\" /* CLEAR */, undefined, undefined, oldTarget);\r\n    }\r\n    return result;\r\n}\r\nfunction createForEach(isReadonly, isShallow) {\r\n    return function forEach(callback, thisArg) {\r\n        const observed = this;\r\n        const target = observed[\"__v_raw\" /* RAW */];\r\n        const rawTarget = toRaw(target);\r\n        const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n        !isReadonly && track(rawTarget, \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n        return target.forEach((value, key) => {\r\n            // important: make sure the callback is\r\n            // 1. invoked with the reactive map as `this` and 3rd arg\r\n            // 2. the value received should be a corresponding reactive/readonly.\r\n            return callback.call(thisArg, wrap(value), wrap(key), observed);\r\n        });\r\n    };\r\n}\r\nfunction createIterableMethod(method, isReadonly, isShallow) {\r\n    return function (...args) {\r\n        const target = this[\"__v_raw\" /* RAW */];\r\n        const rawTarget = toRaw(target);\r\n        const targetIsMap = isMap(rawTarget);\r\n        const isPair = method === 'entries' || (method === Symbol.iterator && targetIsMap);\r\n        const isKeyOnly = method === 'keys' && targetIsMap;\r\n        const innerIterator = target[method](...args);\r\n        const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n        !isReadonly &&\r\n            track(rawTarget, \"iterate\" /* ITERATE */, isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY);\r\n        // return a wrapped iterator which returns observed versions of the\r\n        // values emitted from the real iterator\r\n        return {\r\n            // iterator protocol\r\n            next() {\r\n                const { value, done } = innerIterator.next();\r\n                return done\r\n                    ? { value, done }\r\n                    : {\r\n                        value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),\r\n                        done\r\n                    };\r\n            },\r\n            // iterable protocol\r\n            [Symbol.iterator]() {\r\n                return this;\r\n            }\r\n        };\r\n    };\r\n}\r\nfunction createReadonlyMethod(type) {\r\n    return function (...args) {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            const key = args[0] ? `on key \"${args[0]}\" ` : ``;\r\n            console.warn(`${capitalize(type)} operation ${key}failed: target is readonly.`, toRaw(this));\r\n        }\r\n        return type === \"delete\" /* DELETE */ ? false : this;\r\n    };\r\n}\r\nfunction createInstrumentations() {\r\n    const mutableInstrumentations = {\r\n        get(key) {\r\n            return get$1(this, key);\r\n        },\r\n        get size() {\r\n            return size(this);\r\n        },\r\n        has: has$1,\r\n        add,\r\n        set: set$1,\r\n        delete: deleteEntry,\r\n        clear,\r\n        forEach: createForEach(false, false)\r\n    };\r\n    const shallowInstrumentations = {\r\n        get(key) {\r\n            return get$1(this, key, false, true);\r\n        },\r\n        get size() {\r\n            return size(this);\r\n        },\r\n        has: has$1,\r\n        add,\r\n        set: set$1,\r\n        delete: deleteEntry,\r\n        clear,\r\n        forEach: createForEach(false, true)\r\n    };\r\n    const readonlyInstrumentations = {\r\n        get(key) {\r\n            return get$1(this, key, true);\r\n        },\r\n        get size() {\r\n            return size(this, true);\r\n        },\r\n        has(key) {\r\n            return has$1.call(this, key, true);\r\n        },\r\n        add: createReadonlyMethod(\"add\" /* ADD */),\r\n        set: createReadonlyMethod(\"set\" /* SET */),\r\n        delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n        clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n        forEach: createForEach(true, false)\r\n    };\r\n    const shallowReadonlyInstrumentations = {\r\n        get(key) {\r\n            return get$1(this, key, true, true);\r\n        },\r\n        get size() {\r\n            return size(this, true);\r\n        },\r\n        has(key) {\r\n            return has$1.call(this, key, true);\r\n        },\r\n        add: createReadonlyMethod(\"add\" /* ADD */),\r\n        set: createReadonlyMethod(\"set\" /* SET */),\r\n        delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n        clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n        forEach: createForEach(true, true)\r\n    };\r\n    const iteratorMethods = ['keys', 'values', 'entries', Symbol.iterator];\r\n    iteratorMethods.forEach(method => {\r\n        mutableInstrumentations[method] = createIterableMethod(method, false, false);\r\n        readonlyInstrumentations[method] = createIterableMethod(method, true, false);\r\n        shallowInstrumentations[method] = createIterableMethod(method, false, true);\r\n        shallowReadonlyInstrumentations[method] = createIterableMethod(method, true, true);\r\n    });\r\n    return [\r\n        mutableInstrumentations,\r\n        readonlyInstrumentations,\r\n        shallowInstrumentations,\r\n        shallowReadonlyInstrumentations\r\n    ];\r\n}\r\nconst [mutableInstrumentations, readonlyInstrumentations, shallowInstrumentations, shallowReadonlyInstrumentations] = /* #__PURE__*/ createInstrumentations();\r\nfunction createInstrumentationGetter(isReadonly, shallow) {\r\n    const instrumentations = shallow\r\n        ? isReadonly\r\n            ? shallowReadonlyInstrumentations\r\n            : shallowInstrumentations\r\n        : isReadonly\r\n            ? readonlyInstrumentations\r\n            : mutableInstrumentations;\r\n    return (target, key, receiver) => {\r\n        if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n            return !isReadonly;\r\n        }\r\n        else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n            return isReadonly;\r\n        }\r\n        else if (key === \"__v_raw\" /* RAW */) {\r\n            return target;\r\n        }\r\n        return Reflect.get(hasOwn(instrumentations, key) && key in target\r\n            ? instrumentations\r\n            : target, key, receiver);\r\n    };\r\n}\r\nconst mutableCollectionHandlers = {\r\n    get: /*#__PURE__*/ createInstrumentationGetter(false, false)\r\n};\r\nconst shallowCollectionHandlers = {\r\n    get: /*#__PURE__*/ createInstrumentationGetter(false, true)\r\n};\r\nconst readonlyCollectionHandlers = {\r\n    get: /*#__PURE__*/ createInstrumentationGetter(true, false)\r\n};\r\nconst shallowReadonlyCollectionHandlers = {\r\n    get: /*#__PURE__*/ createInstrumentationGetter(true, true)\r\n};\r\nfunction checkIdentityKeys(target, has, key) {\r\n    const rawKey = toRaw(key);\r\n    if (rawKey !== key && has.call(target, rawKey)) {\r\n        const type = toRawType(target);\r\n        console.warn(`Reactive ${type} contains both the raw and reactive ` +\r\n            `versions of the same object${type === `Map` ? ` as keys` : ``}, ` +\r\n            `which can lead to inconsistencies. ` +\r\n            `Avoid differentiating between the raw and reactive versions ` +\r\n            `of an object and only use the reactive version if possible.`);\r\n    }\r\n}\n\nconst reactiveMap = new WeakMap();\r\nconst shallowReactiveMap = new WeakMap();\r\nconst readonlyMap = new WeakMap();\r\nconst shallowReadonlyMap = new WeakMap();\r\nfunction targetTypeMap(rawType) {\r\n    switch (rawType) {\r\n        case 'Object':\r\n        case 'Array':\r\n            return 1 /* COMMON */;\r\n        case 'Map':\r\n        case 'Set':\r\n        case 'WeakMap':\r\n        case 'WeakSet':\r\n            return 2 /* COLLECTION */;\r\n        default:\r\n            return 0 /* INVALID */;\r\n    }\r\n}\r\nfunction getTargetType(value) {\r\n    return value[\"__v_skip\" /* SKIP */] || !Object.isExtensible(value)\r\n        ? 0 /* INVALID */\r\n        : targetTypeMap(toRawType(value));\r\n}\r\nfunction reactive(target) {\r\n    // if trying to observe a readonly proxy, return the readonly version.\r\n    if (isReadonly(target)) {\r\n        return target;\r\n    }\r\n    return createReactiveObject(target, false, mutableHandlers, mutableCollectionHandlers, reactiveMap);\r\n}\r\n/**\r\n * Return a shallowly-reactive copy of the original object, where only the root\r\n * level properties are reactive. It also does not auto-unwrap refs (even at the\r\n * root level).\r\n */\r\nfunction shallowReactive(target) {\r\n    return createReactiveObject(target, false, shallowReactiveHandlers, shallowCollectionHandlers, shallowReactiveMap);\r\n}\r\n/**\r\n * Creates a readonly copy of the original object. Note the returned copy is not\r\n * made reactive, but `readonly` can be called on an already reactive object.\r\n */\r\nfunction readonly(target) {\r\n    return createReactiveObject(target, true, readonlyHandlers, readonlyCollectionHandlers, readonlyMap);\r\n}\r\n/**\r\n * Returns a reactive-copy of the original object, where only the root level\r\n * properties are readonly, and does NOT unwrap refs nor recursively convert\r\n * returned properties.\r\n * This is used for creating the props proxy object for stateful components.\r\n */\r\nfunction shallowReadonly(target) {\r\n    return createReactiveObject(target, true, shallowReadonlyHandlers, shallowReadonlyCollectionHandlers, shallowReadonlyMap);\r\n}\r\nfunction createReactiveObject(target, isReadonly, baseHandlers, collectionHandlers, proxyMap) {\r\n    if (!isObject(target)) {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            console.warn(`value cannot be made reactive: ${String(target)}`);\r\n        }\r\n        return target;\r\n    }\r\n    // target is already a Proxy, return it.\r\n    // exception: calling readonly() on a reactive object\r\n    if (target[\"__v_raw\" /* RAW */] &&\r\n        !(isReadonly && target[\"__v_isReactive\" /* IS_REACTIVE */])) {\r\n        return target;\r\n    }\r\n    // target already has corresponding Proxy\r\n    const existingProxy = proxyMap.get(target);\r\n    if (existingProxy) {\r\n        return existingProxy;\r\n    }\r\n    // only specific value types can be observed.\r\n    const targetType = getTargetType(target);\r\n    if (targetType === 0 /* INVALID */) {\r\n        return target;\r\n    }\r\n    const proxy = new Proxy(target, targetType === 2 /* COLLECTION */ ? collectionHandlers : baseHandlers);\r\n    proxyMap.set(target, proxy);\r\n    return proxy;\r\n}\r\nfunction isReactive(value) {\r\n    if (isReadonly(value)) {\r\n        return isReactive(value[\"__v_raw\" /* RAW */]);\r\n    }\r\n    return !!(value && value[\"__v_isReactive\" /* IS_REACTIVE */]);\r\n}\r\nfunction isReadonly(value) {\r\n    return !!(value && value[\"__v_isReadonly\" /* IS_READONLY */]);\r\n}\r\nfunction isShallow(value) {\r\n    return !!(value && value[\"__v_isShallow\" /* IS_SHALLOW */]);\r\n}\r\nfunction isProxy(value) {\r\n    return isReactive(value) || isReadonly(value);\r\n}\r\nfunction toRaw(observed) {\r\n    const raw = observed && observed[\"__v_raw\" /* RAW */];\r\n    return raw ? toRaw(raw) : observed;\r\n}\r\nfunction markRaw(value) {\r\n    def(value, \"__v_skip\" /* SKIP */, true);\r\n    return value;\r\n}\r\nconst toReactive = (value) => isObject(value) ? reactive(value) : value;\r\nconst toReadonly = (value) => isObject(value) ? readonly(value) : value;\n\nfunction trackRefValue(ref) {\r\n    if (shouldTrack && activeEffect) {\r\n        ref = toRaw(ref);\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            trackEffects(ref.dep || (ref.dep = createDep()), {\r\n                target: ref,\r\n                type: \"get\" /* GET */,\r\n                key: 'value'\r\n            });\r\n        }\r\n        else {\r\n            trackEffects(ref.dep || (ref.dep = createDep()));\r\n        }\r\n    }\r\n}\r\nfunction triggerRefValue(ref, newVal) {\r\n    ref = toRaw(ref);\r\n    if (ref.dep) {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            triggerEffects(ref.dep, {\r\n                target: ref,\r\n                type: \"set\" /* SET */,\r\n                key: 'value',\r\n                newValue: newVal\r\n            });\r\n        }\r\n        else {\r\n            triggerEffects(ref.dep);\r\n        }\r\n    }\r\n}\r\nfunction isRef(r) {\r\n    return !!(r && r.__v_isRef === true);\r\n}\r\nfunction ref(value) {\r\n    return createRef(value, false);\r\n}\r\nfunction shallowRef(value) {\r\n    return createRef(value, true);\r\n}\r\nfunction createRef(rawValue, shallow) {\r\n    if (isRef(rawValue)) {\r\n        return rawValue;\r\n    }\r\n    return new RefImpl(rawValue, shallow);\r\n}\r\nclass RefImpl {\r\n    constructor(value, __v_isShallow) {\r\n        this.__v_isShallow = __v_isShallow;\r\n        this.dep = undefined;\r\n        this.__v_isRef = true;\r\n        this._rawValue = __v_isShallow ? value : toRaw(value);\r\n        this._value = __v_isShallow ? value : toReactive(value);\r\n    }\r\n    get value() {\r\n        trackRefValue(this);\r\n        return this._value;\r\n    }\r\n    set value(newVal) {\r\n        newVal = this.__v_isShallow ? newVal : toRaw(newVal);\r\n        if (hasChanged(newVal, this._rawValue)) {\r\n            this._rawValue = newVal;\r\n            this._value = this.__v_isShallow ? newVal : toReactive(newVal);\r\n            triggerRefValue(this, newVal);\r\n        }\r\n    }\r\n}\r\nfunction triggerRef(ref) {\r\n    triggerRefValue(ref, (process.env.NODE_ENV !== 'production') ? ref.value : void 0);\r\n}\r\nfunction unref(ref) {\r\n    return isRef(ref) ? ref.value : ref;\r\n}\r\nconst shallowUnwrapHandlers = {\r\n    get: (target, key, receiver) => unref(Reflect.get(target, key, receiver)),\r\n    set: (target, key, value, receiver) => {\r\n        const oldValue = target[key];\r\n        if (isRef(oldValue) && !isRef(value)) {\r\n            oldValue.value = value;\r\n            return true;\r\n        }\r\n        else {\r\n            return Reflect.set(target, key, value, receiver);\r\n        }\r\n    }\r\n};\r\nfunction proxyRefs(objectWithRefs) {\r\n    return isReactive(objectWithRefs)\r\n        ? objectWithRefs\r\n        : new Proxy(objectWithRefs, shallowUnwrapHandlers);\r\n}\r\nclass CustomRefImpl {\r\n    constructor(factory) {\r\n        this.dep = undefined;\r\n        this.__v_isRef = true;\r\n        const { get, set } = factory(() => trackRefValue(this), () => triggerRefValue(this));\r\n        this._get = get;\r\n        this._set = set;\r\n    }\r\n    get value() {\r\n        return this._get();\r\n    }\r\n    set value(newVal) {\r\n        this._set(newVal);\r\n    }\r\n}\r\nfunction customRef(factory) {\r\n    return new CustomRefImpl(factory);\r\n}\r\nfunction toRefs(object) {\r\n    if ((process.env.NODE_ENV !== 'production') && !isProxy(object)) {\r\n        console.warn(`toRefs() expects a reactive object but received a plain one.`);\r\n    }\r\n    const ret = isArray(object) ? new Array(object.length) : {};\r\n    for (const key in object) {\r\n        ret[key] = toRef(object, key);\r\n    }\r\n    return ret;\r\n}\r\nclass ObjectRefImpl {\r\n    constructor(_object, _key, _defaultValue) {\r\n        this._object = _object;\r\n        this._key = _key;\r\n        this._defaultValue = _defaultValue;\r\n        this.__v_isRef = true;\r\n    }\r\n    get value() {\r\n        const val = this._object[this._key];\r\n        return val === undefined ? this._defaultValue : val;\r\n    }\r\n    set value(newVal) {\r\n        this._object[this._key] = newVal;\r\n    }\r\n}\r\nfunction toRef(object, key, defaultValue) {\r\n    const val = object[key];\r\n    return isRef(val)\r\n        ? val\r\n        : new ObjectRefImpl(object, key, defaultValue);\r\n}\n\nclass ComputedRefImpl {\r\n    constructor(getter, _setter, isReadonly, isSSR) {\r\n        this._setter = _setter;\r\n        this.dep = undefined;\r\n        this.__v_isRef = true;\r\n        this._dirty = true;\r\n        this.effect = new ReactiveEffect(getter, () => {\r\n            if (!this._dirty) {\r\n                this._dirty = true;\r\n                triggerRefValue(this);\r\n            }\r\n        });\r\n        this.effect.computed = this;\r\n        this.effect.active = this._cacheable = !isSSR;\r\n        this[\"__v_isReadonly\" /* IS_READONLY */] = isReadonly;\r\n    }\r\n    get value() {\r\n        // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n        const self = toRaw(this);\r\n        trackRefValue(self);\r\n        if (self._dirty || !self._cacheable) {\r\n            self._dirty = false;\r\n            self._value = self.effect.run();\r\n        }\r\n        return self._value;\r\n    }\r\n    set value(newValue) {\r\n        this._setter(newValue);\r\n    }\r\n}\r\nfunction computed(getterOrOptions, debugOptions, isSSR = false) {\r\n    let getter;\r\n    let setter;\r\n    const onlyGetter = isFunction(getterOrOptions);\r\n    if (onlyGetter) {\r\n        getter = getterOrOptions;\r\n        setter = (process.env.NODE_ENV !== 'production')\r\n            ? () => {\r\n                console.warn('Write operation failed: computed value is readonly');\r\n            }\r\n            : NOOP;\r\n    }\r\n    else {\r\n        getter = getterOrOptions.get;\r\n        setter = getterOrOptions.set;\r\n    }\r\n    const cRef = new ComputedRefImpl(getter, setter, onlyGetter || !setter, isSSR);\r\n    if ((process.env.NODE_ENV !== 'production') && debugOptions && !isSSR) {\r\n        cRef.effect.onTrack = debugOptions.onTrack;\r\n        cRef.effect.onTrigger = debugOptions.onTrigger;\r\n    }\r\n    return cRef;\r\n}\n\nvar _a;\r\nconst tick = /*#__PURE__*/ Promise.resolve();\r\nconst queue = [];\r\nlet queued = false;\r\nconst scheduler = (fn) => {\r\n    queue.push(fn);\r\n    if (!queued) {\r\n        queued = true;\r\n        tick.then(flush);\r\n    }\r\n};\r\nconst flush = () => {\r\n    for (let i = 0; i < queue.length; i++) {\r\n        queue[i]();\r\n    }\r\n    queue.length = 0;\r\n    queued = false;\r\n};\r\nclass DeferredComputedRefImpl {\r\n    constructor(getter) {\r\n        this.dep = undefined;\r\n        this._dirty = true;\r\n        this.__v_isRef = true;\r\n        this[_a] = true;\r\n        let compareTarget;\r\n        let hasCompareTarget = false;\r\n        let scheduled = false;\r\n        this.effect = new ReactiveEffect(getter, (computedTrigger) => {\r\n            if (this.dep) {\r\n                if (computedTrigger) {\r\n                    compareTarget = this._value;\r\n                    hasCompareTarget = true;\r\n                }\r\n                else if (!scheduled) {\r\n                    const valueToCompare = hasCompareTarget ? compareTarget : this._value;\r\n                    scheduled = true;\r\n                    hasCompareTarget = false;\r\n                    scheduler(() => {\r\n                        if (this.effect.active && this._get() !== valueToCompare) {\r\n                            triggerRefValue(this);\r\n                        }\r\n                        scheduled = false;\r\n                    });\r\n                }\r\n                // chained upstream computeds are notified synchronously to ensure\r\n                // value invalidation in case of sync access; normal effects are\r\n                // deferred to be triggered in scheduler.\r\n                for (const e of this.dep) {\r\n                    if (e.computed instanceof DeferredComputedRefImpl) {\r\n                        e.scheduler(true /* computedTrigger */);\r\n                    }\r\n                }\r\n            }\r\n            this._dirty = true;\r\n        });\r\n        this.effect.computed = this;\r\n    }\r\n    _get() {\r\n        if (this._dirty) {\r\n            this._dirty = false;\r\n            return (this._value = this.effect.run());\r\n        }\r\n        return this._value;\r\n    }\r\n    get value() {\r\n        trackRefValue(this);\r\n        // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n        return toRaw(this)._get();\r\n    }\r\n}\r\n_a = \"__v_isReadonly\" /* IS_READONLY */;\r\nfunction deferredComputed(getter) {\r\n    return new DeferredComputedRefImpl(getter);\r\n}\n\nexport { EffectScope, ITERATE_KEY, ReactiveEffect, computed, customRef, deferredComputed, effect, effectScope, enableTracking, getCurrentScope, isProxy, isReactive, isReadonly, isRef, isShallow, markRaw, onScopeDispose, pauseTracking, proxyRefs, reactive, readonly, ref, resetTracking, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, track, trigger, triggerRef, unref };\n","import { pauseTracking, resetTracking, isRef, toRaw, isShallow as isShallow$1, isReactive, ReactiveEffect, ref, shallowReadonly, track, reactive, shallowReactive, trigger, isProxy, EffectScope, markRaw, proxyRefs, computed as computed$1, isReadonly } from '@vue/reactivity';\nexport { EffectScope, ReactiveEffect, customRef, effect, effectScope, getCurrentScope, isProxy, isReactive, isReadonly, isRef, isShallow, markRaw, onScopeDispose, proxyRefs, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, triggerRef, unref } from '@vue/reactivity';\nimport { isString, isFunction, isPromise, isArray, NOOP, getGlobalThis, extend, EMPTY_OBJ, toHandlerKey, toNumber, hyphenate, camelize, isOn, hasOwn, isModelListener, hasChanged, remove, isObject, isSet, isMap, isPlainObject, invokeArrayFns, isBuiltInDirective, capitalize, isGloballyWhitelisted, def, isReservedProp, EMPTY_ARR, toRawType, makeMap, NO, normalizeClass, normalizeStyle } from '@vue/shared';\nexport { camelize, capitalize, normalizeClass, normalizeProps, normalizeStyle, toDisplayString, toHandlerKey } from '@vue/shared';\n\nconst stack = [];\r\nfunction pushWarningContext(vnode) {\r\n    stack.push(vnode);\r\n}\r\nfunction popWarningContext() {\r\n    stack.pop();\r\n}\r\nfunction warn(msg, ...args) {\r\n    // avoid props formatting or warn handler tracking deps that might be mutated\r\n    // during patch, leading to infinite recursion.\r\n    pauseTracking();\r\n    const instance = stack.length ? stack[stack.length - 1].component : null;\r\n    const appWarnHandler = instance && instance.appContext.config.warnHandler;\r\n    const trace = getComponentTrace();\r\n    if (appWarnHandler) {\r\n        callWithErrorHandling(appWarnHandler, instance, 11 /* APP_WARN_HANDLER */, [\r\n            msg + args.join(''),\r\n            instance && instance.proxy,\r\n            trace\r\n                .map(({ vnode }) => `at <${formatComponentName(instance, vnode.type)}>`)\r\n                .join('\\n'),\r\n            trace\r\n        ]);\r\n    }\r\n    else {\r\n        const warnArgs = [`[Vue warn]: ${msg}`, ...args];\r\n        /* istanbul ignore if */\r\n        if (trace.length &&\r\n            // avoid spamming console during tests\r\n            !false) {\r\n            warnArgs.push(`\\n`, ...formatTrace(trace));\r\n        }\r\n        console.warn(...warnArgs);\r\n    }\r\n    resetTracking();\r\n}\r\nfunction getComponentTrace() {\r\n    let currentVNode = stack[stack.length - 1];\r\n    if (!currentVNode) {\r\n        return [];\r\n    }\r\n    // we can't just use the stack because it will be incomplete during updates\r\n    // that did not start from the root. Re-construct the parent chain using\r\n    // instance parent pointers.\r\n    const normalizedStack = [];\r\n    while (currentVNode) {\r\n        const last = normalizedStack[0];\r\n        if (last && last.vnode === currentVNode) {\r\n            last.recurseCount++;\r\n        }\r\n        else {\r\n            normalizedStack.push({\r\n                vnode: currentVNode,\r\n                recurseCount: 0\r\n            });\r\n        }\r\n        const parentInstance = currentVNode.component && currentVNode.component.parent;\r\n        currentVNode = parentInstance && parentInstance.vnode;\r\n    }\r\n    return normalizedStack;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatTrace(trace) {\r\n    const logs = [];\r\n    trace.forEach((entry, i) => {\r\n        logs.push(...(i === 0 ? [] : [`\\n`]), ...formatTraceEntry(entry));\r\n    });\r\n    return logs;\r\n}\r\nfunction formatTraceEntry({ vnode, recurseCount }) {\r\n    const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;\r\n    const isRoot = vnode.component ? vnode.component.parent == null : false;\r\n    const open = ` at <${formatComponentName(vnode.component, vnode.type, isRoot)}`;\r\n    const close = `>` + postfix;\r\n    return vnode.props\r\n        ? [open, ...formatProps(vnode.props), close]\r\n        : [open + close];\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProps(props) {\r\n    const res = [];\r\n    const keys = Object.keys(props);\r\n    keys.slice(0, 3).forEach(key => {\r\n        res.push(...formatProp(key, props[key]));\r\n    });\r\n    if (keys.length > 3) {\r\n        res.push(` ...`);\r\n    }\r\n    return res;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProp(key, value, raw) {\r\n    if (isString(value)) {\r\n        value = JSON.stringify(value);\r\n        return raw ? value : [`${key}=${value}`];\r\n    }\r\n    else if (typeof value === 'number' ||\r\n        typeof value === 'boolean' ||\r\n        value == null) {\r\n        return raw ? value : [`${key}=${value}`];\r\n    }\r\n    else if (isRef(value)) {\r\n        value = formatProp(key, toRaw(value.value), true);\r\n        return raw ? value : [`${key}=Ref<`, value, `>`];\r\n    }\r\n    else if (isFunction(value)) {\r\n        return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];\r\n    }\r\n    else {\r\n        value = toRaw(value);\r\n        return raw ? value : [`${key}=`, value];\r\n    }\r\n}\n\nconst ErrorTypeStrings = {\r\n    [\"sp\" /* SERVER_PREFETCH */]: 'serverPrefetch hook',\r\n    [\"bc\" /* BEFORE_CREATE */]: 'beforeCreate hook',\r\n    [\"c\" /* CREATED */]: 'created hook',\r\n    [\"bm\" /* BEFORE_MOUNT */]: 'beforeMount hook',\r\n    [\"m\" /* MOUNTED */]: 'mounted hook',\r\n    [\"bu\" /* BEFORE_UPDATE */]: 'beforeUpdate hook',\r\n    [\"u\" /* UPDATED */]: 'updated',\r\n    [\"bum\" /* BEFORE_UNMOUNT */]: 'beforeUnmount hook',\r\n    [\"um\" /* UNMOUNTED */]: 'unmounted hook',\r\n    [\"a\" /* ACTIVATED */]: 'activated hook',\r\n    [\"da\" /* DEACTIVATED */]: 'deactivated hook',\r\n    [\"ec\" /* ERROR_CAPTURED */]: 'errorCaptured hook',\r\n    [\"rtc\" /* RENDER_TRACKED */]: 'renderTracked hook',\r\n    [\"rtg\" /* RENDER_TRIGGERED */]: 'renderTriggered hook',\r\n    [0 /* SETUP_FUNCTION */]: 'setup function',\r\n    [1 /* RENDER_FUNCTION */]: 'render function',\r\n    [2 /* WATCH_GETTER */]: 'watcher getter',\r\n    [3 /* WATCH_CALLBACK */]: 'watcher callback',\r\n    [4 /* WATCH_CLEANUP */]: 'watcher cleanup function',\r\n    [5 /* NATIVE_EVENT_HANDLER */]: 'native event handler',\r\n    [6 /* COMPONENT_EVENT_HANDLER */]: 'component event handler',\r\n    [7 /* VNODE_HOOK */]: 'vnode hook',\r\n    [8 /* DIRECTIVE_HOOK */]: 'directive hook',\r\n    [9 /* TRANSITION_HOOK */]: 'transition hook',\r\n    [10 /* APP_ERROR_HANDLER */]: 'app errorHandler',\r\n    [11 /* APP_WARN_HANDLER */]: 'app warnHandler',\r\n    [12 /* FUNCTION_REF */]: 'ref function',\r\n    [13 /* ASYNC_COMPONENT_LOADER */]: 'async component loader',\r\n    [14 /* SCHEDULER */]: 'scheduler flush. This is likely a Vue internals bug. ' +\r\n        'Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/core'\r\n};\r\nfunction callWithErrorHandling(fn, instance, type, args) {\r\n    let res;\r\n    try {\r\n        res = args ? fn(...args) : fn();\r\n    }\r\n    catch (err) {\r\n        handleError(err, instance, type);\r\n    }\r\n    return res;\r\n}\r\nfunction callWithAsyncErrorHandling(fn, instance, type, args) {\r\n    if (isFunction(fn)) {\r\n        const res = callWithErrorHandling(fn, instance, type, args);\r\n        if (res && isPromise(res)) {\r\n            res.catch(err => {\r\n                handleError(err, instance, type);\r\n            });\r\n        }\r\n        return res;\r\n    }\r\n    const values = [];\r\n    for (let i = 0; i < fn.length; i++) {\r\n        values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));\r\n    }\r\n    return values;\r\n}\r\nfunction handleError(err, instance, type, throwInDev = true) {\r\n    const contextVNode = instance ? instance.vnode : null;\r\n    if (instance) {\r\n        let cur = instance.parent;\r\n        // the exposed instance is the render proxy to keep it consistent with 2.x\r\n        const exposedInstance = instance.proxy;\r\n        // in production the hook receives only the error code\r\n        const errorInfo = (process.env.NODE_ENV !== 'production') ? ErrorTypeStrings[type] : type;\r\n        while (cur) {\r\n            const errorCapturedHooks = cur.ec;\r\n            if (errorCapturedHooks) {\r\n                for (let i = 0; i < errorCapturedHooks.length; i++) {\r\n                    if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {\r\n                        return;\r\n                    }\r\n                }\r\n            }\r\n            cur = cur.parent;\r\n        }\r\n        // app-level handling\r\n        const appErrorHandler = instance.appContext.config.errorHandler;\r\n        if (appErrorHandler) {\r\n            callWithErrorHandling(appErrorHandler, null, 10 /* APP_ERROR_HANDLER */, [err, exposedInstance, errorInfo]);\r\n            return;\r\n        }\r\n    }\r\n    logError(err, type, contextVNode, throwInDev);\r\n}\r\nfunction logError(err, type, contextVNode, throwInDev = true) {\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        const info = ErrorTypeStrings[type];\r\n        if (contextVNode) {\r\n            pushWarningContext(contextVNode);\r\n        }\r\n        warn(`Unhandled error${info ? ` during execution of ${info}` : ``}`);\r\n        if (contextVNode) {\r\n            popWarningContext();\r\n        }\r\n        // crash in dev by default so it's more noticeable\r\n        if (throwInDev) {\r\n            throw err;\r\n        }\r\n        else {\r\n            console.error(err);\r\n        }\r\n    }\r\n    else {\r\n        // recover in prod to reduce the impact on end-user\r\n        console.error(err);\r\n    }\r\n}\n\nlet isFlushing = false;\r\nlet isFlushPending = false;\r\nconst queue = [];\r\nlet flushIndex = 0;\r\nconst pendingPreFlushCbs = [];\r\nlet activePreFlushCbs = null;\r\nlet preFlushIndex = 0;\r\nconst pendingPostFlushCbs = [];\r\nlet activePostFlushCbs = null;\r\nlet postFlushIndex = 0;\r\nconst resolvedPromise = /*#__PURE__*/ Promise.resolve();\r\nlet currentFlushPromise = null;\r\nlet currentPreFlushParentJob = null;\r\nconst RECURSION_LIMIT = 100;\r\nfunction nextTick(fn) {\r\n    const p = currentFlushPromise || resolvedPromise;\r\n    return fn ? p.then(this ? fn.bind(this) : fn) : p;\r\n}\r\n// #2768\r\n// Use binary-search to find a suitable position in the queue,\r\n// so that the queue maintains the increasing order of job's id,\r\n// which can prevent the job from being skipped and also can avoid repeated patching.\r\nfunction findInsertionIndex(id) {\r\n    // the start index should be `flushIndex + 1`\r\n    let start = flushIndex + 1;\r\n    let end = queue.length;\r\n    while (start < end) {\r\n        const middle = (start + end) >>> 1;\r\n        const middleJobId = getId(queue[middle]);\r\n        middleJobId < id ? (start = middle + 1) : (end = middle);\r\n    }\r\n    return start;\r\n}\r\nfunction queueJob(job) {\r\n    // the dedupe search uses the startIndex argument of Array.includes()\r\n    // by default the search index includes the current job that is being run\r\n    // so it cannot recursively trigger itself again.\r\n    // if the job is a watch() callback, the search will start with a +1 index to\r\n    // allow it recursively trigger itself - it is the user's responsibility to\r\n    // ensure it doesn't end up in an infinite loop.\r\n    if ((!queue.length ||\r\n        !queue.includes(job, isFlushing && job.allowRecurse ? flushIndex + 1 : flushIndex)) &&\r\n        job !== currentPreFlushParentJob) {\r\n        if (job.id == null) {\r\n            queue.push(job);\r\n        }\r\n        else {\r\n            queue.splice(findInsertionIndex(job.id), 0, job);\r\n        }\r\n        queueFlush();\r\n    }\r\n}\r\nfunction queueFlush() {\r\n    if (!isFlushing && !isFlushPending) {\r\n        isFlushPending = true;\r\n        currentFlushPromise = resolvedPromise.then(flushJobs);\r\n    }\r\n}\r\nfunction invalidateJob(job) {\r\n    const i = queue.indexOf(job);\r\n    if (i > flushIndex) {\r\n        queue.splice(i, 1);\r\n    }\r\n}\r\nfunction queueCb(cb, activeQueue, pendingQueue, index) {\r\n    if (!isArray(cb)) {\r\n        if (!activeQueue ||\r\n            !activeQueue.includes(cb, cb.allowRecurse ? index + 1 : index)) {\r\n            pendingQueue.push(cb);\r\n        }\r\n    }\r\n    else {\r\n        // if cb is an array, it is a component lifecycle hook which can only be\r\n        // triggered by a job, which is already deduped in the main queue, so\r\n        // we can skip duplicate check here to improve perf\r\n        pendingQueue.push(...cb);\r\n    }\r\n    queueFlush();\r\n}\r\nfunction queuePreFlushCb(cb) {\r\n    queueCb(cb, activePreFlushCbs, pendingPreFlushCbs, preFlushIndex);\r\n}\r\nfunction queuePostFlushCb(cb) {\r\n    queueCb(cb, activePostFlushCbs, pendingPostFlushCbs, postFlushIndex);\r\n}\r\nfunction flushPreFlushCbs(seen, parentJob = null) {\r\n    if (pendingPreFlushCbs.length) {\r\n        currentPreFlushParentJob = parentJob;\r\n        activePreFlushCbs = [...new Set(pendingPreFlushCbs)];\r\n        pendingPreFlushCbs.length = 0;\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            seen = seen || new Map();\r\n        }\r\n        for (preFlushIndex = 0; preFlushIndex < activePreFlushCbs.length; preFlushIndex++) {\r\n            if ((process.env.NODE_ENV !== 'production') &&\r\n                checkRecursiveUpdates(seen, activePreFlushCbs[preFlushIndex])) {\r\n                continue;\r\n            }\r\n            activePreFlushCbs[preFlushIndex]();\r\n        }\r\n        activePreFlushCbs = null;\r\n        preFlushIndex = 0;\r\n        currentPreFlushParentJob = null;\r\n        // recursively flush until it drains\r\n        flushPreFlushCbs(seen, parentJob);\r\n    }\r\n}\r\nfunction flushPostFlushCbs(seen) {\r\n    // flush any pre cbs queued during the flush (e.g. pre watchers)\r\n    flushPreFlushCbs();\r\n    if (pendingPostFlushCbs.length) {\r\n        const deduped = [...new Set(pendingPostFlushCbs)];\r\n        pendingPostFlushCbs.length = 0;\r\n        // #1947 already has active queue, nested flushPostFlushCbs call\r\n        if (activePostFlushCbs) {\r\n            activePostFlushCbs.push(...deduped);\r\n            return;\r\n        }\r\n        activePostFlushCbs = deduped;\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            seen = seen || new Map();\r\n        }\r\n        activePostFlushCbs.sort((a, b) => getId(a) - getId(b));\r\n        for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {\r\n            if ((process.env.NODE_ENV !== 'production') &&\r\n                checkRecursiveUpdates(seen, activePostFlushCbs[postFlushIndex])) {\r\n                continue;\r\n            }\r\n            activePostFlushCbs[postFlushIndex]();\r\n        }\r\n        activePostFlushCbs = null;\r\n        postFlushIndex = 0;\r\n    }\r\n}\r\nconst getId = (job) => job.id == null ? Infinity : job.id;\r\nfunction flushJobs(seen) {\r\n    isFlushPending = false;\r\n    isFlushing = true;\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        seen = seen || new Map();\r\n    }\r\n    flushPreFlushCbs(seen);\r\n    // Sort queue before flush.\r\n    // This ensures that:\r\n    // 1. Components are updated from parent to child. (because parent is always\r\n    //    created before the child so its render effect will have smaller\r\n    //    priority number)\r\n    // 2. If a component is unmounted during a parent component's update,\r\n    //    its update can be skipped.\r\n    queue.sort((a, b) => getId(a) - getId(b));\r\n    // conditional usage of checkRecursiveUpdate must be determined out of\r\n    // try ... catch block since Rollup by default de-optimizes treeshaking\r\n    // inside try-catch. This can leave all warning code unshaked. Although\r\n    // they would get eventually shaken by a minifier like terser, some minifiers\r\n    // would fail to do that (e.g. https://github.com/evanw/esbuild/issues/1610)\r\n    const check = (process.env.NODE_ENV !== 'production')\r\n        ? (job) => checkRecursiveUpdates(seen, job)\r\n        : NOOP;\r\n    try {\r\n        for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {\r\n            const job = queue[flushIndex];\r\n            if (job && job.active !== false) {\r\n                if ((process.env.NODE_ENV !== 'production') && check(job)) {\r\n                    continue;\r\n                }\r\n                // console.log(`running:`, job.id)\r\n                callWithErrorHandling(job, null, 14 /* SCHEDULER */);\r\n            }\r\n        }\r\n    }\r\n    finally {\r\n        flushIndex = 0;\r\n        queue.length = 0;\r\n        flushPostFlushCbs(seen);\r\n        isFlushing = false;\r\n        currentFlushPromise = null;\r\n        // some postFlushCb queued jobs!\r\n        // keep flushing until it drains.\r\n        if (queue.length ||\r\n            pendingPreFlushCbs.length ||\r\n            pendingPostFlushCbs.length) {\r\n            flushJobs(seen);\r\n        }\r\n    }\r\n}\r\nfunction checkRecursiveUpdates(seen, fn) {\r\n    if (!seen.has(fn)) {\r\n        seen.set(fn, 1);\r\n    }\r\n    else {\r\n        const count = seen.get(fn);\r\n        if (count > RECURSION_LIMIT) {\r\n            const instance = fn.ownerInstance;\r\n            const componentName = instance && getComponentName(instance.type);\r\n            warn(`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. ` +\r\n                `This means you have a reactive effect that is mutating its own ` +\r\n                `dependencies and thus recursively triggering itself. Possible sources ` +\r\n                `include component template, render function, updated hook or ` +\r\n                `watcher source function.`);\r\n            return true;\r\n        }\r\n        else {\r\n            seen.set(fn, count + 1);\r\n        }\r\n    }\r\n}\n\n/* eslint-disable no-restricted-globals */\r\nlet isHmrUpdating = false;\r\nconst hmrDirtyComponents = new Set();\r\n// Expose the HMR runtime on the global object\r\n// This makes it entirely tree-shakable without polluting the exports and makes\r\n// it easier to be used in toolings like vue-loader\r\n// Note: for a component to be eligible for HMR it also needs the __hmrId option\r\n// to be set so that its instances can be registered / removed.\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n    getGlobalThis().__VUE_HMR_RUNTIME__ = {\r\n        createRecord: tryWrap(createRecord),\r\n        rerender: tryWrap(rerender),\r\n        reload: tryWrap(reload)\r\n    };\r\n}\r\nconst map = new Map();\r\nfunction registerHMR(instance) {\r\n    const id = instance.type.__hmrId;\r\n    let record = map.get(id);\r\n    if (!record) {\r\n        createRecord(id, instance.type);\r\n        record = map.get(id);\r\n    }\r\n    record.instances.add(instance);\r\n}\r\nfunction unregisterHMR(instance) {\r\n    map.get(instance.type.__hmrId).instances.delete(instance);\r\n}\r\nfunction createRecord(id, initialDef) {\r\n    if (map.has(id)) {\r\n        return false;\r\n    }\r\n    map.set(id, {\r\n        initialDef: normalizeClassComponent(initialDef),\r\n        instances: new Set()\r\n    });\r\n    return true;\r\n}\r\nfunction normalizeClassComponent(component) {\r\n    return isClassComponent(component) ? component.__vccOpts : component;\r\n}\r\nfunction rerender(id, newRender) {\r\n    const record = map.get(id);\r\n    if (!record) {\r\n        return;\r\n    }\r\n    // update initial record (for not-yet-rendered component)\r\n    record.initialDef.render = newRender;\r\n    [...record.instances].forEach(instance => {\r\n        if (newRender) {\r\n            instance.render = newRender;\r\n            normalizeClassComponent(instance.type).render = newRender;\r\n        }\r\n        instance.renderCache = [];\r\n        // this flag forces child components with slot content to update\r\n        isHmrUpdating = true;\r\n        instance.update();\r\n        isHmrUpdating = false;\r\n    });\r\n}\r\nfunction reload(id, newComp) {\r\n    const record = map.get(id);\r\n    if (!record)\r\n        return;\r\n    newComp = normalizeClassComponent(newComp);\r\n    // update initial def (for not-yet-rendered components)\r\n    updateComponentDef(record.initialDef, newComp);\r\n    // create a snapshot which avoids the set being mutated during updates\r\n    const instances = [...record.instances];\r\n    for (const instance of instances) {\r\n        const oldComp = normalizeClassComponent(instance.type);\r\n        if (!hmrDirtyComponents.has(oldComp)) {\r\n            // 1. Update existing comp definition to match new one\r\n            if (oldComp !== record.initialDef) {\r\n                updateComponentDef(oldComp, newComp);\r\n            }\r\n            // 2. mark definition dirty. This forces the renderer to replace the\r\n            // component on patch.\r\n            hmrDirtyComponents.add(oldComp);\r\n        }\r\n        // 3. invalidate options resolution cache\r\n        instance.appContext.optionsCache.delete(instance.type);\r\n        // 4. actually update\r\n        if (instance.ceReload) {\r\n            // custom element\r\n            hmrDirtyComponents.add(oldComp);\r\n            instance.ceReload(newComp.styles);\r\n            hmrDirtyComponents.delete(oldComp);\r\n        }\r\n        else if (instance.parent) {\r\n            // 4. Force the parent instance to re-render. This will cause all updated\r\n            // components to be unmounted and re-mounted. Queue the update so that we\r\n            // don't end up forcing the same parent to re-render multiple times.\r\n            queueJob(instance.parent.update);\r\n            // instance is the inner component of an async custom element\r\n            // invoke to reset styles\r\n            if (instance.parent.type.__asyncLoader &&\r\n                instance.parent.ceReload) {\r\n                instance.parent.ceReload(newComp.styles);\r\n            }\r\n        }\r\n        else if (instance.appContext.reload) {\r\n            // root instance mounted via createApp() has a reload method\r\n            instance.appContext.reload();\r\n        }\r\n        else if (typeof window !== 'undefined') {\r\n            // root instance inside tree created via raw render(). Force reload.\r\n            window.location.reload();\r\n        }\r\n        else {\r\n            console.warn('[HMR] Root or manually mounted instance modified. Full reload required.');\r\n        }\r\n    }\r\n    // 5. make sure to cleanup dirty hmr components after update\r\n    queuePostFlushCb(() => {\r\n        for (const instance of instances) {\r\n            hmrDirtyComponents.delete(normalizeClassComponent(instance.type));\r\n        }\r\n    });\r\n}\r\nfunction updateComponentDef(oldComp, newComp) {\r\n    extend(oldComp, newComp);\r\n    for (const key in oldComp) {\r\n        if (key !== '__file' && !(key in newComp)) {\r\n            delete oldComp[key];\r\n        }\r\n    }\r\n}\r\nfunction tryWrap(fn) {\r\n    return (id, arg) => {\r\n        try {\r\n            return fn(id, arg);\r\n        }\r\n        catch (e) {\r\n            console.error(e);\r\n            console.warn(`[HMR] Something went wrong during Vue component hot-reload. ` +\r\n                `Full reload required.`);\r\n        }\r\n    };\r\n}\n\nlet devtools;\r\nlet buffer = [];\r\nlet devtoolsNotInstalled = false;\r\nfunction emit(event, ...args) {\r\n    if (devtools) {\r\n        devtools.emit(event, ...args);\r\n    }\r\n    else if (!devtoolsNotInstalled) {\r\n        buffer.push({ event, args });\r\n    }\r\n}\r\nfunction setDevtoolsHook(hook, target) {\r\n    var _a, _b;\r\n    devtools = hook;\r\n    if (devtools) {\r\n        devtools.enabled = true;\r\n        buffer.forEach(({ event, args }) => devtools.emit(event, ...args));\r\n        buffer = [];\r\n    }\r\n    else if (\r\n    // handle late devtools injection - only do this if we are in an actual\r\n    // browser environment to avoid the timer handle stalling test runner exit\r\n    // (#4815)\r\n    typeof window !== 'undefined' &&\r\n        // some envs mock window but not fully\r\n        window.HTMLElement &&\r\n        // also exclude jsdom\r\n        !((_b = (_a = window.navigator) === null || _a === void 0 ? void 0 : _a.userAgent) === null || _b === void 0 ? void 0 : _b.includes('jsdom'))) {\r\n        const replay = (target.__VUE_DEVTOOLS_HOOK_REPLAY__ =\r\n            target.__VUE_DEVTOOLS_HOOK_REPLAY__ || []);\r\n        replay.push((newHook) => {\r\n            setDevtoolsHook(newHook, target);\r\n        });\r\n        // clear buffer after 3s - the user probably doesn't have devtools installed\r\n        // at all, and keeping the buffer will cause memory leaks (#4738)\r\n        setTimeout(() => {\r\n            if (!devtools) {\r\n                target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null;\r\n                devtoolsNotInstalled = true;\r\n                buffer = [];\r\n            }\r\n        }, 3000);\r\n    }\r\n    else {\r\n        // non-browser env, assume not installed\r\n        devtoolsNotInstalled = true;\r\n        buffer = [];\r\n    }\r\n}\r\nfunction devtoolsInitApp(app, version) {\r\n    emit(\"app:init\" /* APP_INIT */, app, version, {\r\n        Fragment,\r\n        Text,\r\n        Comment,\r\n        Static\r\n    });\r\n}\r\nfunction devtoolsUnmountApp(app) {\r\n    emit(\"app:unmount\" /* APP_UNMOUNT */, app);\r\n}\r\nconst devtoolsComponentAdded = /*#__PURE__*/ createDevtoolsComponentHook(\"component:added\" /* COMPONENT_ADDED */);\r\nconst devtoolsComponentUpdated = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:updated\" /* COMPONENT_UPDATED */);\r\nconst devtoolsComponentRemoved = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:removed\" /* COMPONENT_REMOVED */);\r\nfunction createDevtoolsComponentHook(hook) {\r\n    return (component) => {\r\n        emit(hook, component.appContext.app, component.uid, component.parent ? component.parent.uid : undefined, component);\r\n    };\r\n}\r\nconst devtoolsPerfStart = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:start\" /* PERFORMANCE_START */);\r\nconst devtoolsPerfEnd = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:end\" /* PERFORMANCE_END */);\r\nfunction createDevtoolsPerformanceHook(hook) {\r\n    return (component, type, time) => {\r\n        emit(hook, component.appContext.app, component.uid, component, type, time);\r\n    };\r\n}\r\nfunction devtoolsComponentEmit(component, event, params) {\r\n    emit(\"component:emit\" /* COMPONENT_EMIT */, component.appContext.app, component, event, params);\r\n}\n\nfunction emit$1(instance, event, ...rawArgs) {\r\n    if (instance.isUnmounted)\r\n        return;\r\n    const props = instance.vnode.props || EMPTY_OBJ;\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        const { emitsOptions, propsOptions: [propsOptions] } = instance;\r\n        if (emitsOptions) {\r\n            if (!(event in emitsOptions) &&\r\n                !(false )) {\r\n                if (!propsOptions || !(toHandlerKey(event) in propsOptions)) {\r\n                    warn(`Component emitted event \"${event}\" but it is neither declared in ` +\r\n                        `the emits option nor as an \"${toHandlerKey(event)}\" prop.`);\r\n                }\r\n            }\r\n            else {\r\n                const validator = emitsOptions[event];\r\n                if (isFunction(validator)) {\r\n                    const isValid = validator(...rawArgs);\r\n                    if (!isValid) {\r\n                        warn(`Invalid event arguments: event validation failed for event \"${event}\".`);\r\n                    }\r\n                }\r\n            }\r\n        }\r\n    }\r\n    let args = rawArgs;\r\n    const isModelListener = event.startsWith('update:');\r\n    // for v-model update:xxx events, apply modifiers on args\r\n    const modelArg = isModelListener && event.slice(7);\r\n    if (modelArg && modelArg in props) {\r\n        const modifiersKey = `${modelArg === 'modelValue' ? 'model' : modelArg}Modifiers`;\r\n        const { number, trim } = props[modifiersKey] || EMPTY_OBJ;\r\n        if (trim) {\r\n            args = rawArgs.map(a => a.trim());\r\n        }\r\n        if (number) {\r\n            args = rawArgs.map(toNumber);\r\n        }\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n        devtoolsComponentEmit(instance, event, args);\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        const lowerCaseEvent = event.toLowerCase();\r\n        if (lowerCaseEvent !== event && props[toHandlerKey(lowerCaseEvent)]) {\r\n            warn(`Event \"${lowerCaseEvent}\" is emitted in component ` +\r\n                `${formatComponentName(instance, instance.type)} but the handler is registered for \"${event}\". ` +\r\n                `Note that HTML attributes are case-insensitive and you cannot use ` +\r\n                `v-on to listen to camelCase events when using in-DOM templates. ` +\r\n                `You should probably use \"${hyphenate(event)}\" instead of \"${event}\".`);\r\n        }\r\n    }\r\n    let handlerName;\r\n    let handler = props[(handlerName = toHandlerKey(event))] ||\r\n        // also try camelCase event handler (#2249)\r\n        props[(handlerName = toHandlerKey(camelize(event)))];\r\n    // for v-model update:xxx events, also trigger kebab-case equivalent\r\n    // for props passed via kebab-case\r\n    if (!handler && isModelListener) {\r\n        handler = props[(handlerName = toHandlerKey(hyphenate(event)))];\r\n    }\r\n    if (handler) {\r\n        callWithAsyncErrorHandling(handler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n    }\r\n    const onceHandler = props[handlerName + `Once`];\r\n    if (onceHandler) {\r\n        if (!instance.emitted) {\r\n            instance.emitted = {};\r\n        }\r\n        else if (instance.emitted[handlerName]) {\r\n            return;\r\n        }\r\n        instance.emitted[handlerName] = true;\r\n        callWithAsyncErrorHandling(onceHandler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n    }\r\n}\r\nfunction normalizeEmitsOptions(comp, appContext, asMixin = false) {\r\n    const cache = appContext.emitsCache;\r\n    const cached = cache.get(comp);\r\n    if (cached !== undefined) {\r\n        return cached;\r\n    }\r\n    const raw = comp.emits;\r\n    let normalized = {};\r\n    // apply mixin/extends props\r\n    let hasExtends = false;\r\n    if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n        const extendEmits = (raw) => {\r\n            const normalizedFromExtend = normalizeEmitsOptions(raw, appContext, true);\r\n            if (normalizedFromExtend) {\r\n                hasExtends = true;\r\n                extend(normalized, normalizedFromExtend);\r\n            }\r\n        };\r\n        if (!asMixin && appContext.mixins.length) {\r\n            appContext.mixins.forEach(extendEmits);\r\n        }\r\n        if (comp.extends) {\r\n            extendEmits(comp.extends);\r\n        }\r\n        if (comp.mixins) {\r\n            comp.mixins.forEach(extendEmits);\r\n        }\r\n    }\r\n    if (!raw && !hasExtends) {\r\n        cache.set(comp, null);\r\n        return null;\r\n    }\r\n    if (isArray(raw)) {\r\n        raw.forEach(key => (normalized[key] = null));\r\n    }\r\n    else {\r\n        extend(normalized, raw);\r\n    }\r\n    cache.set(comp, normalized);\r\n    return normalized;\r\n}\r\n// Check if an incoming prop key is a declared emit event listener.\r\n// e.g. With `emits: { click: null }`, props named `onClick` and `onclick` are\r\n// both considered matched listeners.\r\nfunction isEmitListener(options, key) {\r\n    if (!options || !isOn(key)) {\r\n        return false;\r\n    }\r\n    key = key.slice(2).replace(/Once$/, '');\r\n    return (hasOwn(options, key[0].toLowerCase() + key.slice(1)) ||\r\n        hasOwn(options, hyphenate(key)) ||\r\n        hasOwn(options, key));\r\n}\n\n/**\r\n * mark the current rendering instance for asset resolution (e.g.\r\n * resolveComponent, resolveDirective) during render\r\n */\r\nlet currentRenderingInstance = null;\r\nlet currentScopeId = null;\r\n/**\r\n * Note: rendering calls maybe nested. The function returns the parent rendering\r\n * instance if present, which should be restored after the render is done:\r\n *\r\n * ```js\r\n * const prev = setCurrentRenderingInstance(i)\r\n * // ...render\r\n * setCurrentRenderingInstance(prev)\r\n * ```\r\n */\r\nfunction setCurrentRenderingInstance(instance) {\r\n    const prev = currentRenderingInstance;\r\n    currentRenderingInstance = instance;\r\n    currentScopeId = (instance && instance.type.__scopeId) || null;\r\n    return prev;\r\n}\r\n/**\r\n * Set scope id when creating hoisted vnodes.\r\n * @private compiler helper\r\n */\r\nfunction pushScopeId(id) {\r\n    currentScopeId = id;\r\n}\r\n/**\r\n * Technically we no longer need this after 3.0.8 but we need to keep the same\r\n * API for backwards compat w/ code generated by compilers.\r\n * @private\r\n */\r\nfunction popScopeId() {\r\n    currentScopeId = null;\r\n}\r\n/**\r\n * Only for backwards compat\r\n * @private\r\n */\r\nconst withScopeId = (_id) => withCtx;\r\n/**\r\n * Wrap a slot function to memoize current rendering instance\r\n * @private compiler helper\r\n */\r\nfunction withCtx(fn, ctx = currentRenderingInstance, isNonScopedSlot // false only\r\n) {\r\n    if (!ctx)\r\n        return fn;\r\n    // already normalized\r\n    if (fn._n) {\r\n        return fn;\r\n    }\r\n    const renderFnWithContext = (...args) => {\r\n        // If a user calls a compiled slot inside a template expression (#1745), it\r\n        // can mess up block tracking, so by default we disable block tracking and\r\n        // force bail out when invoking a compiled slot (indicated by the ._d flag).\r\n        // This isn't necessary if rendering a compiled `<slot>`, so we flip the\r\n        // ._d flag off when invoking the wrapped fn inside `renderSlot`.\r\n        if (renderFnWithContext._d) {\r\n            setBlockTracking(-1);\r\n        }\r\n        const prevInstance = setCurrentRenderingInstance(ctx);\r\n        const res = fn(...args);\r\n        setCurrentRenderingInstance(prevInstance);\r\n        if (renderFnWithContext._d) {\r\n            setBlockTracking(1);\r\n        }\r\n        if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n            devtoolsComponentUpdated(ctx);\r\n        }\r\n        return res;\r\n    };\r\n    // mark normalized to avoid duplicated wrapping\r\n    renderFnWithContext._n = true;\r\n    // mark this as compiled by default\r\n    // this is used in vnode.ts -> normalizeChildren() to set the slot\r\n    // rendering flag.\r\n    renderFnWithContext._c = true;\r\n    // disable block tracking by default\r\n    renderFnWithContext._d = true;\r\n    return renderFnWithContext;\r\n}\n\n/**\r\n * dev only flag to track whether $attrs was used during render.\r\n * If $attrs was used during render then the warning for failed attrs\r\n * fallthrough can be suppressed.\r\n */\r\nlet accessedAttrs = false;\r\nfunction markAttrsAccessed() {\r\n    accessedAttrs = true;\r\n}\r\nfunction renderComponentRoot(instance) {\r\n    const { type: Component, vnode, proxy, withProxy, props, propsOptions: [propsOptions], slots, attrs, emit, render, renderCache, data, setupState, ctx, inheritAttrs } = instance;\r\n    let result;\r\n    let fallthroughAttrs;\r\n    const prev = setCurrentRenderingInstance(instance);\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        accessedAttrs = false;\r\n    }\r\n    try {\r\n        if (vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */) {\r\n            // withProxy is a proxy with a different `has` trap only for\r\n            // runtime-compiled render functions using `with` block.\r\n            const proxyToUse = withProxy || proxy;\r\n            result = normalizeVNode(render.call(proxyToUse, proxyToUse, renderCache, props, setupState, data, ctx));\r\n            fallthroughAttrs = attrs;\r\n        }\r\n        else {\r\n            // functional\r\n            const render = Component;\r\n            // in dev, mark attrs accessed if optional props (attrs === props)\r\n            if ((process.env.NODE_ENV !== 'production') && attrs === props) {\r\n                markAttrsAccessed();\r\n            }\r\n            result = normalizeVNode(render.length > 1\r\n                ? render(props, (process.env.NODE_ENV !== 'production')\r\n                    ? {\r\n                        get attrs() {\r\n                            markAttrsAccessed();\r\n                            return attrs;\r\n                        },\r\n                        slots,\r\n                        emit\r\n                    }\r\n                    : { attrs, slots, emit })\r\n                : render(props, null /* we know it doesn't need it */));\r\n            fallthroughAttrs = Component.props\r\n                ? attrs\r\n                : getFunctionalFallthrough(attrs);\r\n        }\r\n    }\r\n    catch (err) {\r\n        blockStack.length = 0;\r\n        handleError(err, instance, 1 /* RENDER_FUNCTION */);\r\n        result = createVNode(Comment);\r\n    }\r\n    // attr merging\r\n    // in dev mode, comments are preserved, and it's possible for a template\r\n    // to have comments along side the root element which makes it a fragment\r\n    let root = result;\r\n    let setRoot = undefined;\r\n    if ((process.env.NODE_ENV !== 'production') &&\r\n        result.patchFlag > 0 &&\r\n        result.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n        [root, setRoot] = getChildRoot(result);\r\n    }\r\n    if (fallthroughAttrs && inheritAttrs !== false) {\r\n        const keys = Object.keys(fallthroughAttrs);\r\n        const { shapeFlag } = root;\r\n        if (keys.length) {\r\n            if (shapeFlag & (1 /* ELEMENT */ | 6 /* COMPONENT */)) {\r\n                if (propsOptions && keys.some(isModelListener)) {\r\n                    // If a v-model listener (onUpdate:xxx) has a corresponding declared\r\n                    // prop, it indicates this component expects to handle v-model and\r\n                    // it should not fallthrough.\r\n                    // related: #1543, #1643, #1989\r\n                    fallthroughAttrs = filterModelListeners(fallthroughAttrs, propsOptions);\r\n                }\r\n                root = cloneVNode(root, fallthroughAttrs);\r\n            }\r\n            else if ((process.env.NODE_ENV !== 'production') && !accessedAttrs && root.type !== Comment) {\r\n                const allAttrs = Object.keys(attrs);\r\n                const eventAttrs = [];\r\n                const extraAttrs = [];\r\n                for (let i = 0, l = allAttrs.length; i < l; i++) {\r\n                    const key = allAttrs[i];\r\n                    if (isOn(key)) {\r\n                        // ignore v-model handlers when they fail to fallthrough\r\n                        if (!isModelListener(key)) {\r\n                            // remove `on`, lowercase first letter to reflect event casing\r\n                            // accurately\r\n                            eventAttrs.push(key[2].toLowerCase() + key.slice(3));\r\n                        }\r\n                    }\r\n                    else {\r\n                        extraAttrs.push(key);\r\n                    }\r\n                }\r\n                if (extraAttrs.length) {\r\n                    warn(`Extraneous non-props attributes (` +\r\n                        `${extraAttrs.join(', ')}) ` +\r\n                        `were passed to component but could not be automatically inherited ` +\r\n                        `because component renders fragment or text root nodes.`);\r\n                }\r\n                if (eventAttrs.length) {\r\n                    warn(`Extraneous non-emits event listeners (` +\r\n                        `${eventAttrs.join(', ')}) ` +\r\n                        `were passed to component but could not be automatically inherited ` +\r\n                        `because component renders fragment or text root nodes. ` +\r\n                        `If the listener is intended to be a component custom event listener only, ` +\r\n                        `declare it using the \"emits\" option.`);\r\n                }\r\n            }\r\n        }\r\n    }\r\n    // inherit directives\r\n    if (vnode.dirs) {\r\n        if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n            warn(`Runtime directive used on component with non-element root node. ` +\r\n                `The directives will not function as intended.`);\r\n        }\r\n        // clone before mutating since the root may be a hoisted vnode\r\n        root = cloneVNode(root);\r\n        root.dirs = root.dirs ? root.dirs.concat(vnode.dirs) : vnode.dirs;\r\n    }\r\n    // inherit transition data\r\n    if (vnode.transition) {\r\n        if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n            warn(`Component inside <Transition> renders non-element root node ` +\r\n                `that cannot be animated.`);\r\n        }\r\n        root.transition = vnode.transition;\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production') && setRoot) {\r\n        setRoot(root);\r\n    }\r\n    else {\r\n        result = root;\r\n    }\r\n    setCurrentRenderingInstance(prev);\r\n    return result;\r\n}\r\n/**\r\n * dev only\r\n * In dev mode, template root level comments are rendered, which turns the\r\n * template into a fragment root, but we need to locate the single element\r\n * root for attrs and scope id processing.\r\n */\r\nconst getChildRoot = (vnode) => {\r\n    const rawChildren = vnode.children;\r\n    const dynamicChildren = vnode.dynamicChildren;\r\n    const childRoot = filterSingleRoot(rawChildren);\r\n    if (!childRoot) {\r\n        return [vnode, undefined];\r\n    }\r\n    const index = rawChildren.indexOf(childRoot);\r\n    const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1;\r\n    const setRoot = (updatedRoot) => {\r\n        rawChildren[index] = updatedRoot;\r\n        if (dynamicChildren) {\r\n            if (dynamicIndex > -1) {\r\n                dynamicChildren[dynamicIndex] = updatedRoot;\r\n            }\r\n            else if (updatedRoot.patchFlag > 0) {\r\n                vnode.dynamicChildren = [...dynamicChildren, updatedRoot];\r\n            }\r\n        }\r\n    };\r\n    return [normalizeVNode(childRoot), setRoot];\r\n};\r\nfunction filterSingleRoot(children) {\r\n    let singleRoot;\r\n    for (let i = 0; i < children.length; i++) {\r\n        const child = children[i];\r\n        if (isVNode(child)) {\r\n            // ignore user comment\r\n            if (child.type !== Comment || child.children === 'v-if') {\r\n                if (singleRoot) {\r\n                    // has more than 1 non-comment child, return now\r\n                    return;\r\n                }\r\n                else {\r\n                    singleRoot = child;\r\n                }\r\n            }\r\n        }\r\n        else {\r\n            return;\r\n        }\r\n    }\r\n    return singleRoot;\r\n}\r\nconst getFunctionalFallthrough = (attrs) => {\r\n    let res;\r\n    for (const key in attrs) {\r\n        if (key === 'class' || key === 'style' || isOn(key)) {\r\n            (res || (res = {}))[key] = attrs[key];\r\n        }\r\n    }\r\n    return res;\r\n};\r\nconst filterModelListeners = (attrs, props) => {\r\n    const res = {};\r\n    for (const key in attrs) {\r\n        if (!isModelListener(key) || !(key.slice(9) in props)) {\r\n            res[key] = attrs[key];\r\n        }\r\n    }\r\n    return res;\r\n};\r\nconst isElementRoot = (vnode) => {\r\n    return (vnode.shapeFlag & (6 /* COMPONENT */ | 1 /* ELEMENT */) ||\r\n        vnode.type === Comment // potential v-if branch switch\r\n    );\r\n};\r\nfunction shouldUpdateComponent(prevVNode, nextVNode, optimized) {\r\n    const { props: prevProps, children: prevChildren, component } = prevVNode;\r\n    const { props: nextProps, children: nextChildren, patchFlag } = nextVNode;\r\n    const emits = component.emitsOptions;\r\n    // Parent component's render function was hot-updated. Since this may have\r\n    // caused the child component's slots content to have changed, we need to\r\n    // force the child to update as well.\r\n    if ((process.env.NODE_ENV !== 'production') && (prevChildren || nextChildren) && isHmrUpdating) {\r\n        return true;\r\n    }\r\n    // force child update for runtime directive or transition on component vnode.\r\n    if (nextVNode.dirs || nextVNode.transition) {\r\n        return true;\r\n    }\r\n    if (optimized && patchFlag >= 0) {\r\n        if (patchFlag & 1024 /* DYNAMIC_SLOTS */) {\r\n            // slot content that references values that might have changed,\r\n            // e.g. in a v-for\r\n            return true;\r\n        }\r\n        if (patchFlag & 16 /* FULL_PROPS */) {\r\n            if (!prevProps) {\r\n                return !!nextProps;\r\n            }\r\n            // presence of this flag indicates props are always non-null\r\n            return hasPropsChanged(prevProps, nextProps, emits);\r\n        }\r\n        else if (patchFlag & 8 /* PROPS */) {\r\n            const dynamicProps = nextVNode.dynamicProps;\r\n            for (let i = 0; i < dynamicProps.length; i++) {\r\n                const key = dynamicProps[i];\r\n                if (nextProps[key] !== prevProps[key] &&\r\n                    !isEmitListener(emits, key)) {\r\n                    return true;\r\n                }\r\n            }\r\n        }\r\n    }\r\n    else {\r\n        // this path is only taken by manually written render functions\r\n        // so presence of any children leads to a forced update\r\n        if (prevChildren || nextChildren) {\r\n            if (!nextChildren || !nextChildren.$stable) {\r\n                return true;\r\n            }\r\n        }\r\n        if (prevProps === nextProps) {\r\n            return false;\r\n        }\r\n        if (!prevProps) {\r\n            return !!nextProps;\r\n        }\r\n        if (!nextProps) {\r\n            return true;\r\n        }\r\n        return hasPropsChanged(prevProps, nextProps, emits);\r\n    }\r\n    return false;\r\n}\r\nfunction hasPropsChanged(prevProps, nextProps, emitsOptions) {\r\n    const nextKeys = Object.keys(nextProps);\r\n    if (nextKeys.length !== Object.keys(prevProps).length) {\r\n        return true;\r\n    }\r\n    for (let i = 0; i < nextKeys.length; i++) {\r\n        const key = nextKeys[i];\r\n        if (nextProps[key] !== prevProps[key] &&\r\n            !isEmitListener(emitsOptions, key)) {\r\n            return true;\r\n        }\r\n    }\r\n    return false;\r\n}\r\nfunction updateHOCHostEl({ vnode, parent }, el // HostNode\r\n) {\r\n    while (parent && parent.subTree === vnode) {\r\n        (vnode = parent.vnode).el = el;\r\n        parent = parent.parent;\r\n    }\r\n}\n\nconst isSuspense = (type) => type.__isSuspense;\r\n// Suspense exposes a component-like API, and is treated like a component\r\n// in the compiler, but internally it's a special built-in type that hooks\r\n// directly into the renderer.\r\nconst SuspenseImpl = {\r\n    name: 'Suspense',\r\n    // In order to make Suspense tree-shakable, we need to avoid importing it\r\n    // directly in the renderer. The renderer checks for the __isSuspense flag\r\n    // on a vnode's type and calls the `process` method, passing in renderer\r\n    // internals.\r\n    __isSuspense: true,\r\n    process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, \r\n    // platform-specific impl passed from renderer\r\n    rendererInternals) {\r\n        if (n1 == null) {\r\n            mountSuspense(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals);\r\n        }\r\n        else {\r\n            patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, rendererInternals);\r\n        }\r\n    },\r\n    hydrate: hydrateSuspense,\r\n    create: createSuspenseBoundary,\r\n    normalize: normalizeSuspenseChildren\r\n};\r\n// Force-casted public typing for h and TSX props inference\r\nconst Suspense = (SuspenseImpl );\r\nfunction triggerEvent(vnode, name) {\r\n    const eventListener = vnode.props && vnode.props[name];\r\n    if (isFunction(eventListener)) {\r\n        eventListener();\r\n    }\r\n}\r\nfunction mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) {\r\n    const { p: patch, o: { createElement } } = rendererInternals;\r\n    const hiddenContainer = createElement('div');\r\n    const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals));\r\n    // start mounting the content subtree in an off-dom container\r\n    patch(null, (suspense.pendingBranch = vnode.ssContent), hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds);\r\n    // now check if we have encountered any async deps\r\n    if (suspense.deps > 0) {\r\n        // has async\r\n        // invoke @fallback event\r\n        triggerEvent(vnode, 'onPending');\r\n        triggerEvent(vnode, 'onFallback');\r\n        // mount the fallback tree\r\n        patch(null, vnode.ssFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n        isSVG, slotScopeIds);\r\n        setActiveBranch(suspense, vnode.ssFallback);\r\n    }\r\n    else {\r\n        // Suspense has no async deps. Just resolve.\r\n        suspense.resolve();\r\n    }\r\n}\r\nfunction patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) {\r\n    const suspense = (n2.suspense = n1.suspense);\r\n    suspense.vnode = n2;\r\n    n2.el = n1.el;\r\n    const newBranch = n2.ssContent;\r\n    const newFallback = n2.ssFallback;\r\n    const { activeBranch, pendingBranch, isInFallback, isHydrating } = suspense;\r\n    if (pendingBranch) {\r\n        suspense.pendingBranch = newBranch;\r\n        if (isSameVNodeType(newBranch, pendingBranch)) {\r\n            // same root type but content may have changed.\r\n            patch(pendingBranch, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n            if (suspense.deps <= 0) {\r\n                suspense.resolve();\r\n            }\r\n            else if (isInFallback) {\r\n                patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n                isSVG, slotScopeIds, optimized);\r\n                setActiveBranch(suspense, newFallback);\r\n            }\r\n        }\r\n        else {\r\n            // toggled before pending tree is resolved\r\n            suspense.pendingId++;\r\n            if (isHydrating) {\r\n                // if toggled before hydration is finished, the current DOM tree is\r\n                // no longer valid. set it as the active branch so it will be unmounted\r\n                // when resolved\r\n                suspense.isHydrating = false;\r\n                suspense.activeBranch = pendingBranch;\r\n            }\r\n            else {\r\n                unmount(pendingBranch, parentComponent, suspense);\r\n            }\r\n            // increment pending ID. this is used to invalidate async callbacks\r\n            // reset suspense state\r\n            suspense.deps = 0;\r\n            // discard effects from pending branch\r\n            suspense.effects.length = 0;\r\n            // discard previous container\r\n            suspense.hiddenContainer = createElement('div');\r\n            if (isInFallback) {\r\n                // already in fallback state\r\n                patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n                if (suspense.deps <= 0) {\r\n                    suspense.resolve();\r\n                }\r\n                else {\r\n                    patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n                    isSVG, slotScopeIds, optimized);\r\n                    setActiveBranch(suspense, newFallback);\r\n                }\r\n            }\r\n            else if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n                // toggled \"back\" to current active branch\r\n                patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n                // force resolve\r\n                suspense.resolve(true);\r\n            }\r\n            else {\r\n                // switched to a 3rd branch\r\n                patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n                if (suspense.deps <= 0) {\r\n                    suspense.resolve();\r\n                }\r\n            }\r\n        }\r\n    }\r\n    else {\r\n        if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n            // root did not change, just normal patch\r\n            patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n            setActiveBranch(suspense, newBranch);\r\n        }\r\n        else {\r\n            // root node toggled\r\n            // invoke @pending event\r\n            triggerEvent(n2, 'onPending');\r\n            // mount pending branch in off-dom container\r\n            suspense.pendingBranch = newBranch;\r\n            suspense.pendingId++;\r\n            patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n            if (suspense.deps <= 0) {\r\n                // incoming branch has no async deps, resolve now.\r\n                suspense.resolve();\r\n            }\r\n            else {\r\n                const { timeout, pendingId } = suspense;\r\n                if (timeout > 0) {\r\n                    setTimeout(() => {\r\n                        if (suspense.pendingId === pendingId) {\r\n                            suspense.fallback(newFallback);\r\n                        }\r\n                    }, timeout);\r\n                }\r\n                else if (timeout === 0) {\r\n                    suspense.fallback(newFallback);\r\n                }\r\n            }\r\n        }\r\n    }\r\n}\r\nlet hasWarned = false;\r\nfunction createSuspenseBoundary(vnode, parent, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals, isHydrating = false) {\r\n    /* istanbul ignore if */\r\n    if ((process.env.NODE_ENV !== 'production') && !false && !hasWarned) {\r\n        hasWarned = true;\r\n        // @ts-ignore `console.info` cannot be null error\r\n        console[console.info ? 'info' : 'log'](`<Suspense> is an experimental feature and its API will likely change.`);\r\n    }\r\n    const { p: patch, m: move, um: unmount, n: next, o: { parentNode, remove } } = rendererInternals;\r\n    const timeout = toNumber(vnode.props && vnode.props.timeout);\r\n    const suspense = {\r\n        vnode,\r\n        parent,\r\n        parentComponent,\r\n        isSVG,\r\n        container,\r\n        hiddenContainer,\r\n        anchor,\r\n        deps: 0,\r\n        pendingId: 0,\r\n        timeout: typeof timeout === 'number' ? timeout : -1,\r\n        activeBranch: null,\r\n        pendingBranch: null,\r\n        isInFallback: true,\r\n        isHydrating,\r\n        isUnmounted: false,\r\n        effects: [],\r\n        resolve(resume = false) {\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                if (!resume && !suspense.pendingBranch) {\r\n                    throw new Error(`suspense.resolve() is called without a pending branch.`);\r\n                }\r\n                if (suspense.isUnmounted) {\r\n                    throw new Error(`suspense.resolve() is called on an already unmounted suspense boundary.`);\r\n                }\r\n            }\r\n            const { vnode, activeBranch, pendingBranch, pendingId, effects, parentComponent, container } = suspense;\r\n            if (suspense.isHydrating) {\r\n                suspense.isHydrating = false;\r\n            }\r\n            else if (!resume) {\r\n                const delayEnter = activeBranch &&\r\n                    pendingBranch.transition &&\r\n                    pendingBranch.transition.mode === 'out-in';\r\n                if (delayEnter) {\r\n                    activeBranch.transition.afterLeave = () => {\r\n                        if (pendingId === suspense.pendingId) {\r\n                            move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n                        }\r\n                    };\r\n                }\r\n                // this is initial anchor on mount\r\n                let { anchor } = suspense;\r\n                // unmount current active tree\r\n                if (activeBranch) {\r\n                    // if the fallback tree was mounted, it may have been moved\r\n                    // as part of a parent suspense. get the latest anchor for insertion\r\n                    anchor = next(activeBranch);\r\n                    unmount(activeBranch, parentComponent, suspense, true);\r\n                }\r\n                if (!delayEnter) {\r\n                    // move content from off-dom container to actual container\r\n                    move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n                }\r\n            }\r\n            setActiveBranch(suspense, pendingBranch);\r\n            suspense.pendingBranch = null;\r\n            suspense.isInFallback = false;\r\n            // flush buffered effects\r\n            // check if there is a pending parent suspense\r\n            let parent = suspense.parent;\r\n            let hasUnresolvedAncestor = false;\r\n            while (parent) {\r\n                if (parent.pendingBranch) {\r\n                    // found a pending parent suspense, merge buffered post jobs\r\n                    // into that parent\r\n                    parent.effects.push(...effects);\r\n                    hasUnresolvedAncestor = true;\r\n                    break;\r\n                }\r\n                parent = parent.parent;\r\n            }\r\n            // no pending parent suspense, flush all jobs\r\n            if (!hasUnresolvedAncestor) {\r\n                queuePostFlushCb(effects);\r\n            }\r\n            suspense.effects = [];\r\n            // invoke @resolve event\r\n            triggerEvent(vnode, 'onResolve');\r\n        },\r\n        fallback(fallbackVNode) {\r\n            if (!suspense.pendingBranch) {\r\n                return;\r\n            }\r\n            const { vnode, activeBranch, parentComponent, container, isSVG } = suspense;\r\n            // invoke @fallback event\r\n            triggerEvent(vnode, 'onFallback');\r\n            const anchor = next(activeBranch);\r\n            const mountFallback = () => {\r\n                if (!suspense.isInFallback) {\r\n                    return;\r\n                }\r\n                // mount the fallback tree\r\n                patch(null, fallbackVNode, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n                isSVG, slotScopeIds, optimized);\r\n                setActiveBranch(suspense, fallbackVNode);\r\n            };\r\n            const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === 'out-in';\r\n            if (delayEnter) {\r\n                activeBranch.transition.afterLeave = mountFallback;\r\n            }\r\n            suspense.isInFallback = true;\r\n            // unmount current active branch\r\n            unmount(activeBranch, parentComponent, null, // no suspense so unmount hooks fire now\r\n            true // shouldRemove\r\n            );\r\n            if (!delayEnter) {\r\n                mountFallback();\r\n            }\r\n        },\r\n        move(container, anchor, type) {\r\n            suspense.activeBranch &&\r\n                move(suspense.activeBranch, container, anchor, type);\r\n            suspense.container = container;\r\n        },\r\n        next() {\r\n            return suspense.activeBranch && next(suspense.activeBranch);\r\n        },\r\n        registerDep(instance, setupRenderEffect) {\r\n            const isInPendingSuspense = !!suspense.pendingBranch;\r\n            if (isInPendingSuspense) {\r\n                suspense.deps++;\r\n            }\r\n            const hydratedEl = instance.vnode.el;\r\n            instance\r\n                .asyncDep.catch(err => {\r\n                handleError(err, instance, 0 /* SETUP_FUNCTION */);\r\n            })\r\n                .then(asyncSetupResult => {\r\n                // retry when the setup() promise resolves.\r\n                // component may have been unmounted before resolve.\r\n                if (instance.isUnmounted ||\r\n                    suspense.isUnmounted ||\r\n                    suspense.pendingId !== instance.suspenseId) {\r\n                    return;\r\n                }\r\n                // retry from this component\r\n                instance.asyncResolved = true;\r\n                const { vnode } = instance;\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    pushWarningContext(vnode);\r\n                }\r\n                handleSetupResult(instance, asyncSetupResult, false);\r\n                if (hydratedEl) {\r\n                    // vnode may have been replaced if an update happened before the\r\n                    // async dep is resolved.\r\n                    vnode.el = hydratedEl;\r\n                }\r\n                const placeholder = !hydratedEl && instance.subTree.el;\r\n                setupRenderEffect(instance, vnode, \r\n                // component may have been moved before resolve.\r\n                // if this is not a hydration, instance.subTree will be the comment\r\n                // placeholder.\r\n                parentNode(hydratedEl || instance.subTree.el), \r\n                // anchor will not be used if this is hydration, so only need to\r\n                // consider the comment placeholder case.\r\n                hydratedEl ? null : next(instance.subTree), suspense, isSVG, optimized);\r\n                if (placeholder) {\r\n                    remove(placeholder);\r\n                }\r\n                updateHOCHostEl(instance, vnode.el);\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    popWarningContext();\r\n                }\r\n                // only decrease deps count if suspense is not already resolved\r\n                if (isInPendingSuspense && --suspense.deps === 0) {\r\n                    suspense.resolve();\r\n                }\r\n            });\r\n        },\r\n        unmount(parentSuspense, doRemove) {\r\n            suspense.isUnmounted = true;\r\n            if (suspense.activeBranch) {\r\n                unmount(suspense.activeBranch, parentComponent, parentSuspense, doRemove);\r\n            }\r\n            if (suspense.pendingBranch) {\r\n                unmount(suspense.pendingBranch, parentComponent, parentSuspense, doRemove);\r\n            }\r\n        }\r\n    };\r\n    return suspense;\r\n}\r\nfunction hydrateSuspense(node, vnode, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals, hydrateNode) {\r\n    /* eslint-disable no-restricted-globals */\r\n    const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, node.parentNode, document.createElement('div'), null, isSVG, slotScopeIds, optimized, rendererInternals, true /* hydrating */));\r\n    // there are two possible scenarios for server-rendered suspense:\r\n    // - success: ssr content should be fully resolved\r\n    // - failure: ssr content should be the fallback branch.\r\n    // however, on the client we don't really know if it has failed or not\r\n    // attempt to hydrate the DOM assuming it has succeeded, but we still\r\n    // need to construct a suspense boundary first\r\n    const result = hydrateNode(node, (suspense.pendingBranch = vnode.ssContent), parentComponent, suspense, slotScopeIds, optimized);\r\n    if (suspense.deps === 0) {\r\n        suspense.resolve();\r\n    }\r\n    return result;\r\n    /* eslint-enable no-restricted-globals */\r\n}\r\nfunction normalizeSuspenseChildren(vnode) {\r\n    const { shapeFlag, children } = vnode;\r\n    const isSlotChildren = shapeFlag & 32 /* SLOTS_CHILDREN */;\r\n    vnode.ssContent = normalizeSuspenseSlot(isSlotChildren ? children.default : children);\r\n    vnode.ssFallback = isSlotChildren\r\n        ? normalizeSuspenseSlot(children.fallback)\r\n        : createVNode(Comment);\r\n}\r\nfunction normalizeSuspenseSlot(s) {\r\n    let block;\r\n    if (isFunction(s)) {\r\n        const trackBlock = isBlockTreeEnabled && s._c;\r\n        if (trackBlock) {\r\n            // disableTracking: false\r\n            // allow block tracking for compiled slots\r\n            // (see ./componentRenderContext.ts)\r\n            s._d = false;\r\n            openBlock();\r\n        }\r\n        s = s();\r\n        if (trackBlock) {\r\n            s._d = true;\r\n            block = currentBlock;\r\n            closeBlock();\r\n        }\r\n    }\r\n    if (isArray(s)) {\r\n        const singleChild = filterSingleRoot(s);\r\n        if ((process.env.NODE_ENV !== 'production') && !singleChild) {\r\n            warn(`<Suspense> slots expect a single root node.`);\r\n        }\r\n        s = singleChild;\r\n    }\r\n    s = normalizeVNode(s);\r\n    if (block && !s.dynamicChildren) {\r\n        s.dynamicChildren = block.filter(c => c !== s);\r\n    }\r\n    return s;\r\n}\r\nfunction queueEffectWithSuspense(fn, suspense) {\r\n    if (suspense && suspense.pendingBranch) {\r\n        if (isArray(fn)) {\r\n            suspense.effects.push(...fn);\r\n        }\r\n        else {\r\n            suspense.effects.push(fn);\r\n        }\r\n    }\r\n    else {\r\n        queuePostFlushCb(fn);\r\n    }\r\n}\r\nfunction setActiveBranch(suspense, branch) {\r\n    suspense.activeBranch = branch;\r\n    const { vnode, parentComponent } = suspense;\r\n    const el = (vnode.el = branch.el);\r\n    // in case suspense is the root node of a component,\r\n    // recursively update the HOC el\r\n    if (parentComponent && parentComponent.subTree === vnode) {\r\n        parentComponent.vnode.el = el;\r\n        updateHOCHostEl(parentComponent, el);\r\n    }\r\n}\n\nfunction provide(key, value) {\r\n    if (!currentInstance) {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`provide() can only be used inside setup().`);\r\n        }\r\n    }\r\n    else {\r\n        let provides = currentInstance.provides;\r\n        // by default an instance inherits its parent's provides object\r\n        // but when it needs to provide values of its own, it creates its\r\n        // own provides object using parent provides object as prototype.\r\n        // this way in `inject` we can simply look up injections from direct\r\n        // parent and let the prototype chain do the work.\r\n        const parentProvides = currentInstance.parent && currentInstance.parent.provides;\r\n        if (parentProvides === provides) {\r\n            provides = currentInstance.provides = Object.create(parentProvides);\r\n        }\r\n        // TS doesn't allow symbol as index type\r\n        provides[key] = value;\r\n    }\r\n}\r\nfunction inject(key, defaultValue, treatDefaultAsFactory = false) {\r\n    // fallback to `currentRenderingInstance` so that this can be called in\r\n    // a functional component\r\n    const instance = currentInstance || currentRenderingInstance;\r\n    if (instance) {\r\n        // #2400\r\n        // to support `app.use` plugins,\r\n        // fallback to appContext's `provides` if the instance is at root\r\n        const provides = instance.parent == null\r\n            ? instance.vnode.appContext && instance.vnode.appContext.provides\r\n            : instance.parent.provides;\r\n        if (provides && key in provides) {\r\n            // TS doesn't allow symbol as index type\r\n            return provides[key];\r\n        }\r\n        else if (arguments.length > 1) {\r\n            return treatDefaultAsFactory && isFunction(defaultValue)\r\n                ? defaultValue.call(instance.proxy)\r\n                : defaultValue;\r\n        }\r\n        else if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`injection \"${String(key)}\" not found.`);\r\n        }\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        warn(`inject() can only be used inside setup() or functional components.`);\r\n    }\r\n}\n\n// Simple effect.\r\nfunction watchEffect(effect, options) {\r\n    return doWatch(effect, null, options);\r\n}\r\nfunction watchPostEffect(effect, options) {\r\n    return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n        ? Object.assign(Object.assign({}, options), { flush: 'post' }) : { flush: 'post' }));\r\n}\r\nfunction watchSyncEffect(effect, options) {\r\n    return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n        ? Object.assign(Object.assign({}, options), { flush: 'sync' }) : { flush: 'sync' }));\r\n}\r\n// initial value for watchers to trigger on undefined initial values\r\nconst INITIAL_WATCHER_VALUE = {};\r\n// implementation\r\nfunction watch(source, cb, options) {\r\n    if ((process.env.NODE_ENV !== 'production') && !isFunction(cb)) {\r\n        warn(`\\`watch(fn, options?)\\` signature has been moved to a separate API. ` +\r\n            `Use \\`watchEffect(fn, options?)\\` instead. \\`watch\\` now only ` +\r\n            `supports \\`watch(source, cb, options?) signature.`);\r\n    }\r\n    return doWatch(source, cb, options);\r\n}\r\nfunction doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EMPTY_OBJ) {\r\n    if ((process.env.NODE_ENV !== 'production') && !cb) {\r\n        if (immediate !== undefined) {\r\n            warn(`watch() \"immediate\" option is only respected when using the ` +\r\n                `watch(source, callback, options?) signature.`);\r\n        }\r\n        if (deep !== undefined) {\r\n            warn(`watch() \"deep\" option is only respected when using the ` +\r\n                `watch(source, callback, options?) signature.`);\r\n        }\r\n    }\r\n    const warnInvalidSource = (s) => {\r\n        warn(`Invalid watch source: `, s, `A watch source can only be a getter/effect function, a ref, ` +\r\n            `a reactive object, or an array of these types.`);\r\n    };\r\n    const instance = currentInstance;\r\n    let getter;\r\n    let forceTrigger = false;\r\n    let isMultiSource = false;\r\n    if (isRef(source)) {\r\n        getter = () => source.value;\r\n        forceTrigger = isShallow$1(source);\r\n    }\r\n    else if (isReactive(source)) {\r\n        getter = () => source;\r\n        deep = true;\r\n    }\r\n    else if (isArray(source)) {\r\n        isMultiSource = true;\r\n        forceTrigger = source.some(s => isReactive(s) || isShallow$1(s));\r\n        getter = () => source.map(s => {\r\n            if (isRef(s)) {\r\n                return s.value;\r\n            }\r\n            else if (isReactive(s)) {\r\n                return traverse(s);\r\n            }\r\n            else if (isFunction(s)) {\r\n                return callWithErrorHandling(s, instance, 2 /* WATCH_GETTER */);\r\n            }\r\n            else {\r\n                (process.env.NODE_ENV !== 'production') && warnInvalidSource(s);\r\n            }\r\n        });\r\n    }\r\n    else if (isFunction(source)) {\r\n        if (cb) {\r\n            // getter with cb\r\n            getter = () => callWithErrorHandling(source, instance, 2 /* WATCH_GETTER */);\r\n        }\r\n        else {\r\n            // no cb -> simple effect\r\n            getter = () => {\r\n                if (instance && instance.isUnmounted) {\r\n                    return;\r\n                }\r\n                if (cleanup) {\r\n                    cleanup();\r\n                }\r\n                return callWithAsyncErrorHandling(source, instance, 3 /* WATCH_CALLBACK */, [onCleanup]);\r\n            };\r\n        }\r\n    }\r\n    else {\r\n        getter = NOOP;\r\n        (process.env.NODE_ENV !== 'production') && warnInvalidSource(source);\r\n    }\r\n    if (cb && deep) {\r\n        const baseGetter = getter;\r\n        getter = () => traverse(baseGetter());\r\n    }\r\n    let cleanup;\r\n    let onCleanup = (fn) => {\r\n        cleanup = effect.onStop = () => {\r\n            callWithErrorHandling(fn, instance, 4 /* WATCH_CLEANUP */);\r\n        };\r\n    };\r\n    // in SSR there is no need to setup an actual effect, and it should be noop\r\n    // unless it's eager\r\n    if (isInSSRComponentSetup) {\r\n        // we will also not call the invalidate callback (+ runner is not set up)\r\n        onCleanup = NOOP;\r\n        if (!cb) {\r\n            getter();\r\n        }\r\n        else if (immediate) {\r\n            callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n                getter(),\r\n                isMultiSource ? [] : undefined,\r\n                onCleanup\r\n            ]);\r\n        }\r\n        return NOOP;\r\n    }\r\n    let oldValue = isMultiSource ? [] : INITIAL_WATCHER_VALUE;\r\n    const job = () => {\r\n        if (!effect.active) {\r\n            return;\r\n        }\r\n        if (cb) {\r\n            // watch(source, cb)\r\n            const newValue = effect.run();\r\n            if (deep ||\r\n                forceTrigger ||\r\n                (isMultiSource\r\n                    ? newValue.some((v, i) => hasChanged(v, oldValue[i]))\r\n                    : hasChanged(newValue, oldValue)) ||\r\n                (false  )) {\r\n                // cleanup before running cb again\r\n                if (cleanup) {\r\n                    cleanup();\r\n                }\r\n                callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n                    newValue,\r\n                    // pass undefined as the old value when it's changed for the first time\r\n                    oldValue === INITIAL_WATCHER_VALUE ? undefined : oldValue,\r\n                    onCleanup\r\n                ]);\r\n                oldValue = newValue;\r\n            }\r\n        }\r\n        else {\r\n            // watchEffect\r\n            effect.run();\r\n        }\r\n    };\r\n    // important: mark the job as a watcher callback so that scheduler knows\r\n    // it is allowed to self-trigger (#1727)\r\n    job.allowRecurse = !!cb;\r\n    let scheduler;\r\n    if (flush === 'sync') {\r\n        scheduler = job; // the scheduler function gets called directly\r\n    }\r\n    else if (flush === 'post') {\r\n        scheduler = () => queuePostRenderEffect(job, instance && instance.suspense);\r\n    }\r\n    else {\r\n        // default: 'pre'\r\n        scheduler = () => queuePreFlushCb(job);\r\n    }\r\n    const effect = new ReactiveEffect(getter, scheduler);\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        effect.onTrack = onTrack;\r\n        effect.onTrigger = onTrigger;\r\n    }\r\n    // initial run\r\n    if (cb) {\r\n        if (immediate) {\r\n            job();\r\n        }\r\n        else {\r\n            oldValue = effect.run();\r\n        }\r\n    }\r\n    else if (flush === 'post') {\r\n        queuePostRenderEffect(effect.run.bind(effect), instance && instance.suspense);\r\n    }\r\n    else {\r\n        effect.run();\r\n    }\r\n    return () => {\r\n        effect.stop();\r\n        if (instance && instance.scope) {\r\n            remove(instance.scope.effects, effect);\r\n        }\r\n    };\r\n}\r\n// this.$watch\r\nfunction instanceWatch(source, value, options) {\r\n    const publicThis = this.proxy;\r\n    const getter = isString(source)\r\n        ? source.includes('.')\r\n            ? createPathGetter(publicThis, source)\r\n            : () => publicThis[source]\r\n        : source.bind(publicThis, publicThis);\r\n    let cb;\r\n    if (isFunction(value)) {\r\n        cb = value;\r\n    }\r\n    else {\r\n        cb = value.handler;\r\n        options = value;\r\n    }\r\n    const cur = currentInstance;\r\n    setCurrentInstance(this);\r\n    const res = doWatch(getter, cb.bind(publicThis), options);\r\n    if (cur) {\r\n        setCurrentInstance(cur);\r\n    }\r\n    else {\r\n        unsetCurrentInstance();\r\n    }\r\n    return res;\r\n}\r\nfunction createPathGetter(ctx, path) {\r\n    const segments = path.split('.');\r\n    return () => {\r\n        let cur = ctx;\r\n        for (let i = 0; i < segments.length && cur; i++) {\r\n            cur = cur[segments[i]];\r\n        }\r\n        return cur;\r\n    };\r\n}\r\nfunction traverse(value, seen) {\r\n    if (!isObject(value) || value[\"__v_skip\" /* SKIP */]) {\r\n        return value;\r\n    }\r\n    seen = seen || new Set();\r\n    if (seen.has(value)) {\r\n        return value;\r\n    }\r\n    seen.add(value);\r\n    if (isRef(value)) {\r\n        traverse(value.value, seen);\r\n    }\r\n    else if (isArray(value)) {\r\n        for (let i = 0; i < value.length; i++) {\r\n            traverse(value[i], seen);\r\n        }\r\n    }\r\n    else if (isSet(value) || isMap(value)) {\r\n        value.forEach((v) => {\r\n            traverse(v, seen);\r\n        });\r\n    }\r\n    else if (isPlainObject(value)) {\r\n        for (const key in value) {\r\n            traverse(value[key], seen);\r\n        }\r\n    }\r\n    return value;\r\n}\n\nfunction useTransitionState() {\r\n    const state = {\r\n        isMounted: false,\r\n        isLeaving: false,\r\n        isUnmounting: false,\r\n        leavingVNodes: new Map()\r\n    };\r\n    onMounted(() => {\r\n        state.isMounted = true;\r\n    });\r\n    onBeforeUnmount(() => {\r\n        state.isUnmounting = true;\r\n    });\r\n    return state;\r\n}\r\nconst TransitionHookValidator = [Function, Array];\r\nconst BaseTransitionImpl = {\r\n    name: `BaseTransition`,\r\n    props: {\r\n        mode: String,\r\n        appear: Boolean,\r\n        persisted: Boolean,\r\n        // enter\r\n        onBeforeEnter: TransitionHookValidator,\r\n        onEnter: TransitionHookValidator,\r\n        onAfterEnter: TransitionHookValidator,\r\n        onEnterCancelled: TransitionHookValidator,\r\n        // leave\r\n        onBeforeLeave: TransitionHookValidator,\r\n        onLeave: TransitionHookValidator,\r\n        onAfterLeave: TransitionHookValidator,\r\n        onLeaveCancelled: TransitionHookValidator,\r\n        // appear\r\n        onBeforeAppear: TransitionHookValidator,\r\n        onAppear: TransitionHookValidator,\r\n        onAfterAppear: TransitionHookValidator,\r\n        onAppearCancelled: TransitionHookValidator\r\n    },\r\n    setup(props, { slots }) {\r\n        const instance = getCurrentInstance();\r\n        const state = useTransitionState();\r\n        let prevTransitionKey;\r\n        return () => {\r\n            const children = slots.default && getTransitionRawChildren(slots.default(), true);\r\n            if (!children || !children.length) {\r\n                return;\r\n            }\r\n            let child = children[0];\r\n            if (children.length > 1) {\r\n                let hasFound = false;\r\n                // locate first non-comment child\r\n                for (const c of children) {\r\n                    if (c.type !== Comment) {\r\n                        if ((process.env.NODE_ENV !== 'production') && hasFound) {\r\n                            // warn more than one non-comment child\r\n                            warn('<transition> can only be used on a single element or component. ' +\r\n                                'Use <transition-group> for lists.');\r\n                            break;\r\n                        }\r\n                        child = c;\r\n                        hasFound = true;\r\n                        if (!(process.env.NODE_ENV !== 'production'))\r\n                            break;\r\n                    }\r\n                }\r\n            }\r\n            // there's no need to track reactivity for these props so use the raw\r\n            // props for a bit better perf\r\n            const rawProps = toRaw(props);\r\n            const { mode } = rawProps;\r\n            // check mode\r\n            if ((process.env.NODE_ENV !== 'production') &&\r\n                mode &&\r\n                mode !== 'in-out' &&\r\n                mode !== 'out-in' &&\r\n                mode !== 'default') {\r\n                warn(`invalid <transition> mode: ${mode}`);\r\n            }\r\n            if (state.isLeaving) {\r\n                return emptyPlaceholder(child);\r\n            }\r\n            // in the case of <transition><keep-alive/></transition>, we need to\r\n            // compare the type of the kept-alive children.\r\n            const innerChild = getKeepAliveChild(child);\r\n            if (!innerChild) {\r\n                return emptyPlaceholder(child);\r\n            }\r\n            const enterHooks = resolveTransitionHooks(innerChild, rawProps, state, instance);\r\n            setTransitionHooks(innerChild, enterHooks);\r\n            const oldChild = instance.subTree;\r\n            const oldInnerChild = oldChild && getKeepAliveChild(oldChild);\r\n            let transitionKeyChanged = false;\r\n            const { getTransitionKey } = innerChild.type;\r\n            if (getTransitionKey) {\r\n                const key = getTransitionKey();\r\n                if (prevTransitionKey === undefined) {\r\n                    prevTransitionKey = key;\r\n                }\r\n                else if (key !== prevTransitionKey) {\r\n                    prevTransitionKey = key;\r\n                    transitionKeyChanged = true;\r\n                }\r\n            }\r\n            // handle mode\r\n            if (oldInnerChild &&\r\n                oldInnerChild.type !== Comment &&\r\n                (!isSameVNodeType(innerChild, oldInnerChild) || transitionKeyChanged)) {\r\n                const leavingHooks = resolveTransitionHooks(oldInnerChild, rawProps, state, instance);\r\n                // update old tree's hooks in case of dynamic transition\r\n                setTransitionHooks(oldInnerChild, leavingHooks);\r\n                // switching between different views\r\n                if (mode === 'out-in') {\r\n                    state.isLeaving = true;\r\n                    // return placeholder node and queue update when leave finishes\r\n                    leavingHooks.afterLeave = () => {\r\n                        state.isLeaving = false;\r\n                        instance.update();\r\n                    };\r\n                    return emptyPlaceholder(child);\r\n                }\r\n                else if (mode === 'in-out' && innerChild.type !== Comment) {\r\n                    leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {\r\n                        const leavingVNodesCache = getLeavingNodesForType(state, oldInnerChild);\r\n                        leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;\r\n                        // early removal callback\r\n                        el._leaveCb = () => {\r\n                            earlyRemove();\r\n                            el._leaveCb = undefined;\r\n                            delete enterHooks.delayedLeave;\r\n                        };\r\n                        enterHooks.delayedLeave = delayedLeave;\r\n                    };\r\n                }\r\n            }\r\n            return child;\r\n        };\r\n    }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst BaseTransition = BaseTransitionImpl;\r\nfunction getLeavingNodesForType(state, vnode) {\r\n    const { leavingVNodes } = state;\r\n    let leavingVNodesCache = leavingVNodes.get(vnode.type);\r\n    if (!leavingVNodesCache) {\r\n        leavingVNodesCache = Object.create(null);\r\n        leavingVNodes.set(vnode.type, leavingVNodesCache);\r\n    }\r\n    return leavingVNodesCache;\r\n}\r\n// The transition hooks are attached to the vnode as vnode.transition\r\n// and will be called at appropriate timing in the renderer.\r\nfunction resolveTransitionHooks(vnode, props, state, instance) {\r\n    const { appear, mode, persisted = false, onBeforeEnter, onEnter, onAfterEnter, onEnterCancelled, onBeforeLeave, onLeave, onAfterLeave, onLeaveCancelled, onBeforeAppear, onAppear, onAfterAppear, onAppearCancelled } = props;\r\n    const key = String(vnode.key);\r\n    const leavingVNodesCache = getLeavingNodesForType(state, vnode);\r\n    const callHook = (hook, args) => {\r\n        hook &&\r\n            callWithAsyncErrorHandling(hook, instance, 9 /* TRANSITION_HOOK */, args);\r\n    };\r\n    const callAsyncHook = (hook, args) => {\r\n        const done = args[1];\r\n        callHook(hook, args);\r\n        if (isArray(hook)) {\r\n            if (hook.every(hook => hook.length <= 1))\r\n                done();\r\n        }\r\n        else if (hook.length <= 1) {\r\n            done();\r\n        }\r\n    };\r\n    const hooks = {\r\n        mode,\r\n        persisted,\r\n        beforeEnter(el) {\r\n            let hook = onBeforeEnter;\r\n            if (!state.isMounted) {\r\n                if (appear) {\r\n                    hook = onBeforeAppear || onBeforeEnter;\r\n                }\r\n                else {\r\n                    return;\r\n                }\r\n            }\r\n            // for same element (v-show)\r\n            if (el._leaveCb) {\r\n                el._leaveCb(true /* cancelled */);\r\n            }\r\n            // for toggled element with same key (v-if)\r\n            const leavingVNode = leavingVNodesCache[key];\r\n            if (leavingVNode &&\r\n                isSameVNodeType(vnode, leavingVNode) &&\r\n                leavingVNode.el._leaveCb) {\r\n                // force early removal (not cancelled)\r\n                leavingVNode.el._leaveCb();\r\n            }\r\n            callHook(hook, [el]);\r\n        },\r\n        enter(el) {\r\n            let hook = onEnter;\r\n            let afterHook = onAfterEnter;\r\n            let cancelHook = onEnterCancelled;\r\n            if (!state.isMounted) {\r\n                if (appear) {\r\n                    hook = onAppear || onEnter;\r\n                    afterHook = onAfterAppear || onAfterEnter;\r\n                    cancelHook = onAppearCancelled || onEnterCancelled;\r\n                }\r\n                else {\r\n                    return;\r\n                }\r\n            }\r\n            let called = false;\r\n            const done = (el._enterCb = (cancelled) => {\r\n                if (called)\r\n                    return;\r\n                called = true;\r\n                if (cancelled) {\r\n                    callHook(cancelHook, [el]);\r\n                }\r\n                else {\r\n                    callHook(afterHook, [el]);\r\n                }\r\n                if (hooks.delayedLeave) {\r\n                    hooks.delayedLeave();\r\n                }\r\n                el._enterCb = undefined;\r\n            });\r\n            if (hook) {\r\n                callAsyncHook(hook, [el, done]);\r\n            }\r\n            else {\r\n                done();\r\n            }\r\n        },\r\n        leave(el, remove) {\r\n            const key = String(vnode.key);\r\n            if (el._enterCb) {\r\n                el._enterCb(true /* cancelled */);\r\n            }\r\n            if (state.isUnmounting) {\r\n                return remove();\r\n            }\r\n            callHook(onBeforeLeave, [el]);\r\n            let called = false;\r\n            const done = (el._leaveCb = (cancelled) => {\r\n                if (called)\r\n                    return;\r\n                called = true;\r\n                remove();\r\n                if (cancelled) {\r\n                    callHook(onLeaveCancelled, [el]);\r\n                }\r\n                else {\r\n                    callHook(onAfterLeave, [el]);\r\n                }\r\n                el._leaveCb = undefined;\r\n                if (leavingVNodesCache[key] === vnode) {\r\n                    delete leavingVNodesCache[key];\r\n                }\r\n            });\r\n            leavingVNodesCache[key] = vnode;\r\n            if (onLeave) {\r\n                callAsyncHook(onLeave, [el, done]);\r\n            }\r\n            else {\r\n                done();\r\n            }\r\n        },\r\n        clone(vnode) {\r\n            return resolveTransitionHooks(vnode, props, state, instance);\r\n        }\r\n    };\r\n    return hooks;\r\n}\r\n// the placeholder really only handles one special case: KeepAlive\r\n// in the case of a KeepAlive in a leave phase we need to return a KeepAlive\r\n// placeholder with empty content to avoid the KeepAlive instance from being\r\n// unmounted.\r\nfunction emptyPlaceholder(vnode) {\r\n    if (isKeepAlive(vnode)) {\r\n        vnode = cloneVNode(vnode);\r\n        vnode.children = null;\r\n        return vnode;\r\n    }\r\n}\r\nfunction getKeepAliveChild(vnode) {\r\n    return isKeepAlive(vnode)\r\n        ? vnode.children\r\n            ? vnode.children[0]\r\n            : undefined\r\n        : vnode;\r\n}\r\nfunction setTransitionHooks(vnode, hooks) {\r\n    if (vnode.shapeFlag & 6 /* COMPONENT */ && vnode.component) {\r\n        setTransitionHooks(vnode.component.subTree, hooks);\r\n    }\r\n    else if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n        vnode.ssContent.transition = hooks.clone(vnode.ssContent);\r\n        vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);\r\n    }\r\n    else {\r\n        vnode.transition = hooks;\r\n    }\r\n}\r\nfunction getTransitionRawChildren(children, keepComment = false, parentKey) {\r\n    let ret = [];\r\n    let keyedFragmentCount = 0;\r\n    for (let i = 0; i < children.length; i++) {\r\n        let child = children[i];\r\n        // #5360 inherit parent key in case of <template v-for>\r\n        const key = parentKey == null\r\n            ? child.key\r\n            : String(parentKey) + String(child.key != null ? child.key : i);\r\n        // handle fragment children case, e.g. v-for\r\n        if (child.type === Fragment) {\r\n            if (child.patchFlag & 128 /* KEYED_FRAGMENT */)\r\n                keyedFragmentCount++;\r\n            ret = ret.concat(getTransitionRawChildren(child.children, keepComment, key));\r\n        }\r\n        // comment placeholders should be skipped, e.g. v-if\r\n        else if (keepComment || child.type !== Comment) {\r\n            ret.push(key != null ? cloneVNode(child, { key }) : child);\r\n        }\r\n    }\r\n    // #1126 if a transition children list contains multiple sub fragments, these\r\n    // fragments will be merged into a flat children array. Since each v-for\r\n    // fragment may contain different static bindings inside, we need to de-op\r\n    // these children to force full diffs to ensure correct behavior.\r\n    if (keyedFragmentCount > 1) {\r\n        for (let i = 0; i < ret.length; i++) {\r\n            ret[i].patchFlag = -2 /* BAIL */;\r\n        }\r\n    }\r\n    return ret;\r\n}\n\n// implementation, close to no-op\r\nfunction defineComponent(options) {\r\n    return isFunction(options) ? { setup: options, name: options.name } : options;\r\n}\n\nconst isAsyncWrapper = (i) => !!i.type.__asyncLoader;\r\nfunction defineAsyncComponent(source) {\r\n    if (isFunction(source)) {\r\n        source = { loader: source };\r\n    }\r\n    const { loader, loadingComponent, errorComponent, delay = 200, timeout, // undefined = never times out\r\n    suspensible = true, onError: userOnError } = source;\r\n    let pendingRequest = null;\r\n    let resolvedComp;\r\n    let retries = 0;\r\n    const retry = () => {\r\n        retries++;\r\n        pendingRequest = null;\r\n        return load();\r\n    };\r\n    const load = () => {\r\n        let thisRequest;\r\n        return (pendingRequest ||\r\n            (thisRequest = pendingRequest =\r\n                loader()\r\n                    .catch(err => {\r\n                    err = err instanceof Error ? err : new Error(String(err));\r\n                    if (userOnError) {\r\n                        return new Promise((resolve, reject) => {\r\n                            const userRetry = () => resolve(retry());\r\n                            const userFail = () => reject(err);\r\n                            userOnError(err, userRetry, userFail, retries + 1);\r\n                        });\r\n                    }\r\n                    else {\r\n                        throw err;\r\n                    }\r\n                })\r\n                    .then((comp) => {\r\n                    if (thisRequest !== pendingRequest && pendingRequest) {\r\n                        return pendingRequest;\r\n                    }\r\n                    if ((process.env.NODE_ENV !== 'production') && !comp) {\r\n                        warn(`Async component loader resolved to undefined. ` +\r\n                            `If you are using retry(), make sure to return its return value.`);\r\n                    }\r\n                    // interop module default\r\n                    if (comp &&\r\n                        (comp.__esModule || comp[Symbol.toStringTag] === 'Module')) {\r\n                        comp = comp.default;\r\n                    }\r\n                    if ((process.env.NODE_ENV !== 'production') && comp && !isObject(comp) && !isFunction(comp)) {\r\n                        throw new Error(`Invalid async component load result: ${comp}`);\r\n                    }\r\n                    resolvedComp = comp;\r\n                    return comp;\r\n                })));\r\n    };\r\n    return defineComponent({\r\n        name: 'AsyncComponentWrapper',\r\n        __asyncLoader: load,\r\n        get __asyncResolved() {\r\n            return resolvedComp;\r\n        },\r\n        setup() {\r\n            const instance = currentInstance;\r\n            // already resolved\r\n            if (resolvedComp) {\r\n                return () => createInnerComp(resolvedComp, instance);\r\n            }\r\n            const onError = (err) => {\r\n                pendingRequest = null;\r\n                handleError(err, instance, 13 /* ASYNC_COMPONENT_LOADER */, !errorComponent /* do not throw in dev if user provided error component */);\r\n            };\r\n            // suspense-controlled or SSR.\r\n            if ((suspensible && instance.suspense) ||\r\n                (isInSSRComponentSetup)) {\r\n                return load()\r\n                    .then(comp => {\r\n                    return () => createInnerComp(comp, instance);\r\n                })\r\n                    .catch(err => {\r\n                    onError(err);\r\n                    return () => errorComponent\r\n                        ? createVNode(errorComponent, {\r\n                            error: err\r\n                        })\r\n                        : null;\r\n                });\r\n            }\r\n            const loaded = ref(false);\r\n            const error = ref();\r\n            const delayed = ref(!!delay);\r\n            if (delay) {\r\n                setTimeout(() => {\r\n                    delayed.value = false;\r\n                }, delay);\r\n            }\r\n            if (timeout != null) {\r\n                setTimeout(() => {\r\n                    if (!loaded.value && !error.value) {\r\n                        const err = new Error(`Async component timed out after ${timeout}ms.`);\r\n                        onError(err);\r\n                        error.value = err;\r\n                    }\r\n                }, timeout);\r\n            }\r\n            load()\r\n                .then(() => {\r\n                loaded.value = true;\r\n                if (instance.parent && isKeepAlive(instance.parent.vnode)) {\r\n                    // parent is keep-alive, force update so the loaded component's\r\n                    // name is taken into account\r\n                    queueJob(instance.parent.update);\r\n                }\r\n            })\r\n                .catch(err => {\r\n                onError(err);\r\n                error.value = err;\r\n            });\r\n            return () => {\r\n                if (loaded.value && resolvedComp) {\r\n                    return createInnerComp(resolvedComp, instance);\r\n                }\r\n                else if (error.value && errorComponent) {\r\n                    return createVNode(errorComponent, {\r\n                        error: error.value\r\n                    });\r\n                }\r\n                else if (loadingComponent && !delayed.value) {\r\n                    return createVNode(loadingComponent);\r\n                }\r\n            };\r\n        }\r\n    });\r\n}\r\nfunction createInnerComp(comp, { vnode: { ref, props, children, shapeFlag }, parent }) {\r\n    const vnode = createVNode(comp, props, children);\r\n    // ensure inner component inherits the async wrapper's ref owner\r\n    vnode.ref = ref;\r\n    return vnode;\r\n}\n\nconst isKeepAlive = (vnode) => vnode.type.__isKeepAlive;\r\nconst KeepAliveImpl = {\r\n    name: `KeepAlive`,\r\n    // Marker for special handling inside the renderer. We are not using a ===\r\n    // check directly on KeepAlive in the renderer, because importing it directly\r\n    // would prevent it from being tree-shaken.\r\n    __isKeepAlive: true,\r\n    props: {\r\n        include: [String, RegExp, Array],\r\n        exclude: [String, RegExp, Array],\r\n        max: [String, Number]\r\n    },\r\n    setup(props, { slots }) {\r\n        const instance = getCurrentInstance();\r\n        // KeepAlive communicates with the instantiated renderer via the\r\n        // ctx where the renderer passes in its internals,\r\n        // and the KeepAlive instance exposes activate/deactivate implementations.\r\n        // The whole point of this is to avoid importing KeepAlive directly in the\r\n        // renderer to facilitate tree-shaking.\r\n        const sharedContext = instance.ctx;\r\n        // if the internal renderer is not registered, it indicates that this is server-side rendering,\r\n        // for KeepAlive, we just need to render its children\r\n        if (!sharedContext.renderer) {\r\n            return () => {\r\n                const children = slots.default && slots.default();\r\n                return children && children.length === 1 ? children[0] : children;\r\n            };\r\n        }\r\n        const cache = new Map();\r\n        const keys = new Set();\r\n        let current = null;\r\n        if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n            instance.__v_cache = cache;\r\n        }\r\n        const parentSuspense = instance.suspense;\r\n        const { renderer: { p: patch, m: move, um: _unmount, o: { createElement } } } = sharedContext;\r\n        const storageContainer = createElement('div');\r\n        sharedContext.activate = (vnode, container, anchor, isSVG, optimized) => {\r\n            const instance = vnode.component;\r\n            move(vnode, container, anchor, 0 /* ENTER */, parentSuspense);\r\n            // in case props have changed\r\n            patch(instance.vnode, vnode, container, anchor, instance, parentSuspense, isSVG, vnode.slotScopeIds, optimized);\r\n            queuePostRenderEffect(() => {\r\n                instance.isDeactivated = false;\r\n                if (instance.a) {\r\n                    invokeArrayFns(instance.a);\r\n                }\r\n                const vnodeHook = vnode.props && vnode.props.onVnodeMounted;\r\n                if (vnodeHook) {\r\n                    invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n                }\r\n            }, parentSuspense);\r\n            if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n                // Update components tree\r\n                devtoolsComponentAdded(instance);\r\n            }\r\n        };\r\n        sharedContext.deactivate = (vnode) => {\r\n            const instance = vnode.component;\r\n            move(vnode, storageContainer, null, 1 /* LEAVE */, parentSuspense);\r\n            queuePostRenderEffect(() => {\r\n                if (instance.da) {\r\n                    invokeArrayFns(instance.da);\r\n                }\r\n                const vnodeHook = vnode.props && vnode.props.onVnodeUnmounted;\r\n                if (vnodeHook) {\r\n                    invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n                }\r\n                instance.isDeactivated = true;\r\n            }, parentSuspense);\r\n            if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n                // Update components tree\r\n                devtoolsComponentAdded(instance);\r\n            }\r\n        };\r\n        function unmount(vnode) {\r\n            // reset the shapeFlag so it can be properly unmounted\r\n            resetShapeFlag(vnode);\r\n            _unmount(vnode, instance, parentSuspense, true);\r\n        }\r\n        function pruneCache(filter) {\r\n            cache.forEach((vnode, key) => {\r\n                const name = getComponentName(vnode.type);\r\n                if (name && (!filter || !filter(name))) {\r\n                    pruneCacheEntry(key);\r\n                }\r\n            });\r\n        }\r\n        function pruneCacheEntry(key) {\r\n            const cached = cache.get(key);\r\n            if (!current || cached.type !== current.type) {\r\n                unmount(cached);\r\n            }\r\n            else if (current) {\r\n                // current active instance should no longer be kept-alive.\r\n                // we can't unmount it now but it might be later, so reset its flag now.\r\n                resetShapeFlag(current);\r\n            }\r\n            cache.delete(key);\r\n            keys.delete(key);\r\n        }\r\n        // prune cache on include/exclude prop change\r\n        watch(() => [props.include, props.exclude], ([include, exclude]) => {\r\n            include && pruneCache(name => matches(include, name));\r\n            exclude && pruneCache(name => !matches(exclude, name));\r\n        }, \r\n        // prune post-render after `current` has been updated\r\n        { flush: 'post', deep: true });\r\n        // cache sub tree after render\r\n        let pendingCacheKey = null;\r\n        const cacheSubtree = () => {\r\n            // fix #1621, the pendingCacheKey could be 0\r\n            if (pendingCacheKey != null) {\r\n                cache.set(pendingCacheKey, getInnerChild(instance.subTree));\r\n            }\r\n        };\r\n        onMounted(cacheSubtree);\r\n        onUpdated(cacheSubtree);\r\n        onBeforeUnmount(() => {\r\n            cache.forEach(cached => {\r\n                const { subTree, suspense } = instance;\r\n                const vnode = getInnerChild(subTree);\r\n                if (cached.type === vnode.type) {\r\n                    // current instance will be unmounted as part of keep-alive's unmount\r\n                    resetShapeFlag(vnode);\r\n                    // but invoke its deactivated hook here\r\n                    const da = vnode.component.da;\r\n                    da && queuePostRenderEffect(da, suspense);\r\n                    return;\r\n                }\r\n                unmount(cached);\r\n            });\r\n        });\r\n        return () => {\r\n            pendingCacheKey = null;\r\n            if (!slots.default) {\r\n                return null;\r\n            }\r\n            const children = slots.default();\r\n            const rawVNode = children[0];\r\n            if (children.length > 1) {\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn(`KeepAlive should contain exactly one component child.`);\r\n                }\r\n                current = null;\r\n                return children;\r\n            }\r\n            else if (!isVNode(rawVNode) ||\r\n                (!(rawVNode.shapeFlag & 4 /* STATEFUL_COMPONENT */) &&\r\n                    !(rawVNode.shapeFlag & 128 /* SUSPENSE */))) {\r\n                current = null;\r\n                return rawVNode;\r\n            }\r\n            let vnode = getInnerChild(rawVNode);\r\n            const comp = vnode.type;\r\n            // for async components, name check should be based in its loaded\r\n            // inner component if available\r\n            const name = getComponentName(isAsyncWrapper(vnode)\r\n                ? vnode.type.__asyncResolved || {}\r\n                : comp);\r\n            const { include, exclude, max } = props;\r\n            if ((include && (!name || !matches(include, name))) ||\r\n                (exclude && name && matches(exclude, name))) {\r\n                current = vnode;\r\n                return rawVNode;\r\n            }\r\n            const key = vnode.key == null ? comp : vnode.key;\r\n            const cachedVNode = cache.get(key);\r\n            // clone vnode if it's reused because we are going to mutate it\r\n            if (vnode.el) {\r\n                vnode = cloneVNode(vnode);\r\n                if (rawVNode.shapeFlag & 128 /* SUSPENSE */) {\r\n                    rawVNode.ssContent = vnode;\r\n                }\r\n            }\r\n            // #1513 it's possible for the returned vnode to be cloned due to attr\r\n            // fallthrough or scopeId, so the vnode here may not be the final vnode\r\n            // that is mounted. Instead of caching it directly, we store the pending\r\n            // key and cache `instance.subTree` (the normalized vnode) in\r\n            // beforeMount/beforeUpdate hooks.\r\n            pendingCacheKey = key;\r\n            if (cachedVNode) {\r\n                // copy over mounted state\r\n                vnode.el = cachedVNode.el;\r\n                vnode.component = cachedVNode.component;\r\n                if (vnode.transition) {\r\n                    // recursively update transition hooks on subTree\r\n                    setTransitionHooks(vnode, vnode.transition);\r\n                }\r\n                // avoid vnode being mounted as fresh\r\n                vnode.shapeFlag |= 512 /* COMPONENT_KEPT_ALIVE */;\r\n                // make this key the freshest\r\n                keys.delete(key);\r\n                keys.add(key);\r\n            }\r\n            else {\r\n                keys.add(key);\r\n                // prune oldest entry\r\n                if (max && keys.size > parseInt(max, 10)) {\r\n                    pruneCacheEntry(keys.values().next().value);\r\n                }\r\n            }\r\n            // avoid vnode being unmounted\r\n            vnode.shapeFlag |= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n            current = vnode;\r\n            return isSuspense(rawVNode.type) ? rawVNode : vnode;\r\n        };\r\n    }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst KeepAlive = KeepAliveImpl;\r\nfunction matches(pattern, name) {\r\n    if (isArray(pattern)) {\r\n        return pattern.some((p) => matches(p, name));\r\n    }\r\n    else if (isString(pattern)) {\r\n        return pattern.split(',').includes(name);\r\n    }\r\n    else if (pattern.test) {\r\n        return pattern.test(name);\r\n    }\r\n    /* istanbul ignore next */\r\n    return false;\r\n}\r\nfunction onActivated(hook, target) {\r\n    registerKeepAliveHook(hook, \"a\" /* ACTIVATED */, target);\r\n}\r\nfunction onDeactivated(hook, target) {\r\n    registerKeepAliveHook(hook, \"da\" /* DEACTIVATED */, target);\r\n}\r\nfunction registerKeepAliveHook(hook, type, target = currentInstance) {\r\n    // cache the deactivate branch check wrapper for injected hooks so the same\r\n    // hook can be properly deduped by the scheduler. \"__wdc\" stands for \"with\r\n    // deactivation check\".\r\n    const wrappedHook = hook.__wdc ||\r\n        (hook.__wdc = () => {\r\n            // only fire the hook if the target instance is NOT in a deactivated branch.\r\n            let current = target;\r\n            while (current) {\r\n                if (current.isDeactivated) {\r\n                    return;\r\n                }\r\n                current = current.parent;\r\n            }\r\n            return hook();\r\n        });\r\n    injectHook(type, wrappedHook, target);\r\n    // In addition to registering it on the target instance, we walk up the parent\r\n    // chain and register it on all ancestor instances that are keep-alive roots.\r\n    // This avoids the need to walk the entire component tree when invoking these\r\n    // hooks, and more importantly, avoids the need to track child components in\r\n    // arrays.\r\n    if (target) {\r\n        let current = target.parent;\r\n        while (current && current.parent) {\r\n            if (isKeepAlive(current.parent.vnode)) {\r\n                injectToKeepAliveRoot(wrappedHook, type, target, current);\r\n            }\r\n            current = current.parent;\r\n        }\r\n    }\r\n}\r\nfunction injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {\r\n    // injectHook wraps the original for error handling, so make sure to remove\r\n    // the wrapped version.\r\n    const injected = injectHook(type, hook, keepAliveRoot, true /* prepend */);\r\n    onUnmounted(() => {\r\n        remove(keepAliveRoot[type], injected);\r\n    }, target);\r\n}\r\nfunction resetShapeFlag(vnode) {\r\n    let shapeFlag = vnode.shapeFlag;\r\n    if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n        shapeFlag -= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n    }\r\n    if (shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n        shapeFlag -= 512 /* COMPONENT_KEPT_ALIVE */;\r\n    }\r\n    vnode.shapeFlag = shapeFlag;\r\n}\r\nfunction getInnerChild(vnode) {\r\n    return vnode.shapeFlag & 128 /* SUSPENSE */ ? vnode.ssContent : vnode;\r\n}\n\nfunction injectHook(type, hook, target = currentInstance, prepend = false) {\r\n    if (target) {\r\n        const hooks = target[type] || (target[type] = []);\r\n        // cache the error handling wrapper for injected hooks so the same hook\r\n        // can be properly deduped by the scheduler. \"__weh\" stands for \"with error\r\n        // handling\".\r\n        const wrappedHook = hook.__weh ||\r\n            (hook.__weh = (...args) => {\r\n                if (target.isUnmounted) {\r\n                    return;\r\n                }\r\n                // disable tracking inside all lifecycle hooks\r\n                // since they can potentially be called inside effects.\r\n                pauseTracking();\r\n                // Set currentInstance during hook invocation.\r\n                // This assumes the hook does not synchronously trigger other hooks, which\r\n                // can only be false when the user does something really funky.\r\n                setCurrentInstance(target);\r\n                const res = callWithAsyncErrorHandling(hook, target, type, args);\r\n                unsetCurrentInstance();\r\n                resetTracking();\r\n                return res;\r\n            });\r\n        if (prepend) {\r\n            hooks.unshift(wrappedHook);\r\n        }\r\n        else {\r\n            hooks.push(wrappedHook);\r\n        }\r\n        return wrappedHook;\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        const apiName = toHandlerKey(ErrorTypeStrings[type].replace(/ hook$/, ''));\r\n        warn(`${apiName} is called when there is no active component instance to be ` +\r\n            `associated with. ` +\r\n            `Lifecycle injection APIs can only be used during execution of setup().` +\r\n            (` If you are using async setup(), make sure to register lifecycle ` +\r\n                    `hooks before the first await statement.`\r\n                ));\r\n    }\r\n}\r\nconst createHook = (lifecycle) => (hook, target = currentInstance) => \r\n// post-create lifecycle registrations are noops during SSR (except for serverPrefetch)\r\n(!isInSSRComponentSetup || lifecycle === \"sp\" /* SERVER_PREFETCH */) &&\r\n    injectHook(lifecycle, hook, target);\r\nconst onBeforeMount = createHook(\"bm\" /* BEFORE_MOUNT */);\r\nconst onMounted = createHook(\"m\" /* MOUNTED */);\r\nconst onBeforeUpdate = createHook(\"bu\" /* BEFORE_UPDATE */);\r\nconst onUpdated = createHook(\"u\" /* UPDATED */);\r\nconst onBeforeUnmount = createHook(\"bum\" /* BEFORE_UNMOUNT */);\r\nconst onUnmounted = createHook(\"um\" /* UNMOUNTED */);\r\nconst onServerPrefetch = createHook(\"sp\" /* SERVER_PREFETCH */);\r\nconst onRenderTriggered = createHook(\"rtg\" /* RENDER_TRIGGERED */);\r\nconst onRenderTracked = createHook(\"rtc\" /* RENDER_TRACKED */);\r\nfunction onErrorCaptured(hook, target = currentInstance) {\r\n    injectHook(\"ec\" /* ERROR_CAPTURED */, hook, target);\r\n}\n\n/**\r\nRuntime helper for applying directives to a vnode. Example usage:\r\n\nconst comp = resolveComponent('comp')\r\nconst foo = resolveDirective('foo')\r\nconst bar = resolveDirective('bar')\r\n\nreturn withDirectives(h(comp), [\r\n  [foo, this.x],\r\n  [bar, this.y]\r\n])\r\n*/\r\nfunction validateDirectiveName(name) {\r\n    if (isBuiltInDirective(name)) {\r\n        warn('Do not use built-in directive ids as custom directive id: ' + name);\r\n    }\r\n}\r\n/**\r\n * Adds directives to a VNode.\r\n */\r\nfunction withDirectives(vnode, directives) {\r\n    const internalInstance = currentRenderingInstance;\r\n    if (internalInstance === null) {\r\n        (process.env.NODE_ENV !== 'production') && warn(`withDirectives can only be used inside render functions.`);\r\n        return vnode;\r\n    }\r\n    const instance = getExposeProxy(internalInstance) ||\r\n        internalInstance.proxy;\r\n    const bindings = vnode.dirs || (vnode.dirs = []);\r\n    for (let i = 0; i < directives.length; i++) {\r\n        let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];\r\n        if (isFunction(dir)) {\r\n            dir = {\r\n                mounted: dir,\r\n                updated: dir\r\n            };\r\n        }\r\n        if (dir.deep) {\r\n            traverse(value);\r\n        }\r\n        bindings.push({\r\n            dir,\r\n            instance,\r\n            value,\r\n            oldValue: void 0,\r\n            arg,\r\n            modifiers\r\n        });\r\n    }\r\n    return vnode;\r\n}\r\nfunction invokeDirectiveHook(vnode, prevVNode, instance, name) {\r\n    const bindings = vnode.dirs;\r\n    const oldBindings = prevVNode && prevVNode.dirs;\r\n    for (let i = 0; i < bindings.length; i++) {\r\n        const binding = bindings[i];\r\n        if (oldBindings) {\r\n            binding.oldValue = oldBindings[i].value;\r\n        }\r\n        let hook = binding.dir[name];\r\n        if (hook) {\r\n            // disable tracking inside all lifecycle hooks\r\n            // since they can potentially be called inside effects.\r\n            pauseTracking();\r\n            callWithAsyncErrorHandling(hook, instance, 8 /* DIRECTIVE_HOOK */, [\r\n                vnode.el,\r\n                binding,\r\n                vnode,\r\n                prevVNode\r\n            ]);\r\n            resetTracking();\r\n        }\r\n    }\r\n}\n\nconst COMPONENTS = 'components';\r\nconst DIRECTIVES = 'directives';\r\n/**\r\n * @private\r\n */\r\nfunction resolveComponent(name, maybeSelfReference) {\r\n    return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;\r\n}\r\nconst NULL_DYNAMIC_COMPONENT = Symbol();\r\n/**\r\n * @private\r\n */\r\nfunction resolveDynamicComponent(component) {\r\n    if (isString(component)) {\r\n        return resolveAsset(COMPONENTS, component, false) || component;\r\n    }\r\n    else {\r\n        // invalid types will fallthrough to createVNode and raise warning\r\n        return (component || NULL_DYNAMIC_COMPONENT);\r\n    }\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction resolveDirective(name) {\r\n    return resolveAsset(DIRECTIVES, name);\r\n}\r\n// implementation\r\nfunction resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {\r\n    const instance = currentRenderingInstance || currentInstance;\r\n    if (instance) {\r\n        const Component = instance.type;\r\n        // explicit self name has highest priority\r\n        if (type === COMPONENTS) {\r\n            const selfName = getComponentName(Component, false /* do not include inferred name to avoid breaking existing code */);\r\n            if (selfName &&\r\n                (selfName === name ||\r\n                    selfName === camelize(name) ||\r\n                    selfName === capitalize(camelize(name)))) {\r\n                return Component;\r\n            }\r\n        }\r\n        const res = \r\n        // local registration\r\n        // check instance[type] first which is resolved for options API\r\n        resolve(instance[type] || Component[type], name) ||\r\n            // global registration\r\n            resolve(instance.appContext[type], name);\r\n        if (!res && maybeSelfReference) {\r\n            // fallback to implicit self-reference\r\n            return Component;\r\n        }\r\n        if ((process.env.NODE_ENV !== 'production') && warnMissing && !res) {\r\n            const extra = type === COMPONENTS\r\n                ? `\\nIf this is a native custom element, make sure to exclude it from ` +\r\n                    `component resolution via compilerOptions.isCustomElement.`\r\n                : ``;\r\n            warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);\r\n        }\r\n        return res;\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        warn(`resolve${capitalize(type.slice(0, -1))} ` +\r\n            `can only be used in render() or setup().`);\r\n    }\r\n}\r\nfunction resolve(registry, name) {\r\n    return (registry &&\r\n        (registry[name] ||\r\n            registry[camelize(name)] ||\r\n            registry[capitalize(camelize(name))]));\r\n}\n\n/**\r\n * Actual implementation\r\n */\r\nfunction renderList(source, renderItem, cache, index) {\r\n    let ret;\r\n    const cached = (cache && cache[index]);\r\n    if (isArray(source) || isString(source)) {\r\n        ret = new Array(source.length);\r\n        for (let i = 0, l = source.length; i < l; i++) {\r\n            ret[i] = renderItem(source[i], i, undefined, cached && cached[i]);\r\n        }\r\n    }\r\n    else if (typeof source === 'number') {\r\n        if ((process.env.NODE_ENV !== 'production') && !Number.isInteger(source)) {\r\n            warn(`The v-for range expect an integer value but got ${source}.`);\r\n        }\r\n        ret = new Array(source);\r\n        for (let i = 0; i < source; i++) {\r\n            ret[i] = renderItem(i + 1, i, undefined, cached && cached[i]);\r\n        }\r\n    }\r\n    else if (isObject(source)) {\r\n        if (source[Symbol.iterator]) {\r\n            ret = Array.from(source, (item, i) => renderItem(item, i, undefined, cached && cached[i]));\r\n        }\r\n        else {\r\n            const keys = Object.keys(source);\r\n            ret = new Array(keys.length);\r\n            for (let i = 0, l = keys.length; i < l; i++) {\r\n                const key = keys[i];\r\n                ret[i] = renderItem(source[key], key, i, cached && cached[i]);\r\n            }\r\n        }\r\n    }\r\n    else {\r\n        ret = [];\r\n    }\r\n    if (cache) {\r\n        cache[index] = ret;\r\n    }\r\n    return ret;\r\n}\n\n/**\r\n * Compiler runtime helper for creating dynamic slots object\r\n * @private\r\n */\r\nfunction createSlots(slots, dynamicSlots) {\r\n    for (let i = 0; i < dynamicSlots.length; i++) {\r\n        const slot = dynamicSlots[i];\r\n        // array of dynamic slot generated by <template v-for=\"...\" #[...]>\r\n        if (isArray(slot)) {\r\n            for (let j = 0; j < slot.length; j++) {\r\n                slots[slot[j].name] = slot[j].fn;\r\n            }\r\n        }\r\n        else if (slot) {\r\n            // conditional single slot generated by <template v-if=\"...\" #foo>\r\n            slots[slot.name] = slot.fn;\r\n        }\r\n    }\r\n    return slots;\r\n}\n\n/**\r\n * Compiler runtime helper for rendering `<slot/>`\r\n * @private\r\n */\r\nfunction renderSlot(slots, name, props = {}, \r\n// this is not a user-facing function, so the fallback is always generated by\r\n// the compiler and guaranteed to be a function returning an array\r\nfallback, noSlotted) {\r\n    if (currentRenderingInstance.isCE ||\r\n        (currentRenderingInstance.parent &&\r\n            isAsyncWrapper(currentRenderingInstance.parent) &&\r\n            currentRenderingInstance.parent.isCE)) {\r\n        return createVNode('slot', name === 'default' ? null : { name }, fallback && fallback());\r\n    }\r\n    let slot = slots[name];\r\n    if ((process.env.NODE_ENV !== 'production') && slot && slot.length > 1) {\r\n        warn(`SSR-optimized slot function detected in a non-SSR-optimized render ` +\r\n            `function. You need to mark this component with $dynamic-slots in the ` +\r\n            `parent template.`);\r\n        slot = () => [];\r\n    }\r\n    // a compiled slot disables block tracking by default to avoid manual\r\n    // invocation interfering with template-based block tracking, but in\r\n    // `renderSlot` we can be sure that it's template-based so we can force\r\n    // enable it.\r\n    if (slot && slot._c) {\r\n        slot._d = false;\r\n    }\r\n    openBlock();\r\n    const validSlotContent = slot && ensureValidVNode(slot(props));\r\n    const rendered = createBlock(Fragment, { key: props.key || `_${name}` }, validSlotContent || (fallback ? fallback() : []), validSlotContent && slots._ === 1 /* STABLE */\r\n        ? 64 /* STABLE_FRAGMENT */\r\n        : -2 /* BAIL */);\r\n    if (!noSlotted && rendered.scopeId) {\r\n        rendered.slotScopeIds = [rendered.scopeId + '-s'];\r\n    }\r\n    if (slot && slot._c) {\r\n        slot._d = true;\r\n    }\r\n    return rendered;\r\n}\r\nfunction ensureValidVNode(vnodes) {\r\n    return vnodes.some(child => {\r\n        if (!isVNode(child))\r\n            return true;\r\n        if (child.type === Comment)\r\n            return false;\r\n        if (child.type === Fragment &&\r\n            !ensureValidVNode(child.children))\r\n            return false;\r\n        return true;\r\n    })\r\n        ? vnodes\r\n        : null;\r\n}\n\n/**\r\n * For prefixing keys in v-on=\"obj\" with \"on\"\r\n * @private\r\n */\r\nfunction toHandlers(obj) {\r\n    const ret = {};\r\n    if ((process.env.NODE_ENV !== 'production') && !isObject(obj)) {\r\n        warn(`v-on with no argument expects an object value.`);\r\n        return ret;\r\n    }\r\n    for (const key in obj) {\r\n        ret[toHandlerKey(key)] = obj[key];\r\n    }\r\n    return ret;\r\n}\n\n/**\r\n * #2437 In Vue 3, functional components do not have a public instance proxy but\r\n * they exist in the internal parent chain. For code that relies on traversing\r\n * public $parent chains, skip functional ones and go to the parent instead.\r\n */\r\nconst getPublicInstance = (i) => {\r\n    if (!i)\r\n        return null;\r\n    if (isStatefulComponent(i))\r\n        return getExposeProxy(i) || i.proxy;\r\n    return getPublicInstance(i.parent);\r\n};\r\nconst publicPropertiesMap = \r\n// Move PURE marker to new line to workaround compiler discarding it\r\n// due to type annotation\r\n/*#__PURE__*/ extend(Object.create(null), {\r\n    $: i => i,\r\n    $el: i => i.vnode.el,\r\n    $data: i => i.data,\r\n    $props: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.props) : i.props),\r\n    $attrs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.attrs) : i.attrs),\r\n    $slots: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.slots) : i.slots),\r\n    $refs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.refs) : i.refs),\r\n    $parent: i => getPublicInstance(i.parent),\r\n    $root: i => getPublicInstance(i.root),\r\n    $emit: i => i.emit,\r\n    $options: i => (__VUE_OPTIONS_API__ ? resolveMergedOptions(i) : i.type),\r\n    $forceUpdate: i => i.f || (i.f = () => queueJob(i.update)),\r\n    $nextTick: i => i.n || (i.n = nextTick.bind(i.proxy)),\r\n    $watch: i => (__VUE_OPTIONS_API__ ? instanceWatch.bind(i) : NOOP)\r\n});\r\nconst isReservedPrefix = (key) => key === '_' || key === '$';\r\nconst PublicInstanceProxyHandlers = {\r\n    get({ _: instance }, key) {\r\n        const { ctx, setupState, data, props, accessCache, type, appContext } = instance;\r\n        // for internal formatters to know that this is a Vue instance\r\n        if ((process.env.NODE_ENV !== 'production') && key === '__isVue') {\r\n            return true;\r\n        }\r\n        // prioritize <script setup> bindings during dev.\r\n        // this allows even properties that start with _ or $ to be used - so that\r\n        // it aligns with the production behavior where the render fn is inlined and\r\n        // indeed has access to all declared variables.\r\n        if ((process.env.NODE_ENV !== 'production') &&\r\n            setupState !== EMPTY_OBJ &&\r\n            setupState.__isScriptSetup &&\r\n            hasOwn(setupState, key)) {\r\n            return setupState[key];\r\n        }\r\n        // data / props / ctx\r\n        // This getter gets called for every property access on the render context\r\n        // during render and is a major hotspot. The most expensive part of this\r\n        // is the multiple hasOwn() calls. It's much faster to do a simple property\r\n        // access on a plain object, so we use an accessCache object (with null\r\n        // prototype) to memoize what access type a key corresponds to.\r\n        let normalizedProps;\r\n        if (key[0] !== '$') {\r\n            const n = accessCache[key];\r\n            if (n !== undefined) {\r\n                switch (n) {\r\n                    case 1 /* SETUP */:\r\n                        return setupState[key];\r\n                    case 2 /* DATA */:\r\n                        return data[key];\r\n                    case 4 /* CONTEXT */:\r\n                        return ctx[key];\r\n                    case 3 /* PROPS */:\r\n                        return props[key];\r\n                    // default: just fallthrough\r\n                }\r\n            }\r\n            else if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n                accessCache[key] = 1 /* SETUP */;\r\n                return setupState[key];\r\n            }\r\n            else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n                accessCache[key] = 2 /* DATA */;\r\n                return data[key];\r\n            }\r\n            else if (\r\n            // only cache other properties when instance has declared (thus stable)\r\n            // props\r\n            (normalizedProps = instance.propsOptions[0]) &&\r\n                hasOwn(normalizedProps, key)) {\r\n                accessCache[key] = 3 /* PROPS */;\r\n                return props[key];\r\n            }\r\n            else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n                accessCache[key] = 4 /* CONTEXT */;\r\n                return ctx[key];\r\n            }\r\n            else if (!__VUE_OPTIONS_API__ || shouldCacheAccess) {\r\n                accessCache[key] = 0 /* OTHER */;\r\n            }\r\n        }\r\n        const publicGetter = publicPropertiesMap[key];\r\n        let cssModule, globalProperties;\r\n        // public $xxx properties\r\n        if (publicGetter) {\r\n            if (key === '$attrs') {\r\n                track(instance, \"get\" /* GET */, key);\r\n                (process.env.NODE_ENV !== 'production') && markAttrsAccessed();\r\n            }\r\n            return publicGetter(instance);\r\n        }\r\n        else if (\r\n        // css module (injected by vue-loader)\r\n        (cssModule = type.__cssModules) &&\r\n            (cssModule = cssModule[key])) {\r\n            return cssModule;\r\n        }\r\n        else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n            // user may set custom properties to `this` that start with `$`\r\n            accessCache[key] = 4 /* CONTEXT */;\r\n            return ctx[key];\r\n        }\r\n        else if (\r\n        // global properties\r\n        ((globalProperties = appContext.config.globalProperties),\r\n            hasOwn(globalProperties, key))) {\r\n            {\r\n                return globalProperties[key];\r\n            }\r\n        }\r\n        else if ((process.env.NODE_ENV !== 'production') &&\r\n            currentRenderingInstance &&\r\n            (!isString(key) ||\r\n                // #1091 avoid internal isRef/isVNode checks on component instance leading\r\n                // to infinite warning loop\r\n                key.indexOf('__v') !== 0)) {\r\n            if (data !== EMPTY_OBJ && isReservedPrefix(key[0]) && hasOwn(data, key)) {\r\n                warn(`Property ${JSON.stringify(key)} must be accessed via $data because it starts with a reserved ` +\r\n                    `character (\"$\" or \"_\") and is not proxied on the render context.`);\r\n            }\r\n            else if (instance === currentRenderingInstance) {\r\n                warn(`Property ${JSON.stringify(key)} was accessed during render ` +\r\n                    `but is not defined on instance.`);\r\n            }\r\n        }\r\n    },\r\n    set({ _: instance }, key, value) {\r\n        const { data, setupState, ctx } = instance;\r\n        if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n            setupState[key] = value;\r\n            return true;\r\n        }\r\n        else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n            data[key] = value;\r\n            return true;\r\n        }\r\n        else if (hasOwn(instance.props, key)) {\r\n            (process.env.NODE_ENV !== 'production') &&\r\n                warn(`Attempting to mutate prop \"${key}\". Props are readonly.`, instance);\r\n            return false;\r\n        }\r\n        if (key[0] === '$' && key.slice(1) in instance) {\r\n            (process.env.NODE_ENV !== 'production') &&\r\n                warn(`Attempting to mutate public property \"${key}\". ` +\r\n                    `Properties starting with $ are reserved and readonly.`, instance);\r\n            return false;\r\n        }\r\n        else {\r\n            if ((process.env.NODE_ENV !== 'production') && key in instance.appContext.config.globalProperties) {\r\n                Object.defineProperty(ctx, key, {\r\n                    enumerable: true,\r\n                    configurable: true,\r\n                    value\r\n                });\r\n            }\r\n            else {\r\n                ctx[key] = value;\r\n            }\r\n        }\r\n        return true;\r\n    },\r\n    has({ _: { data, setupState, accessCache, ctx, appContext, propsOptions } }, key) {\r\n        let normalizedProps;\r\n        return (!!accessCache[key] ||\r\n            (data !== EMPTY_OBJ && hasOwn(data, key)) ||\r\n            (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) ||\r\n            ((normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key)) ||\r\n            hasOwn(ctx, key) ||\r\n            hasOwn(publicPropertiesMap, key) ||\r\n            hasOwn(appContext.config.globalProperties, key));\r\n    },\r\n    defineProperty(target, key, descriptor) {\r\n        if (descriptor.get != null) {\r\n            // invalidate key cache of a getter based property #5417\r\n            target._.accessCache[key] = 0;\r\n        }\r\n        else if (hasOwn(descriptor, 'value')) {\r\n            this.set(target, key, descriptor.value, null);\r\n        }\r\n        return Reflect.defineProperty(target, key, descriptor);\r\n    }\r\n};\r\nif ((process.env.NODE_ENV !== 'production') && !false) {\r\n    PublicInstanceProxyHandlers.ownKeys = (target) => {\r\n        warn(`Avoid app logic that relies on enumerating keys on a component instance. ` +\r\n            `The keys will be empty in production mode to avoid performance overhead.`);\r\n        return Reflect.ownKeys(target);\r\n    };\r\n}\r\nconst RuntimeCompiledPublicInstanceProxyHandlers = /*#__PURE__*/ extend({}, PublicInstanceProxyHandlers, {\r\n    get(target, key) {\r\n        // fast path for unscopables when using `with` block\r\n        if (key === Symbol.unscopables) {\r\n            return;\r\n        }\r\n        return PublicInstanceProxyHandlers.get(target, key, target);\r\n    },\r\n    has(_, key) {\r\n        const has = key[0] !== '_' && !isGloballyWhitelisted(key);\r\n        if ((process.env.NODE_ENV !== 'production') && !has && PublicInstanceProxyHandlers.has(_, key)) {\r\n            warn(`Property ${JSON.stringify(key)} should not start with _ which is a reserved prefix for Vue internals.`);\r\n        }\r\n        return has;\r\n    }\r\n});\r\n// dev only\r\n// In dev mode, the proxy target exposes the same properties as seen on `this`\r\n// for easier console inspection. In prod mode it will be an empty object so\r\n// these properties definitions can be skipped.\r\nfunction createDevRenderContext(instance) {\r\n    const target = {};\r\n    // expose internal instance for proxy handlers\r\n    Object.defineProperty(target, `_`, {\r\n        configurable: true,\r\n        enumerable: false,\r\n        get: () => instance\r\n    });\r\n    // expose public properties\r\n    Object.keys(publicPropertiesMap).forEach(key => {\r\n        Object.defineProperty(target, key, {\r\n            configurable: true,\r\n            enumerable: false,\r\n            get: () => publicPropertiesMap[key](instance),\r\n            // intercepted by the proxy so no need for implementation,\r\n            // but needed to prevent set errors\r\n            set: NOOP\r\n        });\r\n    });\r\n    return target;\r\n}\r\n// dev only\r\nfunction exposePropsOnRenderContext(instance) {\r\n    const { ctx, propsOptions: [propsOptions] } = instance;\r\n    if (propsOptions) {\r\n        Object.keys(propsOptions).forEach(key => {\r\n            Object.defineProperty(ctx, key, {\r\n                enumerable: true,\r\n                configurable: true,\r\n                get: () => instance.props[key],\r\n                set: NOOP\r\n            });\r\n        });\r\n    }\r\n}\r\n// dev only\r\nfunction exposeSetupStateOnRenderContext(instance) {\r\n    const { ctx, setupState } = instance;\r\n    Object.keys(toRaw(setupState)).forEach(key => {\r\n        if (!setupState.__isScriptSetup) {\r\n            if (isReservedPrefix(key[0])) {\r\n                warn(`setup() return property ${JSON.stringify(key)} should not start with \"$\" or \"_\" ` +\r\n                    `which are reserved prefixes for Vue internals.`);\r\n                return;\r\n            }\r\n            Object.defineProperty(ctx, key, {\r\n                enumerable: true,\r\n                configurable: true,\r\n                get: () => setupState[key],\r\n                set: NOOP\r\n            });\r\n        }\r\n    });\r\n}\n\nfunction createDuplicateChecker() {\r\n    const cache = Object.create(null);\r\n    return (type, key) => {\r\n        if (cache[key]) {\r\n            warn(`${type} property \"${key}\" is already defined in ${cache[key]}.`);\r\n        }\r\n        else {\r\n            cache[key] = type;\r\n        }\r\n    };\r\n}\r\nlet shouldCacheAccess = true;\r\nfunction applyOptions(instance) {\r\n    const options = resolveMergedOptions(instance);\r\n    const publicThis = instance.proxy;\r\n    const ctx = instance.ctx;\r\n    // do not cache property access on public proxy during state initialization\r\n    shouldCacheAccess = false;\r\n    // call beforeCreate first before accessing other options since\r\n    // the hook may mutate resolved options (#2791)\r\n    if (options.beforeCreate) {\r\n        callHook(options.beforeCreate, instance, \"bc\" /* BEFORE_CREATE */);\r\n    }\r\n    const { \r\n    // state\r\n    data: dataOptions, computed: computedOptions, methods, watch: watchOptions, provide: provideOptions, inject: injectOptions, \r\n    // lifecycle\r\n    created, beforeMount, mounted, beforeUpdate, updated, activated, deactivated, beforeDestroy, beforeUnmount, destroyed, unmounted, render, renderTracked, renderTriggered, errorCaptured, serverPrefetch, \r\n    // public API\r\n    expose, inheritAttrs, \r\n    // assets\r\n    components, directives, filters } = options;\r\n    const checkDuplicateProperties = (process.env.NODE_ENV !== 'production') ? createDuplicateChecker() : null;\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        const [propsOptions] = instance.propsOptions;\r\n        if (propsOptions) {\r\n            for (const key in propsOptions) {\r\n                checkDuplicateProperties(\"Props\" /* PROPS */, key);\r\n            }\r\n        }\r\n    }\r\n    // options initialization order (to be consistent with Vue 2):\r\n    // - props (already done outside of this function)\r\n    // - inject\r\n    // - methods\r\n    // - data (deferred since it relies on `this` access)\r\n    // - computed\r\n    // - watch (deferred since it relies on `this` access)\r\n    if (injectOptions) {\r\n        resolveInjections(injectOptions, ctx, checkDuplicateProperties, instance.appContext.config.unwrapInjectedRef);\r\n    }\r\n    if (methods) {\r\n        for (const key in methods) {\r\n            const methodHandler = methods[key];\r\n            if (isFunction(methodHandler)) {\r\n                // In dev mode, we use the `createRenderContext` function to define\r\n                // methods to the proxy target, and those are read-only but\r\n                // reconfigurable, so it needs to be redefined here\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    Object.defineProperty(ctx, key, {\r\n                        value: methodHandler.bind(publicThis),\r\n                        configurable: true,\r\n                        enumerable: true,\r\n                        writable: true\r\n                    });\r\n                }\r\n                else {\r\n                    ctx[key] = methodHandler.bind(publicThis);\r\n                }\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    checkDuplicateProperties(\"Methods\" /* METHODS */, key);\r\n                }\r\n            }\r\n            else if ((process.env.NODE_ENV !== 'production')) {\r\n                warn(`Method \"${key}\" has type \"${typeof methodHandler}\" in the component definition. ` +\r\n                    `Did you reference the function correctly?`);\r\n            }\r\n        }\r\n    }\r\n    if (dataOptions) {\r\n        if ((process.env.NODE_ENV !== 'production') && !isFunction(dataOptions)) {\r\n            warn(`The data option must be a function. ` +\r\n                `Plain object usage is no longer supported.`);\r\n        }\r\n        const data = dataOptions.call(publicThis, publicThis);\r\n        if ((process.env.NODE_ENV !== 'production') && isPromise(data)) {\r\n            warn(`data() returned a Promise - note data() cannot be async; If you ` +\r\n                `intend to perform data fetching before component renders, use ` +\r\n                `async setup() + <Suspense>.`);\r\n        }\r\n        if (!isObject(data)) {\r\n            (process.env.NODE_ENV !== 'production') && warn(`data() should return an object.`);\r\n        }\r\n        else {\r\n            instance.data = reactive(data);\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                for (const key in data) {\r\n                    checkDuplicateProperties(\"Data\" /* DATA */, key);\r\n                    // expose data on ctx during dev\r\n                    if (!isReservedPrefix(key[0])) {\r\n                        Object.defineProperty(ctx, key, {\r\n                            configurable: true,\r\n                            enumerable: true,\r\n                            get: () => data[key],\r\n                            set: NOOP\r\n                        });\r\n                    }\r\n                }\r\n            }\r\n        }\r\n    }\r\n    // state initialization complete at this point - start caching access\r\n    shouldCacheAccess = true;\r\n    if (computedOptions) {\r\n        for (const key in computedOptions) {\r\n            const opt = computedOptions[key];\r\n            const get = isFunction(opt)\r\n                ? opt.bind(publicThis, publicThis)\r\n                : isFunction(opt.get)\r\n                    ? opt.get.bind(publicThis, publicThis)\r\n                    : NOOP;\r\n            if ((process.env.NODE_ENV !== 'production') && get === NOOP) {\r\n                warn(`Computed property \"${key}\" has no getter.`);\r\n            }\r\n            const set = !isFunction(opt) && isFunction(opt.set)\r\n                ? opt.set.bind(publicThis)\r\n                : (process.env.NODE_ENV !== 'production')\r\n                    ? () => {\r\n                        warn(`Write operation failed: computed property \"${key}\" is readonly.`);\r\n                    }\r\n                    : NOOP;\r\n            const c = computed({\r\n                get,\r\n                set\r\n            });\r\n            Object.defineProperty(ctx, key, {\r\n                enumerable: true,\r\n                configurable: true,\r\n                get: () => c.value,\r\n                set: v => (c.value = v)\r\n            });\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                checkDuplicateProperties(\"Computed\" /* COMPUTED */, key);\r\n            }\r\n        }\r\n    }\r\n    if (watchOptions) {\r\n        for (const key in watchOptions) {\r\n            createWatcher(watchOptions[key], ctx, publicThis, key);\r\n        }\r\n    }\r\n    if (provideOptions) {\r\n        const provides = isFunction(provideOptions)\r\n            ? provideOptions.call(publicThis)\r\n            : provideOptions;\r\n        Reflect.ownKeys(provides).forEach(key => {\r\n            provide(key, provides[key]);\r\n        });\r\n    }\r\n    if (created) {\r\n        callHook(created, instance, \"c\" /* CREATED */);\r\n    }\r\n    function registerLifecycleHook(register, hook) {\r\n        if (isArray(hook)) {\r\n            hook.forEach(_hook => register(_hook.bind(publicThis)));\r\n        }\r\n        else if (hook) {\r\n            register(hook.bind(publicThis));\r\n        }\r\n    }\r\n    registerLifecycleHook(onBeforeMount, beforeMount);\r\n    registerLifecycleHook(onMounted, mounted);\r\n    registerLifecycleHook(onBeforeUpdate, beforeUpdate);\r\n    registerLifecycleHook(onUpdated, updated);\r\n    registerLifecycleHook(onActivated, activated);\r\n    registerLifecycleHook(onDeactivated, deactivated);\r\n    registerLifecycleHook(onErrorCaptured, errorCaptured);\r\n    registerLifecycleHook(onRenderTracked, renderTracked);\r\n    registerLifecycleHook(onRenderTriggered, renderTriggered);\r\n    registerLifecycleHook(onBeforeUnmount, beforeUnmount);\r\n    registerLifecycleHook(onUnmounted, unmounted);\r\n    registerLifecycleHook(onServerPrefetch, serverPrefetch);\r\n    if (isArray(expose)) {\r\n        if (expose.length) {\r\n            const exposed = instance.exposed || (instance.exposed = {});\r\n            expose.forEach(key => {\r\n                Object.defineProperty(exposed, key, {\r\n                    get: () => publicThis[key],\r\n                    set: val => (publicThis[key] = val)\r\n                });\r\n            });\r\n        }\r\n        else if (!instance.exposed) {\r\n            instance.exposed = {};\r\n        }\r\n    }\r\n    // options that are handled when creating the instance but also need to be\r\n    // applied from mixins\r\n    if (render && instance.render === NOOP) {\r\n        instance.render = render;\r\n    }\r\n    if (inheritAttrs != null) {\r\n        instance.inheritAttrs = inheritAttrs;\r\n    }\r\n    // asset options.\r\n    if (components)\r\n        instance.components = components;\r\n    if (directives)\r\n        instance.directives = directives;\r\n}\r\nfunction resolveInjections(injectOptions, ctx, checkDuplicateProperties = NOOP, unwrapRef = false) {\r\n    if (isArray(injectOptions)) {\r\n        injectOptions = normalizeInject(injectOptions);\r\n    }\r\n    for (const key in injectOptions) {\r\n        const opt = injectOptions[key];\r\n        let injected;\r\n        if (isObject(opt)) {\r\n            if ('default' in opt) {\r\n                injected = inject(opt.from || key, opt.default, true /* treat default function as factory */);\r\n            }\r\n            else {\r\n                injected = inject(opt.from || key);\r\n            }\r\n        }\r\n        else {\r\n            injected = inject(opt);\r\n        }\r\n        if (isRef(injected)) {\r\n            // TODO remove the check in 3.3\r\n            if (unwrapRef) {\r\n                Object.defineProperty(ctx, key, {\r\n                    enumerable: true,\r\n                    configurable: true,\r\n                    get: () => injected.value,\r\n                    set: v => (injected.value = v)\r\n                });\r\n            }\r\n            else {\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn(`injected property \"${key}\" is a ref and will be auto-unwrapped ` +\r\n                        `and no longer needs \\`.value\\` in the next minor release. ` +\r\n                        `To opt-in to the new behavior now, ` +\r\n                        `set \\`app.config.unwrapInjectedRef = true\\` (this config is ` +\r\n                        `temporary and will not be needed in the future.)`);\r\n                }\r\n                ctx[key] = injected;\r\n            }\r\n        }\r\n        else {\r\n            ctx[key] = injected;\r\n        }\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            checkDuplicateProperties(\"Inject\" /* INJECT */, key);\r\n        }\r\n    }\r\n}\r\nfunction callHook(hook, instance, type) {\r\n    callWithAsyncErrorHandling(isArray(hook)\r\n        ? hook.map(h => h.bind(instance.proxy))\r\n        : hook.bind(instance.proxy), instance, type);\r\n}\r\nfunction createWatcher(raw, ctx, publicThis, key) {\r\n    const getter = key.includes('.')\r\n        ? createPathGetter(publicThis, key)\r\n        : () => publicThis[key];\r\n    if (isString(raw)) {\r\n        const handler = ctx[raw];\r\n        if (isFunction(handler)) {\r\n            watch(getter, handler);\r\n        }\r\n        else if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`Invalid watch handler specified by key \"${raw}\"`, handler);\r\n        }\r\n    }\r\n    else if (isFunction(raw)) {\r\n        watch(getter, raw.bind(publicThis));\r\n    }\r\n    else if (isObject(raw)) {\r\n        if (isArray(raw)) {\r\n            raw.forEach(r => createWatcher(r, ctx, publicThis, key));\r\n        }\r\n        else {\r\n            const handler = isFunction(raw.handler)\r\n                ? raw.handler.bind(publicThis)\r\n                : ctx[raw.handler];\r\n            if (isFunction(handler)) {\r\n                watch(getter, handler, raw);\r\n            }\r\n            else if ((process.env.NODE_ENV !== 'production')) {\r\n                warn(`Invalid watch handler specified by key \"${raw.handler}\"`, handler);\r\n            }\r\n        }\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        warn(`Invalid watch option: \"${key}\"`, raw);\r\n    }\r\n}\r\n/**\r\n * Resolve merged options and cache it on the component.\r\n * This is done only once per-component since the merging does not involve\r\n * instances.\r\n */\r\nfunction resolveMergedOptions(instance) {\r\n    const base = instance.type;\r\n    const { mixins, extends: extendsOptions } = base;\r\n    const { mixins: globalMixins, optionsCache: cache, config: { optionMergeStrategies } } = instance.appContext;\r\n    const cached = cache.get(base);\r\n    let resolved;\r\n    if (cached) {\r\n        resolved = cached;\r\n    }\r\n    else if (!globalMixins.length && !mixins && !extendsOptions) {\r\n        {\r\n            resolved = base;\r\n        }\r\n    }\r\n    else {\r\n        resolved = {};\r\n        if (globalMixins.length) {\r\n            globalMixins.forEach(m => mergeOptions(resolved, m, optionMergeStrategies, true));\r\n        }\r\n        mergeOptions(resolved, base, optionMergeStrategies);\r\n    }\r\n    cache.set(base, resolved);\r\n    return resolved;\r\n}\r\nfunction mergeOptions(to, from, strats, asMixin = false) {\r\n    const { mixins, extends: extendsOptions } = from;\r\n    if (extendsOptions) {\r\n        mergeOptions(to, extendsOptions, strats, true);\r\n    }\r\n    if (mixins) {\r\n        mixins.forEach((m) => mergeOptions(to, m, strats, true));\r\n    }\r\n    for (const key in from) {\r\n        if (asMixin && key === 'expose') {\r\n            (process.env.NODE_ENV !== 'production') &&\r\n                warn(`\"expose\" option is ignored when declared in mixins or extends. ` +\r\n                    `It should only be declared in the base component itself.`);\r\n        }\r\n        else {\r\n            const strat = internalOptionMergeStrats[key] || (strats && strats[key]);\r\n            to[key] = strat ? strat(to[key], from[key]) : from[key];\r\n        }\r\n    }\r\n    return to;\r\n}\r\nconst internalOptionMergeStrats = {\r\n    data: mergeDataFn,\r\n    props: mergeObjectOptions,\r\n    emits: mergeObjectOptions,\r\n    // objects\r\n    methods: mergeObjectOptions,\r\n    computed: mergeObjectOptions,\r\n    // lifecycle\r\n    beforeCreate: mergeAsArray,\r\n    created: mergeAsArray,\r\n    beforeMount: mergeAsArray,\r\n    mounted: mergeAsArray,\r\n    beforeUpdate: mergeAsArray,\r\n    updated: mergeAsArray,\r\n    beforeDestroy: mergeAsArray,\r\n    beforeUnmount: mergeAsArray,\r\n    destroyed: mergeAsArray,\r\n    unmounted: mergeAsArray,\r\n    activated: mergeAsArray,\r\n    deactivated: mergeAsArray,\r\n    errorCaptured: mergeAsArray,\r\n    serverPrefetch: mergeAsArray,\r\n    // assets\r\n    components: mergeObjectOptions,\r\n    directives: mergeObjectOptions,\r\n    // watch\r\n    watch: mergeWatchOptions,\r\n    // provide / inject\r\n    provide: mergeDataFn,\r\n    inject: mergeInject\r\n};\r\nfunction mergeDataFn(to, from) {\r\n    if (!from) {\r\n        return to;\r\n    }\r\n    if (!to) {\r\n        return from;\r\n    }\r\n    return function mergedDataFn() {\r\n        return (extend)(isFunction(to) ? to.call(this, this) : to, isFunction(from) ? from.call(this, this) : from);\r\n    };\r\n}\r\nfunction mergeInject(to, from) {\r\n    return mergeObjectOptions(normalizeInject(to), normalizeInject(from));\r\n}\r\nfunction normalizeInject(raw) {\r\n    if (isArray(raw)) {\r\n        const res = {};\r\n        for (let i = 0; i < raw.length; i++) {\r\n            res[raw[i]] = raw[i];\r\n        }\r\n        return res;\r\n    }\r\n    return raw;\r\n}\r\nfunction mergeAsArray(to, from) {\r\n    return to ? [...new Set([].concat(to, from))] : from;\r\n}\r\nfunction mergeObjectOptions(to, from) {\r\n    return to ? extend(extend(Object.create(null), to), from) : from;\r\n}\r\nfunction mergeWatchOptions(to, from) {\r\n    if (!to)\r\n        return from;\r\n    if (!from)\r\n        return to;\r\n    const merged = extend(Object.create(null), to);\r\n    for (const key in from) {\r\n        merged[key] = mergeAsArray(to[key], from[key]);\r\n    }\r\n    return merged;\r\n}\n\nfunction initProps(instance, rawProps, isStateful, // result of bitwise flag comparison\r\nisSSR = false) {\r\n    const props = {};\r\n    const attrs = {};\r\n    def(attrs, InternalObjectKey, 1);\r\n    instance.propsDefaults = Object.create(null);\r\n    setFullProps(instance, rawProps, props, attrs);\r\n    // ensure all declared prop keys are present\r\n    for (const key in instance.propsOptions[0]) {\r\n        if (!(key in props)) {\r\n            props[key] = undefined;\r\n        }\r\n    }\r\n    // validation\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        validateProps(rawProps || {}, props, instance);\r\n    }\r\n    if (isStateful) {\r\n        // stateful\r\n        instance.props = isSSR ? props : shallowReactive(props);\r\n    }\r\n    else {\r\n        if (!instance.type.props) {\r\n            // functional w/ optional props, props === attrs\r\n            instance.props = attrs;\r\n        }\r\n        else {\r\n            // functional w/ declared props\r\n            instance.props = props;\r\n        }\r\n    }\r\n    instance.attrs = attrs;\r\n}\r\nfunction updateProps(instance, rawProps, rawPrevProps, optimized) {\r\n    const { props, attrs, vnode: { patchFlag } } = instance;\r\n    const rawCurrentProps = toRaw(props);\r\n    const [options] = instance.propsOptions;\r\n    let hasAttrsChanged = false;\r\n    if (\r\n    // always force full diff in dev\r\n    // - #1942 if hmr is enabled with sfc component\r\n    // - vite#872 non-sfc component used by sfc component\r\n    !((process.env.NODE_ENV !== 'production') &&\r\n        (instance.type.__hmrId ||\r\n            (instance.parent && instance.parent.type.__hmrId))) &&\r\n        (optimized || patchFlag > 0) &&\r\n        !(patchFlag & 16 /* FULL_PROPS */)) {\r\n        if (patchFlag & 8 /* PROPS */) {\r\n            // Compiler-generated props & no keys change, just set the updated\r\n            // the props.\r\n            const propsToUpdate = instance.vnode.dynamicProps;\r\n            for (let i = 0; i < propsToUpdate.length; i++) {\r\n                let key = propsToUpdate[i];\r\n                // skip if the prop key is a declared emit event listener\r\n                if (isEmitListener(instance.emitsOptions, key)) {\r\n                    continue;\r\n                }\r\n                // PROPS flag guarantees rawProps to be non-null\r\n                const value = rawProps[key];\r\n                if (options) {\r\n                    // attr / props separation was done on init and will be consistent\r\n                    // in this code path, so just check if attrs have it.\r\n                    if (hasOwn(attrs, key)) {\r\n                        if (value !== attrs[key]) {\r\n                            attrs[key] = value;\r\n                            hasAttrsChanged = true;\r\n                        }\r\n                    }\r\n                    else {\r\n                        const camelizedKey = camelize(key);\r\n                        props[camelizedKey] = resolvePropValue(options, rawCurrentProps, camelizedKey, value, instance, false /* isAbsent */);\r\n                    }\r\n                }\r\n                else {\r\n                    if (value !== attrs[key]) {\r\n                        attrs[key] = value;\r\n                        hasAttrsChanged = true;\r\n                    }\r\n                }\r\n            }\r\n        }\r\n    }\r\n    else {\r\n        // full props update.\r\n        if (setFullProps(instance, rawProps, props, attrs)) {\r\n            hasAttrsChanged = true;\r\n        }\r\n        // in case of dynamic props, check if we need to delete keys from\r\n        // the props object\r\n        let kebabKey;\r\n        for (const key in rawCurrentProps) {\r\n            if (!rawProps ||\r\n                // for camelCase\r\n                (!hasOwn(rawProps, key) &&\r\n                    // it's possible the original props was passed in as kebab-case\r\n                    // and converted to camelCase (#955)\r\n                    ((kebabKey = hyphenate(key)) === key || !hasOwn(rawProps, kebabKey)))) {\r\n                if (options) {\r\n                    if (rawPrevProps &&\r\n                        // for camelCase\r\n                        (rawPrevProps[key] !== undefined ||\r\n                            // for kebab-case\r\n                            rawPrevProps[kebabKey] !== undefined)) {\r\n                        props[key] = resolvePropValue(options, rawCurrentProps, key, undefined, instance, true /* isAbsent */);\r\n                    }\r\n                }\r\n                else {\r\n                    delete props[key];\r\n                }\r\n            }\r\n        }\r\n        // in the case of functional component w/o props declaration, props and\r\n        // attrs point to the same object so it should already have been updated.\r\n        if (attrs !== rawCurrentProps) {\r\n            for (const key in attrs) {\r\n                if (!rawProps ||\r\n                    (!hasOwn(rawProps, key) &&\r\n                        (!false ))) {\r\n                    delete attrs[key];\r\n                    hasAttrsChanged = true;\r\n                }\r\n            }\r\n        }\r\n    }\r\n    // trigger updates for $attrs in case it's used in component slots\r\n    if (hasAttrsChanged) {\r\n        trigger(instance, \"set\" /* SET */, '$attrs');\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        validateProps(rawProps || {}, props, instance);\r\n    }\r\n}\r\nfunction setFullProps(instance, rawProps, props, attrs) {\r\n    const [options, needCastKeys] = instance.propsOptions;\r\n    let hasAttrsChanged = false;\r\n    let rawCastValues;\r\n    if (rawProps) {\r\n        for (let key in rawProps) {\r\n            // key, ref are reserved and never passed down\r\n            if (isReservedProp(key)) {\r\n                continue;\r\n            }\r\n            const value = rawProps[key];\r\n            // prop option names are camelized during normalization, so to support\r\n            // kebab -> camel conversion here we need to camelize the key.\r\n            let camelKey;\r\n            if (options && hasOwn(options, (camelKey = camelize(key)))) {\r\n                if (!needCastKeys || !needCastKeys.includes(camelKey)) {\r\n                    props[camelKey] = value;\r\n                }\r\n                else {\r\n                    (rawCastValues || (rawCastValues = {}))[camelKey] = value;\r\n                }\r\n            }\r\n            else if (!isEmitListener(instance.emitsOptions, key)) {\r\n                if (!(key in attrs) || value !== attrs[key]) {\r\n                    attrs[key] = value;\r\n                    hasAttrsChanged = true;\r\n                }\r\n            }\r\n        }\r\n    }\r\n    if (needCastKeys) {\r\n        const rawCurrentProps = toRaw(props);\r\n        const castValues = rawCastValues || EMPTY_OBJ;\r\n        for (let i = 0; i < needCastKeys.length; i++) {\r\n            const key = needCastKeys[i];\r\n            props[key] = resolvePropValue(options, rawCurrentProps, key, castValues[key], instance, !hasOwn(castValues, key));\r\n        }\r\n    }\r\n    return hasAttrsChanged;\r\n}\r\nfunction resolvePropValue(options, props, key, value, instance, isAbsent) {\r\n    const opt = options[key];\r\n    if (opt != null) {\r\n        const hasDefault = hasOwn(opt, 'default');\r\n        // default values\r\n        if (hasDefault && value === undefined) {\r\n            const defaultValue = opt.default;\r\n            if (opt.type !== Function && isFunction(defaultValue)) {\r\n                const { propsDefaults } = instance;\r\n                if (key in propsDefaults) {\r\n                    value = propsDefaults[key];\r\n                }\r\n                else {\r\n                    setCurrentInstance(instance);\r\n                    value = propsDefaults[key] = defaultValue.call(null, props);\r\n                    unsetCurrentInstance();\r\n                }\r\n            }\r\n            else {\r\n                value = defaultValue;\r\n            }\r\n        }\r\n        // boolean casting\r\n        if (opt[0 /* shouldCast */]) {\r\n            if (isAbsent && !hasDefault) {\r\n                value = false;\r\n            }\r\n            else if (opt[1 /* shouldCastTrue */] &&\r\n                (value === '' || value === hyphenate(key))) {\r\n                value = true;\r\n            }\r\n        }\r\n    }\r\n    return value;\r\n}\r\nfunction normalizePropsOptions(comp, appContext, asMixin = false) {\r\n    const cache = appContext.propsCache;\r\n    const cached = cache.get(comp);\r\n    if (cached) {\r\n        return cached;\r\n    }\r\n    const raw = comp.props;\r\n    const normalized = {};\r\n    const needCastKeys = [];\r\n    // apply mixin/extends props\r\n    let hasExtends = false;\r\n    if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n        const extendProps = (raw) => {\r\n            hasExtends = true;\r\n            const [props, keys] = normalizePropsOptions(raw, appContext, true);\r\n            extend(normalized, props);\r\n            if (keys)\r\n                needCastKeys.push(...keys);\r\n        };\r\n        if (!asMixin && appContext.mixins.length) {\r\n            appContext.mixins.forEach(extendProps);\r\n        }\r\n        if (comp.extends) {\r\n            extendProps(comp.extends);\r\n        }\r\n        if (comp.mixins) {\r\n            comp.mixins.forEach(extendProps);\r\n        }\r\n    }\r\n    if (!raw && !hasExtends) {\r\n        cache.set(comp, EMPTY_ARR);\r\n        return EMPTY_ARR;\r\n    }\r\n    if (isArray(raw)) {\r\n        for (let i = 0; i < raw.length; i++) {\r\n            if ((process.env.NODE_ENV !== 'production') && !isString(raw[i])) {\r\n                warn(`props must be strings when using array syntax.`, raw[i]);\r\n            }\r\n            const normalizedKey = camelize(raw[i]);\r\n            if (validatePropName(normalizedKey)) {\r\n                normalized[normalizedKey] = EMPTY_OBJ;\r\n            }\r\n        }\r\n    }\r\n    else if (raw) {\r\n        if ((process.env.NODE_ENV !== 'production') && !isObject(raw)) {\r\n            warn(`invalid props options`, raw);\r\n        }\r\n        for (const key in raw) {\r\n            const normalizedKey = camelize(key);\r\n            if (validatePropName(normalizedKey)) {\r\n                const opt = raw[key];\r\n                const prop = (normalized[normalizedKey] =\r\n                    isArray(opt) || isFunction(opt) ? { type: opt } : opt);\r\n                if (prop) {\r\n                    const booleanIndex = getTypeIndex(Boolean, prop.type);\r\n                    const stringIndex = getTypeIndex(String, prop.type);\r\n                    prop[0 /* shouldCast */] = booleanIndex > -1;\r\n                    prop[1 /* shouldCastTrue */] =\r\n                        stringIndex < 0 || booleanIndex < stringIndex;\r\n                    // if the prop needs boolean casting or default value\r\n                    if (booleanIndex > -1 || hasOwn(prop, 'default')) {\r\n                        needCastKeys.push(normalizedKey);\r\n                    }\r\n                }\r\n            }\r\n        }\r\n    }\r\n    const res = [normalized, needCastKeys];\r\n    cache.set(comp, res);\r\n    return res;\r\n}\r\nfunction validatePropName(key) {\r\n    if (key[0] !== '$') {\r\n        return true;\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production')) {\r\n        warn(`Invalid prop name: \"${key}\" is a reserved property.`);\r\n    }\r\n    return false;\r\n}\r\n// use function string name to check type constructors\r\n// so that it works across vms / iframes.\r\nfunction getType(ctor) {\r\n    const match = ctor && ctor.toString().match(/^\\s*function (\\w+)/);\r\n    return match ? match[1] : ctor === null ? 'null' : '';\r\n}\r\nfunction isSameType(a, b) {\r\n    return getType(a) === getType(b);\r\n}\r\nfunction getTypeIndex(type, expectedTypes) {\r\n    if (isArray(expectedTypes)) {\r\n        return expectedTypes.findIndex(t => isSameType(t, type));\r\n    }\r\n    else if (isFunction(expectedTypes)) {\r\n        return isSameType(expectedTypes, type) ? 0 : -1;\r\n    }\r\n    return -1;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProps(rawProps, props, instance) {\r\n    const resolvedValues = toRaw(props);\r\n    const options = instance.propsOptions[0];\r\n    for (const key in options) {\r\n        let opt = options[key];\r\n        if (opt == null)\r\n            continue;\r\n        validateProp(key, resolvedValues[key], opt, !hasOwn(rawProps, key) && !hasOwn(rawProps, hyphenate(key)));\r\n    }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProp(name, value, prop, isAbsent) {\r\n    const { type, required, validator } = prop;\r\n    // required!\r\n    if (required && isAbsent) {\r\n        warn('Missing required prop: \"' + name + '\"');\r\n        return;\r\n    }\r\n    // missing but optional\r\n    if (value == null && !prop.required) {\r\n        return;\r\n    }\r\n    // type check\r\n    if (type != null && type !== true) {\r\n        let isValid = false;\r\n        const types = isArray(type) ? type : [type];\r\n        const expectedTypes = [];\r\n        // value is valid as long as one of the specified types match\r\n        for (let i = 0; i < types.length && !isValid; i++) {\r\n            const { valid, expectedType } = assertType(value, types[i]);\r\n            expectedTypes.push(expectedType || '');\r\n            isValid = valid;\r\n        }\r\n        if (!isValid) {\r\n            warn(getInvalidTypeMessage(name, value, expectedTypes));\r\n            return;\r\n        }\r\n    }\r\n    // custom validator\r\n    if (validator && !validator(value)) {\r\n        warn('Invalid prop: custom validator check failed for prop \"' + name + '\".');\r\n    }\r\n}\r\nconst isSimpleType = /*#__PURE__*/ makeMap('String,Number,Boolean,Function,Symbol,BigInt');\r\n/**\r\n * dev only\r\n */\r\nfunction assertType(value, type) {\r\n    let valid;\r\n    const expectedType = getType(type);\r\n    if (isSimpleType(expectedType)) {\r\n        const t = typeof value;\r\n        valid = t === expectedType.toLowerCase();\r\n        // for primitive wrapper objects\r\n        if (!valid && t === 'object') {\r\n            valid = value instanceof type;\r\n        }\r\n    }\r\n    else if (expectedType === 'Object') {\r\n        valid = isObject(value);\r\n    }\r\n    else if (expectedType === 'Array') {\r\n        valid = isArray(value);\r\n    }\r\n    else if (expectedType === 'null') {\r\n        valid = value === null;\r\n    }\r\n    else {\r\n        valid = value instanceof type;\r\n    }\r\n    return {\r\n        valid,\r\n        expectedType\r\n    };\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction getInvalidTypeMessage(name, value, expectedTypes) {\r\n    let message = `Invalid prop: type check failed for prop \"${name}\".` +\r\n        ` Expected ${expectedTypes.map(capitalize).join(' | ')}`;\r\n    const expectedType = expectedTypes[0];\r\n    const receivedType = toRawType(value);\r\n    const expectedValue = styleValue(value, expectedType);\r\n    const receivedValue = styleValue(value, receivedType);\r\n    // check if we need to specify expected value\r\n    if (expectedTypes.length === 1 &&\r\n        isExplicable(expectedType) &&\r\n        !isBoolean(expectedType, receivedType)) {\r\n        message += ` with value ${expectedValue}`;\r\n    }\r\n    message += `, got ${receivedType} `;\r\n    // check if we need to specify received value\r\n    if (isExplicable(receivedType)) {\r\n        message += `with value ${receivedValue}.`;\r\n    }\r\n    return message;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction styleValue(value, type) {\r\n    if (type === 'String') {\r\n        return `\"${value}\"`;\r\n    }\r\n    else if (type === 'Number') {\r\n        return `${Number(value)}`;\r\n    }\r\n    else {\r\n        return `${value}`;\r\n    }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isExplicable(type) {\r\n    const explicitTypes = ['string', 'number', 'boolean'];\r\n    return explicitTypes.some(elem => type.toLowerCase() === elem);\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isBoolean(...args) {\r\n    return args.some(elem => elem.toLowerCase() === 'boolean');\r\n}\n\nconst isInternalKey = (key) => key[0] === '_' || key === '$stable';\r\nconst normalizeSlotValue = (value) => isArray(value)\r\n    ? value.map(normalizeVNode)\r\n    : [normalizeVNode(value)];\r\nconst normalizeSlot = (key, rawSlot, ctx) => {\r\n    if (rawSlot._n) {\r\n        // already normalized - #5353\r\n        return rawSlot;\r\n    }\r\n    const normalized = withCtx((...args) => {\r\n        if ((process.env.NODE_ENV !== 'production') && currentInstance) {\r\n            warn(`Slot \"${key}\" invoked outside of the render function: ` +\r\n                `this will not track dependencies used in the slot. ` +\r\n                `Invoke the slot function inside the render function instead.`);\r\n        }\r\n        return normalizeSlotValue(rawSlot(...args));\r\n    }, ctx);\r\n    normalized._c = false;\r\n    return normalized;\r\n};\r\nconst normalizeObjectSlots = (rawSlots, slots, instance) => {\r\n    const ctx = rawSlots._ctx;\r\n    for (const key in rawSlots) {\r\n        if (isInternalKey(key))\r\n            continue;\r\n        const value = rawSlots[key];\r\n        if (isFunction(value)) {\r\n            slots[key] = normalizeSlot(key, value, ctx);\r\n        }\r\n        else if (value != null) {\r\n            if ((process.env.NODE_ENV !== 'production') &&\r\n                !(false )) {\r\n                warn(`Non-function value encountered for slot \"${key}\". ` +\r\n                    `Prefer function slots for better performance.`);\r\n            }\r\n            const normalized = normalizeSlotValue(value);\r\n            slots[key] = () => normalized;\r\n        }\r\n    }\r\n};\r\nconst normalizeVNodeSlots = (instance, children) => {\r\n    if ((process.env.NODE_ENV !== 'production') &&\r\n        !isKeepAlive(instance.vnode) &&\r\n        !(false )) {\r\n        warn(`Non-function value encountered for default slot. ` +\r\n            `Prefer function slots for better performance.`);\r\n    }\r\n    const normalized = normalizeSlotValue(children);\r\n    instance.slots.default = () => normalized;\r\n};\r\nconst initSlots = (instance, children) => {\r\n    if (instance.vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n        const type = children._;\r\n        if (type) {\r\n            // users can get the shallow readonly version of the slots object through `this.$slots`,\r\n            // we should avoid the proxy object polluting the slots of the internal instance\r\n            instance.slots = toRaw(children);\r\n            // make compiler marker non-enumerable\r\n            def(children, '_', type);\r\n        }\r\n        else {\r\n            normalizeObjectSlots(children, (instance.slots = {}));\r\n        }\r\n    }\r\n    else {\r\n        instance.slots = {};\r\n        if (children) {\r\n            normalizeVNodeSlots(instance, children);\r\n        }\r\n    }\r\n    def(instance.slots, InternalObjectKey, 1);\r\n};\r\nconst updateSlots = (instance, children, optimized) => {\r\n    const { vnode, slots } = instance;\r\n    let needDeletionCheck = true;\r\n    let deletionComparisonTarget = EMPTY_OBJ;\r\n    if (vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n        const type = children._;\r\n        if (type) {\r\n            // compiled slots.\r\n            if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n                // Parent was HMR updated so slot content may have changed.\r\n                // force update slots and mark instance for hmr as well\r\n                extend(slots, children);\r\n            }\r\n            else if (optimized && type === 1 /* STABLE */) {\r\n                // compiled AND stable.\r\n                // no need to update, and skip stale slots removal.\r\n                needDeletionCheck = false;\r\n            }\r\n            else {\r\n                // compiled but dynamic (v-if/v-for on slots) - update slots, but skip\r\n                // normalization.\r\n                extend(slots, children);\r\n                // #2893\r\n                // when rendering the optimized slots by manually written render function,\r\n                // we need to delete the `slots._` flag if necessary to make subsequent updates reliable,\r\n                // i.e. let the `renderSlot` create the bailed Fragment\r\n                if (!optimized && type === 1 /* STABLE */) {\r\n                    delete slots._;\r\n                }\r\n            }\r\n        }\r\n        else {\r\n            needDeletionCheck = !children.$stable;\r\n            normalizeObjectSlots(children, slots);\r\n        }\r\n        deletionComparisonTarget = children;\r\n    }\r\n    else if (children) {\r\n        // non slot object children (direct value) passed to a component\r\n        normalizeVNodeSlots(instance, children);\r\n        deletionComparisonTarget = { default: 1 };\r\n    }\r\n    // delete stale slots\r\n    if (needDeletionCheck) {\r\n        for (const key in slots) {\r\n            if (!isInternalKey(key) && !(key in deletionComparisonTarget)) {\r\n                delete slots[key];\r\n            }\r\n        }\r\n    }\r\n};\n\nfunction createAppContext() {\r\n    return {\r\n        app: null,\r\n        config: {\r\n            isNativeTag: NO,\r\n            performance: false,\r\n            globalProperties: {},\r\n            optionMergeStrategies: {},\r\n            errorHandler: undefined,\r\n            warnHandler: undefined,\r\n            compilerOptions: {}\r\n        },\r\n        mixins: [],\r\n        components: {},\r\n        directives: {},\r\n        provides: Object.create(null),\r\n        optionsCache: new WeakMap(),\r\n        propsCache: new WeakMap(),\r\n        emitsCache: new WeakMap()\r\n    };\r\n}\r\nlet uid = 0;\r\nfunction createAppAPI(render, hydrate) {\r\n    return function createApp(rootComponent, rootProps = null) {\r\n        if (!isFunction(rootComponent)) {\r\n            rootComponent = Object.assign({}, rootComponent);\r\n        }\r\n        if (rootProps != null && !isObject(rootProps)) {\r\n            (process.env.NODE_ENV !== 'production') && warn(`root props passed to app.mount() must be an object.`);\r\n            rootProps = null;\r\n        }\r\n        const context = createAppContext();\r\n        const installedPlugins = new Set();\r\n        let isMounted = false;\r\n        const app = (context.app = {\r\n            _uid: uid++,\r\n            _component: rootComponent,\r\n            _props: rootProps,\r\n            _container: null,\r\n            _context: context,\r\n            _instance: null,\r\n            version,\r\n            get config() {\r\n                return context.config;\r\n            },\r\n            set config(v) {\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn(`app.config cannot be replaced. Modify individual options instead.`);\r\n                }\r\n            },\r\n            use(plugin, ...options) {\r\n                if (installedPlugins.has(plugin)) {\r\n                    (process.env.NODE_ENV !== 'production') && warn(`Plugin has already been applied to target app.`);\r\n                }\r\n                else if (plugin && isFunction(plugin.install)) {\r\n                    installedPlugins.add(plugin);\r\n                    plugin.install(app, ...options);\r\n                }\r\n                else if (isFunction(plugin)) {\r\n                    installedPlugins.add(plugin);\r\n                    plugin(app, ...options);\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn(`A plugin must either be a function or an object with an \"install\" ` +\r\n                        `function.`);\r\n                }\r\n                return app;\r\n            },\r\n            mixin(mixin) {\r\n                if (__VUE_OPTIONS_API__) {\r\n                    if (!context.mixins.includes(mixin)) {\r\n                        context.mixins.push(mixin);\r\n                    }\r\n                    else if ((process.env.NODE_ENV !== 'production')) {\r\n                        warn('Mixin has already been applied to target app' +\r\n                            (mixin.name ? `: ${mixin.name}` : ''));\r\n                    }\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn('Mixins are only available in builds supporting Options API');\r\n                }\r\n                return app;\r\n            },\r\n            component(name, component) {\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    validateComponentName(name, context.config);\r\n                }\r\n                if (!component) {\r\n                    return context.components[name];\r\n                }\r\n                if ((process.env.NODE_ENV !== 'production') && context.components[name]) {\r\n                    warn(`Component \"${name}\" has already been registered in target app.`);\r\n                }\r\n                context.components[name] = component;\r\n                return app;\r\n            },\r\n            directive(name, directive) {\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    validateDirectiveName(name);\r\n                }\r\n                if (!directive) {\r\n                    return context.directives[name];\r\n                }\r\n                if ((process.env.NODE_ENV !== 'production') && context.directives[name]) {\r\n                    warn(`Directive \"${name}\" has already been registered in target app.`);\r\n                }\r\n                context.directives[name] = directive;\r\n                return app;\r\n            },\r\n            mount(rootContainer, isHydrate, isSVG) {\r\n                if (!isMounted) {\r\n                    // #5571\r\n                    if ((process.env.NODE_ENV !== 'production') && rootContainer.__vue_app__) {\r\n                        warn(`There is already an app instance mounted on the host container.\\n` +\r\n                            ` If you want to mount another app on the same host container,` +\r\n                            ` you need to unmount the previous app by calling \\`app.unmount()\\` first.`);\r\n                    }\r\n                    const vnode = createVNode(rootComponent, rootProps);\r\n                    // store app context on the root VNode.\r\n                    // this will be set on the root instance on initial mount.\r\n                    vnode.appContext = context;\r\n                    // HMR root reload\r\n                    if ((process.env.NODE_ENV !== 'production')) {\r\n                        context.reload = () => {\r\n                            render(cloneVNode(vnode), rootContainer, isSVG);\r\n                        };\r\n                    }\r\n                    if (isHydrate && hydrate) {\r\n                        hydrate(vnode, rootContainer);\r\n                    }\r\n                    else {\r\n                        render(vnode, rootContainer, isSVG);\r\n                    }\r\n                    isMounted = true;\r\n                    app._container = rootContainer;\r\n                    rootContainer.__vue_app__ = app;\r\n                    if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n                        app._instance = vnode.component;\r\n                        devtoolsInitApp(app, version);\r\n                    }\r\n                    return getExposeProxy(vnode.component) || vnode.component.proxy;\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn(`App has already been mounted.\\n` +\r\n                        `If you want to remount the same app, move your app creation logic ` +\r\n                        `into a factory function and create fresh app instances for each ` +\r\n                        `mount - e.g. \\`const createMyApp = () => createApp(App)\\``);\r\n                }\r\n            },\r\n            unmount() {\r\n                if (isMounted) {\r\n                    render(null, app._container);\r\n                    if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n                        app._instance = null;\r\n                        devtoolsUnmountApp(app);\r\n                    }\r\n                    delete app._container.__vue_app__;\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn(`Cannot unmount an app that is not mounted.`);\r\n                }\r\n            },\r\n            provide(key, value) {\r\n                if ((process.env.NODE_ENV !== 'production') && key in context.provides) {\r\n                    warn(`App already provides property with key \"${String(key)}\". ` +\r\n                        `It will be overwritten with the new value.`);\r\n                }\r\n                context.provides[key] = value;\r\n                return app;\r\n            }\r\n        });\r\n        return app;\r\n    };\r\n}\n\n/**\r\n * Function for handling a template ref\r\n */\r\nfunction setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {\r\n    if (isArray(rawRef)) {\r\n        rawRef.forEach((r, i) => setRef(r, oldRawRef && (isArray(oldRawRef) ? oldRawRef[i] : oldRawRef), parentSuspense, vnode, isUnmount));\r\n        return;\r\n    }\r\n    if (isAsyncWrapper(vnode) && !isUnmount) {\r\n        // when mounting async components, nothing needs to be done,\r\n        // because the template ref is forwarded to inner component\r\n        return;\r\n    }\r\n    const refValue = vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */\r\n        ? getExposeProxy(vnode.component) || vnode.component.proxy\r\n        : vnode.el;\r\n    const value = isUnmount ? null : refValue;\r\n    const { i: owner, r: ref } = rawRef;\r\n    if ((process.env.NODE_ENV !== 'production') && !owner) {\r\n        warn(`Missing ref owner context. ref cannot be used on hoisted vnodes. ` +\r\n            `A vnode with ref must be created inside the render function.`);\r\n        return;\r\n    }\r\n    const oldRef = oldRawRef && oldRawRef.r;\r\n    const refs = owner.refs === EMPTY_OBJ ? (owner.refs = {}) : owner.refs;\r\n    const setupState = owner.setupState;\r\n    // dynamic ref changed. unset old ref\r\n    if (oldRef != null && oldRef !== ref) {\r\n        if (isString(oldRef)) {\r\n            refs[oldRef] = null;\r\n            if (hasOwn(setupState, oldRef)) {\r\n                setupState[oldRef] = null;\r\n            }\r\n        }\r\n        else if (isRef(oldRef)) {\r\n            oldRef.value = null;\r\n        }\r\n    }\r\n    if (isFunction(ref)) {\r\n        callWithErrorHandling(ref, owner, 12 /* FUNCTION_REF */, [value, refs]);\r\n    }\r\n    else {\r\n        const _isString = isString(ref);\r\n        const _isRef = isRef(ref);\r\n        if (_isString || _isRef) {\r\n            const doSet = () => {\r\n                if (rawRef.f) {\r\n                    const existing = _isString ? refs[ref] : ref.value;\r\n                    if (isUnmount) {\r\n                        isArray(existing) && remove(existing, refValue);\r\n                    }\r\n                    else {\r\n                        if (!isArray(existing)) {\r\n                            if (_isString) {\r\n                                refs[ref] = [refValue];\r\n                                if (hasOwn(setupState, ref)) {\r\n                                    setupState[ref] = refs[ref];\r\n                                }\r\n                            }\r\n                            else {\r\n                                ref.value = [refValue];\r\n                                if (rawRef.k)\r\n                                    refs[rawRef.k] = ref.value;\r\n                            }\r\n                        }\r\n                        else if (!existing.includes(refValue)) {\r\n                            existing.push(refValue);\r\n                        }\r\n                    }\r\n                }\r\n                else if (_isString) {\r\n                    refs[ref] = value;\r\n                    if (hasOwn(setupState, ref)) {\r\n                        setupState[ref] = value;\r\n                    }\r\n                }\r\n                else if (_isRef) {\r\n                    ref.value = value;\r\n                    if (rawRef.k)\r\n                        refs[rawRef.k] = value;\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn('Invalid template ref type:', ref, `(${typeof ref})`);\r\n                }\r\n            };\r\n            if (value) {\r\n                doSet.id = -1;\r\n                queuePostRenderEffect(doSet, parentSuspense);\r\n            }\r\n            else {\r\n                doSet();\r\n            }\r\n        }\r\n        else if ((process.env.NODE_ENV !== 'production')) {\r\n            warn('Invalid template ref type:', ref, `(${typeof ref})`);\r\n        }\r\n    }\r\n}\n\nlet hasMismatch = false;\r\nconst isSVGContainer = (container) => /svg/.test(container.namespaceURI) && container.tagName !== 'foreignObject';\r\nconst isComment = (node) => node.nodeType === 8 /* COMMENT */;\r\n// Note: hydration is DOM-specific\r\n// But we have to place it in core due to tight coupling with core - splitting\r\n// it out creates a ton of unnecessary complexity.\r\n// Hydration also depends on some renderer internal logic which needs to be\r\n// passed in via arguments.\r\nfunction createHydrationFunctions(rendererInternals) {\r\n    const { mt: mountComponent, p: patch, o: { patchProp, createText, nextSibling, parentNode, remove, insert, createComment } } = rendererInternals;\r\n    const hydrate = (vnode, container) => {\r\n        if (!container.hasChildNodes()) {\r\n            (process.env.NODE_ENV !== 'production') &&\r\n                warn(`Attempting to hydrate existing markup but container is empty. ` +\r\n                    `Performing full mount instead.`);\r\n            patch(null, vnode, container);\r\n            flushPostFlushCbs();\r\n            container._vnode = vnode;\r\n            return;\r\n        }\r\n        hasMismatch = false;\r\n        hydrateNode(container.firstChild, vnode, null, null, null);\r\n        flushPostFlushCbs();\r\n        container._vnode = vnode;\r\n        if (hasMismatch && !false) {\r\n            // this error should show up in production\r\n            console.error(`Hydration completed but contains mismatches.`);\r\n        }\r\n    };\r\n    const hydrateNode = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized = false) => {\r\n        const isFragmentStart = isComment(node) && node.data === '[';\r\n        const onMismatch = () => handleMismatch(node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragmentStart);\r\n        const { type, ref, shapeFlag, patchFlag } = vnode;\r\n        const domType = node.nodeType;\r\n        vnode.el = node;\r\n        if (patchFlag === -2 /* BAIL */) {\r\n            optimized = false;\r\n            vnode.dynamicChildren = null;\r\n        }\r\n        let nextNode = null;\r\n        switch (type) {\r\n            case Text:\r\n                if (domType !== 3 /* TEXT */) {\r\n                    // #5728 empty text node inside a slot can cause hydration failure\r\n                    // because the server rendered HTML won't contain a text node\r\n                    if (vnode.children === '') {\r\n                        insert((vnode.el = createText('')), parentNode(node), node);\r\n                        nextNode = node;\r\n                    }\r\n                    else {\r\n                        nextNode = onMismatch();\r\n                    }\r\n                }\r\n                else {\r\n                    if (node.data !== vnode.children) {\r\n                        hasMismatch = true;\r\n                        (process.env.NODE_ENV !== 'production') &&\r\n                            warn(`Hydration text mismatch:` +\r\n                                `\\n- Client: ${JSON.stringify(node.data)}` +\r\n                                `\\n- Server: ${JSON.stringify(vnode.children)}`);\r\n                        node.data = vnode.children;\r\n                    }\r\n                    nextNode = nextSibling(node);\r\n                }\r\n                break;\r\n            case Comment:\r\n                if (domType !== 8 /* COMMENT */ || isFragmentStart) {\r\n                    nextNode = onMismatch();\r\n                }\r\n                else {\r\n                    nextNode = nextSibling(node);\r\n                }\r\n                break;\r\n            case Static:\r\n                if (domType !== 1 /* ELEMENT */ && domType !== 3 /* TEXT */) {\r\n                    nextNode = onMismatch();\r\n                }\r\n                else {\r\n                    // determine anchor, adopt content\r\n                    nextNode = node;\r\n                    // if the static vnode has its content stripped during build,\r\n                    // adopt it from the server-rendered HTML.\r\n                    const needToAdoptContent = !vnode.children.length;\r\n                    for (let i = 0; i < vnode.staticCount; i++) {\r\n                        if (needToAdoptContent)\r\n                            vnode.children +=\r\n                                nextNode.nodeType === 1 /* ELEMENT */\r\n                                    ? nextNode.outerHTML\r\n                                    : nextNode.data;\r\n                        if (i === vnode.staticCount - 1) {\r\n                            vnode.anchor = nextNode;\r\n                        }\r\n                        nextNode = nextSibling(nextNode);\r\n                    }\r\n                    return nextNode;\r\n                }\r\n                break;\r\n            case Fragment:\r\n                if (!isFragmentStart) {\r\n                    nextNode = onMismatch();\r\n                }\r\n                else {\r\n                    nextNode = hydrateFragment(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n                }\r\n                break;\r\n            default:\r\n                if (shapeFlag & 1 /* ELEMENT */) {\r\n                    if (domType !== 1 /* ELEMENT */ ||\r\n                        vnode.type.toLowerCase() !==\r\n                            node.tagName.toLowerCase()) {\r\n                        nextNode = onMismatch();\r\n                    }\r\n                    else {\r\n                        nextNode = hydrateElement(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n                    }\r\n                }\r\n                else if (shapeFlag & 6 /* COMPONENT */) {\r\n                    // when setting up the render effect, if the initial vnode already\r\n                    // has .el set, the component will perform hydration instead of mount\r\n                    // on its sub-tree.\r\n                    vnode.slotScopeIds = slotScopeIds;\r\n                    const container = parentNode(node);\r\n                    mountComponent(vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), optimized);\r\n                    // component may be async, so in the case of fragments we cannot rely\r\n                    // on component's rendered output to determine the end of the fragment\r\n                    // instead, we do a lookahead to find the end anchor node.\r\n                    nextNode = isFragmentStart\r\n                        ? locateClosingAsyncAnchor(node)\r\n                        : nextSibling(node);\r\n                    // #4293 teleport as component root\r\n                    if (nextNode &&\r\n                        isComment(nextNode) &&\r\n                        nextNode.data === 'teleport end') {\r\n                        nextNode = nextSibling(nextNode);\r\n                    }\r\n                    // #3787\r\n                    // if component is async, it may get moved / unmounted before its\r\n                    // inner component is loaded, so we need to give it a placeholder\r\n                    // vnode that matches its adopted DOM.\r\n                    if (isAsyncWrapper(vnode)) {\r\n                        let subTree;\r\n                        if (isFragmentStart) {\r\n                            subTree = createVNode(Fragment);\r\n                            subTree.anchor = nextNode\r\n                                ? nextNode.previousSibling\r\n                                : container.lastChild;\r\n                        }\r\n                        else {\r\n                            subTree =\r\n                                node.nodeType === 3 ? createTextVNode('') : createVNode('div');\r\n                        }\r\n                        subTree.el = node;\r\n                        vnode.component.subTree = subTree;\r\n                    }\r\n                }\r\n                else if (shapeFlag & 64 /* TELEPORT */) {\r\n                    if (domType !== 8 /* COMMENT */) {\r\n                        nextNode = onMismatch();\r\n                    }\r\n                    else {\r\n                        nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, rendererInternals, hydrateChildren);\r\n                    }\r\n                }\r\n                else if (shapeFlag & 128 /* SUSPENSE */) {\r\n                    nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, isSVGContainer(parentNode(node)), slotScopeIds, optimized, rendererInternals, hydrateNode);\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn('Invalid HostVNode type:', type, `(${typeof type})`);\r\n                }\r\n        }\r\n        if (ref != null) {\r\n            setRef(ref, null, parentSuspense, vnode);\r\n        }\r\n        return nextNode;\r\n    };\r\n    const hydrateElement = (el, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n        optimized = optimized || !!vnode.dynamicChildren;\r\n        const { type, props, patchFlag, shapeFlag, dirs } = vnode;\r\n        // #4006 for form elements with non-string v-model value bindings\r\n        // e.g. <option :value=\"obj\">, <input type=\"checkbox\" :true-value=\"1\">\r\n        const forcePatchValue = (type === 'input' && dirs) || type === 'option';\r\n        // skip props & children if this is hoisted static nodes\r\n        // #5405 in dev, always hydrate children for HMR\r\n        if ((process.env.NODE_ENV !== 'production') || forcePatchValue || patchFlag !== -1 /* HOISTED */) {\r\n            if (dirs) {\r\n                invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n            }\r\n            // props\r\n            if (props) {\r\n                if (forcePatchValue ||\r\n                    !optimized ||\r\n                    patchFlag & (16 /* FULL_PROPS */ | 32 /* HYDRATE_EVENTS */)) {\r\n                    for (const key in props) {\r\n                        if ((forcePatchValue && key.endsWith('value')) ||\r\n                            (isOn(key) && !isReservedProp(key))) {\r\n                            patchProp(el, key, null, props[key], false, undefined, parentComponent);\r\n                        }\r\n                    }\r\n                }\r\n                else if (props.onClick) {\r\n                    // Fast path for click listeners (which is most often) to avoid\r\n                    // iterating through props.\r\n                    patchProp(el, 'onClick', null, props.onClick, false, undefined, parentComponent);\r\n                }\r\n            }\r\n            // vnode / directive hooks\r\n            let vnodeHooks;\r\n            if ((vnodeHooks = props && props.onVnodeBeforeMount)) {\r\n                invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n            }\r\n            if (dirs) {\r\n                invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n            }\r\n            if ((vnodeHooks = props && props.onVnodeMounted) || dirs) {\r\n                queueEffectWithSuspense(() => {\r\n                    vnodeHooks && invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n                    dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n                }, parentSuspense);\r\n            }\r\n            // children\r\n            if (shapeFlag & 16 /* ARRAY_CHILDREN */ &&\r\n                // skip if element has innerHTML / textContent\r\n                !(props && (props.innerHTML || props.textContent))) {\r\n                let next = hydrateChildren(el.firstChild, vnode, el, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n                let hasWarned = false;\r\n                while (next) {\r\n                    hasMismatch = true;\r\n                    if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n                        warn(`Hydration children mismatch in <${vnode.type}>: ` +\r\n                            `server rendered element contains more child nodes than client vdom.`);\r\n                        hasWarned = true;\r\n                    }\r\n                    // The SSRed DOM contains more nodes than it should. Remove them.\r\n                    const cur = next;\r\n                    next = next.nextSibling;\r\n                    remove(cur);\r\n                }\r\n            }\r\n            else if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n                if (el.textContent !== vnode.children) {\r\n                    hasMismatch = true;\r\n                    (process.env.NODE_ENV !== 'production') &&\r\n                        warn(`Hydration text content mismatch in <${vnode.type}>:\\n` +\r\n                            `- Client: ${el.textContent}\\n` +\r\n                            `- Server: ${vnode.children}`);\r\n                    el.textContent = vnode.children;\r\n                }\r\n            }\r\n        }\r\n        return el.nextSibling;\r\n    };\r\n    const hydrateChildren = (node, parentVNode, container, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n        optimized = optimized || !!parentVNode.dynamicChildren;\r\n        const children = parentVNode.children;\r\n        const l = children.length;\r\n        let hasWarned = false;\r\n        for (let i = 0; i < l; i++) {\r\n            const vnode = optimized\r\n                ? children[i]\r\n                : (children[i] = normalizeVNode(children[i]));\r\n            if (node) {\r\n                node = hydrateNode(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n            }\r\n            else if (vnode.type === Text && !vnode.children) {\r\n                continue;\r\n            }\r\n            else {\r\n                hasMismatch = true;\r\n                if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n                    warn(`Hydration children mismatch in <${container.tagName.toLowerCase()}>: ` +\r\n                        `server rendered element contains fewer child nodes than client vdom.`);\r\n                    hasWarned = true;\r\n                }\r\n                // the SSRed DOM didn't contain enough nodes. Mount the missing ones.\r\n                patch(null, vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n            }\r\n        }\r\n        return node;\r\n    };\r\n    const hydrateFragment = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n        const { slotScopeIds: fragmentSlotScopeIds } = vnode;\r\n        if (fragmentSlotScopeIds) {\r\n            slotScopeIds = slotScopeIds\r\n                ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n                : fragmentSlotScopeIds;\r\n        }\r\n        const container = parentNode(node);\r\n        const next = hydrateChildren(nextSibling(node), vnode, container, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n        if (next && isComment(next) && next.data === ']') {\r\n            return nextSibling((vnode.anchor = next));\r\n        }\r\n        else {\r\n            // fragment didn't hydrate successfully, since we didn't get a end anchor\r\n            // back. This should have led to node/children mismatch warnings.\r\n            hasMismatch = true;\r\n            // since the anchor is missing, we need to create one and insert it\r\n            insert((vnode.anchor = createComment(`]`)), container, next);\r\n            return next;\r\n        }\r\n    };\r\n    const handleMismatch = (node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragment) => {\r\n        hasMismatch = true;\r\n        (process.env.NODE_ENV !== 'production') &&\r\n            warn(`Hydration node mismatch:\\n- Client vnode:`, vnode.type, `\\n- Server rendered DOM:`, node, node.nodeType === 3 /* TEXT */\r\n                ? `(text)`\r\n                : isComment(node) && node.data === '['\r\n                    ? `(start of fragment)`\r\n                    : ``);\r\n        vnode.el = null;\r\n        if (isFragment) {\r\n            // remove excessive fragment nodes\r\n            const end = locateClosingAsyncAnchor(node);\r\n            while (true) {\r\n                const next = nextSibling(node);\r\n                if (next && next !== end) {\r\n                    remove(next);\r\n                }\r\n                else {\r\n                    break;\r\n                }\r\n            }\r\n        }\r\n        const next = nextSibling(node);\r\n        const container = parentNode(node);\r\n        remove(node);\r\n        patch(null, vnode, container, next, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n        return next;\r\n    };\r\n    const locateClosingAsyncAnchor = (node) => {\r\n        let match = 0;\r\n        while (node) {\r\n            node = nextSibling(node);\r\n            if (node && isComment(node)) {\r\n                if (node.data === '[')\r\n                    match++;\r\n                if (node.data === ']') {\r\n                    if (match === 0) {\r\n                        return nextSibling(node);\r\n                    }\r\n                    else {\r\n                        match--;\r\n                    }\r\n                }\r\n            }\r\n        }\r\n        return node;\r\n    };\r\n    return [hydrate, hydrateNode];\r\n}\n\n/* eslint-disable no-restricted-globals */\r\nlet supported;\r\nlet perf;\r\nfunction startMeasure(instance, type) {\r\n    if (instance.appContext.config.performance && isSupported()) {\r\n        perf.mark(`vue-${type}-${instance.uid}`);\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n        devtoolsPerfStart(instance, type, isSupported() ? perf.now() : Date.now());\r\n    }\r\n}\r\nfunction endMeasure(instance, type) {\r\n    if (instance.appContext.config.performance && isSupported()) {\r\n        const startTag = `vue-${type}-${instance.uid}`;\r\n        const endTag = startTag + `:end`;\r\n        perf.mark(endTag);\r\n        perf.measure(`<${formatComponentName(instance, instance.type)}> ${type}`, startTag, endTag);\r\n        perf.clearMarks(startTag);\r\n        perf.clearMarks(endTag);\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n        devtoolsPerfEnd(instance, type, isSupported() ? perf.now() : Date.now());\r\n    }\r\n}\r\nfunction isSupported() {\r\n    if (supported !== undefined) {\r\n        return supported;\r\n    }\r\n    if (typeof window !== 'undefined' && window.performance) {\r\n        supported = true;\r\n        perf = window.performance;\r\n    }\r\n    else {\r\n        supported = false;\r\n    }\r\n    return supported;\r\n}\n\n/**\r\n * This is only called in esm-bundler builds.\r\n * It is called when a renderer is created, in `baseCreateRenderer` so that\r\n * importing runtime-core is side-effects free.\r\n *\r\n * istanbul-ignore-next\r\n */\r\nfunction initFeatureFlags() {\r\n    const needWarn = [];\r\n    if (typeof __VUE_OPTIONS_API__ !== 'boolean') {\r\n        (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_OPTIONS_API__`);\r\n        getGlobalThis().__VUE_OPTIONS_API__ = true;\r\n    }\r\n    if (typeof __VUE_PROD_DEVTOOLS__ !== 'boolean') {\r\n        (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_PROD_DEVTOOLS__`);\r\n        getGlobalThis().__VUE_PROD_DEVTOOLS__ = false;\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production') && needWarn.length) {\r\n        const multi = needWarn.length > 1;\r\n        console.warn(`Feature flag${multi ? `s` : ``} ${needWarn.join(', ')} ${multi ? `are` : `is`} not explicitly defined. You are running the esm-bundler build of Vue, ` +\r\n            `which expects these compile-time feature flags to be globally injected ` +\r\n            `via the bundler config in order to get better tree-shaking in the ` +\r\n            `production bundle.\\n\\n` +\r\n            `For more details, see https://link.vuejs.org/feature-flags.`);\r\n    }\r\n}\n\nconst queuePostRenderEffect = queueEffectWithSuspense\r\n    ;\r\n/**\r\n * The createRenderer function accepts two generic arguments:\r\n * HostNode and HostElement, corresponding to Node and Element types in the\r\n * host environment. For example, for runtime-dom, HostNode would be the DOM\r\n * `Node` interface and HostElement would be the DOM `Element` interface.\r\n *\r\n * Custom renderers can pass in the platform specific types like this:\r\n *\r\n * ``` js\r\n * const { render, createApp } = createRenderer<Node, Element>({\r\n *   patchProp,\r\n *   ...nodeOps\r\n * })\r\n * ```\r\n */\r\nfunction createRenderer(options) {\r\n    return baseCreateRenderer(options);\r\n}\r\n// Separate API for creating hydration-enabled renderer.\r\n// Hydration logic is only used when calling this function, making it\r\n// tree-shakable.\r\nfunction createHydrationRenderer(options) {\r\n    return baseCreateRenderer(options, createHydrationFunctions);\r\n}\r\n// implementation\r\nfunction baseCreateRenderer(options, createHydrationFns) {\r\n    // compile-time feature flags check\r\n    {\r\n        initFeatureFlags();\r\n    }\r\n    const target = getGlobalThis();\r\n    target.__VUE__ = true;\r\n    if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n        setDevtoolsHook(target.__VUE_DEVTOOLS_GLOBAL_HOOK__, target);\r\n    }\r\n    const { insert: hostInsert, remove: hostRemove, patchProp: hostPatchProp, createElement: hostCreateElement, createText: hostCreateText, createComment: hostCreateComment, setText: hostSetText, setElementText: hostSetElementText, parentNode: hostParentNode, nextSibling: hostNextSibling, setScopeId: hostSetScopeId = NOOP, cloneNode: hostCloneNode, insertStaticContent: hostInsertStaticContent } = options;\r\n    // Note: functions inside this closure should use `const xxx = () => {}`\r\n    // style in order to prevent being inlined by minifiers.\r\n    const patch = (n1, n2, container, anchor = null, parentComponent = null, parentSuspense = null, isSVG = false, slotScopeIds = null, optimized = (process.env.NODE_ENV !== 'production') && isHmrUpdating ? false : !!n2.dynamicChildren) => {\r\n        if (n1 === n2) {\r\n            return;\r\n        }\r\n        // patching & not same type, unmount old tree\r\n        if (n1 && !isSameVNodeType(n1, n2)) {\r\n            anchor = getNextHostNode(n1);\r\n            unmount(n1, parentComponent, parentSuspense, true);\r\n            n1 = null;\r\n        }\r\n        if (n2.patchFlag === -2 /* BAIL */) {\r\n            optimized = false;\r\n            n2.dynamicChildren = null;\r\n        }\r\n        const { type, ref, shapeFlag } = n2;\r\n        switch (type) {\r\n            case Text:\r\n                processText(n1, n2, container, anchor);\r\n                break;\r\n            case Comment:\r\n                processCommentNode(n1, n2, container, anchor);\r\n                break;\r\n            case Static:\r\n                if (n1 == null) {\r\n                    mountStaticNode(n2, container, anchor, isSVG);\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    patchStaticNode(n1, n2, container, isSVG);\r\n                }\r\n                break;\r\n            case Fragment:\r\n                processFragment(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                break;\r\n            default:\r\n                if (shapeFlag & 1 /* ELEMENT */) {\r\n                    processElement(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                }\r\n                else if (shapeFlag & 6 /* COMPONENT */) {\r\n                    processComponent(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                }\r\n                else if (shapeFlag & 64 /* TELEPORT */) {\r\n                    type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n                }\r\n                else if (shapeFlag & 128 /* SUSPENSE */) {\r\n                    type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn('Invalid VNode type:', type, `(${typeof type})`);\r\n                }\r\n        }\r\n        // set ref\r\n        if (ref != null && parentComponent) {\r\n            setRef(ref, n1 && n1.ref, parentSuspense, n2 || n1, !n2);\r\n        }\r\n    };\r\n    const processText = (n1, n2, container, anchor) => {\r\n        if (n1 == null) {\r\n            hostInsert((n2.el = hostCreateText(n2.children)), container, anchor);\r\n        }\r\n        else {\r\n            const el = (n2.el = n1.el);\r\n            if (n2.children !== n1.children) {\r\n                hostSetText(el, n2.children);\r\n            }\r\n        }\r\n    };\r\n    const processCommentNode = (n1, n2, container, anchor) => {\r\n        if (n1 == null) {\r\n            hostInsert((n2.el = hostCreateComment(n2.children || '')), container, anchor);\r\n        }\r\n        else {\r\n            // there's no support for dynamic comments\r\n            n2.el = n1.el;\r\n        }\r\n    };\r\n    const mountStaticNode = (n2, container, anchor, isSVG) => {\r\n        [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG, n2.el, n2.anchor);\r\n    };\r\n    /**\r\n     * Dev / HMR only\r\n     */\r\n    const patchStaticNode = (n1, n2, container, isSVG) => {\r\n        // static nodes are only patched during dev for HMR\r\n        if (n2.children !== n1.children) {\r\n            const anchor = hostNextSibling(n1.anchor);\r\n            // remove existing\r\n            removeStaticNode(n1);\r\n            [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG);\r\n        }\r\n        else {\r\n            n2.el = n1.el;\r\n            n2.anchor = n1.anchor;\r\n        }\r\n    };\r\n    const moveStaticNode = ({ el, anchor }, container, nextSibling) => {\r\n        let next;\r\n        while (el && el !== anchor) {\r\n            next = hostNextSibling(el);\r\n            hostInsert(el, container, nextSibling);\r\n            el = next;\r\n        }\r\n        hostInsert(anchor, container, nextSibling);\r\n    };\r\n    const removeStaticNode = ({ el, anchor }) => {\r\n        let next;\r\n        while (el && el !== anchor) {\r\n            next = hostNextSibling(el);\r\n            hostRemove(el);\r\n            el = next;\r\n        }\r\n        hostRemove(anchor);\r\n    };\r\n    const processElement = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n        isSVG = isSVG || n2.type === 'svg';\r\n        if (n1 == null) {\r\n            mountElement(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n        }\r\n        else {\r\n            patchElement(n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n        }\r\n    };\r\n    const mountElement = (vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n        let el;\r\n        let vnodeHook;\r\n        const { type, props, shapeFlag, transition, patchFlag, dirs } = vnode;\r\n        if (!(process.env.NODE_ENV !== 'production') &&\r\n            vnode.el &&\r\n            hostCloneNode !== undefined &&\r\n            patchFlag === -1 /* HOISTED */) {\r\n            // If a vnode has non-null el, it means it's being reused.\r\n            // Only static vnodes can be reused, so its mounted DOM nodes should be\r\n            // exactly the same, and we can simply do a clone here.\r\n            // only do this in production since cloned trees cannot be HMR updated.\r\n            el = vnode.el = hostCloneNode(vnode.el);\r\n        }\r\n        else {\r\n            el = vnode.el = hostCreateElement(vnode.type, isSVG, props && props.is, props);\r\n            // mount children first, since some props may rely on child content\r\n            // being already rendered, e.g. `<select value>`\r\n            if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n                hostSetElementText(el, vnode.children);\r\n            }\r\n            else if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n                mountChildren(vnode.children, el, null, parentComponent, parentSuspense, isSVG && type !== 'foreignObject', slotScopeIds, optimized);\r\n            }\r\n            if (dirs) {\r\n                invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n            }\r\n            // props\r\n            if (props) {\r\n                for (const key in props) {\r\n                    if (key !== 'value' && !isReservedProp(key)) {\r\n                        hostPatchProp(el, key, null, props[key], isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n                    }\r\n                }\r\n                /**\r\n                 * Special case for setting value on DOM elements:\r\n                 * - it can be order-sensitive (e.g. should be set *after* min/max, #2325, #4024)\r\n                 * - it needs to be forced (#1471)\r\n                 * #2353 proposes adding another renderer option to configure this, but\r\n                 * the properties affects are so finite it is worth special casing it\r\n                 * here to reduce the complexity. (Special casing it also should not\r\n                 * affect non-DOM renderers)\r\n                 */\r\n                if ('value' in props) {\r\n                    hostPatchProp(el, 'value', null, props.value);\r\n                }\r\n                if ((vnodeHook = props.onVnodeBeforeMount)) {\r\n                    invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n                }\r\n            }\r\n            // scopeId\r\n            setScopeId(el, vnode, vnode.scopeId, slotScopeIds, parentComponent);\r\n        }\r\n        if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n            Object.defineProperty(el, '__vnode', {\r\n                value: vnode,\r\n                enumerable: false\r\n            });\r\n            Object.defineProperty(el, '__vueParentComponent', {\r\n                value: parentComponent,\r\n                enumerable: false\r\n            });\r\n        }\r\n        if (dirs) {\r\n            invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n        }\r\n        // #1583 For inside suspense + suspense not resolved case, enter hook should call when suspense resolved\r\n        // #1689 For inside suspense + suspense resolved case, just call it\r\n        const needCallTransitionHooks = (!parentSuspense || (parentSuspense && !parentSuspense.pendingBranch)) &&\r\n            transition &&\r\n            !transition.persisted;\r\n        if (needCallTransitionHooks) {\r\n            transition.beforeEnter(el);\r\n        }\r\n        hostInsert(el, container, anchor);\r\n        if ((vnodeHook = props && props.onVnodeMounted) ||\r\n            needCallTransitionHooks ||\r\n            dirs) {\r\n            queuePostRenderEffect(() => {\r\n                vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n                needCallTransitionHooks && transition.enter(el);\r\n                dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n            }, parentSuspense);\r\n        }\r\n    };\r\n    const setScopeId = (el, vnode, scopeId, slotScopeIds, parentComponent) => {\r\n        if (scopeId) {\r\n            hostSetScopeId(el, scopeId);\r\n        }\r\n        if (slotScopeIds) {\r\n            for (let i = 0; i < slotScopeIds.length; i++) {\r\n                hostSetScopeId(el, slotScopeIds[i]);\r\n            }\r\n        }\r\n        if (parentComponent) {\r\n            let subTree = parentComponent.subTree;\r\n            if ((process.env.NODE_ENV !== 'production') &&\r\n                subTree.patchFlag > 0 &&\r\n                subTree.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n                subTree =\r\n                    filterSingleRoot(subTree.children) || subTree;\r\n            }\r\n            if (vnode === subTree) {\r\n                const parentVNode = parentComponent.vnode;\r\n                setScopeId(el, parentVNode, parentVNode.scopeId, parentVNode.slotScopeIds, parentComponent.parent);\r\n            }\r\n        }\r\n    };\r\n    const mountChildren = (children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, start = 0) => {\r\n        for (let i = start; i < children.length; i++) {\r\n            const child = (children[i] = optimized\r\n                ? cloneIfMounted(children[i])\r\n                : normalizeVNode(children[i]));\r\n            patch(null, child, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n        }\r\n    };\r\n    const patchElement = (n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n        const el = (n2.el = n1.el);\r\n        let { patchFlag, dynamicChildren, dirs } = n2;\r\n        // #1426 take the old vnode's patch flag into account since user may clone a\r\n        // compiler-generated vnode, which de-opts to FULL_PROPS\r\n        patchFlag |= n1.patchFlag & 16 /* FULL_PROPS */;\r\n        const oldProps = n1.props || EMPTY_OBJ;\r\n        const newProps = n2.props || EMPTY_OBJ;\r\n        let vnodeHook;\r\n        // disable recurse in beforeUpdate hooks\r\n        parentComponent && toggleRecurse(parentComponent, false);\r\n        if ((vnodeHook = newProps.onVnodeBeforeUpdate)) {\r\n            invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n        }\r\n        if (dirs) {\r\n            invokeDirectiveHook(n2, n1, parentComponent, 'beforeUpdate');\r\n        }\r\n        parentComponent && toggleRecurse(parentComponent, true);\r\n        if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n            // HMR updated, force full diff\r\n            patchFlag = 0;\r\n            optimized = false;\r\n            dynamicChildren = null;\r\n        }\r\n        const areChildrenSVG = isSVG && n2.type !== 'foreignObject';\r\n        if (dynamicChildren) {\r\n            patchBlockChildren(n1.dynamicChildren, dynamicChildren, el, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds);\r\n            if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n                traverseStaticChildren(n1, n2);\r\n            }\r\n        }\r\n        else if (!optimized) {\r\n            // full diff\r\n            patchChildren(n1, n2, el, null, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds, false);\r\n        }\r\n        if (patchFlag > 0) {\r\n            // the presence of a patchFlag means this element's render code was\r\n            // generated by the compiler and can take the fast path.\r\n            // in this path old node and new node are guaranteed to have the same shape\r\n            // (i.e. at the exact same position in the source template)\r\n            if (patchFlag & 16 /* FULL_PROPS */) {\r\n                // element props contain dynamic keys, full diff needed\r\n                patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n            }\r\n            else {\r\n                // class\r\n                // this flag is matched when the element has dynamic class bindings.\r\n                if (patchFlag & 2 /* CLASS */) {\r\n                    if (oldProps.class !== newProps.class) {\r\n                        hostPatchProp(el, 'class', null, newProps.class, isSVG);\r\n                    }\r\n                }\r\n                // style\r\n                // this flag is matched when the element has dynamic style bindings\r\n                if (patchFlag & 4 /* STYLE */) {\r\n                    hostPatchProp(el, 'style', oldProps.style, newProps.style, isSVG);\r\n                }\r\n                // props\r\n                // This flag is matched when the element has dynamic prop/attr bindings\r\n                // other than class and style. The keys of dynamic prop/attrs are saved for\r\n                // faster iteration.\r\n                // Note dynamic keys like :[foo]=\"bar\" will cause this optimization to\r\n                // bail out and go through a full diff because we need to unset the old key\r\n                if (patchFlag & 8 /* PROPS */) {\r\n                    // if the flag is present then dynamicProps must be non-null\r\n                    const propsToUpdate = n2.dynamicProps;\r\n                    for (let i = 0; i < propsToUpdate.length; i++) {\r\n                        const key = propsToUpdate[i];\r\n                        const prev = oldProps[key];\r\n                        const next = newProps[key];\r\n                        // #1471 force patch value\r\n                        if (next !== prev || key === 'value') {\r\n                            hostPatchProp(el, key, prev, next, isSVG, n1.children, parentComponent, parentSuspense, unmountChildren);\r\n                        }\r\n                    }\r\n                }\r\n            }\r\n            // text\r\n            // This flag is matched when the element has only dynamic text children.\r\n            if (patchFlag & 1 /* TEXT */) {\r\n                if (n1.children !== n2.children) {\r\n                    hostSetElementText(el, n2.children);\r\n                }\r\n            }\r\n        }\r\n        else if (!optimized && dynamicChildren == null) {\r\n            // unoptimized, full diff\r\n            patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n        }\r\n        if ((vnodeHook = newProps.onVnodeUpdated) || dirs) {\r\n            queuePostRenderEffect(() => {\r\n                vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n                dirs && invokeDirectiveHook(n2, n1, parentComponent, 'updated');\r\n            }, parentSuspense);\r\n        }\r\n    };\r\n    // The fast path for blocks.\r\n    const patchBlockChildren = (oldChildren, newChildren, fallbackContainer, parentComponent, parentSuspense, isSVG, slotScopeIds) => {\r\n        for (let i = 0; i < newChildren.length; i++) {\r\n            const oldVNode = oldChildren[i];\r\n            const newVNode = newChildren[i];\r\n            // Determine the container (parent element) for the patch.\r\n            const container = \r\n            // oldVNode may be an errored async setup() component inside Suspense\r\n            // which will not have a mounted element\r\n            oldVNode.el &&\r\n                // - In the case of a Fragment, we need to provide the actual parent\r\n                // of the Fragment itself so it can move its children.\r\n                (oldVNode.type === Fragment ||\r\n                    // - In the case of different nodes, there is going to be a replacement\r\n                    // which also requires the correct parent container\r\n                    !isSameVNodeType(oldVNode, newVNode) ||\r\n                    // - In the case of a component, it could contain anything.\r\n                    oldVNode.shapeFlag & (6 /* COMPONENT */ | 64 /* TELEPORT */))\r\n                ? hostParentNode(oldVNode.el)\r\n                : // In other cases, the parent container is not actually used so we\r\n                    // just pass the block element here to avoid a DOM parentNode call.\r\n                    fallbackContainer;\r\n            patch(oldVNode, newVNode, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, true);\r\n        }\r\n    };\r\n    const patchProps = (el, vnode, oldProps, newProps, parentComponent, parentSuspense, isSVG) => {\r\n        if (oldProps !== newProps) {\r\n            for (const key in newProps) {\r\n                // empty string is not valid prop\r\n                if (isReservedProp(key))\r\n                    continue;\r\n                const next = newProps[key];\r\n                const prev = oldProps[key];\r\n                // defer patching value\r\n                if (next !== prev && key !== 'value') {\r\n                    hostPatchProp(el, key, prev, next, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n                }\r\n            }\r\n            if (oldProps !== EMPTY_OBJ) {\r\n                for (const key in oldProps) {\r\n                    if (!isReservedProp(key) && !(key in newProps)) {\r\n                        hostPatchProp(el, key, oldProps[key], null, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n                    }\r\n                }\r\n            }\r\n            if ('value' in newProps) {\r\n                hostPatchProp(el, 'value', oldProps.value, newProps.value);\r\n            }\r\n        }\r\n    };\r\n    const processFragment = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n        const fragmentStartAnchor = (n2.el = n1 ? n1.el : hostCreateText(''));\r\n        const fragmentEndAnchor = (n2.anchor = n1 ? n1.anchor : hostCreateText(''));\r\n        let { patchFlag, dynamicChildren, slotScopeIds: fragmentSlotScopeIds } = n2;\r\n        if ((process.env.NODE_ENV !== 'production') &&\r\n            // #5523 dev root fragment may inherit directives\r\n            (isHmrUpdating || patchFlag & 2048 /* DEV_ROOT_FRAGMENT */)) {\r\n            // HMR updated / Dev root fragment (w/ comments), force full diff\r\n            patchFlag = 0;\r\n            optimized = false;\r\n            dynamicChildren = null;\r\n        }\r\n        // check if this is a slot fragment with :slotted scope ids\r\n        if (fragmentSlotScopeIds) {\r\n            slotScopeIds = slotScopeIds\r\n                ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n                : fragmentSlotScopeIds;\r\n        }\r\n        if (n1 == null) {\r\n            hostInsert(fragmentStartAnchor, container, anchor);\r\n            hostInsert(fragmentEndAnchor, container, anchor);\r\n            // a fragment can only have array children\r\n            // since they are either generated by the compiler, or implicitly created\r\n            // from arrays.\r\n            mountChildren(n2.children, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n        }\r\n        else {\r\n            if (patchFlag > 0 &&\r\n                patchFlag & 64 /* STABLE_FRAGMENT */ &&\r\n                dynamicChildren &&\r\n                // #2715 the previous fragment could've been a BAILed one as a result\r\n                // of renderSlot() with no valid children\r\n                n1.dynamicChildren) {\r\n                // a stable fragment (template root or <template v-for>) doesn't need to\r\n                // patch children order, but it may contain dynamicChildren.\r\n                patchBlockChildren(n1.dynamicChildren, dynamicChildren, container, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n                if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n                    traverseStaticChildren(n1, n2);\r\n                }\r\n                else if (\r\n                // #2080 if the stable fragment has a key, it's a <template v-for> that may\r\n                //  get moved around. Make sure all root level vnodes inherit el.\r\n                // #2134 or if it's a component root, it may also get moved around\r\n                // as the component is being moved.\r\n                n2.key != null ||\r\n                    (parentComponent && n2 === parentComponent.subTree)) {\r\n                    traverseStaticChildren(n1, n2, true /* shallow */);\r\n                }\r\n            }\r\n            else {\r\n                // keyed / unkeyed, or manual fragments.\r\n                // for keyed & unkeyed, since they are compiler generated from v-for,\r\n                // each child is guaranteed to be a block so the fragment will never\r\n                // have dynamicChildren.\r\n                patchChildren(n1, n2, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n            }\r\n        }\r\n    };\r\n    const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n        n2.slotScopeIds = slotScopeIds;\r\n        if (n1 == null) {\r\n            if (n2.shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n                parentComponent.ctx.activate(n2, container, anchor, isSVG, optimized);\r\n            }\r\n            else {\r\n                mountComponent(n2, container, anchor, parentComponent, parentSuspense, isSVG, optimized);\r\n            }\r\n        }\r\n        else {\r\n            updateComponent(n1, n2, optimized);\r\n        }\r\n    };\r\n    const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, isSVG, optimized) => {\r\n        const instance = (initialVNode.component = createComponentInstance(initialVNode, parentComponent, parentSuspense));\r\n        if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n            registerHMR(instance);\r\n        }\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            pushWarningContext(initialVNode);\r\n            startMeasure(instance, `mount`);\r\n        }\r\n        // inject renderer internals for keepAlive\r\n        if (isKeepAlive(initialVNode)) {\r\n            instance.ctx.renderer = internals;\r\n        }\r\n        // resolve props and slots for setup context\r\n        {\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                startMeasure(instance, `init`);\r\n            }\r\n            setupComponent(instance);\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                endMeasure(instance, `init`);\r\n            }\r\n        }\r\n        // setup() is async. This component relies on async logic to be resolved\r\n        // before proceeding\r\n        if (instance.asyncDep) {\r\n            parentSuspense && parentSuspense.registerDep(instance, setupRenderEffect);\r\n            // Give it a placeholder if this is not hydration\r\n            // TODO handle self-defined fallback\r\n            if (!initialVNode.el) {\r\n                const placeholder = (instance.subTree = createVNode(Comment));\r\n                processCommentNode(null, placeholder, container, anchor);\r\n            }\r\n            return;\r\n        }\r\n        setupRenderEffect(instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized);\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            popWarningContext();\r\n            endMeasure(instance, `mount`);\r\n        }\r\n    };\r\n    const updateComponent = (n1, n2, optimized) => {\r\n        const instance = (n2.component = n1.component);\r\n        if (shouldUpdateComponent(n1, n2, optimized)) {\r\n            if (instance.asyncDep &&\r\n                !instance.asyncResolved) {\r\n                // async & still pending - just update props and slots\r\n                // since the component's reactive effect for render isn't set-up yet\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    pushWarningContext(n2);\r\n                }\r\n                updateComponentPreRender(instance, n2, optimized);\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    popWarningContext();\r\n                }\r\n                return;\r\n            }\r\n            else {\r\n                // normal update\r\n                instance.next = n2;\r\n                // in case the child component is also queued, remove it to avoid\r\n                // double updating the same child component in the same flush.\r\n                invalidateJob(instance.update);\r\n                // instance.update is the reactive effect.\r\n                instance.update();\r\n            }\r\n        }\r\n        else {\r\n            // no update needed. just copy over properties\r\n            n2.el = n1.el;\r\n            instance.vnode = n2;\r\n        }\r\n    };\r\n    const setupRenderEffect = (instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized) => {\r\n        const componentUpdateFn = () => {\r\n            if (!instance.isMounted) {\r\n                let vnodeHook;\r\n                const { el, props } = initialVNode;\r\n                const { bm, m, parent } = instance;\r\n                const isAsyncWrapperVNode = isAsyncWrapper(initialVNode);\r\n                toggleRecurse(instance, false);\r\n                // beforeMount hook\r\n                if (bm) {\r\n                    invokeArrayFns(bm);\r\n                }\r\n                // onVnodeBeforeMount\r\n                if (!isAsyncWrapperVNode &&\r\n                    (vnodeHook = props && props.onVnodeBeforeMount)) {\r\n                    invokeVNodeHook(vnodeHook, parent, initialVNode);\r\n                }\r\n                toggleRecurse(instance, true);\r\n                if (el && hydrateNode) {\r\n                    // vnode has adopted host node - perform hydration instead of mount.\r\n                    const hydrateSubTree = () => {\r\n                        if ((process.env.NODE_ENV !== 'production')) {\r\n                            startMeasure(instance, `render`);\r\n                        }\r\n                        instance.subTree = renderComponentRoot(instance);\r\n                        if ((process.env.NODE_ENV !== 'production')) {\r\n                            endMeasure(instance, `render`);\r\n                        }\r\n                        if ((process.env.NODE_ENV !== 'production')) {\r\n                            startMeasure(instance, `hydrate`);\r\n                        }\r\n                        hydrateNode(el, instance.subTree, instance, parentSuspense, null);\r\n                        if ((process.env.NODE_ENV !== 'production')) {\r\n                            endMeasure(instance, `hydrate`);\r\n                        }\r\n                    };\r\n                    if (isAsyncWrapperVNode) {\r\n                        initialVNode.type.__asyncLoader().then(\r\n                        // note: we are moving the render call into an async callback,\r\n                        // which means it won't track dependencies - but it's ok because\r\n                        // a server-rendered async wrapper is already in resolved state\r\n                        // and it will never need to change.\r\n                        () => !instance.isUnmounted && hydrateSubTree());\r\n                    }\r\n                    else {\r\n                        hydrateSubTree();\r\n                    }\r\n                }\r\n                else {\r\n                    if ((process.env.NODE_ENV !== 'production')) {\r\n                        startMeasure(instance, `render`);\r\n                    }\r\n                    const subTree = (instance.subTree = renderComponentRoot(instance));\r\n                    if ((process.env.NODE_ENV !== 'production')) {\r\n                        endMeasure(instance, `render`);\r\n                    }\r\n                    if ((process.env.NODE_ENV !== 'production')) {\r\n                        startMeasure(instance, `patch`);\r\n                    }\r\n                    patch(null, subTree, container, anchor, instance, parentSuspense, isSVG);\r\n                    if ((process.env.NODE_ENV !== 'production')) {\r\n                        endMeasure(instance, `patch`);\r\n                    }\r\n                    initialVNode.el = subTree.el;\r\n                }\r\n                // mounted hook\r\n                if (m) {\r\n                    queuePostRenderEffect(m, parentSuspense);\r\n                }\r\n                // onVnodeMounted\r\n                if (!isAsyncWrapperVNode &&\r\n                    (vnodeHook = props && props.onVnodeMounted)) {\r\n                    const scopedInitialVNode = initialVNode;\r\n                    queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, scopedInitialVNode), parentSuspense);\r\n                }\r\n                // activated hook for keep-alive roots.\r\n                // #1742 activated hook must be accessed after first render\r\n                // since the hook may be injected by a child keep-alive\r\n                if (initialVNode.shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */ ||\r\n                    (parent &&\r\n                        isAsyncWrapper(parent.vnode) &&\r\n                        parent.vnode.shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */)) {\r\n                    instance.a && queuePostRenderEffect(instance.a, parentSuspense);\r\n                }\r\n                instance.isMounted = true;\r\n                if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n                    devtoolsComponentAdded(instance);\r\n                }\r\n                // #2458: deference mount-only object parameters to prevent memleaks\r\n                initialVNode = container = anchor = null;\r\n            }\r\n            else {\r\n                // updateComponent\r\n                // This is triggered by mutation of component's own state (next: null)\r\n                // OR parent calling processComponent (next: VNode)\r\n                let { next, bu, u, parent, vnode } = instance;\r\n                let originNext = next;\r\n                let vnodeHook;\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    pushWarningContext(next || instance.vnode);\r\n                }\r\n                // Disallow component effect recursion during pre-lifecycle hooks.\r\n                toggleRecurse(instance, false);\r\n                if (next) {\r\n                    next.el = vnode.el;\r\n                    updateComponentPreRender(instance, next, optimized);\r\n                }\r\n                else {\r\n                    next = vnode;\r\n                }\r\n                // beforeUpdate hook\r\n                if (bu) {\r\n                    invokeArrayFns(bu);\r\n                }\r\n                // onVnodeBeforeUpdate\r\n                if ((vnodeHook = next.props && next.props.onVnodeBeforeUpdate)) {\r\n                    invokeVNodeHook(vnodeHook, parent, next, vnode);\r\n                }\r\n                toggleRecurse(instance, true);\r\n                // render\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    startMeasure(instance, `render`);\r\n                }\r\n                const nextTree = renderComponentRoot(instance);\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    endMeasure(instance, `render`);\r\n                }\r\n                const prevTree = instance.subTree;\r\n                instance.subTree = nextTree;\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    startMeasure(instance, `patch`);\r\n                }\r\n                patch(prevTree, nextTree, \r\n                // parent may have changed if it's in a teleport\r\n                hostParentNode(prevTree.el), \r\n                // anchor may have changed if it's in a fragment\r\n                getNextHostNode(prevTree), instance, parentSuspense, isSVG);\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    endMeasure(instance, `patch`);\r\n                }\r\n                next.el = nextTree.el;\r\n                if (originNext === null) {\r\n                    // self-triggered update. In case of HOC, update parent component\r\n                    // vnode el. HOC is indicated by parent instance's subTree pointing\r\n                    // to child component's vnode\r\n                    updateHOCHostEl(instance, nextTree.el);\r\n                }\r\n                // updated hook\r\n                if (u) {\r\n                    queuePostRenderEffect(u, parentSuspense);\r\n                }\r\n                // onVnodeUpdated\r\n                if ((vnodeHook = next.props && next.props.onVnodeUpdated)) {\r\n                    queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, next, vnode), parentSuspense);\r\n                }\r\n                if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n                    devtoolsComponentUpdated(instance);\r\n                }\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    popWarningContext();\r\n                }\r\n            }\r\n        };\r\n        // create reactive effect for rendering\r\n        const effect = (instance.effect = new ReactiveEffect(componentUpdateFn, () => queueJob(update), instance.scope // track it in component's effect scope\r\n        ));\r\n        const update = (instance.update = () => effect.run());\r\n        update.id = instance.uid;\r\n        // allowRecurse\r\n        // #1801, #2043 component render effects should allow recursive updates\r\n        toggleRecurse(instance, true);\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            effect.onTrack = instance.rtc\r\n                ? e => invokeArrayFns(instance.rtc, e)\r\n                : void 0;\r\n            effect.onTrigger = instance.rtg\r\n                ? e => invokeArrayFns(instance.rtg, e)\r\n                : void 0;\r\n            update.ownerInstance = instance;\r\n        }\r\n        update();\r\n    };\r\n    const updateComponentPreRender = (instance, nextVNode, optimized) => {\r\n        nextVNode.component = instance;\r\n        const prevProps = instance.vnode.props;\r\n        instance.vnode = nextVNode;\r\n        instance.next = null;\r\n        updateProps(instance, nextVNode.props, prevProps, optimized);\r\n        updateSlots(instance, nextVNode.children, optimized);\r\n        pauseTracking();\r\n        // props update may have triggered pre-flush watchers.\r\n        // flush them before the render update.\r\n        flushPreFlushCbs(undefined, instance.update);\r\n        resetTracking();\r\n    };\r\n    const patchChildren = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized = false) => {\r\n        const c1 = n1 && n1.children;\r\n        const prevShapeFlag = n1 ? n1.shapeFlag : 0;\r\n        const c2 = n2.children;\r\n        const { patchFlag, shapeFlag } = n2;\r\n        // fast path\r\n        if (patchFlag > 0) {\r\n            if (patchFlag & 128 /* KEYED_FRAGMENT */) {\r\n                // this could be either fully-keyed or mixed (some keyed some not)\r\n                // presence of patchFlag means children are guaranteed to be arrays\r\n                patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                return;\r\n            }\r\n            else if (patchFlag & 256 /* UNKEYED_FRAGMENT */) {\r\n                // unkeyed\r\n                patchUnkeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                return;\r\n            }\r\n        }\r\n        // children has 3 possibilities: text, array or no children.\r\n        if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n            // text children fast path\r\n            if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n                unmountChildren(c1, parentComponent, parentSuspense);\r\n            }\r\n            if (c2 !== c1) {\r\n                hostSetElementText(container, c2);\r\n            }\r\n        }\r\n        else {\r\n            if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n                // prev children was array\r\n                if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n                    // two arrays, cannot assume anything, do full diff\r\n                    patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                }\r\n                else {\r\n                    // no new children, just unmount old\r\n                    unmountChildren(c1, parentComponent, parentSuspense, true);\r\n                }\r\n            }\r\n            else {\r\n                // prev children was text OR null\r\n                // new children is array OR null\r\n                if (prevShapeFlag & 8 /* TEXT_CHILDREN */) {\r\n                    hostSetElementText(container, '');\r\n                }\r\n                // mount new if array\r\n                if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n                    mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                }\r\n            }\r\n        }\r\n    };\r\n    const patchUnkeyedChildren = (c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n        c1 = c1 || EMPTY_ARR;\r\n        c2 = c2 || EMPTY_ARR;\r\n        const oldLength = c1.length;\r\n        const newLength = c2.length;\r\n        const commonLength = Math.min(oldLength, newLength);\r\n        let i;\r\n        for (i = 0; i < commonLength; i++) {\r\n            const nextChild = (c2[i] = optimized\r\n                ? cloneIfMounted(c2[i])\r\n                : normalizeVNode(c2[i]));\r\n            patch(c1[i], nextChild, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n        }\r\n        if (oldLength > newLength) {\r\n            // remove old\r\n            unmountChildren(c1, parentComponent, parentSuspense, true, false, commonLength);\r\n        }\r\n        else {\r\n            // mount new\r\n            mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, commonLength);\r\n        }\r\n    };\r\n    // can be all-keyed or mixed\r\n    const patchKeyedChildren = (c1, c2, container, parentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n        let i = 0;\r\n        const l2 = c2.length;\r\n        let e1 = c1.length - 1; // prev ending index\r\n        let e2 = l2 - 1; // next ending index\r\n        // 1. sync from start\r\n        // (a b) c\r\n        // (a b) d e\r\n        while (i <= e1 && i <= e2) {\r\n            const n1 = c1[i];\r\n            const n2 = (c2[i] = optimized\r\n                ? cloneIfMounted(c2[i])\r\n                : normalizeVNode(c2[i]));\r\n            if (isSameVNodeType(n1, n2)) {\r\n                patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n            }\r\n            else {\r\n                break;\r\n            }\r\n            i++;\r\n        }\r\n        // 2. sync from end\r\n        // a (b c)\r\n        // d e (b c)\r\n        while (i <= e1 && i <= e2) {\r\n            const n1 = c1[e1];\r\n            const n2 = (c2[e2] = optimized\r\n                ? cloneIfMounted(c2[e2])\r\n                : normalizeVNode(c2[e2]));\r\n            if (isSameVNodeType(n1, n2)) {\r\n                patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n            }\r\n            else {\r\n                break;\r\n            }\r\n            e1--;\r\n            e2--;\r\n        }\r\n        // 3. common sequence + mount\r\n        // (a b)\r\n        // (a b) c\r\n        // i = 2, e1 = 1, e2 = 2\r\n        // (a b)\r\n        // c (a b)\r\n        // i = 0, e1 = -1, e2 = 0\r\n        if (i > e1) {\r\n            if (i <= e2) {\r\n                const nextPos = e2 + 1;\r\n                const anchor = nextPos < l2 ? c2[nextPos].el : parentAnchor;\r\n                while (i <= e2) {\r\n                    patch(null, (c2[i] = optimized\r\n                        ? cloneIfMounted(c2[i])\r\n                        : normalizeVNode(c2[i])), container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                    i++;\r\n                }\r\n            }\r\n        }\r\n        // 4. common sequence + unmount\r\n        // (a b) c\r\n        // (a b)\r\n        // i = 2, e1 = 2, e2 = 1\r\n        // a (b c)\r\n        // (b c)\r\n        // i = 0, e1 = 0, e2 = -1\r\n        else if (i > e2) {\r\n            while (i <= e1) {\r\n                unmount(c1[i], parentComponent, parentSuspense, true);\r\n                i++;\r\n            }\r\n        }\r\n        // 5. unknown sequence\r\n        // [i ... e1 + 1]: a b [c d e] f g\r\n        // [i ... e2 + 1]: a b [e d c h] f g\r\n        // i = 2, e1 = 4, e2 = 5\r\n        else {\r\n            const s1 = i; // prev starting index\r\n            const s2 = i; // next starting index\r\n            // 5.1 build key:index map for newChildren\r\n            const keyToNewIndexMap = new Map();\r\n            for (i = s2; i <= e2; i++) {\r\n                const nextChild = (c2[i] = optimized\r\n                    ? cloneIfMounted(c2[i])\r\n                    : normalizeVNode(c2[i]));\r\n                if (nextChild.key != null) {\r\n                    if ((process.env.NODE_ENV !== 'production') && keyToNewIndexMap.has(nextChild.key)) {\r\n                        warn(`Duplicate keys found during update:`, JSON.stringify(nextChild.key), `Make sure keys are unique.`);\r\n                    }\r\n                    keyToNewIndexMap.set(nextChild.key, i);\r\n                }\r\n            }\r\n            // 5.2 loop through old children left to be patched and try to patch\r\n            // matching nodes & remove nodes that are no longer present\r\n            let j;\r\n            let patched = 0;\r\n            const toBePatched = e2 - s2 + 1;\r\n            let moved = false;\r\n            // used to track whether any node has moved\r\n            let maxNewIndexSoFar = 0;\r\n            // works as Map<newIndex, oldIndex>\r\n            // Note that oldIndex is offset by +1\r\n            // and oldIndex = 0 is a special value indicating the new node has\r\n            // no corresponding old node.\r\n            // used for determining longest stable subsequence\r\n            const newIndexToOldIndexMap = new Array(toBePatched);\r\n            for (i = 0; i < toBePatched; i++)\r\n                newIndexToOldIndexMap[i] = 0;\r\n            for (i = s1; i <= e1; i++) {\r\n                const prevChild = c1[i];\r\n                if (patched >= toBePatched) {\r\n                    // all new children have been patched so this can only be a removal\r\n                    unmount(prevChild, parentComponent, parentSuspense, true);\r\n                    continue;\r\n                }\r\n                let newIndex;\r\n                if (prevChild.key != null) {\r\n                    newIndex = keyToNewIndexMap.get(prevChild.key);\r\n                }\r\n                else {\r\n                    // key-less node, try to locate a key-less node of the same type\r\n                    for (j = s2; j <= e2; j++) {\r\n                        if (newIndexToOldIndexMap[j - s2] === 0 &&\r\n                            isSameVNodeType(prevChild, c2[j])) {\r\n                            newIndex = j;\r\n                            break;\r\n                        }\r\n                    }\r\n                }\r\n                if (newIndex === undefined) {\r\n                    unmount(prevChild, parentComponent, parentSuspense, true);\r\n                }\r\n                else {\r\n                    newIndexToOldIndexMap[newIndex - s2] = i + 1;\r\n                    if (newIndex >= maxNewIndexSoFar) {\r\n                        maxNewIndexSoFar = newIndex;\r\n                    }\r\n                    else {\r\n                        moved = true;\r\n                    }\r\n                    patch(prevChild, c2[newIndex], container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                    patched++;\r\n                }\r\n            }\r\n            // 5.3 move and mount\r\n            // generate longest stable subsequence only when nodes have moved\r\n            const increasingNewIndexSequence = moved\r\n                ? getSequence(newIndexToOldIndexMap)\r\n                : EMPTY_ARR;\r\n            j = increasingNewIndexSequence.length - 1;\r\n            // looping backwards so that we can use last patched node as anchor\r\n            for (i = toBePatched - 1; i >= 0; i--) {\r\n                const nextIndex = s2 + i;\r\n                const nextChild = c2[nextIndex];\r\n                const anchor = nextIndex + 1 < l2 ? c2[nextIndex + 1].el : parentAnchor;\r\n                if (newIndexToOldIndexMap[i] === 0) {\r\n                    // mount new\r\n                    patch(null, nextChild, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                }\r\n                else if (moved) {\r\n                    // move if:\r\n                    // There is no stable subsequence (e.g. a reverse)\r\n                    // OR current node is not among the stable sequence\r\n                    if (j < 0 || i !== increasingNewIndexSequence[j]) {\r\n                        move(nextChild, container, anchor, 2 /* REORDER */);\r\n                    }\r\n                    else {\r\n                        j--;\r\n                    }\r\n                }\r\n            }\r\n        }\r\n    };\r\n    const move = (vnode, container, anchor, moveType, parentSuspense = null) => {\r\n        const { el, type, transition, children, shapeFlag } = vnode;\r\n        if (shapeFlag & 6 /* COMPONENT */) {\r\n            move(vnode.component.subTree, container, anchor, moveType);\r\n            return;\r\n        }\r\n        if (shapeFlag & 128 /* SUSPENSE */) {\r\n            vnode.suspense.move(container, anchor, moveType);\r\n            return;\r\n        }\r\n        if (shapeFlag & 64 /* TELEPORT */) {\r\n            type.move(vnode, container, anchor, internals);\r\n            return;\r\n        }\r\n        if (type === Fragment) {\r\n            hostInsert(el, container, anchor);\r\n            for (let i = 0; i < children.length; i++) {\r\n                move(children[i], container, anchor, moveType);\r\n            }\r\n            hostInsert(vnode.anchor, container, anchor);\r\n            return;\r\n        }\r\n        if (type === Static) {\r\n            moveStaticNode(vnode, container, anchor);\r\n            return;\r\n        }\r\n        // single nodes\r\n        const needTransition = moveType !== 2 /* REORDER */ &&\r\n            shapeFlag & 1 /* ELEMENT */ &&\r\n            transition;\r\n        if (needTransition) {\r\n            if (moveType === 0 /* ENTER */) {\r\n                transition.beforeEnter(el);\r\n                hostInsert(el, container, anchor);\r\n                queuePostRenderEffect(() => transition.enter(el), parentSuspense);\r\n            }\r\n            else {\r\n                const { leave, delayLeave, afterLeave } = transition;\r\n                const remove = () => hostInsert(el, container, anchor);\r\n                const performLeave = () => {\r\n                    leave(el, () => {\r\n                        remove();\r\n                        afterLeave && afterLeave();\r\n                    });\r\n                };\r\n                if (delayLeave) {\r\n                    delayLeave(el, remove, performLeave);\r\n                }\r\n                else {\r\n                    performLeave();\r\n                }\r\n            }\r\n        }\r\n        else {\r\n            hostInsert(el, container, anchor);\r\n        }\r\n    };\r\n    const unmount = (vnode, parentComponent, parentSuspense, doRemove = false, optimized = false) => {\r\n        const { type, props, ref, children, dynamicChildren, shapeFlag, patchFlag, dirs } = vnode;\r\n        // unset ref\r\n        if (ref != null) {\r\n            setRef(ref, null, parentSuspense, vnode, true);\r\n        }\r\n        if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n            parentComponent.ctx.deactivate(vnode);\r\n            return;\r\n        }\r\n        const shouldInvokeDirs = shapeFlag & 1 /* ELEMENT */ && dirs;\r\n        const shouldInvokeVnodeHook = !isAsyncWrapper(vnode);\r\n        let vnodeHook;\r\n        if (shouldInvokeVnodeHook &&\r\n            (vnodeHook = props && props.onVnodeBeforeUnmount)) {\r\n            invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n        }\r\n        if (shapeFlag & 6 /* COMPONENT */) {\r\n            unmountComponent(vnode.component, parentSuspense, doRemove);\r\n        }\r\n        else {\r\n            if (shapeFlag & 128 /* SUSPENSE */) {\r\n                vnode.suspense.unmount(parentSuspense, doRemove);\r\n                return;\r\n            }\r\n            if (shouldInvokeDirs) {\r\n                invokeDirectiveHook(vnode, null, parentComponent, 'beforeUnmount');\r\n            }\r\n            if (shapeFlag & 64 /* TELEPORT */) {\r\n                vnode.type.remove(vnode, parentComponent, parentSuspense, optimized, internals, doRemove);\r\n            }\r\n            else if (dynamicChildren &&\r\n                // #1153: fast path should not be taken for non-stable (v-for) fragments\r\n                (type !== Fragment ||\r\n                    (patchFlag > 0 && patchFlag & 64 /* STABLE_FRAGMENT */))) {\r\n                // fast path for block nodes: only need to unmount dynamic children.\r\n                unmountChildren(dynamicChildren, parentComponent, parentSuspense, false, true);\r\n            }\r\n            else if ((type === Fragment &&\r\n                patchFlag &\r\n                    (128 /* KEYED_FRAGMENT */ | 256 /* UNKEYED_FRAGMENT */)) ||\r\n                (!optimized && shapeFlag & 16 /* ARRAY_CHILDREN */)) {\r\n                unmountChildren(children, parentComponent, parentSuspense);\r\n            }\r\n            if (doRemove) {\r\n                remove(vnode);\r\n            }\r\n        }\r\n        if ((shouldInvokeVnodeHook &&\r\n            (vnodeHook = props && props.onVnodeUnmounted)) ||\r\n            shouldInvokeDirs) {\r\n            queuePostRenderEffect(() => {\r\n                vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n                shouldInvokeDirs &&\r\n                    invokeDirectiveHook(vnode, null, parentComponent, 'unmounted');\r\n            }, parentSuspense);\r\n        }\r\n    };\r\n    const remove = vnode => {\r\n        const { type, el, anchor, transition } = vnode;\r\n        if (type === Fragment) {\r\n            if ((process.env.NODE_ENV !== 'production') &&\r\n                vnode.patchFlag > 0 &&\r\n                vnode.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */ &&\r\n                transition &&\r\n                !transition.persisted) {\r\n                vnode.children.forEach(child => {\r\n                    if (child.type === Comment) {\r\n                        hostRemove(child.el);\r\n                    }\r\n                    else {\r\n                        remove(child);\r\n                    }\r\n                });\r\n            }\r\n            else {\r\n                removeFragment(el, anchor);\r\n            }\r\n            return;\r\n        }\r\n        if (type === Static) {\r\n            removeStaticNode(vnode);\r\n            return;\r\n        }\r\n        const performRemove = () => {\r\n            hostRemove(el);\r\n            if (transition && !transition.persisted && transition.afterLeave) {\r\n                transition.afterLeave();\r\n            }\r\n        };\r\n        if (vnode.shapeFlag & 1 /* ELEMENT */ &&\r\n            transition &&\r\n            !transition.persisted) {\r\n            const { leave, delayLeave } = transition;\r\n            const performLeave = () => leave(el, performRemove);\r\n            if (delayLeave) {\r\n                delayLeave(vnode.el, performRemove, performLeave);\r\n            }\r\n            else {\r\n                performLeave();\r\n            }\r\n        }\r\n        else {\r\n            performRemove();\r\n        }\r\n    };\r\n    const removeFragment = (cur, end) => {\r\n        // For fragments, directly remove all contained DOM nodes.\r\n        // (fragment child nodes cannot have transition)\r\n        let next;\r\n        while (cur !== end) {\r\n            next = hostNextSibling(cur);\r\n            hostRemove(cur);\r\n            cur = next;\r\n        }\r\n        hostRemove(end);\r\n    };\r\n    const unmountComponent = (instance, parentSuspense, doRemove) => {\r\n        if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n            unregisterHMR(instance);\r\n        }\r\n        const { bum, scope, update, subTree, um } = instance;\r\n        // beforeUnmount hook\r\n        if (bum) {\r\n            invokeArrayFns(bum);\r\n        }\r\n        // stop effects in component scope\r\n        scope.stop();\r\n        // update may be null if a component is unmounted before its async\r\n        // setup has resolved.\r\n        if (update) {\r\n            // so that scheduler will no longer invoke it\r\n            update.active = false;\r\n            unmount(subTree, instance, parentSuspense, doRemove);\r\n        }\r\n        // unmounted hook\r\n        if (um) {\r\n            queuePostRenderEffect(um, parentSuspense);\r\n        }\r\n        queuePostRenderEffect(() => {\r\n            instance.isUnmounted = true;\r\n        }, parentSuspense);\r\n        // A component with async dep inside a pending suspense is unmounted before\r\n        // its async dep resolves. This should remove the dep from the suspense, and\r\n        // cause the suspense to resolve immediately if that was the last dep.\r\n        if (parentSuspense &&\r\n            parentSuspense.pendingBranch &&\r\n            !parentSuspense.isUnmounted &&\r\n            instance.asyncDep &&\r\n            !instance.asyncResolved &&\r\n            instance.suspenseId === parentSuspense.pendingId) {\r\n            parentSuspense.deps--;\r\n            if (parentSuspense.deps === 0) {\r\n                parentSuspense.resolve();\r\n            }\r\n        }\r\n        if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n            devtoolsComponentRemoved(instance);\r\n        }\r\n    };\r\n    const unmountChildren = (children, parentComponent, parentSuspense, doRemove = false, optimized = false, start = 0) => {\r\n        for (let i = start; i < children.length; i++) {\r\n            unmount(children[i], parentComponent, parentSuspense, doRemove, optimized);\r\n        }\r\n    };\r\n    const getNextHostNode = vnode => {\r\n        if (vnode.shapeFlag & 6 /* COMPONENT */) {\r\n            return getNextHostNode(vnode.component.subTree);\r\n        }\r\n        if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n            return vnode.suspense.next();\r\n        }\r\n        return hostNextSibling((vnode.anchor || vnode.el));\r\n    };\r\n    const render = (vnode, container, isSVG) => {\r\n        if (vnode == null) {\r\n            if (container._vnode) {\r\n                unmount(container._vnode, null, null, true);\r\n            }\r\n        }\r\n        else {\r\n            patch(container._vnode || null, vnode, container, null, null, null, isSVG);\r\n        }\r\n        flushPostFlushCbs();\r\n        container._vnode = vnode;\r\n    };\r\n    const internals = {\r\n        p: patch,\r\n        um: unmount,\r\n        m: move,\r\n        r: remove,\r\n        mt: mountComponent,\r\n        mc: mountChildren,\r\n        pc: patchChildren,\r\n        pbc: patchBlockChildren,\r\n        n: getNextHostNode,\r\n        o: options\r\n    };\r\n    let hydrate;\r\n    let hydrateNode;\r\n    if (createHydrationFns) {\r\n        [hydrate, hydrateNode] = createHydrationFns(internals);\r\n    }\r\n    return {\r\n        render,\r\n        hydrate,\r\n        createApp: createAppAPI(render, hydrate)\r\n    };\r\n}\r\nfunction toggleRecurse({ effect, update }, allowed) {\r\n    effect.allowRecurse = update.allowRecurse = allowed;\r\n}\r\n/**\r\n * #1156\r\n * When a component is HMR-enabled, we need to make sure that all static nodes\r\n * inside a block also inherit the DOM element from the previous tree so that\r\n * HMR updates (which are full updates) can retrieve the element for patching.\r\n *\r\n * #2080\r\n * Inside keyed `template` fragment static children, if a fragment is moved,\r\n * the children will always be moved. Therefore, in order to ensure correct move\r\n * position, el should be inherited from previous nodes.\r\n */\r\nfunction traverseStaticChildren(n1, n2, shallow = false) {\r\n    const ch1 = n1.children;\r\n    const ch2 = n2.children;\r\n    if (isArray(ch1) && isArray(ch2)) {\r\n        for (let i = 0; i < ch1.length; i++) {\r\n            // this is only called in the optimized path so array children are\r\n            // guaranteed to be vnodes\r\n            const c1 = ch1[i];\r\n            let c2 = ch2[i];\r\n            if (c2.shapeFlag & 1 /* ELEMENT */ && !c2.dynamicChildren) {\r\n                if (c2.patchFlag <= 0 || c2.patchFlag === 32 /* HYDRATE_EVENTS */) {\r\n                    c2 = ch2[i] = cloneIfMounted(ch2[i]);\r\n                    c2.el = c1.el;\r\n                }\r\n                if (!shallow)\r\n                    traverseStaticChildren(c1, c2);\r\n            }\r\n            // also inherit for comment nodes, but not placeholders (e.g. v-if which\r\n            // would have received .el during block patch)\r\n            if ((process.env.NODE_ENV !== 'production') && c2.type === Comment && !c2.el) {\r\n                c2.el = c1.el;\r\n            }\r\n        }\r\n    }\r\n}\r\n// https://en.wikipedia.org/wiki/Longest_increasing_subsequence\r\nfunction getSequence(arr) {\r\n    const p = arr.slice();\r\n    const result = [0];\r\n    let i, j, u, v, c;\r\n    const len = arr.length;\r\n    for (i = 0; i < len; i++) {\r\n        const arrI = arr[i];\r\n        if (arrI !== 0) {\r\n            j = result[result.length - 1];\r\n            if (arr[j] < arrI) {\r\n                p[i] = j;\r\n                result.push(i);\r\n                continue;\r\n            }\r\n            u = 0;\r\n            v = result.length - 1;\r\n            while (u < v) {\r\n                c = (u + v) >> 1;\r\n                if (arr[result[c]] < arrI) {\r\n                    u = c + 1;\r\n                }\r\n                else {\r\n                    v = c;\r\n                }\r\n            }\r\n            if (arrI < arr[result[u]]) {\r\n                if (u > 0) {\r\n                    p[i] = result[u - 1];\r\n                }\r\n                result[u] = i;\r\n            }\r\n        }\r\n    }\r\n    u = result.length;\r\n    v = result[u - 1];\r\n    while (u-- > 0) {\r\n        result[u] = v;\r\n        v = p[v];\r\n    }\r\n    return result;\r\n}\n\nconst isTeleport = (type) => type.__isTeleport;\r\nconst isTeleportDisabled = (props) => props && (props.disabled || props.disabled === '');\r\nconst isTargetSVG = (target) => typeof SVGElement !== 'undefined' && target instanceof SVGElement;\r\nconst resolveTarget = (props, select) => {\r\n    const targetSelector = props && props.to;\r\n    if (isString(targetSelector)) {\r\n        if (!select) {\r\n            (process.env.NODE_ENV !== 'production') &&\r\n                warn(`Current renderer does not support string target for Teleports. ` +\r\n                    `(missing querySelector renderer option)`);\r\n            return null;\r\n        }\r\n        else {\r\n            const target = select(targetSelector);\r\n            if (!target) {\r\n                (process.env.NODE_ENV !== 'production') &&\r\n                    warn(`Failed to locate Teleport target with selector \"${targetSelector}\". ` +\r\n                        `Note the target element must exist before the component is mounted - ` +\r\n                        `i.e. the target cannot be rendered by the component itself, and ` +\r\n                        `ideally should be outside of the entire Vue component tree.`);\r\n            }\r\n            return target;\r\n        }\r\n    }\r\n    else {\r\n        if ((process.env.NODE_ENV !== 'production') && !targetSelector && !isTeleportDisabled(props)) {\r\n            warn(`Invalid Teleport target: ${targetSelector}`);\r\n        }\r\n        return targetSelector;\r\n    }\r\n};\r\nconst TeleportImpl = {\r\n    __isTeleport: true,\r\n    process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals) {\r\n        const { mc: mountChildren, pc: patchChildren, pbc: patchBlockChildren, o: { insert, querySelector, createText, createComment } } = internals;\r\n        const disabled = isTeleportDisabled(n2.props);\r\n        let { shapeFlag, children, dynamicChildren } = n2;\r\n        // #3302\r\n        // HMR updated, force full diff\r\n        if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n            optimized = false;\r\n            dynamicChildren = null;\r\n        }\r\n        if (n1 == null) {\r\n            // insert anchors in the main view\r\n            const placeholder = (n2.el = (process.env.NODE_ENV !== 'production')\r\n                ? createComment('teleport start')\r\n                : createText(''));\r\n            const mainAnchor = (n2.anchor = (process.env.NODE_ENV !== 'production')\r\n                ? createComment('teleport end')\r\n                : createText(''));\r\n            insert(placeholder, container, anchor);\r\n            insert(mainAnchor, container, anchor);\r\n            const target = (n2.target = resolveTarget(n2.props, querySelector));\r\n            const targetAnchor = (n2.targetAnchor = createText(''));\r\n            if (target) {\r\n                insert(targetAnchor, target);\r\n                // #2652 we could be teleporting from a non-SVG tree into an SVG tree\r\n                isSVG = isSVG || isTargetSVG(target);\r\n            }\r\n            else if ((process.env.NODE_ENV !== 'production') && !disabled) {\r\n                warn('Invalid Teleport target on mount:', target, `(${typeof target})`);\r\n            }\r\n            const mount = (container, anchor) => {\r\n                // Teleport *always* has Array children. This is enforced in both the\r\n                // compiler and vnode children normalization.\r\n                if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n                    mountChildren(children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n                }\r\n            };\r\n            if (disabled) {\r\n                mount(container, mainAnchor);\r\n            }\r\n            else if (target) {\r\n                mount(target, targetAnchor);\r\n            }\r\n        }\r\n        else {\r\n            // update content\r\n            n2.el = n1.el;\r\n            const mainAnchor = (n2.anchor = n1.anchor);\r\n            const target = (n2.target = n1.target);\r\n            const targetAnchor = (n2.targetAnchor = n1.targetAnchor);\r\n            const wasDisabled = isTeleportDisabled(n1.props);\r\n            const currentContainer = wasDisabled ? container : target;\r\n            const currentAnchor = wasDisabled ? mainAnchor : targetAnchor;\r\n            isSVG = isSVG || isTargetSVG(target);\r\n            if (dynamicChildren) {\r\n                // fast path when the teleport happens to be a block root\r\n                patchBlockChildren(n1.dynamicChildren, dynamicChildren, currentContainer, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n                // even in block tree mode we need to make sure all root-level nodes\r\n                // in the teleport inherit previous DOM references so that they can\r\n                // be moved in future patches.\r\n                traverseStaticChildren(n1, n2, true);\r\n            }\r\n            else if (!optimized) {\r\n                patchChildren(n1, n2, currentContainer, currentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, false);\r\n            }\r\n            if (disabled) {\r\n                if (!wasDisabled) {\r\n                    // enabled -> disabled\r\n                    // move into main container\r\n                    moveTeleport(n2, container, mainAnchor, internals, 1 /* TOGGLE */);\r\n                }\r\n            }\r\n            else {\r\n                // target changed\r\n                if ((n2.props && n2.props.to) !== (n1.props && n1.props.to)) {\r\n                    const nextTarget = (n2.target = resolveTarget(n2.props, querySelector));\r\n                    if (nextTarget) {\r\n                        moveTeleport(n2, nextTarget, null, internals, 0 /* TARGET_CHANGE */);\r\n                    }\r\n                    else if ((process.env.NODE_ENV !== 'production')) {\r\n                        warn('Invalid Teleport target on update:', target, `(${typeof target})`);\r\n                    }\r\n                }\r\n                else if (wasDisabled) {\r\n                    // disabled -> enabled\r\n                    // move into teleport target\r\n                    moveTeleport(n2, target, targetAnchor, internals, 1 /* TOGGLE */);\r\n                }\r\n            }\r\n        }\r\n    },\r\n    remove(vnode, parentComponent, parentSuspense, optimized, { um: unmount, o: { remove: hostRemove } }, doRemove) {\r\n        const { shapeFlag, children, anchor, targetAnchor, target, props } = vnode;\r\n        if (target) {\r\n            hostRemove(targetAnchor);\r\n        }\r\n        // an unmounted teleport should always remove its children if not disabled\r\n        if (doRemove || !isTeleportDisabled(props)) {\r\n            hostRemove(anchor);\r\n            if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n                for (let i = 0; i < children.length; i++) {\r\n                    const child = children[i];\r\n                    unmount(child, parentComponent, parentSuspense, true, !!child.dynamicChildren);\r\n                }\r\n            }\r\n        }\r\n    },\r\n    move: moveTeleport,\r\n    hydrate: hydrateTeleport\r\n};\r\nfunction moveTeleport(vnode, container, parentAnchor, { o: { insert }, m: move }, moveType = 2 /* REORDER */) {\r\n    // move target anchor if this is a target change.\r\n    if (moveType === 0 /* TARGET_CHANGE */) {\r\n        insert(vnode.targetAnchor, container, parentAnchor);\r\n    }\r\n    const { el, anchor, shapeFlag, children, props } = vnode;\r\n    const isReorder = moveType === 2 /* REORDER */;\r\n    // move main view anchor if this is a re-order.\r\n    if (isReorder) {\r\n        insert(el, container, parentAnchor);\r\n    }\r\n    // if this is a re-order and teleport is enabled (content is in target)\r\n    // do not move children. So the opposite is: only move children if this\r\n    // is not a reorder, or the teleport is disabled\r\n    if (!isReorder || isTeleportDisabled(props)) {\r\n        // Teleport has either Array children or no children.\r\n        if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n            for (let i = 0; i < children.length; i++) {\r\n                move(children[i], container, parentAnchor, 2 /* REORDER */);\r\n            }\r\n        }\r\n    }\r\n    // move main view anchor if this is a re-order.\r\n    if (isReorder) {\r\n        insert(anchor, container, parentAnchor);\r\n    }\r\n}\r\nfunction hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, { o: { nextSibling, parentNode, querySelector } }, hydrateChildren) {\r\n    const target = (vnode.target = resolveTarget(vnode.props, querySelector));\r\n    if (target) {\r\n        // if multiple teleports rendered to the same target element, we need to\r\n        // pick up from where the last teleport finished instead of the first node\r\n        const targetNode = target._lpa || target.firstChild;\r\n        if (vnode.shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n            if (isTeleportDisabled(vnode.props)) {\r\n                vnode.anchor = hydrateChildren(nextSibling(node), vnode, parentNode(node), parentComponent, parentSuspense, slotScopeIds, optimized);\r\n                vnode.targetAnchor = targetNode;\r\n            }\r\n            else {\r\n                vnode.anchor = nextSibling(node);\r\n                // lookahead until we find the target anchor\r\n                // we cannot rely on return value of hydrateChildren() because there\r\n                // could be nested teleports\r\n                let targetAnchor = targetNode;\r\n                while (targetAnchor) {\r\n                    targetAnchor = nextSibling(targetAnchor);\r\n                    if (targetAnchor &&\r\n                        targetAnchor.nodeType === 8 &&\r\n                        targetAnchor.data === 'teleport anchor') {\r\n                        vnode.targetAnchor = targetAnchor;\r\n                        target._lpa =\r\n                            vnode.targetAnchor && nextSibling(vnode.targetAnchor);\r\n                        break;\r\n                    }\r\n                }\r\n                hydrateChildren(targetNode, vnode, target, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n            }\r\n        }\r\n    }\r\n    return vnode.anchor && nextSibling(vnode.anchor);\r\n}\r\n// Force-casted public typing for h and TSX props inference\r\nconst Teleport = TeleportImpl;\n\nconst Fragment = Symbol((process.env.NODE_ENV !== 'production') ? 'Fragment' : undefined);\r\nconst Text = Symbol((process.env.NODE_ENV !== 'production') ? 'Text' : undefined);\r\nconst Comment = Symbol((process.env.NODE_ENV !== 'production') ? 'Comment' : undefined);\r\nconst Static = Symbol((process.env.NODE_ENV !== 'production') ? 'Static' : undefined);\r\n// Since v-if and v-for are the two possible ways node structure can dynamically\r\n// change, once we consider v-if branches and each v-for fragment a block, we\r\n// can divide a template into nested blocks, and within each block the node\r\n// structure would be stable. This allows us to skip most children diffing\r\n// and only worry about the dynamic nodes (indicated by patch flags).\r\nconst blockStack = [];\r\nlet currentBlock = null;\r\n/**\r\n * Open a block.\r\n * This must be called before `createBlock`. It cannot be part of `createBlock`\r\n * because the children of the block are evaluated before `createBlock` itself\r\n * is called. The generated code typically looks like this:\r\n *\r\n * ```js\r\n * function render() {\r\n *   return (openBlock(),createBlock('div', null, [...]))\r\n * }\r\n * ```\r\n * disableTracking is true when creating a v-for fragment block, since a v-for\r\n * fragment always diffs its children.\r\n *\r\n * @private\r\n */\r\nfunction openBlock(disableTracking = false) {\r\n    blockStack.push((currentBlock = disableTracking ? null : []));\r\n}\r\nfunction closeBlock() {\r\n    blockStack.pop();\r\n    currentBlock = blockStack[blockStack.length - 1] || null;\r\n}\r\n// Whether we should be tracking dynamic child nodes inside a block.\r\n// Only tracks when this value is > 0\r\n// We are not using a simple boolean because this value may need to be\r\n// incremented/decremented by nested usage of v-once (see below)\r\nlet isBlockTreeEnabled = 1;\r\n/**\r\n * Block tracking sometimes needs to be disabled, for example during the\r\n * creation of a tree that needs to be cached by v-once. The compiler generates\r\n * code like this:\r\n *\r\n * ``` js\r\n * _cache[1] || (\r\n *   setBlockTracking(-1),\r\n *   _cache[1] = createVNode(...),\r\n *   setBlockTracking(1),\r\n *   _cache[1]\r\n * )\r\n * ```\r\n *\r\n * @private\r\n */\r\nfunction setBlockTracking(value) {\r\n    isBlockTreeEnabled += value;\r\n}\r\nfunction setupBlock(vnode) {\r\n    // save current block children on the block vnode\r\n    vnode.dynamicChildren =\r\n        isBlockTreeEnabled > 0 ? currentBlock || EMPTY_ARR : null;\r\n    // close block\r\n    closeBlock();\r\n    // a block is always going to be patched, so track it as a child of its\r\n    // parent block\r\n    if (isBlockTreeEnabled > 0 && currentBlock) {\r\n        currentBlock.push(vnode);\r\n    }\r\n    return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createElementBlock(type, props, children, patchFlag, dynamicProps, shapeFlag) {\r\n    return setupBlock(createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, true /* isBlock */));\r\n}\r\n/**\r\n * Create a block root vnode. Takes the same exact arguments as `createVNode`.\r\n * A block root keeps track of dynamic nodes within the block in the\r\n * `dynamicChildren` array.\r\n *\r\n * @private\r\n */\r\nfunction createBlock(type, props, children, patchFlag, dynamicProps) {\r\n    return setupBlock(createVNode(type, props, children, patchFlag, dynamicProps, true /* isBlock: prevent a block from tracking itself */));\r\n}\r\nfunction isVNode(value) {\r\n    return value ? value.__v_isVNode === true : false;\r\n}\r\nfunction isSameVNodeType(n1, n2) {\r\n    if ((process.env.NODE_ENV !== 'production') &&\r\n        n2.shapeFlag & 6 /* COMPONENT */ &&\r\n        hmrDirtyComponents.has(n2.type)) {\r\n        // HMR only: if the component has been hot-updated, force a reload.\r\n        return false;\r\n    }\r\n    return n1.type === n2.type && n1.key === n2.key;\r\n}\r\nlet vnodeArgsTransformer;\r\n/**\r\n * Internal API for registering an arguments transform for createVNode\r\n * used for creating stubs in the test-utils\r\n * It is *internal* but needs to be exposed for test-utils to pick up proper\r\n * typings\r\n */\r\nfunction transformVNodeArgs(transformer) {\r\n    vnodeArgsTransformer = transformer;\r\n}\r\nconst createVNodeWithArgsTransform = (...args) => {\r\n    return _createVNode(...(vnodeArgsTransformer\r\n        ? vnodeArgsTransformer(args, currentRenderingInstance)\r\n        : args));\r\n};\r\nconst InternalObjectKey = `__vInternal`;\r\nconst normalizeKey = ({ key }) => key != null ? key : null;\r\nconst normalizeRef = ({ ref, ref_key, ref_for }) => {\r\n    return (ref != null\r\n        ? isString(ref) || isRef(ref) || isFunction(ref)\r\n            ? { i: currentRenderingInstance, r: ref, k: ref_key, f: !!ref_for }\r\n            : ref\r\n        : null);\r\n};\r\nfunction createBaseVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, shapeFlag = type === Fragment ? 0 : 1 /* ELEMENT */, isBlockNode = false, needFullChildrenNormalization = false) {\r\n    const vnode = {\r\n        __v_isVNode: true,\r\n        __v_skip: true,\r\n        type,\r\n        props,\r\n        key: props && normalizeKey(props),\r\n        ref: props && normalizeRef(props),\r\n        scopeId: currentScopeId,\r\n        slotScopeIds: null,\r\n        children,\r\n        component: null,\r\n        suspense: null,\r\n        ssContent: null,\r\n        ssFallback: null,\r\n        dirs: null,\r\n        transition: null,\r\n        el: null,\r\n        anchor: null,\r\n        target: null,\r\n        targetAnchor: null,\r\n        staticCount: 0,\r\n        shapeFlag,\r\n        patchFlag,\r\n        dynamicProps,\r\n        dynamicChildren: null,\r\n        appContext: null\r\n    };\r\n    if (needFullChildrenNormalization) {\r\n        normalizeChildren(vnode, children);\r\n        // normalize suspense children\r\n        if (shapeFlag & 128 /* SUSPENSE */) {\r\n            type.normalize(vnode);\r\n        }\r\n    }\r\n    else if (children) {\r\n        // compiled element vnode - if children is passed, only possible types are\r\n        // string or Array.\r\n        vnode.shapeFlag |= isString(children)\r\n            ? 8 /* TEXT_CHILDREN */\r\n            : 16 /* ARRAY_CHILDREN */;\r\n    }\r\n    // validate key\r\n    if ((process.env.NODE_ENV !== 'production') && vnode.key !== vnode.key) {\r\n        warn(`VNode created with invalid key (NaN). VNode type:`, vnode.type);\r\n    }\r\n    // track vnode for block tree\r\n    if (isBlockTreeEnabled > 0 &&\r\n        // avoid a block node from tracking itself\r\n        !isBlockNode &&\r\n        // has current parent block\r\n        currentBlock &&\r\n        // presence of a patch flag indicates this node needs patching on updates.\r\n        // component nodes also should always be patched, because even if the\r\n        // component doesn't need to update, it needs to persist the instance on to\r\n        // the next vnode so that it can be properly unmounted later.\r\n        (vnode.patchFlag > 0 || shapeFlag & 6 /* COMPONENT */) &&\r\n        // the EVENTS flag is only for hydration and if it is the only flag, the\r\n        // vnode should not be considered dynamic due to handler caching.\r\n        vnode.patchFlag !== 32 /* HYDRATE_EVENTS */) {\r\n        currentBlock.push(vnode);\r\n    }\r\n    return vnode;\r\n}\r\nconst createVNode = ((process.env.NODE_ENV !== 'production') ? createVNodeWithArgsTransform : _createVNode);\r\nfunction _createVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, isBlockNode = false) {\r\n    if (!type || type === NULL_DYNAMIC_COMPONENT) {\r\n        if ((process.env.NODE_ENV !== 'production') && !type) {\r\n            warn(`Invalid vnode type when creating vnode: ${type}.`);\r\n        }\r\n        type = Comment;\r\n    }\r\n    if (isVNode(type)) {\r\n        // createVNode receiving an existing vnode. This happens in cases like\r\n        // <component :is=\"vnode\"/>\r\n        // #2078 make sure to merge refs during the clone instead of overwriting it\r\n        const cloned = cloneVNode(type, props, true /* mergeRef: true */);\r\n        if (children) {\r\n            normalizeChildren(cloned, children);\r\n        }\r\n        if (isBlockTreeEnabled > 0 && !isBlockNode && currentBlock) {\r\n            if (cloned.shapeFlag & 6 /* COMPONENT */) {\r\n                currentBlock[currentBlock.indexOf(type)] = cloned;\r\n            }\r\n            else {\r\n                currentBlock.push(cloned);\r\n            }\r\n        }\r\n        cloned.patchFlag |= -2 /* BAIL */;\r\n        return cloned;\r\n    }\r\n    // class component normalization.\r\n    if (isClassComponent(type)) {\r\n        type = type.__vccOpts;\r\n    }\r\n    // class & style normalization.\r\n    if (props) {\r\n        // for reactive or proxy objects, we need to clone it to enable mutation.\r\n        props = guardReactiveProps(props);\r\n        let { class: klass, style } = props;\r\n        if (klass && !isString(klass)) {\r\n            props.class = normalizeClass(klass);\r\n        }\r\n        if (isObject(style)) {\r\n            // reactive state objects need to be cloned since they are likely to be\r\n            // mutated\r\n            if (isProxy(style) && !isArray(style)) {\r\n                style = extend({}, style);\r\n            }\r\n            props.style = normalizeStyle(style);\r\n        }\r\n    }\r\n    // encode the vnode type information into a bitmap\r\n    const shapeFlag = isString(type)\r\n        ? 1 /* ELEMENT */\r\n        : isSuspense(type)\r\n            ? 128 /* SUSPENSE */\r\n            : isTeleport(type)\r\n                ? 64 /* TELEPORT */\r\n                : isObject(type)\r\n                    ? 4 /* STATEFUL_COMPONENT */\r\n                    : isFunction(type)\r\n                        ? 2 /* FUNCTIONAL_COMPONENT */\r\n                        : 0;\r\n    if ((process.env.NODE_ENV !== 'production') && shapeFlag & 4 /* STATEFUL_COMPONENT */ && isProxy(type)) {\r\n        type = toRaw(type);\r\n        warn(`Vue received a Component which was made a reactive object. This can ` +\r\n            `lead to unnecessary performance overhead, and should be avoided by ` +\r\n            `marking the component with \\`markRaw\\` or using \\`shallowRef\\` ` +\r\n            `instead of \\`ref\\`.`, `\\nComponent that was made reactive: `, type);\r\n    }\r\n    return createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, isBlockNode, true);\r\n}\r\nfunction guardReactiveProps(props) {\r\n    if (!props)\r\n        return null;\r\n    return isProxy(props) || InternalObjectKey in props\r\n        ? extend({}, props)\r\n        : props;\r\n}\r\nfunction cloneVNode(vnode, extraProps, mergeRef = false) {\r\n    // This is intentionally NOT using spread or extend to avoid the runtime\r\n    // key enumeration cost.\r\n    const { props, ref, patchFlag, children } = vnode;\r\n    const mergedProps = extraProps ? mergeProps(props || {}, extraProps) : props;\r\n    const cloned = {\r\n        __v_isVNode: true,\r\n        __v_skip: true,\r\n        type: vnode.type,\r\n        props: mergedProps,\r\n        key: mergedProps && normalizeKey(mergedProps),\r\n        ref: extraProps && extraProps.ref\r\n            ? // #2078 in the case of <component :is=\"vnode\" ref=\"extra\"/>\r\n                // if the vnode itself already has a ref, cloneVNode will need to merge\r\n                // the refs so the single vnode can be set on multiple refs\r\n                mergeRef && ref\r\n                    ? isArray(ref)\r\n                        ? ref.concat(normalizeRef(extraProps))\r\n                        : [ref, normalizeRef(extraProps)]\r\n                    : normalizeRef(extraProps)\r\n            : ref,\r\n        scopeId: vnode.scopeId,\r\n        slotScopeIds: vnode.slotScopeIds,\r\n        children: (process.env.NODE_ENV !== 'production') && patchFlag === -1 /* HOISTED */ && isArray(children)\r\n            ? children.map(deepCloneVNode)\r\n            : children,\r\n        target: vnode.target,\r\n        targetAnchor: vnode.targetAnchor,\r\n        staticCount: vnode.staticCount,\r\n        shapeFlag: vnode.shapeFlag,\r\n        // if the vnode is cloned with extra props, we can no longer assume its\r\n        // existing patch flag to be reliable and need to add the FULL_PROPS flag.\r\n        // note: preserve flag for fragments since they use the flag for children\r\n        // fast paths only.\r\n        patchFlag: extraProps && vnode.type !== Fragment\r\n            ? patchFlag === -1 // hoisted node\r\n                ? 16 /* FULL_PROPS */\r\n                : patchFlag | 16 /* FULL_PROPS */\r\n            : patchFlag,\r\n        dynamicProps: vnode.dynamicProps,\r\n        dynamicChildren: vnode.dynamicChildren,\r\n        appContext: vnode.appContext,\r\n        dirs: vnode.dirs,\r\n        transition: vnode.transition,\r\n        // These should technically only be non-null on mounted VNodes. However,\r\n        // they *should* be copied for kept-alive vnodes. So we just always copy\r\n        // them since them being non-null during a mount doesn't affect the logic as\r\n        // they will simply be overwritten.\r\n        component: vnode.component,\r\n        suspense: vnode.suspense,\r\n        ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),\r\n        ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),\r\n        el: vnode.el,\r\n        anchor: vnode.anchor\r\n    };\r\n    return cloned;\r\n}\r\n/**\r\n * Dev only, for HMR of hoisted vnodes reused in v-for\r\n * https://github.com/vitejs/vite/issues/2022\r\n */\r\nfunction deepCloneVNode(vnode) {\r\n    const cloned = cloneVNode(vnode);\r\n    if (isArray(vnode.children)) {\r\n        cloned.children = vnode.children.map(deepCloneVNode);\r\n    }\r\n    return cloned;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createTextVNode(text = ' ', flag = 0) {\r\n    return createVNode(Text, null, text, flag);\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createStaticVNode(content, numberOfNodes) {\r\n    // A static vnode can contain multiple stringified elements, and the number\r\n    // of elements is necessary for hydration.\r\n    const vnode = createVNode(Static, null, content);\r\n    vnode.staticCount = numberOfNodes;\r\n    return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createCommentVNode(text = '', \r\n// when used as the v-else branch, the comment node must be created as a\r\n// block to ensure correct updates.\r\nasBlock = false) {\r\n    return asBlock\r\n        ? (openBlock(), createBlock(Comment, null, text))\r\n        : createVNode(Comment, null, text);\r\n}\r\nfunction normalizeVNode(child) {\r\n    if (child == null || typeof child === 'boolean') {\r\n        // empty placeholder\r\n        return createVNode(Comment);\r\n    }\r\n    else if (isArray(child)) {\r\n        // fragment\r\n        return createVNode(Fragment, null, \r\n        // #3666, avoid reference pollution when reusing vnode\r\n        child.slice());\r\n    }\r\n    else if (typeof child === 'object') {\r\n        // already vnode, this should be the most common since compiled templates\r\n        // always produce all-vnode children arrays\r\n        return cloneIfMounted(child);\r\n    }\r\n    else {\r\n        // strings and numbers\r\n        return createVNode(Text, null, String(child));\r\n    }\r\n}\r\n// optimized normalization for template-compiled render fns\r\nfunction cloneIfMounted(child) {\r\n    return child.el === null || child.memo ? child : cloneVNode(child);\r\n}\r\nfunction normalizeChildren(vnode, children) {\r\n    let type = 0;\r\n    const { shapeFlag } = vnode;\r\n    if (children == null) {\r\n        children = null;\r\n    }\r\n    else if (isArray(children)) {\r\n        type = 16 /* ARRAY_CHILDREN */;\r\n    }\r\n    else if (typeof children === 'object') {\r\n        if (shapeFlag & (1 /* ELEMENT */ | 64 /* TELEPORT */)) {\r\n            // Normalize slot to plain children for plain element and Teleport\r\n            const slot = children.default;\r\n            if (slot) {\r\n                // _c marker is added by withCtx() indicating this is a compiled slot\r\n                slot._c && (slot._d = false);\r\n                normalizeChildren(vnode, slot());\r\n                slot._c && (slot._d = true);\r\n            }\r\n            return;\r\n        }\r\n        else {\r\n            type = 32 /* SLOTS_CHILDREN */;\r\n            const slotFlag = children._;\r\n            if (!slotFlag && !(InternalObjectKey in children)) {\r\n                children._ctx = currentRenderingInstance;\r\n            }\r\n            else if (slotFlag === 3 /* FORWARDED */ && currentRenderingInstance) {\r\n                // a child component receives forwarded slots from the parent.\r\n                // its slot type is determined by its parent's slot type.\r\n                if (currentRenderingInstance.slots._ === 1 /* STABLE */) {\r\n                    children._ = 1 /* STABLE */;\r\n                }\r\n                else {\r\n                    children._ = 2 /* DYNAMIC */;\r\n                    vnode.patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n                }\r\n            }\r\n        }\r\n    }\r\n    else if (isFunction(children)) {\r\n        children = { default: children, _ctx: currentRenderingInstance };\r\n        type = 32 /* SLOTS_CHILDREN */;\r\n    }\r\n    else {\r\n        children = String(children);\r\n        // force teleport children to array so it can be moved around\r\n        if (shapeFlag & 64 /* TELEPORT */) {\r\n            type = 16 /* ARRAY_CHILDREN */;\r\n            children = [createTextVNode(children)];\r\n        }\r\n        else {\r\n            type = 8 /* TEXT_CHILDREN */;\r\n        }\r\n    }\r\n    vnode.children = children;\r\n    vnode.shapeFlag |= type;\r\n}\r\nfunction mergeProps(...args) {\r\n    const ret = {};\r\n    for (let i = 0; i < args.length; i++) {\r\n        const toMerge = args[i];\r\n        for (const key in toMerge) {\r\n            if (key === 'class') {\r\n                if (ret.class !== toMerge.class) {\r\n                    ret.class = normalizeClass([ret.class, toMerge.class]);\r\n                }\r\n            }\r\n            else if (key === 'style') {\r\n                ret.style = normalizeStyle([ret.style, toMerge.style]);\r\n            }\r\n            else if (isOn(key)) {\r\n                const existing = ret[key];\r\n                const incoming = toMerge[key];\r\n                if (incoming &&\r\n                    existing !== incoming &&\r\n                    !(isArray(existing) && existing.includes(incoming))) {\r\n                    ret[key] = existing\r\n                        ? [].concat(existing, incoming)\r\n                        : incoming;\r\n                }\r\n            }\r\n            else if (key !== '') {\r\n                ret[key] = toMerge[key];\r\n            }\r\n        }\r\n    }\r\n    return ret;\r\n}\r\nfunction invokeVNodeHook(hook, instance, vnode, prevVNode = null) {\r\n    callWithAsyncErrorHandling(hook, instance, 7 /* VNODE_HOOK */, [\r\n        vnode,\r\n        prevVNode\r\n    ]);\r\n}\n\nconst emptyAppContext = createAppContext();\r\nlet uid$1 = 0;\r\nfunction createComponentInstance(vnode, parent, suspense) {\r\n    const type = vnode.type;\r\n    // inherit parent app context - or - if root, adopt from root vnode\r\n    const appContext = (parent ? parent.appContext : vnode.appContext) || emptyAppContext;\r\n    const instance = {\r\n        uid: uid$1++,\r\n        vnode,\r\n        type,\r\n        parent,\r\n        appContext,\r\n        root: null,\r\n        next: null,\r\n        subTree: null,\r\n        effect: null,\r\n        update: null,\r\n        scope: new EffectScope(true /* detached */),\r\n        render: null,\r\n        proxy: null,\r\n        exposed: null,\r\n        exposeProxy: null,\r\n        withProxy: null,\r\n        provides: parent ? parent.provides : Object.create(appContext.provides),\r\n        accessCache: null,\r\n        renderCache: [],\r\n        // local resolved assets\r\n        components: null,\r\n        directives: null,\r\n        // resolved props and emits options\r\n        propsOptions: normalizePropsOptions(type, appContext),\r\n        emitsOptions: normalizeEmitsOptions(type, appContext),\r\n        // emit\r\n        emit: null,\r\n        emitted: null,\r\n        // props default value\r\n        propsDefaults: EMPTY_OBJ,\r\n        // inheritAttrs\r\n        inheritAttrs: type.inheritAttrs,\r\n        // state\r\n        ctx: EMPTY_OBJ,\r\n        data: EMPTY_OBJ,\r\n        props: EMPTY_OBJ,\r\n        attrs: EMPTY_OBJ,\r\n        slots: EMPTY_OBJ,\r\n        refs: EMPTY_OBJ,\r\n        setupState: EMPTY_OBJ,\r\n        setupContext: null,\r\n        // suspense related\r\n        suspense,\r\n        suspenseId: suspense ? suspense.pendingId : 0,\r\n        asyncDep: null,\r\n        asyncResolved: false,\r\n        // lifecycle hooks\r\n        // not using enums here because it results in computed properties\r\n        isMounted: false,\r\n        isUnmounted: false,\r\n        isDeactivated: false,\r\n        bc: null,\r\n        c: null,\r\n        bm: null,\r\n        m: null,\r\n        bu: null,\r\n        u: null,\r\n        um: null,\r\n        bum: null,\r\n        da: null,\r\n        a: null,\r\n        rtg: null,\r\n        rtc: null,\r\n        ec: null,\r\n        sp: null\r\n    };\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        instance.ctx = createDevRenderContext(instance);\r\n    }\r\n    else {\r\n        instance.ctx = { _: instance };\r\n    }\r\n    instance.root = parent ? parent.root : instance;\r\n    instance.emit = emit$1.bind(null, instance);\r\n    // apply custom element special handling\r\n    if (vnode.ce) {\r\n        vnode.ce(instance);\r\n    }\r\n    return instance;\r\n}\r\nlet currentInstance = null;\r\nconst getCurrentInstance = () => currentInstance || currentRenderingInstance;\r\nconst setCurrentInstance = (instance) => {\r\n    currentInstance = instance;\r\n    instance.scope.on();\r\n};\r\nconst unsetCurrentInstance = () => {\r\n    currentInstance && currentInstance.scope.off();\r\n    currentInstance = null;\r\n};\r\nconst isBuiltInTag = /*#__PURE__*/ makeMap('slot,component');\r\nfunction validateComponentName(name, config) {\r\n    const appIsNativeTag = config.isNativeTag || NO;\r\n    if (isBuiltInTag(name) || appIsNativeTag(name)) {\r\n        warn('Do not use built-in or reserved HTML elements as component id: ' + name);\r\n    }\r\n}\r\nfunction isStatefulComponent(instance) {\r\n    return instance.vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */;\r\n}\r\nlet isInSSRComponentSetup = false;\r\nfunction setupComponent(instance, isSSR = false) {\r\n    isInSSRComponentSetup = isSSR;\r\n    const { props, children } = instance.vnode;\r\n    const isStateful = isStatefulComponent(instance);\r\n    initProps(instance, props, isStateful, isSSR);\r\n    initSlots(instance, children);\r\n    const setupResult = isStateful\r\n        ? setupStatefulComponent(instance, isSSR)\r\n        : undefined;\r\n    isInSSRComponentSetup = false;\r\n    return setupResult;\r\n}\r\nfunction setupStatefulComponent(instance, isSSR) {\r\n    var _a;\r\n    const Component = instance.type;\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        if (Component.name) {\r\n            validateComponentName(Component.name, instance.appContext.config);\r\n        }\r\n        if (Component.components) {\r\n            const names = Object.keys(Component.components);\r\n            for (let i = 0; i < names.length; i++) {\r\n                validateComponentName(names[i], instance.appContext.config);\r\n            }\r\n        }\r\n        if (Component.directives) {\r\n            const names = Object.keys(Component.directives);\r\n            for (let i = 0; i < names.length; i++) {\r\n                validateDirectiveName(names[i]);\r\n            }\r\n        }\r\n        if (Component.compilerOptions && isRuntimeOnly()) {\r\n            warn(`\"compilerOptions\" is only supported when using a build of Vue that ` +\r\n                `includes the runtime compiler. Since you are using a runtime-only ` +\r\n                `build, the options should be passed via your build tool config instead.`);\r\n        }\r\n    }\r\n    // 0. create render proxy property access cache\r\n    instance.accessCache = Object.create(null);\r\n    // 1. create public instance / render proxy\r\n    // also mark it raw so it's never observed\r\n    instance.proxy = markRaw(new Proxy(instance.ctx, PublicInstanceProxyHandlers));\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        exposePropsOnRenderContext(instance);\r\n    }\r\n    // 2. call setup()\r\n    const { setup } = Component;\r\n    if (setup) {\r\n        const setupContext = (instance.setupContext =\r\n            setup.length > 1 ? createSetupContext(instance) : null);\r\n        setCurrentInstance(instance);\r\n        pauseTracking();\r\n        const setupResult = callWithErrorHandling(setup, instance, 0 /* SETUP_FUNCTION */, [(process.env.NODE_ENV !== 'production') ? shallowReadonly(instance.props) : instance.props, setupContext]);\r\n        resetTracking();\r\n        unsetCurrentInstance();\r\n        if (isPromise(setupResult)) {\r\n            setupResult.then(unsetCurrentInstance, unsetCurrentInstance);\r\n            if (isSSR) {\r\n                // return the promise so server-renderer can wait on it\r\n                return setupResult\r\n                    .then((resolvedResult) => {\r\n                    handleSetupResult(instance, resolvedResult, isSSR);\r\n                })\r\n                    .catch(e => {\r\n                    handleError(e, instance, 0 /* SETUP_FUNCTION */);\r\n                });\r\n            }\r\n            else {\r\n                // async setup returned Promise.\r\n                // bail here and wait for re-entry.\r\n                instance.asyncDep = setupResult;\r\n                if ((process.env.NODE_ENV !== 'production') && !instance.suspense) {\r\n                    const name = (_a = Component.name) !== null && _a !== void 0 ? _a : 'Anonymous';\r\n                    warn(`Component <${name}>: setup function returned a promise, but no ` +\r\n                        `<Suspense> boundary was found in the parent component tree. ` +\r\n                        `A component with async setup() must be nested in a <Suspense> ` +\r\n                        `in order to be rendered.`);\r\n                }\r\n            }\r\n        }\r\n        else {\r\n            handleSetupResult(instance, setupResult, isSSR);\r\n        }\r\n    }\r\n    else {\r\n        finishComponentSetup(instance, isSSR);\r\n    }\r\n}\r\nfunction handleSetupResult(instance, setupResult, isSSR) {\r\n    if (isFunction(setupResult)) {\r\n        // setup returned an inline render function\r\n        if (instance.type.__ssrInlineRender) {\r\n            // when the function's name is `ssrRender` (compiled by SFC inline mode),\r\n            // set it as ssrRender instead.\r\n            instance.ssrRender = setupResult;\r\n        }\r\n        else {\r\n            instance.render = setupResult;\r\n        }\r\n    }\r\n    else if (isObject(setupResult)) {\r\n        if ((process.env.NODE_ENV !== 'production') && isVNode(setupResult)) {\r\n            warn(`setup() should not return VNodes directly - ` +\r\n                `return a render function instead.`);\r\n        }\r\n        // setup returned bindings.\r\n        // assuming a render function compiled from template is present.\r\n        if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n            instance.devtoolsRawSetupState = setupResult;\r\n        }\r\n        instance.setupState = proxyRefs(setupResult);\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            exposeSetupStateOnRenderContext(instance);\r\n        }\r\n    }\r\n    else if ((process.env.NODE_ENV !== 'production') && setupResult !== undefined) {\r\n        warn(`setup() should return an object. Received: ${setupResult === null ? 'null' : typeof setupResult}`);\r\n    }\r\n    finishComponentSetup(instance, isSSR);\r\n}\r\nlet compile;\r\nlet installWithProxy;\r\n/**\r\n * For runtime-dom to register the compiler.\r\n * Note the exported method uses any to avoid d.ts relying on the compiler types.\r\n */\r\nfunction registerRuntimeCompiler(_compile) {\r\n    compile = _compile;\r\n    installWithProxy = i => {\r\n        if (i.render._rc) {\r\n            i.withProxy = new Proxy(i.ctx, RuntimeCompiledPublicInstanceProxyHandlers);\r\n        }\r\n    };\r\n}\r\n// dev only\r\nconst isRuntimeOnly = () => !compile;\r\nfunction finishComponentSetup(instance, isSSR, skipOptions) {\r\n    const Component = instance.type;\r\n    // template / render function normalization\r\n    // could be already set when returned from setup()\r\n    if (!instance.render) {\r\n        // only do on-the-fly compile if not in SSR - SSR on-the-fly compilation\r\n        // is done by server-renderer\r\n        if (!isSSR && compile && !Component.render) {\r\n            const template = Component.template;\r\n            if (template) {\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    startMeasure(instance, `compile`);\r\n                }\r\n                const { isCustomElement, compilerOptions } = instance.appContext.config;\r\n                const { delimiters, compilerOptions: componentCompilerOptions } = Component;\r\n                const finalCompilerOptions = extend(extend({\r\n                    isCustomElement,\r\n                    delimiters\r\n                }, compilerOptions), componentCompilerOptions);\r\n                Component.render = compile(template, finalCompilerOptions);\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    endMeasure(instance, `compile`);\r\n                }\r\n            }\r\n        }\r\n        instance.render = (Component.render || NOOP);\r\n        // for runtime-compiled render functions using `with` blocks, the render\r\n        // proxy used needs a different `has` handler which is more performant and\r\n        // also only allows a whitelist of globals to fallthrough.\r\n        if (installWithProxy) {\r\n            installWithProxy(instance);\r\n        }\r\n    }\r\n    // support for 2.x options\r\n    if (__VUE_OPTIONS_API__ && !(false )) {\r\n        setCurrentInstance(instance);\r\n        pauseTracking();\r\n        applyOptions(instance);\r\n        resetTracking();\r\n        unsetCurrentInstance();\r\n    }\r\n    // warn missing template/render\r\n    // the runtime compilation of template in SSR is done by server-render\r\n    if ((process.env.NODE_ENV !== 'production') && !Component.render && instance.render === NOOP && !isSSR) {\r\n        /* istanbul ignore if */\r\n        if (!compile && Component.template) {\r\n            warn(`Component provided template option but ` +\r\n                `runtime compilation is not supported in this build of Vue.` +\r\n                (` Configure your bundler to alias \"vue\" to \"vue/dist/vue.esm-bundler.js\".`\r\n                    ) /* should not happen */);\r\n        }\r\n        else {\r\n            warn(`Component is missing template or render function.`);\r\n        }\r\n    }\r\n}\r\nfunction createAttrsProxy(instance) {\r\n    return new Proxy(instance.attrs, (process.env.NODE_ENV !== 'production')\r\n        ? {\r\n            get(target, key) {\r\n                markAttrsAccessed();\r\n                track(instance, \"get\" /* GET */, '$attrs');\r\n                return target[key];\r\n            },\r\n            set() {\r\n                warn(`setupContext.attrs is readonly.`);\r\n                return false;\r\n            },\r\n            deleteProperty() {\r\n                warn(`setupContext.attrs is readonly.`);\r\n                return false;\r\n            }\r\n        }\r\n        : {\r\n            get(target, key) {\r\n                track(instance, \"get\" /* GET */, '$attrs');\r\n                return target[key];\r\n            }\r\n        });\r\n}\r\nfunction createSetupContext(instance) {\r\n    const expose = exposed => {\r\n        if ((process.env.NODE_ENV !== 'production') && instance.exposed) {\r\n            warn(`expose() should be called only once per setup().`);\r\n        }\r\n        instance.exposed = exposed || {};\r\n    };\r\n    let attrs;\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        // We use getters in dev in case libs like test-utils overwrite instance\r\n        // properties (overwrites should not be done in prod)\r\n        return Object.freeze({\r\n            get attrs() {\r\n                return attrs || (attrs = createAttrsProxy(instance));\r\n            },\r\n            get slots() {\r\n                return shallowReadonly(instance.slots);\r\n            },\r\n            get emit() {\r\n                return (event, ...args) => instance.emit(event, ...args);\r\n            },\r\n            expose\r\n        });\r\n    }\r\n    else {\r\n        return {\r\n            get attrs() {\r\n                return attrs || (attrs = createAttrsProxy(instance));\r\n            },\r\n            slots: instance.slots,\r\n            emit: instance.emit,\r\n            expose\r\n        };\r\n    }\r\n}\r\nfunction getExposeProxy(instance) {\r\n    if (instance.exposed) {\r\n        return (instance.exposeProxy ||\r\n            (instance.exposeProxy = new Proxy(proxyRefs(markRaw(instance.exposed)), {\r\n                get(target, key) {\r\n                    if (key in target) {\r\n                        return target[key];\r\n                    }\r\n                    else if (key in publicPropertiesMap) {\r\n                        return publicPropertiesMap[key](instance);\r\n                    }\r\n                }\r\n            })));\r\n    }\r\n}\r\nconst classifyRE = /(?:^|[-_])(\\w)/g;\r\nconst classify = (str) => str.replace(classifyRE, c => c.toUpperCase()).replace(/[-_]/g, '');\r\nfunction getComponentName(Component, includeInferred = true) {\r\n    return isFunction(Component)\r\n        ? Component.displayName || Component.name\r\n        : Component.name || (includeInferred && Component.__name);\r\n}\r\n/* istanbul ignore next */\r\nfunction formatComponentName(instance, Component, isRoot = false) {\r\n    let name = getComponentName(Component);\r\n    if (!name && Component.__file) {\r\n        const match = Component.__file.match(/([^/\\\\]+)\\.\\w+$/);\r\n        if (match) {\r\n            name = match[1];\r\n        }\r\n    }\r\n    if (!name && instance && instance.parent) {\r\n        // try to infer the name based on reverse resolution\r\n        const inferFromRegistry = (registry) => {\r\n            for (const key in registry) {\r\n                if (registry[key] === Component) {\r\n                    return key;\r\n                }\r\n            }\r\n        };\r\n        name =\r\n            inferFromRegistry(instance.components ||\r\n                instance.parent.type.components) || inferFromRegistry(instance.appContext.components);\r\n    }\r\n    return name ? classify(name) : isRoot ? `App` : `Anonymous`;\r\n}\r\nfunction isClassComponent(value) {\r\n    return isFunction(value) && '__vccOpts' in value;\r\n}\n\nconst computed = ((getterOrOptions, debugOptions) => {\r\n    // @ts-ignore\r\n    return computed$1(getterOrOptions, debugOptions, isInSSRComponentSetup);\r\n});\n\n// dev only\r\nconst warnRuntimeUsage = (method) => warn(`${method}() is a compiler-hint helper that is only usable inside ` +\r\n    `<script setup> of a single file component. Its arguments should be ` +\r\n    `compiled away and passing it at runtime has no effect.`);\r\n// implementation\r\nfunction defineProps() {\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        warnRuntimeUsage(`defineProps`);\r\n    }\r\n    return null;\r\n}\r\n// implementation\r\nfunction defineEmits() {\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        warnRuntimeUsage(`defineEmits`);\r\n    }\r\n    return null;\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for declaring a component's exposed\r\n * instance properties when it is accessed by a parent component via template\r\n * refs.\r\n *\r\n * `<script setup>` components are closed by default - i.e. variables inside\r\n * the `<script setup>` scope is not exposed to parent unless explicitly exposed\r\n * via `defineExpose`.\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the\r\n * output and should **not** be actually called at runtime.\r\n */\r\nfunction defineExpose(exposed) {\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        warnRuntimeUsage(`defineExpose`);\r\n    }\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for providing props default values when\r\n * using type-based `defineProps` declaration.\r\n *\r\n * Example usage:\r\n * ```ts\r\n * withDefaults(defineProps<{\r\n *   size?: number\r\n *   labels?: string[]\r\n * }>(), {\r\n *   size: 3,\r\n *   labels: () => ['default label']\r\n * })\r\n * ```\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the output\r\n * and should **not** be actually called at runtime.\r\n */\r\nfunction withDefaults(props, defaults) {\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        warnRuntimeUsage(`withDefaults`);\r\n    }\r\n    return null;\r\n}\r\nfunction useSlots() {\r\n    return getContext().slots;\r\n}\r\nfunction useAttrs() {\r\n    return getContext().attrs;\r\n}\r\nfunction getContext() {\r\n    const i = getCurrentInstance();\r\n    if ((process.env.NODE_ENV !== 'production') && !i) {\r\n        warn(`useContext() called without active instance.`);\r\n    }\r\n    return i.setupContext || (i.setupContext = createSetupContext(i));\r\n}\r\n/**\r\n * Runtime helper for merging default declarations. Imported by compiled code\r\n * only.\r\n * @internal\r\n */\r\nfunction mergeDefaults(raw, defaults) {\r\n    const props = isArray(raw)\r\n        ? raw.reduce((normalized, p) => ((normalized[p] = {}), normalized), {})\r\n        : raw;\r\n    for (const key in defaults) {\r\n        const opt = props[key];\r\n        if (opt) {\r\n            if (isArray(opt) || isFunction(opt)) {\r\n                props[key] = { type: opt, default: defaults[key] };\r\n            }\r\n            else {\r\n                opt.default = defaults[key];\r\n            }\r\n        }\r\n        else if (opt === null) {\r\n            props[key] = { default: defaults[key] };\r\n        }\r\n        else if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`props default key \"${key}\" has no corresponding declaration.`);\r\n        }\r\n    }\r\n    return props;\r\n}\r\n/**\r\n * Used to create a proxy for the rest element when destructuring props with\r\n * defineProps().\r\n * @internal\r\n */\r\nfunction createPropsRestProxy(props, excludedKeys) {\r\n    const ret = {};\r\n    for (const key in props) {\r\n        if (!excludedKeys.includes(key)) {\r\n            Object.defineProperty(ret, key, {\r\n                enumerable: true,\r\n                get: () => props[key]\r\n            });\r\n        }\r\n    }\r\n    return ret;\r\n}\r\n/**\r\n * `<script setup>` helper for persisting the current instance context over\r\n * async/await flows.\r\n *\r\n * `@vue/compiler-sfc` converts the following:\r\n *\r\n * ```ts\r\n * const x = await foo()\r\n * ```\r\n *\r\n * into:\r\n *\r\n * ```ts\r\n * let __temp, __restore\r\n * const x = (([__temp, __restore] = withAsyncContext(() => foo())),__temp=await __temp,__restore(),__temp)\r\n * ```\r\n * @internal\r\n */\r\nfunction withAsyncContext(getAwaitable) {\r\n    const ctx = getCurrentInstance();\r\n    if ((process.env.NODE_ENV !== 'production') && !ctx) {\r\n        warn(`withAsyncContext called without active current instance. ` +\r\n            `This is likely a bug.`);\r\n    }\r\n    let awaitable = getAwaitable();\r\n    unsetCurrentInstance();\r\n    if (isPromise(awaitable)) {\r\n        awaitable = awaitable.catch(e => {\r\n            setCurrentInstance(ctx);\r\n            throw e;\r\n        });\r\n    }\r\n    return [awaitable, () => setCurrentInstance(ctx)];\r\n}\n\n// Actual implementation\r\nfunction h(type, propsOrChildren, children) {\r\n    const l = arguments.length;\r\n    if (l === 2) {\r\n        if (isObject(propsOrChildren) && !isArray(propsOrChildren)) {\r\n            // single vnode without props\r\n            if (isVNode(propsOrChildren)) {\r\n                return createVNode(type, null, [propsOrChildren]);\r\n            }\r\n            // props without children\r\n            return createVNode(type, propsOrChildren);\r\n        }\r\n        else {\r\n            // omit props\r\n            return createVNode(type, null, propsOrChildren);\r\n        }\r\n    }\r\n    else {\r\n        if (l > 3) {\r\n            children = Array.prototype.slice.call(arguments, 2);\r\n        }\r\n        else if (l === 3 && isVNode(children)) {\r\n            children = [children];\r\n        }\r\n        return createVNode(type, propsOrChildren, children);\r\n    }\r\n}\n\nconst ssrContextKey = Symbol((process.env.NODE_ENV !== 'production') ? `ssrContext` : ``);\r\nconst useSSRContext = () => {\r\n    {\r\n        const ctx = inject(ssrContextKey);\r\n        if (!ctx) {\r\n            warn(`Server rendering context not provided. Make sure to only call ` +\r\n                `useSSRContext() conditionally in the server build.`);\r\n        }\r\n        return ctx;\r\n    }\r\n};\n\nfunction isShallow(value) {\r\n    return !!(value && value[\"__v_isShallow\" /* IS_SHALLOW */]);\r\n}\n\nfunction initCustomFormatter() {\r\n    /* eslint-disable no-restricted-globals */\r\n    if (!(process.env.NODE_ENV !== 'production') || typeof window === 'undefined') {\r\n        return;\r\n    }\r\n    const vueStyle = { style: 'color:#3ba776' };\r\n    const numberStyle = { style: 'color:#0b1bc9' };\r\n    const stringStyle = { style: 'color:#b62e24' };\r\n    const keywordStyle = { style: 'color:#9d288c' };\r\n    // custom formatter for Chrome\r\n    // https://www.mattzeunert.com/2016/02/19/custom-chrome-devtools-object-formatters.html\r\n    const formatter = {\r\n        header(obj) {\r\n            // TODO also format ComponentPublicInstance & ctx.slots/attrs in setup\r\n            if (!isObject(obj)) {\r\n                return null;\r\n            }\r\n            if (obj.__isVue) {\r\n                return ['div', vueStyle, `VueInstance`];\r\n            }\r\n            else if (isRef(obj)) {\r\n                return [\r\n                    'div',\r\n                    {},\r\n                    ['span', vueStyle, genRefFlag(obj)],\r\n                    '<',\r\n                    formatValue(obj.value),\r\n                    `>`\r\n                ];\r\n            }\r\n            else if (isReactive(obj)) {\r\n                return [\r\n                    'div',\r\n                    {},\r\n                    ['span', vueStyle, isShallow(obj) ? 'ShallowReactive' : 'Reactive'],\r\n                    '<',\r\n                    formatValue(obj),\r\n                    `>${isReadonly(obj) ? ` (readonly)` : ``}`\r\n                ];\r\n            }\r\n            else if (isReadonly(obj)) {\r\n                return [\r\n                    'div',\r\n                    {},\r\n                    ['span', vueStyle, isShallow(obj) ? 'ShallowReadonly' : 'Readonly'],\r\n                    '<',\r\n                    formatValue(obj),\r\n                    '>'\r\n                ];\r\n            }\r\n            return null;\r\n        },\r\n        hasBody(obj) {\r\n            return obj && obj.__isVue;\r\n        },\r\n        body(obj) {\r\n            if (obj && obj.__isVue) {\r\n                return [\r\n                    'div',\r\n                    {},\r\n                    ...formatInstance(obj.$)\r\n                ];\r\n            }\r\n        }\r\n    };\r\n    function formatInstance(instance) {\r\n        const blocks = [];\r\n        if (instance.type.props && instance.props) {\r\n            blocks.push(createInstanceBlock('props', toRaw(instance.props)));\r\n        }\r\n        if (instance.setupState !== EMPTY_OBJ) {\r\n            blocks.push(createInstanceBlock('setup', instance.setupState));\r\n        }\r\n        if (instance.data !== EMPTY_OBJ) {\r\n            blocks.push(createInstanceBlock('data', toRaw(instance.data)));\r\n        }\r\n        const computed = extractKeys(instance, 'computed');\r\n        if (computed) {\r\n            blocks.push(createInstanceBlock('computed', computed));\r\n        }\r\n        const injected = extractKeys(instance, 'inject');\r\n        if (injected) {\r\n            blocks.push(createInstanceBlock('injected', injected));\r\n        }\r\n        blocks.push([\r\n            'div',\r\n            {},\r\n            [\r\n                'span',\r\n                {\r\n                    style: keywordStyle.style + ';opacity:0.66'\r\n                },\r\n                '$ (internal): '\r\n            ],\r\n            ['object', { object: instance }]\r\n        ]);\r\n        return blocks;\r\n    }\r\n    function createInstanceBlock(type, target) {\r\n        target = extend({}, target);\r\n        if (!Object.keys(target).length) {\r\n            return ['span', {}];\r\n        }\r\n        return [\r\n            'div',\r\n            { style: 'line-height:1.25em;margin-bottom:0.6em' },\r\n            [\r\n                'div',\r\n                {\r\n                    style: 'color:#476582'\r\n                },\r\n                type\r\n            ],\r\n            [\r\n                'div',\r\n                {\r\n                    style: 'padding-left:1.25em'\r\n                },\r\n                ...Object.keys(target).map(key => {\r\n                    return [\r\n                        'div',\r\n                        {},\r\n                        ['span', keywordStyle, key + ': '],\r\n                        formatValue(target[key], false)\r\n                    ];\r\n                })\r\n            ]\r\n        ];\r\n    }\r\n    function formatValue(v, asRaw = true) {\r\n        if (typeof v === 'number') {\r\n            return ['span', numberStyle, v];\r\n        }\r\n        else if (typeof v === 'string') {\r\n            return ['span', stringStyle, JSON.stringify(v)];\r\n        }\r\n        else if (typeof v === 'boolean') {\r\n            return ['span', keywordStyle, v];\r\n        }\r\n        else if (isObject(v)) {\r\n            return ['object', { object: asRaw ? toRaw(v) : v }];\r\n        }\r\n        else {\r\n            return ['span', stringStyle, String(v)];\r\n        }\r\n    }\r\n    function extractKeys(instance, type) {\r\n        const Comp = instance.type;\r\n        if (isFunction(Comp)) {\r\n            return;\r\n        }\r\n        const extracted = {};\r\n        for (const key in instance.ctx) {\r\n            if (isKeyOfType(Comp, key, type)) {\r\n                extracted[key] = instance.ctx[key];\r\n            }\r\n        }\r\n        return extracted;\r\n    }\r\n    function isKeyOfType(Comp, key, type) {\r\n        const opts = Comp[type];\r\n        if ((isArray(opts) && opts.includes(key)) ||\r\n            (isObject(opts) && key in opts)) {\r\n            return true;\r\n        }\r\n        if (Comp.extends && isKeyOfType(Comp.extends, key, type)) {\r\n            return true;\r\n        }\r\n        if (Comp.mixins && Comp.mixins.some(m => isKeyOfType(m, key, type))) {\r\n            return true;\r\n        }\r\n    }\r\n    function genRefFlag(v) {\r\n        if (isShallow(v)) {\r\n            return `ShallowRef`;\r\n        }\r\n        if (v.effect) {\r\n            return `ComputedRef`;\r\n        }\r\n        return `Ref`;\r\n    }\r\n    if (window.devtoolsFormatters) {\r\n        window.devtoolsFormatters.push(formatter);\r\n    }\r\n    else {\r\n        window.devtoolsFormatters = [formatter];\r\n    }\r\n}\n\nfunction withMemo(memo, render, cache, index) {\r\n    const cached = cache[index];\r\n    if (cached && isMemoSame(cached, memo)) {\r\n        return cached;\r\n    }\r\n    const ret = render();\r\n    // shallow clone\r\n    ret.memo = memo.slice();\r\n    return (cache[index] = ret);\r\n}\r\nfunction isMemoSame(cached, memo) {\r\n    const prev = cached.memo;\r\n    if (prev.length != memo.length) {\r\n        return false;\r\n    }\r\n    for (let i = 0; i < prev.length; i++) {\r\n        if (hasChanged(prev[i], memo[i])) {\r\n            return false;\r\n        }\r\n    }\r\n    // make sure to let parent block track it when returning cached\r\n    if (isBlockTreeEnabled > 0 && currentBlock) {\r\n        currentBlock.push(cached);\r\n    }\r\n    return true;\r\n}\n\n// Core API ------------------------------------------------------------------\r\nconst version = \"3.2.37\";\r\nconst _ssrUtils = {\r\n    createComponentInstance,\r\n    setupComponent,\r\n    renderComponentRoot,\r\n    setCurrentRenderingInstance,\r\n    isVNode,\r\n    normalizeVNode\r\n};\r\n/**\r\n * SSR utils for \\@vue/server-renderer. Only exposed in ssr-possible builds.\r\n * @internal\r\n */\r\nconst ssrUtils = (_ssrUtils );\r\n/**\r\n * @internal only exposed in compat builds\r\n */\r\nconst resolveFilter = null;\r\n/**\r\n * @internal only exposed in compat builds.\r\n */\r\nconst compatUtils = (null);\n\nexport { BaseTransition, Comment, Fragment, KeepAlive, Static, Suspense, Teleport, Text, callWithAsyncErrorHandling, callWithErrorHandling, cloneVNode, compatUtils, computed, createBlock, createCommentVNode, createElementBlock, createBaseVNode as createElementVNode, createHydrationRenderer, createPropsRestProxy, createRenderer, createSlots, createStaticVNode, createTextVNode, createVNode, defineAsyncComponent, defineComponent, defineEmits, defineExpose, defineProps, devtools, getCurrentInstance, getTransitionRawChildren, guardReactiveProps, h, handleError, initCustomFormatter, inject, isMemoSame, isRuntimeOnly, isVNode, mergeDefaults, mergeProps, nextTick, onActivated, onBeforeMount, onBeforeUnmount, onBeforeUpdate, onDeactivated, onErrorCaptured, onMounted, onRenderTracked, onRenderTriggered, onServerPrefetch, onUnmounted, onUpdated, openBlock, popScopeId, provide, pushScopeId, queuePostFlushCb, registerRuntimeCompiler, renderList, renderSlot, resolveComponent, resolveDirective, resolveDynamicComponent, resolveFilter, resolveTransitionHooks, setBlockTracking, setDevtoolsHook, setTransitionHooks, ssrContextKey, ssrUtils, toHandlers, transformVNodeArgs, useAttrs, useSSRContext, useSlots, useTransitionState, version, warn, watch, watchEffect, watchPostEffect, watchSyncEffect, withAsyncContext, withCtx, withDefaults, withDirectives, withMemo, withScopeId };\n","import { camelize, warn, callWithAsyncErrorHandling, defineComponent, nextTick, createVNode, getCurrentInstance, watchPostEffect, onMounted, onUnmounted, Fragment, Static, h, BaseTransition, useTransitionState, onUpdated, toRaw, getTransitionRawChildren, setTransitionHooks, resolveTransitionHooks, createRenderer, isRuntimeOnly, createHydrationRenderer } from '@vue/runtime-core';\nexport * from '@vue/runtime-core';\nimport { isString, isArray, hyphenate, capitalize, isSpecialBooleanAttr, includeBooleanAttr, isOn, isModelListener, isFunction, toNumber, camelize as camelize$1, extend, EMPTY_OBJ, isObject, invokeArrayFns, looseIndexOf, isSet, looseEqual, isHTMLTag, isSVGTag } from '@vue/shared';\n\nconst svgNS = 'http://www.w3.org/2000/svg';\r\nconst doc = (typeof document !== 'undefined' ? document : null);\r\nconst templateContainer = doc && /*#__PURE__*/ doc.createElement('template');\r\nconst nodeOps = {\r\n    insert: (child, parent, anchor) => {\r\n        parent.insertBefore(child, anchor || null);\r\n    },\r\n    remove: child => {\r\n        const parent = child.parentNode;\r\n        if (parent) {\r\n            parent.removeChild(child);\r\n        }\r\n    },\r\n    createElement: (tag, isSVG, is, props) => {\r\n        const el = isSVG\r\n            ? doc.createElementNS(svgNS, tag)\r\n            : doc.createElement(tag, is ? { is } : undefined);\r\n        if (tag === 'select' && props && props.multiple != null) {\r\n            el.setAttribute('multiple', props.multiple);\r\n        }\r\n        return el;\r\n    },\r\n    createText: text => doc.createTextNode(text),\r\n    createComment: text => doc.createComment(text),\r\n    setText: (node, text) => {\r\n        node.nodeValue = text;\r\n    },\r\n    setElementText: (el, text) => {\r\n        el.textContent = text;\r\n    },\r\n    parentNode: node => node.parentNode,\r\n    nextSibling: node => node.nextSibling,\r\n    querySelector: selector => doc.querySelector(selector),\r\n    setScopeId(el, id) {\r\n        el.setAttribute(id, '');\r\n    },\r\n    cloneNode(el) {\r\n        const cloned = el.cloneNode(true);\r\n        // #3072\r\n        // - in `patchDOMProp`, we store the actual value in the `el._value` property.\r\n        // - normally, elements using `:value` bindings will not be hoisted, but if\r\n        //   the bound value is a constant, e.g. `:value=\"true\"` - they do get\r\n        //   hoisted.\r\n        // - in production, hoisted nodes are cloned when subsequent inserts, but\r\n        //   cloneNode() does not copy the custom property we attached.\r\n        // - This may need to account for other custom DOM properties we attach to\r\n        //   elements in addition to `_value` in the future.\r\n        if (`_value` in el) {\r\n            cloned._value = el._value;\r\n        }\r\n        return cloned;\r\n    },\r\n    // __UNSAFE__\r\n    // Reason: innerHTML.\r\n    // Static content here can only come from compiled templates.\r\n    // As long as the user only uses trusted templates, this is safe.\r\n    insertStaticContent(content, parent, anchor, isSVG, start, end) {\r\n        // <parent> before | first ... last | anchor </parent>\r\n        const before = anchor ? anchor.previousSibling : parent.lastChild;\r\n        // #5308 can only take cached path if:\r\n        // - has a single root node\r\n        // - nextSibling info is still available\r\n        if (start && (start === end || start.nextSibling)) {\r\n            // cached\r\n            while (true) {\r\n                parent.insertBefore(start.cloneNode(true), anchor);\r\n                if (start === end || !(start = start.nextSibling))\r\n                    break;\r\n            }\r\n        }\r\n        else {\r\n            // fresh insert\r\n            templateContainer.innerHTML = isSVG ? `<svg>${content}</svg>` : content;\r\n            const template = templateContainer.content;\r\n            if (isSVG) {\r\n                // remove outer svg wrapper\r\n                const wrapper = template.firstChild;\r\n                while (wrapper.firstChild) {\r\n                    template.appendChild(wrapper.firstChild);\r\n                }\r\n                template.removeChild(wrapper);\r\n            }\r\n            parent.insertBefore(template, anchor);\r\n        }\r\n        return [\r\n            // first\r\n            before ? before.nextSibling : parent.firstChild,\r\n            // last\r\n            anchor ? anchor.previousSibling : parent.lastChild\r\n        ];\r\n    }\r\n};\n\n// compiler should normalize class + :class bindings on the same element\r\n// into a single binding ['staticClass', dynamic]\r\nfunction patchClass(el, value, isSVG) {\r\n    // directly setting className should be faster than setAttribute in theory\r\n    // if this is an element during a transition, take the temporary transition\r\n    // classes into account.\r\n    const transitionClasses = el._vtc;\r\n    if (transitionClasses) {\r\n        value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(' ');\r\n    }\r\n    if (value == null) {\r\n        el.removeAttribute('class');\r\n    }\r\n    else if (isSVG) {\r\n        el.setAttribute('class', value);\r\n    }\r\n    else {\r\n        el.className = value;\r\n    }\r\n}\n\nfunction patchStyle(el, prev, next) {\r\n    const style = el.style;\r\n    const isCssString = isString(next);\r\n    if (next && !isCssString) {\r\n        for (const key in next) {\r\n            setStyle(style, key, next[key]);\r\n        }\r\n        if (prev && !isString(prev)) {\r\n            for (const key in prev) {\r\n                if (next[key] == null) {\r\n                    setStyle(style, key, '');\r\n                }\r\n            }\r\n        }\r\n    }\r\n    else {\r\n        const currentDisplay = style.display;\r\n        if (isCssString) {\r\n            if (prev !== next) {\r\n                style.cssText = next;\r\n            }\r\n        }\r\n        else if (prev) {\r\n            el.removeAttribute('style');\r\n        }\r\n        // indicates that the `display` of the element is controlled by `v-show`,\r\n        // so we always keep the current `display` value regardless of the `style`\r\n        // value, thus handing over control to `v-show`.\r\n        if ('_vod' in el) {\r\n            style.display = currentDisplay;\r\n        }\r\n    }\r\n}\r\nconst importantRE = /\\s*!important$/;\r\nfunction setStyle(style, name, val) {\r\n    if (isArray(val)) {\r\n        val.forEach(v => setStyle(style, name, v));\r\n    }\r\n    else {\r\n        if (val == null)\r\n            val = '';\r\n        if (name.startsWith('--')) {\r\n            // custom property definition\r\n            style.setProperty(name, val);\r\n        }\r\n        else {\r\n            const prefixed = autoPrefix(style, name);\r\n            if (importantRE.test(val)) {\r\n                // !important\r\n                style.setProperty(hyphenate(prefixed), val.replace(importantRE, ''), 'important');\r\n            }\r\n            else {\r\n                style[prefixed] = val;\r\n            }\r\n        }\r\n    }\r\n}\r\nconst prefixes = ['Webkit', 'Moz', 'ms'];\r\nconst prefixCache = {};\r\nfunction autoPrefix(style, rawName) {\r\n    const cached = prefixCache[rawName];\r\n    if (cached) {\r\n        return cached;\r\n    }\r\n    let name = camelize(rawName);\r\n    if (name !== 'filter' && name in style) {\r\n        return (prefixCache[rawName] = name);\r\n    }\r\n    name = capitalize(name);\r\n    for (let i = 0; i < prefixes.length; i++) {\r\n        const prefixed = prefixes[i] + name;\r\n        if (prefixed in style) {\r\n            return (prefixCache[rawName] = prefixed);\r\n        }\r\n    }\r\n    return rawName;\r\n}\n\nconst xlinkNS = 'http://www.w3.org/1999/xlink';\r\nfunction patchAttr(el, key, value, isSVG, instance) {\r\n    if (isSVG && key.startsWith('xlink:')) {\r\n        if (value == null) {\r\n            el.removeAttributeNS(xlinkNS, key.slice(6, key.length));\r\n        }\r\n        else {\r\n            el.setAttributeNS(xlinkNS, key, value);\r\n        }\r\n    }\r\n    else {\r\n        // note we are only checking boolean attributes that don't have a\r\n        // corresponding dom prop of the same name here.\r\n        const isBoolean = isSpecialBooleanAttr(key);\r\n        if (value == null || (isBoolean && !includeBooleanAttr(value))) {\r\n            el.removeAttribute(key);\r\n        }\r\n        else {\r\n            el.setAttribute(key, isBoolean ? '' : value);\r\n        }\r\n    }\r\n}\n\n// __UNSAFE__\r\n// functions. The user is responsible for using them with only trusted content.\r\nfunction patchDOMProp(el, key, value, \r\n// the following args are passed only due to potential innerHTML/textContent\r\n// overriding existing VNodes, in which case the old tree must be properly\r\n// unmounted.\r\nprevChildren, parentComponent, parentSuspense, unmountChildren) {\r\n    if (key === 'innerHTML' || key === 'textContent') {\r\n        if (prevChildren) {\r\n            unmountChildren(prevChildren, parentComponent, parentSuspense);\r\n        }\r\n        el[key] = value == null ? '' : value;\r\n        return;\r\n    }\r\n    if (key === 'value' &&\r\n        el.tagName !== 'PROGRESS' &&\r\n        // custom elements may use _value internally\r\n        !el.tagName.includes('-')) {\r\n        // store value as _value as well since\r\n        // non-string values will be stringified.\r\n        el._value = value;\r\n        const newValue = value == null ? '' : value;\r\n        if (el.value !== newValue ||\r\n            // #4956: always set for OPTION elements because its value falls back to\r\n            // textContent if no value attribute is present. And setting .value for\r\n            // OPTION has no side effect\r\n            el.tagName === 'OPTION') {\r\n            el.value = newValue;\r\n        }\r\n        if (value == null) {\r\n            el.removeAttribute(key);\r\n        }\r\n        return;\r\n    }\r\n    let needRemove = false;\r\n    if (value === '' || value == null) {\r\n        const type = typeof el[key];\r\n        if (type === 'boolean') {\r\n            // e.g. <select multiple> compiles to { multiple: '' }\r\n            value = includeBooleanAttr(value);\r\n        }\r\n        else if (value == null && type === 'string') {\r\n            // e.g. <div :id=\"null\">\r\n            value = '';\r\n            needRemove = true;\r\n        }\r\n        else if (type === 'number') {\r\n            // e.g. <img :width=\"null\">\r\n            // the value of some IDL attr must be greater than 0, e.g. input.size = 0 -> error\r\n            value = 0;\r\n            needRemove = true;\r\n        }\r\n    }\r\n    // some properties perform value validation and throw,\r\n    // some properties has getter, no setter, will error in 'use strict'\r\n    // eg. <select :type=\"null\"></select> <select :willValidate=\"null\"></select>\r\n    try {\r\n        el[key] = value;\r\n    }\r\n    catch (e) {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            warn(`Failed setting prop \"${key}\" on <${el.tagName.toLowerCase()}>: ` +\r\n                `value ${value} is invalid.`, e);\r\n        }\r\n    }\r\n    needRemove && el.removeAttribute(key);\r\n}\n\n// Async edge case fix requires storing an event listener's attach timestamp.\r\nconst [_getNow, skipTimestampCheck] = /*#__PURE__*/ (() => {\r\n    let _getNow = Date.now;\r\n    let skipTimestampCheck = false;\r\n    if (typeof window !== 'undefined') {\r\n        // Determine what event timestamp the browser is using. Annoyingly, the\r\n        // timestamp can either be hi-res (relative to page load) or low-res\r\n        // (relative to UNIX epoch), so in order to compare time we have to use the\r\n        // same timestamp type when saving the flush timestamp.\r\n        if (Date.now() > document.createEvent('Event').timeStamp) {\r\n            // if the low-res timestamp which is bigger than the event timestamp\r\n            // (which is evaluated AFTER) it means the event is using a hi-res timestamp,\r\n            // and we need to use the hi-res version for event listeners as well.\r\n            _getNow = performance.now.bind(performance);\r\n        }\r\n        // #3485: Firefox <= 53 has incorrect Event.timeStamp implementation\r\n        // and does not fire microtasks in between event propagation, so safe to exclude.\r\n        const ffMatch = navigator.userAgent.match(/firefox\\/(\\d+)/i);\r\n        skipTimestampCheck = !!(ffMatch && Number(ffMatch[1]) <= 53);\r\n    }\r\n    return [_getNow, skipTimestampCheck];\r\n})();\r\n// To avoid the overhead of repeatedly calling performance.now(), we cache\r\n// and use the same timestamp for all event listeners attached in the same tick.\r\nlet cachedNow = 0;\r\nconst p = /*#__PURE__*/ Promise.resolve();\r\nconst reset = () => {\r\n    cachedNow = 0;\r\n};\r\nconst getNow = () => cachedNow || (p.then(reset), (cachedNow = _getNow()));\r\nfunction addEventListener(el, event, handler, options) {\r\n    el.addEventListener(event, handler, options);\r\n}\r\nfunction removeEventListener(el, event, handler, options) {\r\n    el.removeEventListener(event, handler, options);\r\n}\r\nfunction patchEvent(el, rawName, prevValue, nextValue, instance = null) {\r\n    // vei = vue event invokers\r\n    const invokers = el._vei || (el._vei = {});\r\n    const existingInvoker = invokers[rawName];\r\n    if (nextValue && existingInvoker) {\r\n        // patch\r\n        existingInvoker.value = nextValue;\r\n    }\r\n    else {\r\n        const [name, options] = parseName(rawName);\r\n        if (nextValue) {\r\n            // add\r\n            const invoker = (invokers[rawName] = createInvoker(nextValue, instance));\r\n            addEventListener(el, name, invoker, options);\r\n        }\r\n        else if (existingInvoker) {\r\n            // remove\r\n            removeEventListener(el, name, existingInvoker, options);\r\n            invokers[rawName] = undefined;\r\n        }\r\n    }\r\n}\r\nconst optionsModifierRE = /(?:Once|Passive|Capture)$/;\r\nfunction parseName(name) {\r\n    let options;\r\n    if (optionsModifierRE.test(name)) {\r\n        options = {};\r\n        let m;\r\n        while ((m = name.match(optionsModifierRE))) {\r\n            name = name.slice(0, name.length - m[0].length);\r\n            options[m[0].toLowerCase()] = true;\r\n        }\r\n    }\r\n    return [hyphenate(name.slice(2)), options];\r\n}\r\nfunction createInvoker(initialValue, instance) {\r\n    const invoker = (e) => {\r\n        // async edge case #6566: inner click event triggers patch, event handler\r\n        // attached to outer element during patch, and triggered again. This\r\n        // happens because browsers fire microtask ticks between event propagation.\r\n        // the solution is simple: we save the timestamp when a handler is attached,\r\n        // and the handler would only fire if the event passed to it was fired\r\n        // AFTER it was attached.\r\n        const timeStamp = e.timeStamp || _getNow();\r\n        if (skipTimestampCheck || timeStamp >= invoker.attached - 1) {\r\n            callWithAsyncErrorHandling(patchStopImmediatePropagation(e, invoker.value), instance, 5 /* NATIVE_EVENT_HANDLER */, [e]);\r\n        }\r\n    };\r\n    invoker.value = initialValue;\r\n    invoker.attached = getNow();\r\n    return invoker;\r\n}\r\nfunction patchStopImmediatePropagation(e, value) {\r\n    if (isArray(value)) {\r\n        const originalStop = e.stopImmediatePropagation;\r\n        e.stopImmediatePropagation = () => {\r\n            originalStop.call(e);\r\n            e._stopped = true;\r\n        };\r\n        return value.map(fn => (e) => !e._stopped && fn && fn(e));\r\n    }\r\n    else {\r\n        return value;\r\n    }\r\n}\n\nconst nativeOnRE = /^on[a-z]/;\r\nconst patchProp = (el, key, prevValue, nextValue, isSVG = false, prevChildren, parentComponent, parentSuspense, unmountChildren) => {\r\n    if (key === 'class') {\r\n        patchClass(el, nextValue, isSVG);\r\n    }\r\n    else if (key === 'style') {\r\n        patchStyle(el, prevValue, nextValue);\r\n    }\r\n    else if (isOn(key)) {\r\n        // ignore v-model listeners\r\n        if (!isModelListener(key)) {\r\n            patchEvent(el, key, prevValue, nextValue, parentComponent);\r\n        }\r\n    }\r\n    else if (key[0] === '.'\r\n        ? ((key = key.slice(1)), true)\r\n        : key[0] === '^'\r\n            ? ((key = key.slice(1)), false)\r\n            : shouldSetAsProp(el, key, nextValue, isSVG)) {\r\n        patchDOMProp(el, key, nextValue, prevChildren, parentComponent, parentSuspense, unmountChildren);\r\n    }\r\n    else {\r\n        // special case for <input v-model type=\"checkbox\"> with\r\n        // :true-value & :false-value\r\n        // store value as dom properties since non-string values will be\r\n        // stringified.\r\n        if (key === 'true-value') {\r\n            el._trueValue = nextValue;\r\n        }\r\n        else if (key === 'false-value') {\r\n            el._falseValue = nextValue;\r\n        }\r\n        patchAttr(el, key, nextValue, isSVG);\r\n    }\r\n};\r\nfunction shouldSetAsProp(el, key, value, isSVG) {\r\n    if (isSVG) {\r\n        // most keys must be set as attribute on svg elements to work\r\n        // ...except innerHTML & textContent\r\n        if (key === 'innerHTML' || key === 'textContent') {\r\n            return true;\r\n        }\r\n        // or native onclick with function values\r\n        if (key in el && nativeOnRE.test(key) && isFunction(value)) {\r\n            return true;\r\n        }\r\n        return false;\r\n    }\r\n    // these are enumerated attrs, however their corresponding DOM properties\r\n    // are actually booleans - this leads to setting it with a string \"false\"\r\n    // value leading it to be coerced to `true`, so we need to always treat\r\n    // them as attributes.\r\n    // Note that `contentEditable` doesn't have this problem: its DOM\r\n    // property is also enumerated string values.\r\n    if (key === 'spellcheck' || key === 'draggable' || key === 'translate') {\r\n        return false;\r\n    }\r\n    // #1787, #2840 form property on form elements is readonly and must be set as\r\n    // attribute.\r\n    if (key === 'form') {\r\n        return false;\r\n    }\r\n    // #1526 <input list> must be set as attribute\r\n    if (key === 'list' && el.tagName === 'INPUT') {\r\n        return false;\r\n    }\r\n    // #2766 <textarea type> must be set as attribute\r\n    if (key === 'type' && el.tagName === 'TEXTAREA') {\r\n        return false;\r\n    }\r\n    // native onclick with string value, must be set as attribute\r\n    if (nativeOnRE.test(key) && isString(value)) {\r\n        return false;\r\n    }\r\n    return key in el;\r\n}\n\nfunction defineCustomElement(options, hydrate) {\r\n    const Comp = defineComponent(options);\r\n    class VueCustomElement extends VueElement {\r\n        constructor(initialProps) {\r\n            super(Comp, initialProps, hydrate);\r\n        }\r\n    }\r\n    VueCustomElement.def = Comp;\r\n    return VueCustomElement;\r\n}\r\nconst defineSSRCustomElement = ((options) => {\r\n    // @ts-ignore\r\n    return defineCustomElement(options, hydrate);\r\n});\r\nconst BaseClass = (typeof HTMLElement !== 'undefined' ? HTMLElement : class {\r\n});\r\nclass VueElement extends BaseClass {\r\n    constructor(_def, _props = {}, hydrate) {\r\n        super();\r\n        this._def = _def;\r\n        this._props = _props;\r\n        /**\r\n         * @internal\r\n         */\r\n        this._instance = null;\r\n        this._connected = false;\r\n        this._resolved = false;\r\n        this._numberProps = null;\r\n        if (this.shadowRoot && hydrate) {\r\n            hydrate(this._createVNode(), this.shadowRoot);\r\n        }\r\n        else {\r\n            if ((process.env.NODE_ENV !== 'production') && this.shadowRoot) {\r\n                warn(`Custom element has pre-rendered declarative shadow root but is not ` +\r\n                    `defined as hydratable. Use \\`defineSSRCustomElement\\`.`);\r\n            }\r\n            this.attachShadow({ mode: 'open' });\r\n        }\r\n    }\r\n    connectedCallback() {\r\n        this._connected = true;\r\n        if (!this._instance) {\r\n            this._resolveDef();\r\n        }\r\n    }\r\n    disconnectedCallback() {\r\n        this._connected = false;\r\n        nextTick(() => {\r\n            if (!this._connected) {\r\n                render(null, this.shadowRoot);\r\n                this._instance = null;\r\n            }\r\n        });\r\n    }\r\n    /**\r\n     * resolve inner component definition (handle possible async component)\r\n     */\r\n    _resolveDef() {\r\n        if (this._resolved) {\r\n            return;\r\n        }\r\n        this._resolved = true;\r\n        // set initial attrs\r\n        for (let i = 0; i < this.attributes.length; i++) {\r\n            this._setAttr(this.attributes[i].name);\r\n        }\r\n        // watch future attr changes\r\n        new MutationObserver(mutations => {\r\n            for (const m of mutations) {\r\n                this._setAttr(m.attributeName);\r\n            }\r\n        }).observe(this, { attributes: true });\r\n        const resolve = (def) => {\r\n            const { props, styles } = def;\r\n            const hasOptions = !isArray(props);\r\n            const rawKeys = props ? (hasOptions ? Object.keys(props) : props) : [];\r\n            // cast Number-type props set before resolve\r\n            let numberProps;\r\n            if (hasOptions) {\r\n                for (const key in this._props) {\r\n                    const opt = props[key];\r\n                    if (opt === Number || (opt && opt.type === Number)) {\r\n                        this._props[key] = toNumber(this._props[key]);\r\n                        (numberProps || (numberProps = Object.create(null)))[key] = true;\r\n                    }\r\n                }\r\n            }\r\n            this._numberProps = numberProps;\r\n            // check if there are props set pre-upgrade or connect\r\n            for (const key of Object.keys(this)) {\r\n                if (key[0] !== '_') {\r\n                    this._setProp(key, this[key], true, false);\r\n                }\r\n            }\r\n            // defining getter/setters on prototype\r\n            for (const key of rawKeys.map(camelize$1)) {\r\n                Object.defineProperty(this, key, {\r\n                    get() {\r\n                        return this._getProp(key);\r\n                    },\r\n                    set(val) {\r\n                        this._setProp(key, val);\r\n                    }\r\n                });\r\n            }\r\n            // apply CSS\r\n            this._applyStyles(styles);\r\n            // initial render\r\n            this._update();\r\n        };\r\n        const asyncDef = this._def.__asyncLoader;\r\n        if (asyncDef) {\r\n            asyncDef().then(resolve);\r\n        }\r\n        else {\r\n            resolve(this._def);\r\n        }\r\n    }\r\n    _setAttr(key) {\r\n        let value = this.getAttribute(key);\r\n        if (this._numberProps && this._numberProps[key]) {\r\n            value = toNumber(value);\r\n        }\r\n        this._setProp(camelize$1(key), value, false);\r\n    }\r\n    /**\r\n     * @internal\r\n     */\r\n    _getProp(key) {\r\n        return this._props[key];\r\n    }\r\n    /**\r\n     * @internal\r\n     */\r\n    _setProp(key, val, shouldReflect = true, shouldUpdate = true) {\r\n        if (val !== this._props[key]) {\r\n            this._props[key] = val;\r\n            if (shouldUpdate && this._instance) {\r\n                this._update();\r\n            }\r\n            // reflect\r\n            if (shouldReflect) {\r\n                if (val === true) {\r\n                    this.setAttribute(hyphenate(key), '');\r\n                }\r\n                else if (typeof val === 'string' || typeof val === 'number') {\r\n                    this.setAttribute(hyphenate(key), val + '');\r\n                }\r\n                else if (!val) {\r\n                    this.removeAttribute(hyphenate(key));\r\n                }\r\n            }\r\n        }\r\n    }\r\n    _update() {\r\n        render(this._createVNode(), this.shadowRoot);\r\n    }\r\n    _createVNode() {\r\n        const vnode = createVNode(this._def, extend({}, this._props));\r\n        if (!this._instance) {\r\n            vnode.ce = instance => {\r\n                this._instance = instance;\r\n                instance.isCE = true;\r\n                // HMR\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    instance.ceReload = newStyles => {\r\n                        // always reset styles\r\n                        if (this._styles) {\r\n                            this._styles.forEach(s => this.shadowRoot.removeChild(s));\r\n                            this._styles.length = 0;\r\n                        }\r\n                        this._applyStyles(newStyles);\r\n                        // if this is an async component, ceReload is called from the inner\r\n                        // component so no need to reload the async wrapper\r\n                        if (!this._def.__asyncLoader) {\r\n                            // reload\r\n                            this._instance = null;\r\n                            this._update();\r\n                        }\r\n                    };\r\n                }\r\n                // intercept emit\r\n                instance.emit = (event, ...args) => {\r\n                    this.dispatchEvent(new CustomEvent(event, {\r\n                        detail: args\r\n                    }));\r\n                };\r\n                // locate nearest Vue custom element parent for provide/inject\r\n                let parent = this;\r\n                while ((parent =\r\n                    parent && (parent.parentNode || parent.host))) {\r\n                    if (parent instanceof VueElement) {\r\n                        instance.parent = parent._instance;\r\n                        break;\r\n                    }\r\n                }\r\n            };\r\n        }\r\n        return vnode;\r\n    }\r\n    _applyStyles(styles) {\r\n        if (styles) {\r\n            styles.forEach(css => {\r\n                const s = document.createElement('style');\r\n                s.textContent = css;\r\n                this.shadowRoot.appendChild(s);\r\n                // record for HMR\r\n                if ((process.env.NODE_ENV !== 'production')) {\r\n                    (this._styles || (this._styles = [])).push(s);\r\n                }\r\n            });\r\n        }\r\n    }\r\n}\n\nfunction useCssModule(name = '$style') {\r\n    /* istanbul ignore else */\r\n    {\r\n        const instance = getCurrentInstance();\r\n        if (!instance) {\r\n            (process.env.NODE_ENV !== 'production') && warn(`useCssModule must be called inside setup()`);\r\n            return EMPTY_OBJ;\r\n        }\r\n        const modules = instance.type.__cssModules;\r\n        if (!modules) {\r\n            (process.env.NODE_ENV !== 'production') && warn(`Current instance does not have CSS modules injected.`);\r\n            return EMPTY_OBJ;\r\n        }\r\n        const mod = modules[name];\r\n        if (!mod) {\r\n            (process.env.NODE_ENV !== 'production') &&\r\n                warn(`Current instance does not have CSS module named \"${name}\".`);\r\n            return EMPTY_OBJ;\r\n        }\r\n        return mod;\r\n    }\r\n}\n\n/**\r\n * Runtime helper for SFC's CSS variable injection feature.\r\n * @private\r\n */\r\nfunction useCssVars(getter) {\r\n    const instance = getCurrentInstance();\r\n    /* istanbul ignore next */\r\n    if (!instance) {\r\n        (process.env.NODE_ENV !== 'production') &&\r\n            warn(`useCssVars is called without current active component instance.`);\r\n        return;\r\n    }\r\n    const setVars = () => setVarsOnVNode(instance.subTree, getter(instance.proxy));\r\n    watchPostEffect(setVars);\r\n    onMounted(() => {\r\n        const ob = new MutationObserver(setVars);\r\n        ob.observe(instance.subTree.el.parentNode, { childList: true });\r\n        onUnmounted(() => ob.disconnect());\r\n    });\r\n}\r\nfunction setVarsOnVNode(vnode, vars) {\r\n    if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n        const suspense = vnode.suspense;\r\n        vnode = suspense.activeBranch;\r\n        if (suspense.pendingBranch && !suspense.isHydrating) {\r\n            suspense.effects.push(() => {\r\n                setVarsOnVNode(suspense.activeBranch, vars);\r\n            });\r\n        }\r\n    }\r\n    // drill down HOCs until it's a non-component vnode\r\n    while (vnode.component) {\r\n        vnode = vnode.component.subTree;\r\n    }\r\n    if (vnode.shapeFlag & 1 /* ELEMENT */ && vnode.el) {\r\n        setVarsOnNode(vnode.el, vars);\r\n    }\r\n    else if (vnode.type === Fragment) {\r\n        vnode.children.forEach(c => setVarsOnVNode(c, vars));\r\n    }\r\n    else if (vnode.type === Static) {\r\n        let { el, anchor } = vnode;\r\n        while (el) {\r\n            setVarsOnNode(el, vars);\r\n            if (el === anchor)\r\n                break;\r\n            el = el.nextSibling;\r\n        }\r\n    }\r\n}\r\nfunction setVarsOnNode(el, vars) {\r\n    if (el.nodeType === 1) {\r\n        const style = el.style;\r\n        for (const key in vars) {\r\n            style.setProperty(`--${key}`, vars[key]);\r\n        }\r\n    }\r\n}\n\nconst TRANSITION = 'transition';\r\nconst ANIMATION = 'animation';\r\n// DOM Transition is a higher-order-component based on the platform-agnostic\r\n// base Transition component, with DOM-specific logic.\r\nconst Transition = (props, { slots }) => h(BaseTransition, resolveTransitionProps(props), slots);\r\nTransition.displayName = 'Transition';\r\nconst DOMTransitionPropsValidators = {\r\n    name: String,\r\n    type: String,\r\n    css: {\r\n        type: Boolean,\r\n        default: true\r\n    },\r\n    duration: [String, Number, Object],\r\n    enterFromClass: String,\r\n    enterActiveClass: String,\r\n    enterToClass: String,\r\n    appearFromClass: String,\r\n    appearActiveClass: String,\r\n    appearToClass: String,\r\n    leaveFromClass: String,\r\n    leaveActiveClass: String,\r\n    leaveToClass: String\r\n};\r\nconst TransitionPropsValidators = (Transition.props =\r\n    /*#__PURE__*/ extend({}, BaseTransition.props, DOMTransitionPropsValidators));\r\n/**\r\n * #3227 Incoming hooks may be merged into arrays when wrapping Transition\r\n * with custom HOCs.\r\n */\r\nconst callHook = (hook, args = []) => {\r\n    if (isArray(hook)) {\r\n        hook.forEach(h => h(...args));\r\n    }\r\n    else if (hook) {\r\n        hook(...args);\r\n    }\r\n};\r\n/**\r\n * Check if a hook expects a callback (2nd arg), which means the user\r\n * intends to explicitly control the end of the transition.\r\n */\r\nconst hasExplicitCallback = (hook) => {\r\n    return hook\r\n        ? isArray(hook)\r\n            ? hook.some(h => h.length > 1)\r\n            : hook.length > 1\r\n        : false;\r\n};\r\nfunction resolveTransitionProps(rawProps) {\r\n    const baseProps = {};\r\n    for (const key in rawProps) {\r\n        if (!(key in DOMTransitionPropsValidators)) {\r\n            baseProps[key] = rawProps[key];\r\n        }\r\n    }\r\n    if (rawProps.css === false) {\r\n        return baseProps;\r\n    }\r\n    const { name = 'v', type, duration, enterFromClass = `${name}-enter-from`, enterActiveClass = `${name}-enter-active`, enterToClass = `${name}-enter-to`, appearFromClass = enterFromClass, appearActiveClass = enterActiveClass, appearToClass = enterToClass, leaveFromClass = `${name}-leave-from`, leaveActiveClass = `${name}-leave-active`, leaveToClass = `${name}-leave-to` } = rawProps;\r\n    const durations = normalizeDuration(duration);\r\n    const enterDuration = durations && durations[0];\r\n    const leaveDuration = durations && durations[1];\r\n    const { onBeforeEnter, onEnter, onEnterCancelled, onLeave, onLeaveCancelled, onBeforeAppear = onBeforeEnter, onAppear = onEnter, onAppearCancelled = onEnterCancelled } = baseProps;\r\n    const finishEnter = (el, isAppear, done) => {\r\n        removeTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n        removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);\r\n        done && done();\r\n    };\r\n    const finishLeave = (el, done) => {\r\n        el._isLeaving = false;\r\n        removeTransitionClass(el, leaveFromClass);\r\n        removeTransitionClass(el, leaveToClass);\r\n        removeTransitionClass(el, leaveActiveClass);\r\n        done && done();\r\n    };\r\n    const makeEnterHook = (isAppear) => {\r\n        return (el, done) => {\r\n            const hook = isAppear ? onAppear : onEnter;\r\n            const resolve = () => finishEnter(el, isAppear, done);\r\n            callHook(hook, [el, resolve]);\r\n            nextFrame(() => {\r\n                removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass);\r\n                addTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n                if (!hasExplicitCallback(hook)) {\r\n                    whenTransitionEnds(el, type, enterDuration, resolve);\r\n                }\r\n            });\r\n        };\r\n    };\r\n    return extend(baseProps, {\r\n        onBeforeEnter(el) {\r\n            callHook(onBeforeEnter, [el]);\r\n            addTransitionClass(el, enterFromClass);\r\n            addTransitionClass(el, enterActiveClass);\r\n        },\r\n        onBeforeAppear(el) {\r\n            callHook(onBeforeAppear, [el]);\r\n            addTransitionClass(el, appearFromClass);\r\n            addTransitionClass(el, appearActiveClass);\r\n        },\r\n        onEnter: makeEnterHook(false),\r\n        onAppear: makeEnterHook(true),\r\n        onLeave(el, done) {\r\n            el._isLeaving = true;\r\n            const resolve = () => finishLeave(el, done);\r\n            addTransitionClass(el, leaveFromClass);\r\n            // force reflow so *-leave-from classes immediately take effect (#2593)\r\n            forceReflow();\r\n            addTransitionClass(el, leaveActiveClass);\r\n            nextFrame(() => {\r\n                if (!el._isLeaving) {\r\n                    // cancelled\r\n                    return;\r\n                }\r\n                removeTransitionClass(el, leaveFromClass);\r\n                addTransitionClass(el, leaveToClass);\r\n                if (!hasExplicitCallback(onLeave)) {\r\n                    whenTransitionEnds(el, type, leaveDuration, resolve);\r\n                }\r\n            });\r\n            callHook(onLeave, [el, resolve]);\r\n        },\r\n        onEnterCancelled(el) {\r\n            finishEnter(el, false);\r\n            callHook(onEnterCancelled, [el]);\r\n        },\r\n        onAppearCancelled(el) {\r\n            finishEnter(el, true);\r\n            callHook(onAppearCancelled, [el]);\r\n        },\r\n        onLeaveCancelled(el) {\r\n            finishLeave(el);\r\n            callHook(onLeaveCancelled, [el]);\r\n        }\r\n    });\r\n}\r\nfunction normalizeDuration(duration) {\r\n    if (duration == null) {\r\n        return null;\r\n    }\r\n    else if (isObject(duration)) {\r\n        return [NumberOf(duration.enter), NumberOf(duration.leave)];\r\n    }\r\n    else {\r\n        const n = NumberOf(duration);\r\n        return [n, n];\r\n    }\r\n}\r\nfunction NumberOf(val) {\r\n    const res = toNumber(val);\r\n    if ((process.env.NODE_ENV !== 'production'))\r\n        validateDuration(res);\r\n    return res;\r\n}\r\nfunction validateDuration(val) {\r\n    if (typeof val !== 'number') {\r\n        warn(`<transition> explicit duration is not a valid number - ` +\r\n            `got ${JSON.stringify(val)}.`);\r\n    }\r\n    else if (isNaN(val)) {\r\n        warn(`<transition> explicit duration is NaN - ` +\r\n            'the duration expression might be incorrect.');\r\n    }\r\n}\r\nfunction addTransitionClass(el, cls) {\r\n    cls.split(/\\s+/).forEach(c => c && el.classList.add(c));\r\n    (el._vtc ||\r\n        (el._vtc = new Set())).add(cls);\r\n}\r\nfunction removeTransitionClass(el, cls) {\r\n    cls.split(/\\s+/).forEach(c => c && el.classList.remove(c));\r\n    const { _vtc } = el;\r\n    if (_vtc) {\r\n        _vtc.delete(cls);\r\n        if (!_vtc.size) {\r\n            el._vtc = undefined;\r\n        }\r\n    }\r\n}\r\nfunction nextFrame(cb) {\r\n    requestAnimationFrame(() => {\r\n        requestAnimationFrame(cb);\r\n    });\r\n}\r\nlet endId = 0;\r\nfunction whenTransitionEnds(el, expectedType, explicitTimeout, resolve) {\r\n    const id = (el._endId = ++endId);\r\n    const resolveIfNotStale = () => {\r\n        if (id === el._endId) {\r\n            resolve();\r\n        }\r\n    };\r\n    if (explicitTimeout) {\r\n        return setTimeout(resolveIfNotStale, explicitTimeout);\r\n    }\r\n    const { type, timeout, propCount } = getTransitionInfo(el, expectedType);\r\n    if (!type) {\r\n        return resolve();\r\n    }\r\n    const endEvent = type + 'end';\r\n    let ended = 0;\r\n    const end = () => {\r\n        el.removeEventListener(endEvent, onEnd);\r\n        resolveIfNotStale();\r\n    };\r\n    const onEnd = (e) => {\r\n        if (e.target === el && ++ended >= propCount) {\r\n            end();\r\n        }\r\n    };\r\n    setTimeout(() => {\r\n        if (ended < propCount) {\r\n            end();\r\n        }\r\n    }, timeout + 1);\r\n    el.addEventListener(endEvent, onEnd);\r\n}\r\nfunction getTransitionInfo(el, expectedType) {\r\n    const styles = window.getComputedStyle(el);\r\n    // JSDOM may return undefined for transition properties\r\n    const getStyleProperties = (key) => (styles[key] || '').split(', ');\r\n    const transitionDelays = getStyleProperties(TRANSITION + 'Delay');\r\n    const transitionDurations = getStyleProperties(TRANSITION + 'Duration');\r\n    const transitionTimeout = getTimeout(transitionDelays, transitionDurations);\r\n    const animationDelays = getStyleProperties(ANIMATION + 'Delay');\r\n    const animationDurations = getStyleProperties(ANIMATION + 'Duration');\r\n    const animationTimeout = getTimeout(animationDelays, animationDurations);\r\n    let type = null;\r\n    let timeout = 0;\r\n    let propCount = 0;\r\n    /* istanbul ignore if */\r\n    if (expectedType === TRANSITION) {\r\n        if (transitionTimeout > 0) {\r\n            type = TRANSITION;\r\n            timeout = transitionTimeout;\r\n            propCount = transitionDurations.length;\r\n        }\r\n    }\r\n    else if (expectedType === ANIMATION) {\r\n        if (animationTimeout > 0) {\r\n            type = ANIMATION;\r\n            timeout = animationTimeout;\r\n            propCount = animationDurations.length;\r\n        }\r\n    }\r\n    else {\r\n        timeout = Math.max(transitionTimeout, animationTimeout);\r\n        type =\r\n            timeout > 0\r\n                ? transitionTimeout > animationTimeout\r\n                    ? TRANSITION\r\n                    : ANIMATION\r\n                : null;\r\n        propCount = type\r\n            ? type === TRANSITION\r\n                ? transitionDurations.length\r\n                : animationDurations.length\r\n            : 0;\r\n    }\r\n    const hasTransform = type === TRANSITION &&\r\n        /\\b(transform|all)(,|$)/.test(styles[TRANSITION + 'Property']);\r\n    return {\r\n        type,\r\n        timeout,\r\n        propCount,\r\n        hasTransform\r\n    };\r\n}\r\nfunction getTimeout(delays, durations) {\r\n    while (delays.length < durations.length) {\r\n        delays = delays.concat(delays);\r\n    }\r\n    return Math.max(...durations.map((d, i) => toMs(d) + toMs(delays[i])));\r\n}\r\n// Old versions of Chromium (below 61.0.3163.100) formats floating pointer\r\n// numbers in a locale-dependent way, using a comma instead of a dot.\r\n// If comma is not replaced with a dot, the input will be rounded down\r\n// (i.e. acting as a floor function) causing unexpected behaviors\r\nfunction toMs(s) {\r\n    return Number(s.slice(0, -1).replace(',', '.')) * 1000;\r\n}\r\n// synchronously force layout to put elements into a certain state\r\nfunction forceReflow() {\r\n    return document.body.offsetHeight;\r\n}\n\nconst positionMap = new WeakMap();\r\nconst newPositionMap = new WeakMap();\r\nconst TransitionGroupImpl = {\r\n    name: 'TransitionGroup',\r\n    props: /*#__PURE__*/ extend({}, TransitionPropsValidators, {\r\n        tag: String,\r\n        moveClass: String\r\n    }),\r\n    setup(props, { slots }) {\r\n        const instance = getCurrentInstance();\r\n        const state = useTransitionState();\r\n        let prevChildren;\r\n        let children;\r\n        onUpdated(() => {\r\n            // children is guaranteed to exist after initial render\r\n            if (!prevChildren.length) {\r\n                return;\r\n            }\r\n            const moveClass = props.moveClass || `${props.name || 'v'}-move`;\r\n            if (!hasCSSTransform(prevChildren[0].el, instance.vnode.el, moveClass)) {\r\n                return;\r\n            }\r\n            // we divide the work into three loops to avoid mixing DOM reads and writes\r\n            // in each iteration - which helps prevent layout thrashing.\r\n            prevChildren.forEach(callPendingCbs);\r\n            prevChildren.forEach(recordPosition);\r\n            const movedChildren = prevChildren.filter(applyTranslation);\r\n            // force reflow to put everything in position\r\n            forceReflow();\r\n            movedChildren.forEach(c => {\r\n                const el = c.el;\r\n                const style = el.style;\r\n                addTransitionClass(el, moveClass);\r\n                style.transform = style.webkitTransform = style.transitionDuration = '';\r\n                const cb = (el._moveCb = (e) => {\r\n                    if (e && e.target !== el) {\r\n                        return;\r\n                    }\r\n                    if (!e || /transform$/.test(e.propertyName)) {\r\n                        el.removeEventListener('transitionend', cb);\r\n                        el._moveCb = null;\r\n                        removeTransitionClass(el, moveClass);\r\n                    }\r\n                });\r\n                el.addEventListener('transitionend', cb);\r\n            });\r\n        });\r\n        return () => {\r\n            const rawProps = toRaw(props);\r\n            const cssTransitionProps = resolveTransitionProps(rawProps);\r\n            let tag = rawProps.tag || Fragment;\r\n            prevChildren = children;\r\n            children = slots.default ? getTransitionRawChildren(slots.default()) : [];\r\n            for (let i = 0; i < children.length; i++) {\r\n                const child = children[i];\r\n                if (child.key != null) {\r\n                    setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n                }\r\n                else if ((process.env.NODE_ENV !== 'production')) {\r\n                    warn(`<TransitionGroup> children must be keyed.`);\r\n                }\r\n            }\r\n            if (prevChildren) {\r\n                for (let i = 0; i < prevChildren.length; i++) {\r\n                    const child = prevChildren[i];\r\n                    setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n                    positionMap.set(child, child.el.getBoundingClientRect());\r\n                }\r\n            }\r\n            return createVNode(tag, null, children);\r\n        };\r\n    }\r\n};\r\nconst TransitionGroup = TransitionGroupImpl;\r\nfunction callPendingCbs(c) {\r\n    const el = c.el;\r\n    if (el._moveCb) {\r\n        el._moveCb();\r\n    }\r\n    if (el._enterCb) {\r\n        el._enterCb();\r\n    }\r\n}\r\nfunction recordPosition(c) {\r\n    newPositionMap.set(c, c.el.getBoundingClientRect());\r\n}\r\nfunction applyTranslation(c) {\r\n    const oldPos = positionMap.get(c);\r\n    const newPos = newPositionMap.get(c);\r\n    const dx = oldPos.left - newPos.left;\r\n    const dy = oldPos.top - newPos.top;\r\n    if (dx || dy) {\r\n        const s = c.el.style;\r\n        s.transform = s.webkitTransform = `translate(${dx}px,${dy}px)`;\r\n        s.transitionDuration = '0s';\r\n        return c;\r\n    }\r\n}\r\nfunction hasCSSTransform(el, root, moveClass) {\r\n    // Detect whether an element with the move class applied has\r\n    // CSS transitions. Since the element may be inside an entering\r\n    // transition at this very moment, we make a clone of it and remove\r\n    // all other transition classes applied to ensure only the move class\r\n    // is applied.\r\n    const clone = el.cloneNode();\r\n    if (el._vtc) {\r\n        el._vtc.forEach(cls => {\r\n            cls.split(/\\s+/).forEach(c => c && clone.classList.remove(c));\r\n        });\r\n    }\r\n    moveClass.split(/\\s+/).forEach(c => c && clone.classList.add(c));\r\n    clone.style.display = 'none';\r\n    const container = (root.nodeType === 1 ? root : root.parentNode);\r\n    container.appendChild(clone);\r\n    const { hasTransform } = getTransitionInfo(clone);\r\n    container.removeChild(clone);\r\n    return hasTransform;\r\n}\n\nconst getModelAssigner = (vnode) => {\r\n    const fn = vnode.props['onUpdate:modelValue'] ||\r\n        (false );\r\n    return isArray(fn) ? value => invokeArrayFns(fn, value) : fn;\r\n};\r\nfunction onCompositionStart(e) {\r\n    e.target.composing = true;\r\n}\r\nfunction onCompositionEnd(e) {\r\n    const target = e.target;\r\n    if (target.composing) {\r\n        target.composing = false;\r\n        target.dispatchEvent(new Event('input'));\r\n    }\r\n}\r\n// We are exporting the v-model runtime directly as vnode hooks so that it can\r\n// be tree-shaken in case v-model is never used.\r\nconst vModelText = {\r\n    created(el, { modifiers: { lazy, trim, number } }, vnode) {\r\n        el._assign = getModelAssigner(vnode);\r\n        const castToNumber = number || (vnode.props && vnode.props.type === 'number');\r\n        addEventListener(el, lazy ? 'change' : 'input', e => {\r\n            if (e.target.composing)\r\n                return;\r\n            let domValue = el.value;\r\n            if (trim) {\r\n                domValue = domValue.trim();\r\n            }\r\n            if (castToNumber) {\r\n                domValue = toNumber(domValue);\r\n            }\r\n            el._assign(domValue);\r\n        });\r\n        if (trim) {\r\n            addEventListener(el, 'change', () => {\r\n                el.value = el.value.trim();\r\n            });\r\n        }\r\n        if (!lazy) {\r\n            addEventListener(el, 'compositionstart', onCompositionStart);\r\n            addEventListener(el, 'compositionend', onCompositionEnd);\r\n            // Safari < 10.2 & UIWebView doesn't fire compositionend when\r\n            // switching focus before confirming composition choice\r\n            // this also fixes the issue where some browsers e.g. iOS Chrome\r\n            // fires \"change\" instead of \"input\" on autocomplete.\r\n            addEventListener(el, 'change', onCompositionEnd);\r\n        }\r\n    },\r\n    // set value on mounted so it's after min/max for type=\"range\"\r\n    mounted(el, { value }) {\r\n        el.value = value == null ? '' : value;\r\n    },\r\n    beforeUpdate(el, { value, modifiers: { lazy, trim, number } }, vnode) {\r\n        el._assign = getModelAssigner(vnode);\r\n        // avoid clearing unresolved text. #2302\r\n        if (el.composing)\r\n            return;\r\n        if (document.activeElement === el && el.type !== 'range') {\r\n            if (lazy) {\r\n                return;\r\n            }\r\n            if (trim && el.value.trim() === value) {\r\n                return;\r\n            }\r\n            if ((number || el.type === 'number') && toNumber(el.value) === value) {\r\n                return;\r\n            }\r\n        }\r\n        const newValue = value == null ? '' : value;\r\n        if (el.value !== newValue) {\r\n            el.value = newValue;\r\n        }\r\n    }\r\n};\r\nconst vModelCheckbox = {\r\n    // #4096 array checkboxes need to be deep traversed\r\n    deep: true,\r\n    created(el, _, vnode) {\r\n        el._assign = getModelAssigner(vnode);\r\n        addEventListener(el, 'change', () => {\r\n            const modelValue = el._modelValue;\r\n            const elementValue = getValue(el);\r\n            const checked = el.checked;\r\n            const assign = el._assign;\r\n            if (isArray(modelValue)) {\r\n                const index = looseIndexOf(modelValue, elementValue);\r\n                const found = index !== -1;\r\n                if (checked && !found) {\r\n                    assign(modelValue.concat(elementValue));\r\n                }\r\n                else if (!checked && found) {\r\n                    const filtered = [...modelValue];\r\n                    filtered.splice(index, 1);\r\n                    assign(filtered);\r\n                }\r\n            }\r\n            else if (isSet(modelValue)) {\r\n                const cloned = new Set(modelValue);\r\n                if (checked) {\r\n                    cloned.add(elementValue);\r\n                }\r\n                else {\r\n                    cloned.delete(elementValue);\r\n                }\r\n                assign(cloned);\r\n            }\r\n            else {\r\n                assign(getCheckboxValue(el, checked));\r\n            }\r\n        });\r\n    },\r\n    // set initial checked on mount to wait for true-value/false-value\r\n    mounted: setChecked,\r\n    beforeUpdate(el, binding, vnode) {\r\n        el._assign = getModelAssigner(vnode);\r\n        setChecked(el, binding, vnode);\r\n    }\r\n};\r\nfunction setChecked(el, { value, oldValue }, vnode) {\r\n    el._modelValue = value;\r\n    if (isArray(value)) {\r\n        el.checked = looseIndexOf(value, vnode.props.value) > -1;\r\n    }\r\n    else if (isSet(value)) {\r\n        el.checked = value.has(vnode.props.value);\r\n    }\r\n    else if (value !== oldValue) {\r\n        el.checked = looseEqual(value, getCheckboxValue(el, true));\r\n    }\r\n}\r\nconst vModelRadio = {\r\n    created(el, { value }, vnode) {\r\n        el.checked = looseEqual(value, vnode.props.value);\r\n        el._assign = getModelAssigner(vnode);\r\n        addEventListener(el, 'change', () => {\r\n            el._assign(getValue(el));\r\n        });\r\n    },\r\n    beforeUpdate(el, { value, oldValue }, vnode) {\r\n        el._assign = getModelAssigner(vnode);\r\n        if (value !== oldValue) {\r\n            el.checked = looseEqual(value, vnode.props.value);\r\n        }\r\n    }\r\n};\r\nconst vModelSelect = {\r\n    // <select multiple> value need to be deep traversed\r\n    deep: true,\r\n    created(el, { value, modifiers: { number } }, vnode) {\r\n        const isSetModel = isSet(value);\r\n        addEventListener(el, 'change', () => {\r\n            const selectedVal = Array.prototype.filter\r\n                .call(el.options, (o) => o.selected)\r\n                .map((o) => number ? toNumber(getValue(o)) : getValue(o));\r\n            el._assign(el.multiple\r\n                ? isSetModel\r\n                    ? new Set(selectedVal)\r\n                    : selectedVal\r\n                : selectedVal[0]);\r\n        });\r\n        el._assign = getModelAssigner(vnode);\r\n    },\r\n    // set value in mounted & updated because <select> relies on its children\r\n    // <option>s.\r\n    mounted(el, { value }) {\r\n        setSelected(el, value);\r\n    },\r\n    beforeUpdate(el, _binding, vnode) {\r\n        el._assign = getModelAssigner(vnode);\r\n    },\r\n    updated(el, { value }) {\r\n        setSelected(el, value);\r\n    }\r\n};\r\nfunction setSelected(el, value) {\r\n    const isMultiple = el.multiple;\r\n    if (isMultiple && !isArray(value) && !isSet(value)) {\r\n        (process.env.NODE_ENV !== 'production') &&\r\n            warn(`<select multiple v-model> expects an Array or Set value for its binding, ` +\r\n                `but got ${Object.prototype.toString.call(value).slice(8, -1)}.`);\r\n        return;\r\n    }\r\n    for (let i = 0, l = el.options.length; i < l; i++) {\r\n        const option = el.options[i];\r\n        const optionValue = getValue(option);\r\n        if (isMultiple) {\r\n            if (isArray(value)) {\r\n                option.selected = looseIndexOf(value, optionValue) > -1;\r\n            }\r\n            else {\r\n                option.selected = value.has(optionValue);\r\n            }\r\n        }\r\n        else {\r\n            if (looseEqual(getValue(option), value)) {\r\n                if (el.selectedIndex !== i)\r\n                    el.selectedIndex = i;\r\n                return;\r\n            }\r\n        }\r\n    }\r\n    if (!isMultiple && el.selectedIndex !== -1) {\r\n        el.selectedIndex = -1;\r\n    }\r\n}\r\n// retrieve raw value set via :value bindings\r\nfunction getValue(el) {\r\n    return '_value' in el ? el._value : el.value;\r\n}\r\n// retrieve raw value for true-value and false-value set via :true-value or :false-value bindings\r\nfunction getCheckboxValue(el, checked) {\r\n    const key = checked ? '_trueValue' : '_falseValue';\r\n    return key in el ? el[key] : checked;\r\n}\r\nconst vModelDynamic = {\r\n    created(el, binding, vnode) {\r\n        callModelHook(el, binding, vnode, null, 'created');\r\n    },\r\n    mounted(el, binding, vnode) {\r\n        callModelHook(el, binding, vnode, null, 'mounted');\r\n    },\r\n    beforeUpdate(el, binding, vnode, prevVNode) {\r\n        callModelHook(el, binding, vnode, prevVNode, 'beforeUpdate');\r\n    },\r\n    updated(el, binding, vnode, prevVNode) {\r\n        callModelHook(el, binding, vnode, prevVNode, 'updated');\r\n    }\r\n};\r\nfunction resolveDynamicModel(tagName, type) {\r\n    switch (tagName) {\r\n        case 'SELECT':\r\n            return vModelSelect;\r\n        case 'TEXTAREA':\r\n            return vModelText;\r\n        default:\r\n            switch (type) {\r\n                case 'checkbox':\r\n                    return vModelCheckbox;\r\n                case 'radio':\r\n                    return vModelRadio;\r\n                default:\r\n                    return vModelText;\r\n            }\r\n    }\r\n}\r\nfunction callModelHook(el, binding, vnode, prevVNode, hook) {\r\n    const modelToUse = resolveDynamicModel(el.tagName, vnode.props && vnode.props.type);\r\n    const fn = modelToUse[hook];\r\n    fn && fn(el, binding, vnode, prevVNode);\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVModelForSSR() {\r\n    vModelText.getSSRProps = ({ value }) => ({ value });\r\n    vModelRadio.getSSRProps = ({ value }, vnode) => {\r\n        if (vnode.props && looseEqual(vnode.props.value, value)) {\r\n            return { checked: true };\r\n        }\r\n    };\r\n    vModelCheckbox.getSSRProps = ({ value }, vnode) => {\r\n        if (isArray(value)) {\r\n            if (vnode.props && looseIndexOf(value, vnode.props.value) > -1) {\r\n                return { checked: true };\r\n            }\r\n        }\r\n        else if (isSet(value)) {\r\n            if (vnode.props && value.has(vnode.props.value)) {\r\n                return { checked: true };\r\n            }\r\n        }\r\n        else if (value) {\r\n            return { checked: true };\r\n        }\r\n    };\r\n    vModelDynamic.getSSRProps = (binding, vnode) => {\r\n        if (typeof vnode.type !== 'string') {\r\n            return;\r\n        }\r\n        const modelToUse = resolveDynamicModel(\r\n        // resolveDynamicModel expects an uppercase tag name, but vnode.type is lowercase\r\n        vnode.type.toUpperCase(), vnode.props && vnode.props.type);\r\n        if (modelToUse.getSSRProps) {\r\n            return modelToUse.getSSRProps(binding, vnode);\r\n        }\r\n    };\r\n}\n\nconst systemModifiers = ['ctrl', 'shift', 'alt', 'meta'];\r\nconst modifierGuards = {\r\n    stop: e => e.stopPropagation(),\r\n    prevent: e => e.preventDefault(),\r\n    self: e => e.target !== e.currentTarget,\r\n    ctrl: e => !e.ctrlKey,\r\n    shift: e => !e.shiftKey,\r\n    alt: e => !e.altKey,\r\n    meta: e => !e.metaKey,\r\n    left: e => 'button' in e && e.button !== 0,\r\n    middle: e => 'button' in e && e.button !== 1,\r\n    right: e => 'button' in e && e.button !== 2,\r\n    exact: (e, modifiers) => systemModifiers.some(m => e[`${m}Key`] && !modifiers.includes(m))\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withModifiers = (fn, modifiers) => {\r\n    return (event, ...args) => {\r\n        for (let i = 0; i < modifiers.length; i++) {\r\n            const guard = modifierGuards[modifiers[i]];\r\n            if (guard && guard(event, modifiers))\r\n                return;\r\n        }\r\n        return fn(event, ...args);\r\n    };\r\n};\r\n// Kept for 2.x compat.\r\n// Note: IE11 compat for `spacebar` and `del` is removed for now.\r\nconst keyNames = {\r\n    esc: 'escape',\r\n    space: ' ',\r\n    up: 'arrow-up',\r\n    left: 'arrow-left',\r\n    right: 'arrow-right',\r\n    down: 'arrow-down',\r\n    delete: 'backspace'\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withKeys = (fn, modifiers) => {\r\n    return (event) => {\r\n        if (!('key' in event)) {\r\n            return;\r\n        }\r\n        const eventKey = hyphenate(event.key);\r\n        if (modifiers.some(k => k === eventKey || keyNames[k] === eventKey)) {\r\n            return fn(event);\r\n        }\r\n    };\r\n};\n\nconst vShow = {\r\n    beforeMount(el, { value }, { transition }) {\r\n        el._vod = el.style.display === 'none' ? '' : el.style.display;\r\n        if (transition && value) {\r\n            transition.beforeEnter(el);\r\n        }\r\n        else {\r\n            setDisplay(el, value);\r\n        }\r\n    },\r\n    mounted(el, { value }, { transition }) {\r\n        if (transition && value) {\r\n            transition.enter(el);\r\n        }\r\n    },\r\n    updated(el, { value, oldValue }, { transition }) {\r\n        if (!value === !oldValue)\r\n            return;\r\n        if (transition) {\r\n            if (value) {\r\n                transition.beforeEnter(el);\r\n                setDisplay(el, true);\r\n                transition.enter(el);\r\n            }\r\n            else {\r\n                transition.leave(el, () => {\r\n                    setDisplay(el, false);\r\n                });\r\n            }\r\n        }\r\n        else {\r\n            setDisplay(el, value);\r\n        }\r\n    },\r\n    beforeUnmount(el, { value }) {\r\n        setDisplay(el, value);\r\n    }\r\n};\r\nfunction setDisplay(el, value) {\r\n    el.style.display = value ? el._vod : 'none';\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVShowForSSR() {\r\n    vShow.getSSRProps = ({ value }) => {\r\n        if (!value) {\r\n            return { style: { display: 'none' } };\r\n        }\r\n    };\r\n}\n\nconst rendererOptions = /*#__PURE__*/ extend({ patchProp }, nodeOps);\r\n// lazy create the renderer - this makes core renderer logic tree-shakable\r\n// in case the user only imports reactivity utilities from Vue.\r\nlet renderer;\r\nlet enabledHydration = false;\r\nfunction ensureRenderer() {\r\n    return (renderer ||\r\n        (renderer = createRenderer(rendererOptions)));\r\n}\r\nfunction ensureHydrationRenderer() {\r\n    renderer = enabledHydration\r\n        ? renderer\r\n        : createHydrationRenderer(rendererOptions);\r\n    enabledHydration = true;\r\n    return renderer;\r\n}\r\n// use explicit type casts here to avoid import() calls in rolled-up d.ts\r\nconst render = ((...args) => {\r\n    ensureRenderer().render(...args);\r\n});\r\nconst hydrate = ((...args) => {\r\n    ensureHydrationRenderer().hydrate(...args);\r\n});\r\nconst createApp = ((...args) => {\r\n    const app = ensureRenderer().createApp(...args);\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        injectNativeTagCheck(app);\r\n        injectCompilerOptionsCheck(app);\r\n    }\r\n    const { mount } = app;\r\n    app.mount = (containerOrSelector) => {\r\n        const container = normalizeContainer(containerOrSelector);\r\n        if (!container)\r\n            return;\r\n        const component = app._component;\r\n        if (!isFunction(component) && !component.render && !component.template) {\r\n            // __UNSAFE__\r\n            // Reason: potential execution of JS expressions in in-DOM template.\r\n            // The user must make sure the in-DOM template is trusted. If it's\r\n            // rendered by the server, the template should not contain any user data.\r\n            component.template = container.innerHTML;\r\n        }\r\n        // clear content before mounting\r\n        container.innerHTML = '';\r\n        const proxy = mount(container, false, container instanceof SVGElement);\r\n        if (container instanceof Element) {\r\n            container.removeAttribute('v-cloak');\r\n            container.setAttribute('data-v-app', '');\r\n        }\r\n        return proxy;\r\n    };\r\n    return app;\r\n});\r\nconst createSSRApp = ((...args) => {\r\n    const app = ensureHydrationRenderer().createApp(...args);\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        injectNativeTagCheck(app);\r\n        injectCompilerOptionsCheck(app);\r\n    }\r\n    const { mount } = app;\r\n    app.mount = (containerOrSelector) => {\r\n        const container = normalizeContainer(containerOrSelector);\r\n        if (container) {\r\n            return mount(container, true, container instanceof SVGElement);\r\n        }\r\n    };\r\n    return app;\r\n});\r\nfunction injectNativeTagCheck(app) {\r\n    // Inject `isNativeTag`\r\n    // this is used for component name validation (dev only)\r\n    Object.defineProperty(app.config, 'isNativeTag', {\r\n        value: (tag) => isHTMLTag(tag) || isSVGTag(tag),\r\n        writable: false\r\n    });\r\n}\r\n// dev only\r\nfunction injectCompilerOptionsCheck(app) {\r\n    if (isRuntimeOnly()) {\r\n        const isCustomElement = app.config.isCustomElement;\r\n        Object.defineProperty(app.config, 'isCustomElement', {\r\n            get() {\r\n                return isCustomElement;\r\n            },\r\n            set() {\r\n                warn(`The \\`isCustomElement\\` config option is deprecated. Use ` +\r\n                    `\\`compilerOptions.isCustomElement\\` instead.`);\r\n            }\r\n        });\r\n        const compilerOptions = app.config.compilerOptions;\r\n        const msg = `The \\`compilerOptions\\` config option is only respected when using ` +\r\n            `a build of Vue.js that includes the runtime compiler (aka \"full build\"). ` +\r\n            `Since you are using the runtime-only build, \\`compilerOptions\\` ` +\r\n            `must be passed to \\`@vue/compiler-dom\\` in the build setup instead.\\n` +\r\n            `- For vue-loader: pass it via vue-loader's \\`compilerOptions\\` loader option.\\n` +\r\n            `- For vue-cli: see https://cli.vuejs.org/guide/webpack.html#modifying-options-of-a-loader\\n` +\r\n            `- For vite: pass it via @vitejs/plugin-vue options. See https://github.com/vitejs/vite/tree/main/packages/plugin-vue#example-for-passing-options-to-vuecompiler-dom`;\r\n        Object.defineProperty(app.config, 'compilerOptions', {\r\n            get() {\r\n                warn(msg);\r\n                return compilerOptions;\r\n            },\r\n            set() {\r\n                warn(msg);\r\n            }\r\n        });\r\n    }\r\n}\r\nfunction normalizeContainer(container) {\r\n    if (isString(container)) {\r\n        const res = document.querySelector(container);\r\n        if ((process.env.NODE_ENV !== 'production') && !res) {\r\n            warn(`Failed to mount app: mount target selector \"${container}\" returned null.`);\r\n        }\r\n        return res;\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production') &&\r\n        window.ShadowRoot &&\r\n        container instanceof window.ShadowRoot &&\r\n        container.mode === 'closed') {\r\n        warn(`mounting on a ShadowRoot with \\`{mode: \"closed\"}\\` may lead to unpredictable bugs`);\r\n    }\r\n    return container;\r\n}\r\nlet ssrDirectiveInitialized = false;\r\n/**\r\n * @internal\r\n */\r\nconst initDirectivesForSSR = () => {\r\n        if (!ssrDirectiveInitialized) {\r\n            ssrDirectiveInitialized = true;\r\n            initVModelForSSR();\r\n            initVShowForSSR();\r\n        }\r\n    }\r\n    ;\n\nexport { Transition, TransitionGroup, VueElement, createApp, createSSRApp, defineCustomElement, defineSSRCustomElement, hydrate, initDirectivesForSSR, render, useCssModule, useCssVars, vModelCheckbox, vModelDynamic, vModelRadio, vModelSelect, vModelText, vShow, withKeys, withModifiers };\n","import { isString, hyphenate, NOOP, extend, isObject, NO, isArray, makeMap, isSymbol, EMPTY_OBJ, capitalize, camelize as camelize$1, PatchFlagNames, slotFlagsText, isOn, isBuiltInDirective, isReservedProp, toHandlerKey } from '@vue/shared';\nexport { generateCodeFrame } from '@vue/shared';\n\nfunction defaultOnError(error) {\r\n    throw error;\r\n}\r\nfunction defaultOnWarn(msg) {\r\n    (process.env.NODE_ENV !== 'production') && console.warn(`[Vue warn] ${msg.message}`);\r\n}\r\nfunction createCompilerError(code, loc, messages, additionalMessage) {\r\n    const msg = (process.env.NODE_ENV !== 'production') || !true\r\n        ? (messages || errorMessages)[code] + (additionalMessage || ``)\r\n        : code;\r\n    const error = new SyntaxError(String(msg));\r\n    error.code = code;\r\n    error.loc = loc;\r\n    return error;\r\n}\r\nconst errorMessages = {\r\n    // parse errors\r\n    [0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */]: 'Illegal comment.',\r\n    [1 /* CDATA_IN_HTML_CONTENT */]: 'CDATA section is allowed only in XML context.',\r\n    [2 /* DUPLICATE_ATTRIBUTE */]: 'Duplicate attribute.',\r\n    [3 /* END_TAG_WITH_ATTRIBUTES */]: 'End tag cannot have attributes.',\r\n    [4 /* END_TAG_WITH_TRAILING_SOLIDUS */]: \"Illegal '/' in tags.\",\r\n    [5 /* EOF_BEFORE_TAG_NAME */]: 'Unexpected EOF in tag.',\r\n    [6 /* EOF_IN_CDATA */]: 'Unexpected EOF in CDATA section.',\r\n    [7 /* EOF_IN_COMMENT */]: 'Unexpected EOF in comment.',\r\n    [8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */]: 'Unexpected EOF in script.',\r\n    [9 /* EOF_IN_TAG */]: 'Unexpected EOF in tag.',\r\n    [10 /* INCORRECTLY_CLOSED_COMMENT */]: 'Incorrectly closed comment.',\r\n    [11 /* INCORRECTLY_OPENED_COMMENT */]: 'Incorrectly opened comment.',\r\n    [12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */]: \"Illegal tag name. Use '&lt;' to print '<'.\",\r\n    [13 /* MISSING_ATTRIBUTE_VALUE */]: 'Attribute value was expected.',\r\n    [14 /* MISSING_END_TAG_NAME */]: 'End tag name was expected.',\r\n    [15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */]: 'Whitespace was expected.',\r\n    [16 /* NESTED_COMMENT */]: \"Unexpected '<!--' in comment.\",\r\n    [17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */]: 'Attribute name cannot contain U+0022 (\"), U+0027 (\\'), and U+003C (<).',\r\n    [18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */]: 'Unquoted attribute value cannot contain U+0022 (\"), U+0027 (\\'), U+003C (<), U+003D (=), and U+0060 (`).',\r\n    [19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */]: \"Attribute name cannot start with '='.\",\r\n    [21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */]: \"'<?' is allowed only in XML context.\",\r\n    [20 /* UNEXPECTED_NULL_CHARACTER */]: `Unexpected null character.`,\r\n    [22 /* UNEXPECTED_SOLIDUS_IN_TAG */]: \"Illegal '/' in tags.\",\r\n    // Vue-specific parse errors\r\n    [23 /* X_INVALID_END_TAG */]: 'Invalid end tag.',\r\n    [24 /* X_MISSING_END_TAG */]: 'Element is missing end tag.',\r\n    [25 /* X_MISSING_INTERPOLATION_END */]: 'Interpolation end sign was not found.',\r\n    [27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */]: 'End bracket for dynamic directive argument was not found. ' +\r\n        'Note that dynamic directive argument cannot contain spaces.',\r\n    [26 /* X_MISSING_DIRECTIVE_NAME */]: 'Legal directive name was expected.',\r\n    // transform errors\r\n    [28 /* X_V_IF_NO_EXPRESSION */]: `v-if/v-else-if is missing expression.`,\r\n    [29 /* X_V_IF_SAME_KEY */]: `v-if/else branches must use unique keys.`,\r\n    [30 /* X_V_ELSE_NO_ADJACENT_IF */]: `v-else/v-else-if has no adjacent v-if or v-else-if.`,\r\n    [31 /* X_V_FOR_NO_EXPRESSION */]: `v-for is missing expression.`,\r\n    [32 /* X_V_FOR_MALFORMED_EXPRESSION */]: `v-for has invalid expression.`,\r\n    [33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */]: `<template v-for> key should be placed on the <template> tag.`,\r\n    [34 /* X_V_BIND_NO_EXPRESSION */]: `v-bind is missing expression.`,\r\n    [35 /* X_V_ON_NO_EXPRESSION */]: `v-on is missing expression.`,\r\n    [36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */]: `Unexpected custom directive on <slot> outlet.`,\r\n    [37 /* X_V_SLOT_MIXED_SLOT_USAGE */]: `Mixed v-slot usage on both the component and nested <template>.` +\r\n        `When there are multiple named slots, all slots should use <template> ` +\r\n        `syntax to avoid scope ambiguity.`,\r\n    [38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */]: `Duplicate slot names found. `,\r\n    [39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */]: `Extraneous children found when component already has explicitly named ` +\r\n        `default slot. These children will be ignored.`,\r\n    [40 /* X_V_SLOT_MISPLACED */]: `v-slot can only be used on components or <template> tags.`,\r\n    [41 /* X_V_MODEL_NO_EXPRESSION */]: `v-model is missing expression.`,\r\n    [42 /* X_V_MODEL_MALFORMED_EXPRESSION */]: `v-model value must be a valid JavaScript member expression.`,\r\n    [43 /* X_V_MODEL_ON_SCOPE_VARIABLE */]: `v-model cannot be used on v-for or v-slot scope variables because they are not writable.`,\r\n    [44 /* X_INVALID_EXPRESSION */]: `Error parsing JavaScript expression: `,\r\n    [45 /* X_KEEP_ALIVE_INVALID_CHILDREN */]: `<KeepAlive> expects exactly one child component.`,\r\n    // generic errors\r\n    [46 /* X_PREFIX_ID_NOT_SUPPORTED */]: `\"prefixIdentifiers\" option is not supported in this build of compiler.`,\r\n    [47 /* X_MODULE_MODE_NOT_SUPPORTED */]: `ES module mode is not supported in this build of compiler.`,\r\n    [48 /* X_CACHE_HANDLER_NOT_SUPPORTED */]: `\"cacheHandlers\" option is only supported when the \"prefixIdentifiers\" option is enabled.`,\r\n    [49 /* X_SCOPE_ID_NOT_SUPPORTED */]: `\"scopeId\" option is only supported in module mode.`,\r\n    // just to fulfill types\r\n    [50 /* __EXTEND_POINT__ */]: ``\r\n};\n\nconst FRAGMENT = Symbol((process.env.NODE_ENV !== 'production') ? `Fragment` : ``);\r\nconst TELEPORT = Symbol((process.env.NODE_ENV !== 'production') ? `Teleport` : ``);\r\nconst SUSPENSE = Symbol((process.env.NODE_ENV !== 'production') ? `Suspense` : ``);\r\nconst KEEP_ALIVE = Symbol((process.env.NODE_ENV !== 'production') ? `KeepAlive` : ``);\r\nconst BASE_TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `BaseTransition` : ``);\r\nconst OPEN_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `openBlock` : ``);\r\nconst CREATE_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createBlock` : ``);\r\nconst CREATE_ELEMENT_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createElementBlock` : ``);\r\nconst CREATE_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createVNode` : ``);\r\nconst CREATE_ELEMENT_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createElementVNode` : ``);\r\nconst CREATE_COMMENT = Symbol((process.env.NODE_ENV !== 'production') ? `createCommentVNode` : ``);\r\nconst CREATE_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `createTextVNode` : ``);\r\nconst CREATE_STATIC = Symbol((process.env.NODE_ENV !== 'production') ? `createStaticVNode` : ``);\r\nconst RESOLVE_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveComponent` : ``);\r\nconst RESOLVE_DYNAMIC_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDynamicComponent` : ``);\r\nconst RESOLVE_DIRECTIVE = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDirective` : ``);\r\nconst RESOLVE_FILTER = Symbol((process.env.NODE_ENV !== 'production') ? `resolveFilter` : ``);\r\nconst WITH_DIRECTIVES = Symbol((process.env.NODE_ENV !== 'production') ? `withDirectives` : ``);\r\nconst RENDER_LIST = Symbol((process.env.NODE_ENV !== 'production') ? `renderList` : ``);\r\nconst RENDER_SLOT = Symbol((process.env.NODE_ENV !== 'production') ? `renderSlot` : ``);\r\nconst CREATE_SLOTS = Symbol((process.env.NODE_ENV !== 'production') ? `createSlots` : ``);\r\nconst TO_DISPLAY_STRING = Symbol((process.env.NODE_ENV !== 'production') ? `toDisplayString` : ``);\r\nconst MERGE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `mergeProps` : ``);\r\nconst NORMALIZE_CLASS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeClass` : ``);\r\nconst NORMALIZE_STYLE = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeStyle` : ``);\r\nconst NORMALIZE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeProps` : ``);\r\nconst GUARD_REACTIVE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `guardReactiveProps` : ``);\r\nconst TO_HANDLERS = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlers` : ``);\r\nconst CAMELIZE = Symbol((process.env.NODE_ENV !== 'production') ? `camelize` : ``);\r\nconst CAPITALIZE = Symbol((process.env.NODE_ENV !== 'production') ? `capitalize` : ``);\r\nconst TO_HANDLER_KEY = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlerKey` : ``);\r\nconst SET_BLOCK_TRACKING = Symbol((process.env.NODE_ENV !== 'production') ? `setBlockTracking` : ``);\r\nconst PUSH_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `pushScopeId` : ``);\r\nconst POP_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `popScopeId` : ``);\r\nconst WITH_CTX = Symbol((process.env.NODE_ENV !== 'production') ? `withCtx` : ``);\r\nconst UNREF = Symbol((process.env.NODE_ENV !== 'production') ? `unref` : ``);\r\nconst IS_REF = Symbol((process.env.NODE_ENV !== 'production') ? `isRef` : ``);\r\nconst WITH_MEMO = Symbol((process.env.NODE_ENV !== 'production') ? `withMemo` : ``);\r\nconst IS_MEMO_SAME = Symbol((process.env.NODE_ENV !== 'production') ? `isMemoSame` : ``);\r\n// Name mapping for runtime helpers that need to be imported from 'vue' in\r\n// generated code. Make sure these are correctly exported in the runtime!\r\n// Using `any` here because TS doesn't allow symbols as index type.\r\nconst helperNameMap = {\r\n    [FRAGMENT]: `Fragment`,\r\n    [TELEPORT]: `Teleport`,\r\n    [SUSPENSE]: `Suspense`,\r\n    [KEEP_ALIVE]: `KeepAlive`,\r\n    [BASE_TRANSITION]: `BaseTransition`,\r\n    [OPEN_BLOCK]: `openBlock`,\r\n    [CREATE_BLOCK]: `createBlock`,\r\n    [CREATE_ELEMENT_BLOCK]: `createElementBlock`,\r\n    [CREATE_VNODE]: `createVNode`,\r\n    [CREATE_ELEMENT_VNODE]: `createElementVNode`,\r\n    [CREATE_COMMENT]: `createCommentVNode`,\r\n    [CREATE_TEXT]: `createTextVNode`,\r\n    [CREATE_STATIC]: `createStaticVNode`,\r\n    [RESOLVE_COMPONENT]: `resolveComponent`,\r\n    [RESOLVE_DYNAMIC_COMPONENT]: `resolveDynamicComponent`,\r\n    [RESOLVE_DIRECTIVE]: `resolveDirective`,\r\n    [RESOLVE_FILTER]: `resolveFilter`,\r\n    [WITH_DIRECTIVES]: `withDirectives`,\r\n    [RENDER_LIST]: `renderList`,\r\n    [RENDER_SLOT]: `renderSlot`,\r\n    [CREATE_SLOTS]: `createSlots`,\r\n    [TO_DISPLAY_STRING]: `toDisplayString`,\r\n    [MERGE_PROPS]: `mergeProps`,\r\n    [NORMALIZE_CLASS]: `normalizeClass`,\r\n    [NORMALIZE_STYLE]: `normalizeStyle`,\r\n    [NORMALIZE_PROPS]: `normalizeProps`,\r\n    [GUARD_REACTIVE_PROPS]: `guardReactiveProps`,\r\n    [TO_HANDLERS]: `toHandlers`,\r\n    [CAMELIZE]: `camelize`,\r\n    [CAPITALIZE]: `capitalize`,\r\n    [TO_HANDLER_KEY]: `toHandlerKey`,\r\n    [SET_BLOCK_TRACKING]: `setBlockTracking`,\r\n    [PUSH_SCOPE_ID]: `pushScopeId`,\r\n    [POP_SCOPE_ID]: `popScopeId`,\r\n    [WITH_CTX]: `withCtx`,\r\n    [UNREF]: `unref`,\r\n    [IS_REF]: `isRef`,\r\n    [WITH_MEMO]: `withMemo`,\r\n    [IS_MEMO_SAME]: `isMemoSame`\r\n};\r\nfunction registerRuntimeHelpers(helpers) {\r\n    Object.getOwnPropertySymbols(helpers).forEach(s => {\r\n        helperNameMap[s] = helpers[s];\r\n    });\r\n}\n\n// AST Utilities ---------------------------------------------------------------\r\n// Some expressions, e.g. sequence and conditional expressions, are never\r\n// associated with template nodes, so their source locations are just a stub.\r\n// Container types like CompoundExpression also don't need a real location.\r\nconst locStub = {\r\n    source: '',\r\n    start: { line: 1, column: 1, offset: 0 },\r\n    end: { line: 1, column: 1, offset: 0 }\r\n};\r\nfunction createRoot(children, loc = locStub) {\r\n    return {\r\n        type: 0 /* ROOT */,\r\n        children,\r\n        helpers: [],\r\n        components: [],\r\n        directives: [],\r\n        hoists: [],\r\n        imports: [],\r\n        cached: 0,\r\n        temps: 0,\r\n        codegenNode: undefined,\r\n        loc\r\n    };\r\n}\r\nfunction createVNodeCall(context, tag, props, children, patchFlag, dynamicProps, directives, isBlock = false, disableTracking = false, isComponent = false, loc = locStub) {\r\n    if (context) {\r\n        if (isBlock) {\r\n            context.helper(OPEN_BLOCK);\r\n            context.helper(getVNodeBlockHelper(context.inSSR, isComponent));\r\n        }\r\n        else {\r\n            context.helper(getVNodeHelper(context.inSSR, isComponent));\r\n        }\r\n        if (directives) {\r\n            context.helper(WITH_DIRECTIVES);\r\n        }\r\n    }\r\n    return {\r\n        type: 13 /* VNODE_CALL */,\r\n        tag,\r\n        props,\r\n        children,\r\n        patchFlag,\r\n        dynamicProps,\r\n        directives,\r\n        isBlock,\r\n        disableTracking,\r\n        isComponent,\r\n        loc\r\n    };\r\n}\r\nfunction createArrayExpression(elements, loc = locStub) {\r\n    return {\r\n        type: 17 /* JS_ARRAY_EXPRESSION */,\r\n        loc,\r\n        elements\r\n    };\r\n}\r\nfunction createObjectExpression(properties, loc = locStub) {\r\n    return {\r\n        type: 15 /* JS_OBJECT_EXPRESSION */,\r\n        loc,\r\n        properties\r\n    };\r\n}\r\nfunction createObjectProperty(key, value) {\r\n    return {\r\n        type: 16 /* JS_PROPERTY */,\r\n        loc: locStub,\r\n        key: isString(key) ? createSimpleExpression(key, true) : key,\r\n        value\r\n    };\r\n}\r\nfunction createSimpleExpression(content, isStatic = false, loc = locStub, constType = 0 /* NOT_CONSTANT */) {\r\n    return {\r\n        type: 4 /* SIMPLE_EXPRESSION */,\r\n        loc,\r\n        content,\r\n        isStatic,\r\n        constType: isStatic ? 3 /* CAN_STRINGIFY */ : constType\r\n    };\r\n}\r\nfunction createInterpolation(content, loc) {\r\n    return {\r\n        type: 5 /* INTERPOLATION */,\r\n        loc,\r\n        content: isString(content)\r\n            ? createSimpleExpression(content, false, loc)\r\n            : content\r\n    };\r\n}\r\nfunction createCompoundExpression(children, loc = locStub) {\r\n    return {\r\n        type: 8 /* COMPOUND_EXPRESSION */,\r\n        loc,\r\n        children\r\n    };\r\n}\r\nfunction createCallExpression(callee, args = [], loc = locStub) {\r\n    return {\r\n        type: 14 /* JS_CALL_EXPRESSION */,\r\n        loc,\r\n        callee,\r\n        arguments: args\r\n    };\r\n}\r\nfunction createFunctionExpression(params, returns = undefined, newline = false, isSlot = false, loc = locStub) {\r\n    return {\r\n        type: 18 /* JS_FUNCTION_EXPRESSION */,\r\n        params,\r\n        returns,\r\n        newline,\r\n        isSlot,\r\n        loc\r\n    };\r\n}\r\nfunction createConditionalExpression(test, consequent, alternate, newline = true) {\r\n    return {\r\n        type: 19 /* JS_CONDITIONAL_EXPRESSION */,\r\n        test,\r\n        consequent,\r\n        alternate,\r\n        newline,\r\n        loc: locStub\r\n    };\r\n}\r\nfunction createCacheExpression(index, value, isVNode = false) {\r\n    return {\r\n        type: 20 /* JS_CACHE_EXPRESSION */,\r\n        index,\r\n        value,\r\n        isVNode,\r\n        loc: locStub\r\n    };\r\n}\r\nfunction createBlockStatement(body) {\r\n    return {\r\n        type: 21 /* JS_BLOCK_STATEMENT */,\r\n        body,\r\n        loc: locStub\r\n    };\r\n}\r\nfunction createTemplateLiteral(elements) {\r\n    return {\r\n        type: 22 /* JS_TEMPLATE_LITERAL */,\r\n        elements,\r\n        loc: locStub\r\n    };\r\n}\r\nfunction createIfStatement(test, consequent, alternate) {\r\n    return {\r\n        type: 23 /* JS_IF_STATEMENT */,\r\n        test,\r\n        consequent,\r\n        alternate,\r\n        loc: locStub\r\n    };\r\n}\r\nfunction createAssignmentExpression(left, right) {\r\n    return {\r\n        type: 24 /* JS_ASSIGNMENT_EXPRESSION */,\r\n        left,\r\n        right,\r\n        loc: locStub\r\n    };\r\n}\r\nfunction createSequenceExpression(expressions) {\r\n    return {\r\n        type: 25 /* JS_SEQUENCE_EXPRESSION */,\r\n        expressions,\r\n        loc: locStub\r\n    };\r\n}\r\nfunction createReturnStatement(returns) {\r\n    return {\r\n        type: 26 /* JS_RETURN_STATEMENT */,\r\n        returns,\r\n        loc: locStub\r\n    };\r\n}\n\nconst isStaticExp = (p) => p.type === 4 /* SIMPLE_EXPRESSION */ && p.isStatic;\r\nconst isBuiltInType = (tag, expected) => tag === expected || tag === hyphenate(expected);\r\nfunction isCoreComponent(tag) {\r\n    if (isBuiltInType(tag, 'Teleport')) {\r\n        return TELEPORT;\r\n    }\r\n    else if (isBuiltInType(tag, 'Suspense')) {\r\n        return SUSPENSE;\r\n    }\r\n    else if (isBuiltInType(tag, 'KeepAlive')) {\r\n        return KEEP_ALIVE;\r\n    }\r\n    else if (isBuiltInType(tag, 'BaseTransition')) {\r\n        return BASE_TRANSITION;\r\n    }\r\n}\r\nconst nonIdentifierRE = /^\\d|[^\\$\\w]/;\r\nconst isSimpleIdentifier = (name) => !nonIdentifierRE.test(name);\r\nconst validFirstIdentCharRE = /[A-Za-z_$\\xA0-\\uFFFF]/;\r\nconst validIdentCharRE = /[\\.\\?\\w$\\xA0-\\uFFFF]/;\r\nconst whitespaceRE = /\\s+[.[]\\s*|\\s*[.[]\\s+/g;\r\n/**\r\n * Simple lexer to check if an expression is a member expression. This is\r\n * lax and only checks validity at the root level (i.e. does not validate exps\r\n * inside square brackets), but it's ok since these are only used on template\r\n * expressions and false positives are invalid expressions in the first place.\r\n */\r\nconst isMemberExpressionBrowser = (path) => {\r\n    // remove whitespaces around . or [ first\r\n    path = path.trim().replace(whitespaceRE, s => s.trim());\r\n    let state = 0 /* inMemberExp */;\r\n    let stateStack = [];\r\n    let currentOpenBracketCount = 0;\r\n    let currentOpenParensCount = 0;\r\n    let currentStringType = null;\r\n    for (let i = 0; i < path.length; i++) {\r\n        const char = path.charAt(i);\r\n        switch (state) {\r\n            case 0 /* inMemberExp */:\r\n                if (char === '[') {\r\n                    stateStack.push(state);\r\n                    state = 1 /* inBrackets */;\r\n                    currentOpenBracketCount++;\r\n                }\r\n                else if (char === '(') {\r\n                    stateStack.push(state);\r\n                    state = 2 /* inParens */;\r\n                    currentOpenParensCount++;\r\n                }\r\n                else if (!(i === 0 ? validFirstIdentCharRE : validIdentCharRE).test(char)) {\r\n                    return false;\r\n                }\r\n                break;\r\n            case 1 /* inBrackets */:\r\n                if (char === `'` || char === `\"` || char === '`') {\r\n                    stateStack.push(state);\r\n                    state = 3 /* inString */;\r\n                    currentStringType = char;\r\n                }\r\n                else if (char === `[`) {\r\n                    currentOpenBracketCount++;\r\n                }\r\n                else if (char === `]`) {\r\n                    if (!--currentOpenBracketCount) {\r\n                        state = stateStack.pop();\r\n                    }\r\n                }\r\n                break;\r\n            case 2 /* inParens */:\r\n                if (char === `'` || char === `\"` || char === '`') {\r\n                    stateStack.push(state);\r\n                    state = 3 /* inString */;\r\n                    currentStringType = char;\r\n                }\r\n                else if (char === `(`) {\r\n                    currentOpenParensCount++;\r\n                }\r\n                else if (char === `)`) {\r\n                    // if the exp ends as a call then it should not be considered valid\r\n                    if (i === path.length - 1) {\r\n                        return false;\r\n                    }\r\n                    if (!--currentOpenParensCount) {\r\n                        state = stateStack.pop();\r\n                    }\r\n                }\r\n                break;\r\n            case 3 /* inString */:\r\n                if (char === currentStringType) {\r\n                    state = stateStack.pop();\r\n                    currentStringType = null;\r\n                }\r\n                break;\r\n        }\r\n    }\r\n    return !currentOpenBracketCount && !currentOpenParensCount;\r\n};\r\nconst isMemberExpressionNode = NOOP\r\n    ;\r\nconst isMemberExpression = isMemberExpressionBrowser\r\n    ;\r\nfunction getInnerRange(loc, offset, length) {\r\n    const source = loc.source.slice(offset, offset + length);\r\n    const newLoc = {\r\n        source,\r\n        start: advancePositionWithClone(loc.start, loc.source, offset),\r\n        end: loc.end\r\n    };\r\n    if (length != null) {\r\n        newLoc.end = advancePositionWithClone(loc.start, loc.source, offset + length);\r\n    }\r\n    return newLoc;\r\n}\r\nfunction advancePositionWithClone(pos, source, numberOfCharacters = source.length) {\r\n    return advancePositionWithMutation(extend({}, pos), source, numberOfCharacters);\r\n}\r\n// advance by mutation without cloning (for performance reasons), since this\r\n// gets called a lot in the parser\r\nfunction advancePositionWithMutation(pos, source, numberOfCharacters = source.length) {\r\n    let linesCount = 0;\r\n    let lastNewLinePos = -1;\r\n    for (let i = 0; i < numberOfCharacters; i++) {\r\n        if (source.charCodeAt(i) === 10 /* newline char code */) {\r\n            linesCount++;\r\n            lastNewLinePos = i;\r\n        }\r\n    }\r\n    pos.offset += numberOfCharacters;\r\n    pos.line += linesCount;\r\n    pos.column =\r\n        lastNewLinePos === -1\r\n            ? pos.column + numberOfCharacters\r\n            : numberOfCharacters - lastNewLinePos;\r\n    return pos;\r\n}\r\nfunction assert(condition, msg) {\r\n    /* istanbul ignore if */\r\n    if (!condition) {\r\n        throw new Error(msg || `unexpected compiler condition`);\r\n    }\r\n}\r\nfunction findDir(node, name, allowEmpty = false) {\r\n    for (let i = 0; i < node.props.length; i++) {\r\n        const p = node.props[i];\r\n        if (p.type === 7 /* DIRECTIVE */ &&\r\n            (allowEmpty || p.exp) &&\r\n            (isString(name) ? p.name === name : name.test(p.name))) {\r\n            return p;\r\n        }\r\n    }\r\n}\r\nfunction findProp(node, name, dynamicOnly = false, allowEmpty = false) {\r\n    for (let i = 0; i < node.props.length; i++) {\r\n        const p = node.props[i];\r\n        if (p.type === 6 /* ATTRIBUTE */) {\r\n            if (dynamicOnly)\r\n                continue;\r\n            if (p.name === name && (p.value || allowEmpty)) {\r\n                return p;\r\n            }\r\n        }\r\n        else if (p.name === 'bind' &&\r\n            (p.exp || allowEmpty) &&\r\n            isStaticArgOf(p.arg, name)) {\r\n            return p;\r\n        }\r\n    }\r\n}\r\nfunction isStaticArgOf(arg, name) {\r\n    return !!(arg && isStaticExp(arg) && arg.content === name);\r\n}\r\nfunction hasDynamicKeyVBind(node) {\r\n    return node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n        p.name === 'bind' &&\r\n        (!p.arg || // v-bind=\"obj\"\r\n            p.arg.type !== 4 /* SIMPLE_EXPRESSION */ || // v-bind:[_ctx.foo]\r\n            !p.arg.isStatic) // v-bind:[foo]\r\n    );\r\n}\r\nfunction isText(node) {\r\n    return node.type === 5 /* INTERPOLATION */ || node.type === 2 /* TEXT */;\r\n}\r\nfunction isVSlot(p) {\r\n    return p.type === 7 /* DIRECTIVE */ && p.name === 'slot';\r\n}\r\nfunction isTemplateNode(node) {\r\n    return (node.type === 1 /* ELEMENT */ && node.tagType === 3 /* TEMPLATE */);\r\n}\r\nfunction isSlotOutlet(node) {\r\n    return node.type === 1 /* ELEMENT */ && node.tagType === 2 /* SLOT */;\r\n}\r\nfunction getVNodeHelper(ssr, isComponent) {\r\n    return ssr || isComponent ? CREATE_VNODE : CREATE_ELEMENT_VNODE;\r\n}\r\nfunction getVNodeBlockHelper(ssr, isComponent) {\r\n    return ssr || isComponent ? CREATE_BLOCK : CREATE_ELEMENT_BLOCK;\r\n}\r\nconst propsHelperSet = new Set([NORMALIZE_PROPS, GUARD_REACTIVE_PROPS]);\r\nfunction getUnnormalizedProps(props, callPath = []) {\r\n    if (props &&\r\n        !isString(props) &&\r\n        props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n        const callee = props.callee;\r\n        if (!isString(callee) && propsHelperSet.has(callee)) {\r\n            return getUnnormalizedProps(props.arguments[0], callPath.concat(props));\r\n        }\r\n    }\r\n    return [props, callPath];\r\n}\r\nfunction injectProp(node, prop, context) {\r\n    let propsWithInjection;\r\n    /**\r\n     * 1. mergeProps(...)\r\n     * 2. toHandlers(...)\r\n     * 3. normalizeProps(...)\r\n     * 4. normalizeProps(guardReactiveProps(...))\r\n     *\r\n     * we need to get the real props before normalization\r\n     */\r\n    let props = node.type === 13 /* VNODE_CALL */ ? node.props : node.arguments[2];\r\n    let callPath = [];\r\n    let parentCall;\r\n    if (props &&\r\n        !isString(props) &&\r\n        props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n        const ret = getUnnormalizedProps(props);\r\n        props = ret[0];\r\n        callPath = ret[1];\r\n        parentCall = callPath[callPath.length - 1];\r\n    }\r\n    if (props == null || isString(props)) {\r\n        propsWithInjection = createObjectExpression([prop]);\r\n    }\r\n    else if (props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n        // merged props... add ours\r\n        // only inject key to object literal if it's the first argument so that\r\n        // if doesn't override user provided keys\r\n        const first = props.arguments[0];\r\n        if (!isString(first) && first.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n            first.properties.unshift(prop);\r\n        }\r\n        else {\r\n            if (props.callee === TO_HANDLERS) {\r\n                // #2366\r\n                propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n                    createObjectExpression([prop]),\r\n                    props\r\n                ]);\r\n            }\r\n            else {\r\n                props.arguments.unshift(createObjectExpression([prop]));\r\n            }\r\n        }\r\n        !propsWithInjection && (propsWithInjection = props);\r\n    }\r\n    else if (props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n        let alreadyExists = false;\r\n        // check existing key to avoid overriding user provided keys\r\n        if (prop.key.type === 4 /* SIMPLE_EXPRESSION */) {\r\n            const propKeyName = prop.key.content;\r\n            alreadyExists = props.properties.some(p => p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n                p.key.content === propKeyName);\r\n        }\r\n        if (!alreadyExists) {\r\n            props.properties.unshift(prop);\r\n        }\r\n        propsWithInjection = props;\r\n    }\r\n    else {\r\n        // single v-bind with expression, return a merged replacement\r\n        propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n            createObjectExpression([prop]),\r\n            props\r\n        ]);\r\n        // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(props))`,\r\n        // it will be rewritten as `normalizeProps(mergeProps({ key: 0 }, props))`,\r\n        // the `guardReactiveProps` will no longer be needed\r\n        if (parentCall && parentCall.callee === GUARD_REACTIVE_PROPS) {\r\n            parentCall = callPath[callPath.length - 2];\r\n        }\r\n    }\r\n    if (node.type === 13 /* VNODE_CALL */) {\r\n        if (parentCall) {\r\n            parentCall.arguments[0] = propsWithInjection;\r\n        }\r\n        else {\r\n            node.props = propsWithInjection;\r\n        }\r\n    }\r\n    else {\r\n        if (parentCall) {\r\n            parentCall.arguments[0] = propsWithInjection;\r\n        }\r\n        else {\r\n            node.arguments[2] = propsWithInjection;\r\n        }\r\n    }\r\n}\r\nfunction toValidAssetId(name, type) {\r\n    // see issue#4422, we need adding identifier on validAssetId if variable `name` has specific character\r\n    return `_${type}_${name.replace(/[^\\w]/g, (searchValue, replaceValue) => {\r\n        return searchValue === '-' ? '_' : name.charCodeAt(replaceValue).toString();\r\n    })}`;\r\n}\r\n// Check if a node contains expressions that reference current context scope ids\r\nfunction hasScopeRef(node, ids) {\r\n    if (!node || Object.keys(ids).length === 0) {\r\n        return false;\r\n    }\r\n    switch (node.type) {\r\n        case 1 /* ELEMENT */:\r\n            for (let i = 0; i < node.props.length; i++) {\r\n                const p = node.props[i];\r\n                if (p.type === 7 /* DIRECTIVE */ &&\r\n                    (hasScopeRef(p.arg, ids) || hasScopeRef(p.exp, ids))) {\r\n                    return true;\r\n                }\r\n            }\r\n            return node.children.some(c => hasScopeRef(c, ids));\r\n        case 11 /* FOR */:\r\n            if (hasScopeRef(node.source, ids)) {\r\n                return true;\r\n            }\r\n            return node.children.some(c => hasScopeRef(c, ids));\r\n        case 9 /* IF */:\r\n            return node.branches.some(b => hasScopeRef(b, ids));\r\n        case 10 /* IF_BRANCH */:\r\n            if (hasScopeRef(node.condition, ids)) {\r\n                return true;\r\n            }\r\n            return node.children.some(c => hasScopeRef(c, ids));\r\n        case 4 /* SIMPLE_EXPRESSION */:\r\n            return (!node.isStatic &&\r\n                isSimpleIdentifier(node.content) &&\r\n                !!ids[node.content]);\r\n        case 8 /* COMPOUND_EXPRESSION */:\r\n            return node.children.some(c => isObject(c) && hasScopeRef(c, ids));\r\n        case 5 /* INTERPOLATION */:\r\n        case 12 /* TEXT_CALL */:\r\n            return hasScopeRef(node.content, ids);\r\n        case 2 /* TEXT */:\r\n        case 3 /* COMMENT */:\r\n            return false;\r\n        default:\r\n            if ((process.env.NODE_ENV !== 'production')) ;\r\n            return false;\r\n    }\r\n}\r\nfunction getMemoedVNodeCall(node) {\r\n    if (node.type === 14 /* JS_CALL_EXPRESSION */ && node.callee === WITH_MEMO) {\r\n        return node.arguments[1].returns;\r\n    }\r\n    else {\r\n        return node;\r\n    }\r\n}\r\nfunction makeBlock(node, { helper, removeHelper, inSSR }) {\r\n    if (!node.isBlock) {\r\n        node.isBlock = true;\r\n        removeHelper(getVNodeHelper(inSSR, node.isComponent));\r\n        helper(OPEN_BLOCK);\r\n        helper(getVNodeBlockHelper(inSSR, node.isComponent));\r\n    }\r\n}\n\nconst deprecationData = {\r\n    [\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */]: {\r\n        message: `Platform-native elements with \"is\" prop will no longer be ` +\r\n            `treated as components in Vue 3 unless the \"is\" value is explicitly ` +\r\n            `prefixed with \"vue:\".`,\r\n        link: `https://v3-migration.vuejs.org/breaking-changes/custom-elements-interop.html`\r\n    },\r\n    [\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */]: {\r\n        message: key => `.sync modifier for v-bind has been removed. Use v-model with ` +\r\n            `argument instead. \\`v-bind:${key}.sync\\` should be changed to ` +\r\n            `\\`v-model:${key}\\`.`,\r\n        link: `https://v3-migration.vuejs.org/breaking-changes/v-model.html`\r\n    },\r\n    [\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */]: {\r\n        message: `.prop modifier for v-bind has been removed and no longer necessary. ` +\r\n            `Vue 3 will automatically set a binding as DOM property when appropriate.`\r\n    },\r\n    [\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */]: {\r\n        message: `v-bind=\"obj\" usage is now order sensitive and behaves like JavaScript ` +\r\n            `object spread: it will now overwrite an existing non-mergeable attribute ` +\r\n            `that appears before v-bind in the case of conflict. ` +\r\n            `To retain 2.x behavior, move v-bind to make it the first attribute. ` +\r\n            `You can also suppress this warning if the usage is intended.`,\r\n        link: `https://v3-migration.vuejs.org/breaking-changes/v-bind.html`\r\n    },\r\n    [\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */]: {\r\n        message: `.native modifier for v-on has been removed as is no longer necessary.`,\r\n        link: `https://v3-migration.vuejs.org/breaking-changes/v-on-native-modifier-removed.html`\r\n    },\r\n    [\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */]: {\r\n        message: `v-if / v-for precedence when used on the same element has changed ` +\r\n            `in Vue 3: v-if now takes higher precedence and will no longer have ` +\r\n            `access to v-for scope variables. It is best to avoid the ambiguity ` +\r\n            `with <template> tags or use a computed property that filters v-for ` +\r\n            `data source.`,\r\n        link: `https://v3-migration.vuejs.org/breaking-changes/v-if-v-for.html`\r\n    },\r\n    [\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */]: {\r\n        message: `<template> with no special directives will render as a native template ` +\r\n            `element instead of its inner content in Vue 3.`\r\n    },\r\n    [\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */]: {\r\n        message: `\"inline-template\" has been removed in Vue 3.`,\r\n        link: `https://v3-migration.vuejs.org/breaking-changes/inline-template-attribute.html`\r\n    },\r\n    [\"COMPILER_FILTER\" /* COMPILER_FILTERS */]: {\r\n        message: `filters have been removed in Vue 3. ` +\r\n            `The \"|\" symbol will be treated as native JavaScript bitwise OR operator. ` +\r\n            `Use method calls or computed properties instead.`,\r\n        link: `https://v3-migration.vuejs.org/breaking-changes/filters.html`\r\n    }\r\n};\r\nfunction getCompatValue(key, context) {\r\n    const config = context.options\r\n        ? context.options.compatConfig\r\n        : context.compatConfig;\r\n    const value = config && config[key];\r\n    if (key === 'MODE') {\r\n        return value || 3; // compiler defaults to v3 behavior\r\n    }\r\n    else {\r\n        return value;\r\n    }\r\n}\r\nfunction isCompatEnabled(key, context) {\r\n    const mode = getCompatValue('MODE', context);\r\n    const value = getCompatValue(key, context);\r\n    // in v3 mode, only enable if explicitly set to true\r\n    // otherwise enable for any non-false value\r\n    return mode === 3 ? value === true : value !== false;\r\n}\r\nfunction checkCompatEnabled(key, context, loc, ...args) {\r\n    const enabled = isCompatEnabled(key, context);\r\n    if ((process.env.NODE_ENV !== 'production') && enabled) {\r\n        warnDeprecation(key, context, loc, ...args);\r\n    }\r\n    return enabled;\r\n}\r\nfunction warnDeprecation(key, context, loc, ...args) {\r\n    const val = getCompatValue(key, context);\r\n    if (val === 'suppress-warning') {\r\n        return;\r\n    }\r\n    const { message, link } = deprecationData[key];\r\n    const msg = `(deprecation ${key}) ${typeof message === 'function' ? message(...args) : message}${link ? `\\n  Details: ${link}` : ``}`;\r\n    const err = new SyntaxError(msg);\r\n    err.code = key;\r\n    if (loc)\r\n        err.loc = loc;\r\n    context.onWarn(err);\r\n}\n\n// The default decoder only provides escapes for characters reserved as part of\r\n// the template syntax, and is only used if the custom renderer did not provide\r\n// a platform-specific decoder.\r\nconst decodeRE = /&(gt|lt|amp|apos|quot);/g;\r\nconst decodeMap = {\r\n    gt: '>',\r\n    lt: '<',\r\n    amp: '&',\r\n    apos: \"'\",\r\n    quot: '\"'\r\n};\r\nconst defaultParserOptions = {\r\n    delimiters: [`{{`, `}}`],\r\n    getNamespace: () => 0 /* HTML */,\r\n    getTextMode: () => 0 /* DATA */,\r\n    isVoidTag: NO,\r\n    isPreTag: NO,\r\n    isCustomElement: NO,\r\n    decodeEntities: (rawText) => rawText.replace(decodeRE, (_, p1) => decodeMap[p1]),\r\n    onError: defaultOnError,\r\n    onWarn: defaultOnWarn,\r\n    comments: (process.env.NODE_ENV !== 'production')\r\n};\r\nfunction baseParse(content, options = {}) {\r\n    const context = createParserContext(content, options);\r\n    const start = getCursor(context);\r\n    return createRoot(parseChildren(context, 0 /* DATA */, []), getSelection(context, start));\r\n}\r\nfunction createParserContext(content, rawOptions) {\r\n    const options = extend({}, defaultParserOptions);\r\n    let key;\r\n    for (key in rawOptions) {\r\n        // @ts-ignore\r\n        options[key] =\r\n            rawOptions[key] === undefined\r\n                ? defaultParserOptions[key]\r\n                : rawOptions[key];\r\n    }\r\n    return {\r\n        options,\r\n        column: 1,\r\n        line: 1,\r\n        offset: 0,\r\n        originalSource: content,\r\n        source: content,\r\n        inPre: false,\r\n        inVPre: false,\r\n        onWarn: options.onWarn\r\n    };\r\n}\r\nfunction parseChildren(context, mode, ancestors) {\r\n    const parent = last(ancestors);\r\n    const ns = parent ? parent.ns : 0 /* HTML */;\r\n    const nodes = [];\r\n    while (!isEnd(context, mode, ancestors)) {\r\n        const s = context.source;\r\n        let node = undefined;\r\n        if (mode === 0 /* DATA */ || mode === 1 /* RCDATA */) {\r\n            if (!context.inVPre && startsWith(s, context.options.delimiters[0])) {\r\n                // '{{'\r\n                node = parseInterpolation(context, mode);\r\n            }\r\n            else if (mode === 0 /* DATA */ && s[0] === '<') {\r\n                // https://html.spec.whatwg.org/multipage/parsing.html#tag-open-state\r\n                if (s.length === 1) {\r\n                    emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 1);\r\n                }\r\n                else if (s[1] === '!') {\r\n                    // https://html.spec.whatwg.org/multipage/parsing.html#markup-declaration-open-state\r\n                    if (startsWith(s, '<!--')) {\r\n                        node = parseComment(context);\r\n                    }\r\n                    else if (startsWith(s, '<!DOCTYPE')) {\r\n                        // Ignore DOCTYPE by a limitation.\r\n                        node = parseBogusComment(context);\r\n                    }\r\n                    else if (startsWith(s, '<![CDATA[')) {\r\n                        if (ns !== 0 /* HTML */) {\r\n                            node = parseCDATA(context, ancestors);\r\n                        }\r\n                        else {\r\n                            emitError(context, 1 /* CDATA_IN_HTML_CONTENT */);\r\n                            node = parseBogusComment(context);\r\n                        }\r\n                    }\r\n                    else {\r\n                        emitError(context, 11 /* INCORRECTLY_OPENED_COMMENT */);\r\n                        node = parseBogusComment(context);\r\n                    }\r\n                }\r\n                else if (s[1] === '/') {\r\n                    // https://html.spec.whatwg.org/multipage/parsing.html#end-tag-open-state\r\n                    if (s.length === 2) {\r\n                        emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 2);\r\n                    }\r\n                    else if (s[2] === '>') {\r\n                        emitError(context, 14 /* MISSING_END_TAG_NAME */, 2);\r\n                        advanceBy(context, 3);\r\n                        continue;\r\n                    }\r\n                    else if (/[a-z]/i.test(s[2])) {\r\n                        emitError(context, 23 /* X_INVALID_END_TAG */);\r\n                        parseTag(context, 1 /* End */, parent);\r\n                        continue;\r\n                    }\r\n                    else {\r\n                        emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 2);\r\n                        node = parseBogusComment(context);\r\n                    }\r\n                }\r\n                else if (/[a-z]/i.test(s[1])) {\r\n                    node = parseElement(context, ancestors);\r\n                    // 2.x <template> with no directive compat\r\n                    if (isCompatEnabled(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context) &&\r\n                        node &&\r\n                        node.tag === 'template' &&\r\n                        !node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n                            isSpecialTemplateDirective(p.name))) {\r\n                        (process.env.NODE_ENV !== 'production') &&\r\n                            warnDeprecation(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context, node.loc);\r\n                        node = node.children;\r\n                    }\r\n                }\r\n                else if (s[1] === '?') {\r\n                    emitError(context, 21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */, 1);\r\n                    node = parseBogusComment(context);\r\n                }\r\n                else {\r\n                    emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 1);\r\n                }\r\n            }\r\n        }\r\n        if (!node) {\r\n            node = parseText(context, mode);\r\n        }\r\n        if (isArray(node)) {\r\n            for (let i = 0; i < node.length; i++) {\r\n                pushNode(nodes, node[i]);\r\n            }\r\n        }\r\n        else {\r\n            pushNode(nodes, node);\r\n        }\r\n    }\r\n    // Whitespace handling strategy like v2\r\n    let removedWhitespace = false;\r\n    if (mode !== 2 /* RAWTEXT */ && mode !== 1 /* RCDATA */) {\r\n        const shouldCondense = context.options.whitespace !== 'preserve';\r\n        for (let i = 0; i < nodes.length; i++) {\r\n            const node = nodes[i];\r\n            if (!context.inPre && node.type === 2 /* TEXT */) {\r\n                if (!/[^\\t\\r\\n\\f ]/.test(node.content)) {\r\n                    const prev = nodes[i - 1];\r\n                    const next = nodes[i + 1];\r\n                    // Remove if:\r\n                    // - the whitespace is the first or last node, or:\r\n                    // - (condense mode) the whitespace is adjacent to a comment, or:\r\n                    // - (condense mode) the whitespace is between two elements AND contains newline\r\n                    if (!prev ||\r\n                        !next ||\r\n                        (shouldCondense &&\r\n                            (prev.type === 3 /* COMMENT */ ||\r\n                                next.type === 3 /* COMMENT */ ||\r\n                                (prev.type === 1 /* ELEMENT */ &&\r\n                                    next.type === 1 /* ELEMENT */ &&\r\n                                    /[\\r\\n]/.test(node.content))))) {\r\n                        removedWhitespace = true;\r\n                        nodes[i] = null;\r\n                    }\r\n                    else {\r\n                        // Otherwise, the whitespace is condensed into a single space\r\n                        node.content = ' ';\r\n                    }\r\n                }\r\n                else if (shouldCondense) {\r\n                    // in condense mode, consecutive whitespaces in text are condensed\r\n                    // down to a single space.\r\n                    node.content = node.content.replace(/[\\t\\r\\n\\f ]+/g, ' ');\r\n                }\r\n            }\r\n            // Remove comment nodes if desired by configuration.\r\n            else if (node.type === 3 /* COMMENT */ && !context.options.comments) {\r\n                removedWhitespace = true;\r\n                nodes[i] = null;\r\n            }\r\n        }\r\n        if (context.inPre && parent && context.options.isPreTag(parent.tag)) {\r\n            // remove leading newline per html spec\r\n            // https://html.spec.whatwg.org/multipage/grouping-content.html#the-pre-element\r\n            const first = nodes[0];\r\n            if (first && first.type === 2 /* TEXT */) {\r\n                first.content = first.content.replace(/^\\r?\\n/, '');\r\n            }\r\n        }\r\n    }\r\n    return removedWhitespace ? nodes.filter(Boolean) : nodes;\r\n}\r\nfunction pushNode(nodes, node) {\r\n    if (node.type === 2 /* TEXT */) {\r\n        const prev = last(nodes);\r\n        // Merge if both this and the previous node are text and those are\r\n        // consecutive. This happens for cases like \"a < b\".\r\n        if (prev &&\r\n            prev.type === 2 /* TEXT */ &&\r\n            prev.loc.end.offset === node.loc.start.offset) {\r\n            prev.content += node.content;\r\n            prev.loc.end = node.loc.end;\r\n            prev.loc.source += node.loc.source;\r\n            return;\r\n        }\r\n    }\r\n    nodes.push(node);\r\n}\r\nfunction parseCDATA(context, ancestors) {\r\n    advanceBy(context, 9);\r\n    const nodes = parseChildren(context, 3 /* CDATA */, ancestors);\r\n    if (context.source.length === 0) {\r\n        emitError(context, 6 /* EOF_IN_CDATA */);\r\n    }\r\n    else {\r\n        advanceBy(context, 3);\r\n    }\r\n    return nodes;\r\n}\r\nfunction parseComment(context) {\r\n    const start = getCursor(context);\r\n    let content;\r\n    // Regular comment.\r\n    const match = /--(\\!)?>/.exec(context.source);\r\n    if (!match) {\r\n        content = context.source.slice(4);\r\n        advanceBy(context, context.source.length);\r\n        emitError(context, 7 /* EOF_IN_COMMENT */);\r\n    }\r\n    else {\r\n        if (match.index <= 3) {\r\n            emitError(context, 0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */);\r\n        }\r\n        if (match[1]) {\r\n            emitError(context, 10 /* INCORRECTLY_CLOSED_COMMENT */);\r\n        }\r\n        content = context.source.slice(4, match.index);\r\n        // Advancing with reporting nested comments.\r\n        const s = context.source.slice(0, match.index);\r\n        let prevIndex = 1, nestedIndex = 0;\r\n        while ((nestedIndex = s.indexOf('<!--', prevIndex)) !== -1) {\r\n            advanceBy(context, nestedIndex - prevIndex + 1);\r\n            if (nestedIndex + 4 < s.length) {\r\n                emitError(context, 16 /* NESTED_COMMENT */);\r\n            }\r\n            prevIndex = nestedIndex + 1;\r\n        }\r\n        advanceBy(context, match.index + match[0].length - prevIndex + 1);\r\n    }\r\n    return {\r\n        type: 3 /* COMMENT */,\r\n        content,\r\n        loc: getSelection(context, start)\r\n    };\r\n}\r\nfunction parseBogusComment(context) {\r\n    const start = getCursor(context);\r\n    const contentStart = context.source[1] === '?' ? 1 : 2;\r\n    let content;\r\n    const closeIndex = context.source.indexOf('>');\r\n    if (closeIndex === -1) {\r\n        content = context.source.slice(contentStart);\r\n        advanceBy(context, context.source.length);\r\n    }\r\n    else {\r\n        content = context.source.slice(contentStart, closeIndex);\r\n        advanceBy(context, closeIndex + 1);\r\n    }\r\n    return {\r\n        type: 3 /* COMMENT */,\r\n        content,\r\n        loc: getSelection(context, start)\r\n    };\r\n}\r\nfunction parseElement(context, ancestors) {\r\n    // Start tag.\r\n    const wasInPre = context.inPre;\r\n    const wasInVPre = context.inVPre;\r\n    const parent = last(ancestors);\r\n    const element = parseTag(context, 0 /* Start */, parent);\r\n    const isPreBoundary = context.inPre && !wasInPre;\r\n    const isVPreBoundary = context.inVPre && !wasInVPre;\r\n    if (element.isSelfClosing || context.options.isVoidTag(element.tag)) {\r\n        // #4030 self-closing <pre> tag\r\n        if (isPreBoundary) {\r\n            context.inPre = false;\r\n        }\r\n        if (isVPreBoundary) {\r\n            context.inVPre = false;\r\n        }\r\n        return element;\r\n    }\r\n    // Children.\r\n    ancestors.push(element);\r\n    const mode = context.options.getTextMode(element, parent);\r\n    const children = parseChildren(context, mode, ancestors);\r\n    ancestors.pop();\r\n    // 2.x inline-template compat\r\n    {\r\n        const inlineTemplateProp = element.props.find(p => p.type === 6 /* ATTRIBUTE */ && p.name === 'inline-template');\r\n        if (inlineTemplateProp &&\r\n            checkCompatEnabled(\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */, context, inlineTemplateProp.loc)) {\r\n            const loc = getSelection(context, element.loc.end);\r\n            inlineTemplateProp.value = {\r\n                type: 2 /* TEXT */,\r\n                content: loc.source,\r\n                loc\r\n            };\r\n        }\r\n    }\r\n    element.children = children;\r\n    // End tag.\r\n    if (startsWithEndTagOpen(context.source, element.tag)) {\r\n        parseTag(context, 1 /* End */, parent);\r\n    }\r\n    else {\r\n        emitError(context, 24 /* X_MISSING_END_TAG */, 0, element.loc.start);\r\n        if (context.source.length === 0 && element.tag.toLowerCase() === 'script') {\r\n            const first = children[0];\r\n            if (first && startsWith(first.loc.source, '<!--')) {\r\n                emitError(context, 8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */);\r\n            }\r\n        }\r\n    }\r\n    element.loc = getSelection(context, element.loc.start);\r\n    if (isPreBoundary) {\r\n        context.inPre = false;\r\n    }\r\n    if (isVPreBoundary) {\r\n        context.inVPre = false;\r\n    }\r\n    return element;\r\n}\r\nconst isSpecialTemplateDirective = /*#__PURE__*/ makeMap(`if,else,else-if,for,slot`);\r\nfunction parseTag(context, type, parent) {\r\n    // Tag open.\r\n    const start = getCursor(context);\r\n    const match = /^<\\/?([a-z][^\\t\\r\\n\\f />]*)/i.exec(context.source);\r\n    const tag = match[1];\r\n    const ns = context.options.getNamespace(tag, parent);\r\n    advanceBy(context, match[0].length);\r\n    advanceSpaces(context);\r\n    // save current state in case we need to re-parse attributes with v-pre\r\n    const cursor = getCursor(context);\r\n    const currentSource = context.source;\r\n    // check <pre> tag\r\n    if (context.options.isPreTag(tag)) {\r\n        context.inPre = true;\r\n    }\r\n    // Attributes.\r\n    let props = parseAttributes(context, type);\r\n    // check v-pre\r\n    if (type === 0 /* Start */ &&\r\n        !context.inVPre &&\r\n        props.some(p => p.type === 7 /* DIRECTIVE */ && p.name === 'pre')) {\r\n        context.inVPre = true;\r\n        // reset context\r\n        extend(context, cursor);\r\n        context.source = currentSource;\r\n        // re-parse attrs and filter out v-pre itself\r\n        props = parseAttributes(context, type).filter(p => p.name !== 'v-pre');\r\n    }\r\n    // Tag close.\r\n    let isSelfClosing = false;\r\n    if (context.source.length === 0) {\r\n        emitError(context, 9 /* EOF_IN_TAG */);\r\n    }\r\n    else {\r\n        isSelfClosing = startsWith(context.source, '/>');\r\n        if (type === 1 /* End */ && isSelfClosing) {\r\n            emitError(context, 4 /* END_TAG_WITH_TRAILING_SOLIDUS */);\r\n        }\r\n        advanceBy(context, isSelfClosing ? 2 : 1);\r\n    }\r\n    if (type === 1 /* End */) {\r\n        return;\r\n    }\r\n    // 2.x deprecation checks\r\n    if ((process.env.NODE_ENV !== 'production') &&\r\n        isCompatEnabled(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context)) {\r\n        let hasIf = false;\r\n        let hasFor = false;\r\n        for (let i = 0; i < props.length; i++) {\r\n            const p = props[i];\r\n            if (p.type === 7 /* DIRECTIVE */) {\r\n                if (p.name === 'if') {\r\n                    hasIf = true;\r\n                }\r\n                else if (p.name === 'for') {\r\n                    hasFor = true;\r\n                }\r\n            }\r\n            if (hasIf && hasFor) {\r\n                warnDeprecation(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context, getSelection(context, start));\r\n                break;\r\n            }\r\n        }\r\n    }\r\n    let tagType = 0 /* ELEMENT */;\r\n    if (!context.inVPre) {\r\n        if (tag === 'slot') {\r\n            tagType = 2 /* SLOT */;\r\n        }\r\n        else if (tag === 'template') {\r\n            if (props.some(p => p.type === 7 /* DIRECTIVE */ && isSpecialTemplateDirective(p.name))) {\r\n                tagType = 3 /* TEMPLATE */;\r\n            }\r\n        }\r\n        else if (isComponent(tag, props, context)) {\r\n            tagType = 1 /* COMPONENT */;\r\n        }\r\n    }\r\n    return {\r\n        type: 1 /* ELEMENT */,\r\n        ns,\r\n        tag,\r\n        tagType,\r\n        props,\r\n        isSelfClosing,\r\n        children: [],\r\n        loc: getSelection(context, start),\r\n        codegenNode: undefined // to be created during transform phase\r\n    };\r\n}\r\nfunction isComponent(tag, props, context) {\r\n    const options = context.options;\r\n    if (options.isCustomElement(tag)) {\r\n        return false;\r\n    }\r\n    if (tag === 'component' ||\r\n        /^[A-Z]/.test(tag) ||\r\n        isCoreComponent(tag) ||\r\n        (options.isBuiltInComponent && options.isBuiltInComponent(tag)) ||\r\n        (options.isNativeTag && !options.isNativeTag(tag))) {\r\n        return true;\r\n    }\r\n    // at this point the tag should be a native tag, but check for potential \"is\"\r\n    // casting\r\n    for (let i = 0; i < props.length; i++) {\r\n        const p = props[i];\r\n        if (p.type === 6 /* ATTRIBUTE */) {\r\n            if (p.name === 'is' && p.value) {\r\n                if (p.value.content.startsWith('vue:')) {\r\n                    return true;\r\n                }\r\n                else if (checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n                    return true;\r\n                }\r\n            }\r\n        }\r\n        else {\r\n            // directive\r\n            // v-is (TODO Deprecate)\r\n            if (p.name === 'is') {\r\n                return true;\r\n            }\r\n            else if (\r\n            // :is on plain element - only treat as component in compat mode\r\n            p.name === 'bind' &&\r\n                isStaticArgOf(p.arg, 'is') &&\r\n                true &&\r\n                checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n                return true;\r\n            }\r\n        }\r\n    }\r\n}\r\nfunction parseAttributes(context, type) {\r\n    const props = [];\r\n    const attributeNames = new Set();\r\n    while (context.source.length > 0 &&\r\n        !startsWith(context.source, '>') &&\r\n        !startsWith(context.source, '/>')) {\r\n        if (startsWith(context.source, '/')) {\r\n            emitError(context, 22 /* UNEXPECTED_SOLIDUS_IN_TAG */);\r\n            advanceBy(context, 1);\r\n            advanceSpaces(context);\r\n            continue;\r\n        }\r\n        if (type === 1 /* End */) {\r\n            emitError(context, 3 /* END_TAG_WITH_ATTRIBUTES */);\r\n        }\r\n        const attr = parseAttribute(context, attributeNames);\r\n        // Trim whitespace between class\r\n        // https://github.com/vuejs/core/issues/4251\r\n        if (attr.type === 6 /* ATTRIBUTE */ &&\r\n            attr.value &&\r\n            attr.name === 'class') {\r\n            attr.value.content = attr.value.content.replace(/\\s+/g, ' ').trim();\r\n        }\r\n        if (type === 0 /* Start */) {\r\n            props.push(attr);\r\n        }\r\n        if (/^[^\\t\\r\\n\\f />]/.test(context.source)) {\r\n            emitError(context, 15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */);\r\n        }\r\n        advanceSpaces(context);\r\n    }\r\n    return props;\r\n}\r\nfunction parseAttribute(context, nameSet) {\r\n    // Name.\r\n    const start = getCursor(context);\r\n    const match = /^[^\\t\\r\\n\\f />][^\\t\\r\\n\\f />=]*/.exec(context.source);\r\n    const name = match[0];\r\n    if (nameSet.has(name)) {\r\n        emitError(context, 2 /* DUPLICATE_ATTRIBUTE */);\r\n    }\r\n    nameSet.add(name);\r\n    if (name[0] === '=') {\r\n        emitError(context, 19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */);\r\n    }\r\n    {\r\n        const pattern = /[\"'<]/g;\r\n        let m;\r\n        while ((m = pattern.exec(name))) {\r\n            emitError(context, 17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */, m.index);\r\n        }\r\n    }\r\n    advanceBy(context, name.length);\r\n    // Value\r\n    let value = undefined;\r\n    if (/^[\\t\\r\\n\\f ]*=/.test(context.source)) {\r\n        advanceSpaces(context);\r\n        advanceBy(context, 1);\r\n        advanceSpaces(context);\r\n        value = parseAttributeValue(context);\r\n        if (!value) {\r\n            emitError(context, 13 /* MISSING_ATTRIBUTE_VALUE */);\r\n        }\r\n    }\r\n    const loc = getSelection(context, start);\r\n    if (!context.inVPre && /^(v-[A-Za-z0-9-]|:|\\.|@|#)/.test(name)) {\r\n        const match = /(?:^v-([a-z0-9-]+))?(?:(?::|^\\.|^@|^#)(\\[[^\\]]+\\]|[^\\.]+))?(.+)?$/i.exec(name);\r\n        let isPropShorthand = startsWith(name, '.');\r\n        let dirName = match[1] ||\r\n            (isPropShorthand || startsWith(name, ':')\r\n                ? 'bind'\r\n                : startsWith(name, '@')\r\n                    ? 'on'\r\n                    : 'slot');\r\n        let arg;\r\n        if (match[2]) {\r\n            const isSlot = dirName === 'slot';\r\n            const startOffset = name.lastIndexOf(match[2]);\r\n            const loc = getSelection(context, getNewPosition(context, start, startOffset), getNewPosition(context, start, startOffset + match[2].length + ((isSlot && match[3]) || '').length));\r\n            let content = match[2];\r\n            let isStatic = true;\r\n            if (content.startsWith('[')) {\r\n                isStatic = false;\r\n                if (!content.endsWith(']')) {\r\n                    emitError(context, 27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */);\r\n                    content = content.slice(1);\r\n                }\r\n                else {\r\n                    content = content.slice(1, content.length - 1);\r\n                }\r\n            }\r\n            else if (isSlot) {\r\n                // #1241 special case for v-slot: vuetify relies extensively on slot\r\n                // names containing dots. v-slot doesn't have any modifiers and Vue 2.x\r\n                // supports such usage so we are keeping it consistent with 2.x.\r\n                content += match[3] || '';\r\n            }\r\n            arg = {\r\n                type: 4 /* SIMPLE_EXPRESSION */,\r\n                content,\r\n                isStatic,\r\n                constType: isStatic\r\n                    ? 3 /* CAN_STRINGIFY */\r\n                    : 0 /* NOT_CONSTANT */,\r\n                loc\r\n            };\r\n        }\r\n        if (value && value.isQuoted) {\r\n            const valueLoc = value.loc;\r\n            valueLoc.start.offset++;\r\n            valueLoc.start.column++;\r\n            valueLoc.end = advancePositionWithClone(valueLoc.start, value.content);\r\n            valueLoc.source = valueLoc.source.slice(1, -1);\r\n        }\r\n        const modifiers = match[3] ? match[3].slice(1).split('.') : [];\r\n        if (isPropShorthand)\r\n            modifiers.push('prop');\r\n        // 2.x compat v-bind:foo.sync -> v-model:foo\r\n        if (dirName === 'bind' && arg) {\r\n            if (modifiers.includes('sync') &&\r\n                checkCompatEnabled(\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */, context, loc, arg.loc.source)) {\r\n                dirName = 'model';\r\n                modifiers.splice(modifiers.indexOf('sync'), 1);\r\n            }\r\n            if ((process.env.NODE_ENV !== 'production') && modifiers.includes('prop')) {\r\n                checkCompatEnabled(\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */, context, loc);\r\n            }\r\n        }\r\n        return {\r\n            type: 7 /* DIRECTIVE */,\r\n            name: dirName,\r\n            exp: value && {\r\n                type: 4 /* SIMPLE_EXPRESSION */,\r\n                content: value.content,\r\n                isStatic: false,\r\n                // Treat as non-constant by default. This can be potentially set to\r\n                // other values by `transformExpression` to make it eligible for hoisting.\r\n                constType: 0 /* NOT_CONSTANT */,\r\n                loc: value.loc\r\n            },\r\n            arg,\r\n            modifiers,\r\n            loc\r\n        };\r\n    }\r\n    // missing directive name or illegal directive name\r\n    if (!context.inVPre && startsWith(name, 'v-')) {\r\n        emitError(context, 26 /* X_MISSING_DIRECTIVE_NAME */);\r\n    }\r\n    return {\r\n        type: 6 /* ATTRIBUTE */,\r\n        name,\r\n        value: value && {\r\n            type: 2 /* TEXT */,\r\n            content: value.content,\r\n            loc: value.loc\r\n        },\r\n        loc\r\n    };\r\n}\r\nfunction parseAttributeValue(context) {\r\n    const start = getCursor(context);\r\n    let content;\r\n    const quote = context.source[0];\r\n    const isQuoted = quote === `\"` || quote === `'`;\r\n    if (isQuoted) {\r\n        // Quoted value.\r\n        advanceBy(context, 1);\r\n        const endIndex = context.source.indexOf(quote);\r\n        if (endIndex === -1) {\r\n            content = parseTextData(context, context.source.length, 4 /* ATTRIBUTE_VALUE */);\r\n        }\r\n        else {\r\n            content = parseTextData(context, endIndex, 4 /* ATTRIBUTE_VALUE */);\r\n            advanceBy(context, 1);\r\n        }\r\n    }\r\n    else {\r\n        // Unquoted\r\n        const match = /^[^\\t\\r\\n\\f >]+/.exec(context.source);\r\n        if (!match) {\r\n            return undefined;\r\n        }\r\n        const unexpectedChars = /[\"'<=`]/g;\r\n        let m;\r\n        while ((m = unexpectedChars.exec(match[0]))) {\r\n            emitError(context, 18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */, m.index);\r\n        }\r\n        content = parseTextData(context, match[0].length, 4 /* ATTRIBUTE_VALUE */);\r\n    }\r\n    return { content, isQuoted, loc: getSelection(context, start) };\r\n}\r\nfunction parseInterpolation(context, mode) {\r\n    const [open, close] = context.options.delimiters;\r\n    const closeIndex = context.source.indexOf(close, open.length);\r\n    if (closeIndex === -1) {\r\n        emitError(context, 25 /* X_MISSING_INTERPOLATION_END */);\r\n        return undefined;\r\n    }\r\n    const start = getCursor(context);\r\n    advanceBy(context, open.length);\r\n    const innerStart = getCursor(context);\r\n    const innerEnd = getCursor(context);\r\n    const rawContentLength = closeIndex - open.length;\r\n    const rawContent = context.source.slice(0, rawContentLength);\r\n    const preTrimContent = parseTextData(context, rawContentLength, mode);\r\n    const content = preTrimContent.trim();\r\n    const startOffset = preTrimContent.indexOf(content);\r\n    if (startOffset > 0) {\r\n        advancePositionWithMutation(innerStart, rawContent, startOffset);\r\n    }\r\n    const endOffset = rawContentLength - (preTrimContent.length - content.length - startOffset);\r\n    advancePositionWithMutation(innerEnd, rawContent, endOffset);\r\n    advanceBy(context, close.length);\r\n    return {\r\n        type: 5 /* INTERPOLATION */,\r\n        content: {\r\n            type: 4 /* SIMPLE_EXPRESSION */,\r\n            isStatic: false,\r\n            // Set `isConstant` to false by default and will decide in transformExpression\r\n            constType: 0 /* NOT_CONSTANT */,\r\n            content,\r\n            loc: getSelection(context, innerStart, innerEnd)\r\n        },\r\n        loc: getSelection(context, start)\r\n    };\r\n}\r\nfunction parseText(context, mode) {\r\n    const endTokens = mode === 3 /* CDATA */ ? [']]>'] : ['<', context.options.delimiters[0]];\r\n    let endIndex = context.source.length;\r\n    for (let i = 0; i < endTokens.length; i++) {\r\n        const index = context.source.indexOf(endTokens[i], 1);\r\n        if (index !== -1 && endIndex > index) {\r\n            endIndex = index;\r\n        }\r\n    }\r\n    const start = getCursor(context);\r\n    const content = parseTextData(context, endIndex, mode);\r\n    return {\r\n        type: 2 /* TEXT */,\r\n        content,\r\n        loc: getSelection(context, start)\r\n    };\r\n}\r\n/**\r\n * Get text data with a given length from the current location.\r\n * This translates HTML entities in the text data.\r\n */\r\nfunction parseTextData(context, length, mode) {\r\n    const rawText = context.source.slice(0, length);\r\n    advanceBy(context, length);\r\n    if (mode === 2 /* RAWTEXT */ ||\r\n        mode === 3 /* CDATA */ ||\r\n        !rawText.includes('&')) {\r\n        return rawText;\r\n    }\r\n    else {\r\n        // DATA or RCDATA containing \"&\"\". Entity decoding required.\r\n        return context.options.decodeEntities(rawText, mode === 4 /* ATTRIBUTE_VALUE */);\r\n    }\r\n}\r\nfunction getCursor(context) {\r\n    const { column, line, offset } = context;\r\n    return { column, line, offset };\r\n}\r\nfunction getSelection(context, start, end) {\r\n    end = end || getCursor(context);\r\n    return {\r\n        start,\r\n        end,\r\n        source: context.originalSource.slice(start.offset, end.offset)\r\n    };\r\n}\r\nfunction last(xs) {\r\n    return xs[xs.length - 1];\r\n}\r\nfunction startsWith(source, searchString) {\r\n    return source.startsWith(searchString);\r\n}\r\nfunction advanceBy(context, numberOfCharacters) {\r\n    const { source } = context;\r\n    advancePositionWithMutation(context, source, numberOfCharacters);\r\n    context.source = source.slice(numberOfCharacters);\r\n}\r\nfunction advanceSpaces(context) {\r\n    const match = /^[\\t\\r\\n\\f ]+/.exec(context.source);\r\n    if (match) {\r\n        advanceBy(context, match[0].length);\r\n    }\r\n}\r\nfunction getNewPosition(context, start, numberOfCharacters) {\r\n    return advancePositionWithClone(start, context.originalSource.slice(start.offset, numberOfCharacters), numberOfCharacters);\r\n}\r\nfunction emitError(context, code, offset, loc = getCursor(context)) {\r\n    if (offset) {\r\n        loc.offset += offset;\r\n        loc.column += offset;\r\n    }\r\n    context.options.onError(createCompilerError(code, {\r\n        start: loc,\r\n        end: loc,\r\n        source: ''\r\n    }));\r\n}\r\nfunction isEnd(context, mode, ancestors) {\r\n    const s = context.source;\r\n    switch (mode) {\r\n        case 0 /* DATA */:\r\n            if (startsWith(s, '</')) {\r\n                // TODO: probably bad performance\r\n                for (let i = ancestors.length - 1; i >= 0; --i) {\r\n                    if (startsWithEndTagOpen(s, ancestors[i].tag)) {\r\n                        return true;\r\n                    }\r\n                }\r\n            }\r\n            break;\r\n        case 1 /* RCDATA */:\r\n        case 2 /* RAWTEXT */: {\r\n            const parent = last(ancestors);\r\n            if (parent && startsWithEndTagOpen(s, parent.tag)) {\r\n                return true;\r\n            }\r\n            break;\r\n        }\r\n        case 3 /* CDATA */:\r\n            if (startsWith(s, ']]>')) {\r\n                return true;\r\n            }\r\n            break;\r\n    }\r\n    return !s;\r\n}\r\nfunction startsWithEndTagOpen(source, tag) {\r\n    return (startsWith(source, '</') &&\r\n        source.slice(2, 2 + tag.length).toLowerCase() === tag.toLowerCase() &&\r\n        /[\\t\\r\\n\\f />]/.test(source[2 + tag.length] || '>'));\r\n}\n\nfunction hoistStatic(root, context) {\r\n    walk(root, context, \r\n    // Root node is unfortunately non-hoistable due to potential parent\r\n    // fallthrough attributes.\r\n    isSingleElementRoot(root, root.children[0]));\r\n}\r\nfunction isSingleElementRoot(root, child) {\r\n    const { children } = root;\r\n    return (children.length === 1 &&\r\n        child.type === 1 /* ELEMENT */ &&\r\n        !isSlotOutlet(child));\r\n}\r\nfunction walk(node, context, doNotHoistNode = false) {\r\n    const { children } = node;\r\n    const originalCount = children.length;\r\n    let hoistedCount = 0;\r\n    for (let i = 0; i < children.length; i++) {\r\n        const child = children[i];\r\n        // only plain elements & text calls are eligible for hoisting.\r\n        if (child.type === 1 /* ELEMENT */ &&\r\n            child.tagType === 0 /* ELEMENT */) {\r\n            const constantType = doNotHoistNode\r\n                ? 0 /* NOT_CONSTANT */\r\n                : getConstantType(child, context);\r\n            if (constantType > 0 /* NOT_CONSTANT */) {\r\n                if (constantType >= 2 /* CAN_HOIST */) {\r\n                    child.codegenNode.patchFlag =\r\n                        -1 /* HOISTED */ + ((process.env.NODE_ENV !== 'production') ? ` /* HOISTED */` : ``);\r\n                    child.codegenNode = context.hoist(child.codegenNode);\r\n                    hoistedCount++;\r\n                    continue;\r\n                }\r\n            }\r\n            else {\r\n                // node may contain dynamic children, but its props may be eligible for\r\n                // hoisting.\r\n                const codegenNode = child.codegenNode;\r\n                if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n                    const flag = getPatchFlag(codegenNode);\r\n                    if ((!flag ||\r\n                        flag === 512 /* NEED_PATCH */ ||\r\n                        flag === 1 /* TEXT */) &&\r\n                        getGeneratedPropsConstantType(child, context) >=\r\n                            2 /* CAN_HOIST */) {\r\n                        const props = getNodeProps(child);\r\n                        if (props) {\r\n                            codegenNode.props = context.hoist(props);\r\n                        }\r\n                    }\r\n                    if (codegenNode.dynamicProps) {\r\n                        codegenNode.dynamicProps = context.hoist(codegenNode.dynamicProps);\r\n                    }\r\n                }\r\n            }\r\n        }\r\n        else if (child.type === 12 /* TEXT_CALL */ &&\r\n            getConstantType(child.content, context) >= 2 /* CAN_HOIST */) {\r\n            child.codegenNode = context.hoist(child.codegenNode);\r\n            hoistedCount++;\r\n        }\r\n        // walk further\r\n        if (child.type === 1 /* ELEMENT */) {\r\n            const isComponent = child.tagType === 1 /* COMPONENT */;\r\n            if (isComponent) {\r\n                context.scopes.vSlot++;\r\n            }\r\n            walk(child, context);\r\n            if (isComponent) {\r\n                context.scopes.vSlot--;\r\n            }\r\n        }\r\n        else if (child.type === 11 /* FOR */) {\r\n            // Do not hoist v-for single child because it has to be a block\r\n            walk(child, context, child.children.length === 1);\r\n        }\r\n        else if (child.type === 9 /* IF */) {\r\n            for (let i = 0; i < child.branches.length; i++) {\r\n                // Do not hoist v-if single child because it has to be a block\r\n                walk(child.branches[i], context, child.branches[i].children.length === 1);\r\n            }\r\n        }\r\n    }\r\n    if (hoistedCount && context.transformHoist) {\r\n        context.transformHoist(children, context, node);\r\n    }\r\n    // all children were hoisted - the entire children array is hoistable.\r\n    if (hoistedCount &&\r\n        hoistedCount === originalCount &&\r\n        node.type === 1 /* ELEMENT */ &&\r\n        node.tagType === 0 /* ELEMENT */ &&\r\n        node.codegenNode &&\r\n        node.codegenNode.type === 13 /* VNODE_CALL */ &&\r\n        isArray(node.codegenNode.children)) {\r\n        node.codegenNode.children = context.hoist(createArrayExpression(node.codegenNode.children));\r\n    }\r\n}\r\nfunction getConstantType(node, context) {\r\n    const { constantCache } = context;\r\n    switch (node.type) {\r\n        case 1 /* ELEMENT */:\r\n            if (node.tagType !== 0 /* ELEMENT */) {\r\n                return 0 /* NOT_CONSTANT */;\r\n            }\r\n            const cached = constantCache.get(node);\r\n            if (cached !== undefined) {\r\n                return cached;\r\n            }\r\n            const codegenNode = node.codegenNode;\r\n            if (codegenNode.type !== 13 /* VNODE_CALL */) {\r\n                return 0 /* NOT_CONSTANT */;\r\n            }\r\n            if (codegenNode.isBlock &&\r\n                node.tag !== 'svg' &&\r\n                node.tag !== 'foreignObject') {\r\n                return 0 /* NOT_CONSTANT */;\r\n            }\r\n            const flag = getPatchFlag(codegenNode);\r\n            if (!flag) {\r\n                let returnType = 3 /* CAN_STRINGIFY */;\r\n                // Element itself has no patch flag. However we still need to check:\r\n                // 1. Even for a node with no patch flag, it is possible for it to contain\r\n                // non-hoistable expressions that refers to scope variables, e.g. compiler\r\n                // injected keys or cached event handlers. Therefore we need to always\r\n                // check the codegenNode's props to be sure.\r\n                const generatedPropsType = getGeneratedPropsConstantType(node, context);\r\n                if (generatedPropsType === 0 /* NOT_CONSTANT */) {\r\n                    constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n                    return 0 /* NOT_CONSTANT */;\r\n                }\r\n                if (generatedPropsType < returnType) {\r\n                    returnType = generatedPropsType;\r\n                }\r\n                // 2. its children.\r\n                for (let i = 0; i < node.children.length; i++) {\r\n                    const childType = getConstantType(node.children[i], context);\r\n                    if (childType === 0 /* NOT_CONSTANT */) {\r\n                        constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n                        return 0 /* NOT_CONSTANT */;\r\n                    }\r\n                    if (childType < returnType) {\r\n                        returnType = childType;\r\n                    }\r\n                }\r\n                // 3. if the type is not already CAN_SKIP_PATCH which is the lowest non-0\r\n                // type, check if any of the props can cause the type to be lowered\r\n                // we can skip can_patch because it's guaranteed by the absence of a\r\n                // patchFlag.\r\n                if (returnType > 1 /* CAN_SKIP_PATCH */) {\r\n                    for (let i = 0; i < node.props.length; i++) {\r\n                        const p = node.props[i];\r\n                        if (p.type === 7 /* DIRECTIVE */ && p.name === 'bind' && p.exp) {\r\n                            const expType = getConstantType(p.exp, context);\r\n                            if (expType === 0 /* NOT_CONSTANT */) {\r\n                                constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n                                return 0 /* NOT_CONSTANT */;\r\n                            }\r\n                            if (expType < returnType) {\r\n                                returnType = expType;\r\n                            }\r\n                        }\r\n                    }\r\n                }\r\n                // only svg/foreignObject could be block here, however if they are\r\n                // static then they don't need to be blocks since there will be no\r\n                // nested updates.\r\n                if (codegenNode.isBlock) {\r\n                    // except set custom directives.\r\n                    for (let i = 0; i < node.props.length; i++) {\r\n                        const p = node.props[i];\r\n                        if (p.type === 7 /* DIRECTIVE */) {\r\n                            constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n                            return 0 /* NOT_CONSTANT */;\r\n                        }\r\n                    }\r\n                    context.removeHelper(OPEN_BLOCK);\r\n                    context.removeHelper(getVNodeBlockHelper(context.inSSR, codegenNode.isComponent));\r\n                    codegenNode.isBlock = false;\r\n                    context.helper(getVNodeHelper(context.inSSR, codegenNode.isComponent));\r\n                }\r\n                constantCache.set(node, returnType);\r\n                return returnType;\r\n            }\r\n            else {\r\n                constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n                return 0 /* NOT_CONSTANT */;\r\n            }\r\n        case 2 /* TEXT */:\r\n        case 3 /* COMMENT */:\r\n            return 3 /* CAN_STRINGIFY */;\r\n        case 9 /* IF */:\r\n        case 11 /* FOR */:\r\n        case 10 /* IF_BRANCH */:\r\n            return 0 /* NOT_CONSTANT */;\r\n        case 5 /* INTERPOLATION */:\r\n        case 12 /* TEXT_CALL */:\r\n            return getConstantType(node.content, context);\r\n        case 4 /* SIMPLE_EXPRESSION */:\r\n            return node.constType;\r\n        case 8 /* COMPOUND_EXPRESSION */:\r\n            let returnType = 3 /* CAN_STRINGIFY */;\r\n            for (let i = 0; i < node.children.length; i++) {\r\n                const child = node.children[i];\r\n                if (isString(child) || isSymbol(child)) {\r\n                    continue;\r\n                }\r\n                const childType = getConstantType(child, context);\r\n                if (childType === 0 /* NOT_CONSTANT */) {\r\n                    return 0 /* NOT_CONSTANT */;\r\n                }\r\n                else if (childType < returnType) {\r\n                    returnType = childType;\r\n                }\r\n            }\r\n            return returnType;\r\n        default:\r\n            if ((process.env.NODE_ENV !== 'production')) ;\r\n            return 0 /* NOT_CONSTANT */;\r\n    }\r\n}\r\nconst allowHoistedHelperSet = new Set([\r\n    NORMALIZE_CLASS,\r\n    NORMALIZE_STYLE,\r\n    NORMALIZE_PROPS,\r\n    GUARD_REACTIVE_PROPS\r\n]);\r\nfunction getConstantTypeOfHelperCall(value, context) {\r\n    if (value.type === 14 /* JS_CALL_EXPRESSION */ &&\r\n        !isString(value.callee) &&\r\n        allowHoistedHelperSet.has(value.callee)) {\r\n        const arg = value.arguments[0];\r\n        if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n            return getConstantType(arg, context);\r\n        }\r\n        else if (arg.type === 14 /* JS_CALL_EXPRESSION */) {\r\n            // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(exp))`\r\n            return getConstantTypeOfHelperCall(arg, context);\r\n        }\r\n    }\r\n    return 0 /* NOT_CONSTANT */;\r\n}\r\nfunction getGeneratedPropsConstantType(node, context) {\r\n    let returnType = 3 /* CAN_STRINGIFY */;\r\n    const props = getNodeProps(node);\r\n    if (props && props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n        const { properties } = props;\r\n        for (let i = 0; i < properties.length; i++) {\r\n            const { key, value } = properties[i];\r\n            const keyType = getConstantType(key, context);\r\n            if (keyType === 0 /* NOT_CONSTANT */) {\r\n                return keyType;\r\n            }\r\n            if (keyType < returnType) {\r\n                returnType = keyType;\r\n            }\r\n            let valueType;\r\n            if (value.type === 4 /* SIMPLE_EXPRESSION */) {\r\n                valueType = getConstantType(value, context);\r\n            }\r\n            else if (value.type === 14 /* JS_CALL_EXPRESSION */) {\r\n                // some helper calls can be hoisted,\r\n                // such as the `normalizeProps` generated by the compiler for pre-normalize class,\r\n                // in this case we need to respect the ConstantType of the helper's arguments\r\n                valueType = getConstantTypeOfHelperCall(value, context);\r\n            }\r\n            else {\r\n                valueType = 0 /* NOT_CONSTANT */;\r\n            }\r\n            if (valueType === 0 /* NOT_CONSTANT */) {\r\n                return valueType;\r\n            }\r\n            if (valueType < returnType) {\r\n                returnType = valueType;\r\n            }\r\n        }\r\n    }\r\n    return returnType;\r\n}\r\nfunction getNodeProps(node) {\r\n    const codegenNode = node.codegenNode;\r\n    if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n        return codegenNode.props;\r\n    }\r\n}\r\nfunction getPatchFlag(node) {\r\n    const flag = node.patchFlag;\r\n    return flag ? parseInt(flag, 10) : undefined;\r\n}\n\nfunction createTransformContext(root, { filename = '', prefixIdentifiers = false, hoistStatic = false, cacheHandlers = false, nodeTransforms = [], directiveTransforms = {}, transformHoist = null, isBuiltInComponent = NOOP, isCustomElement = NOOP, expressionPlugins = [], scopeId = null, slotted = true, ssr = false, inSSR = false, ssrCssVars = ``, bindingMetadata = EMPTY_OBJ, inline = false, isTS = false, onError = defaultOnError, onWarn = defaultOnWarn, compatConfig }) {\r\n    const nameMatch = filename.replace(/\\?.*$/, '').match(/([^/\\\\]+)\\.\\w+$/);\r\n    const context = {\r\n        // options\r\n        selfName: nameMatch && capitalize(camelize$1(nameMatch[1])),\r\n        prefixIdentifiers,\r\n        hoistStatic,\r\n        cacheHandlers,\r\n        nodeTransforms,\r\n        directiveTransforms,\r\n        transformHoist,\r\n        isBuiltInComponent,\r\n        isCustomElement,\r\n        expressionPlugins,\r\n        scopeId,\r\n        slotted,\r\n        ssr,\r\n        inSSR,\r\n        ssrCssVars,\r\n        bindingMetadata,\r\n        inline,\r\n        isTS,\r\n        onError,\r\n        onWarn,\r\n        compatConfig,\r\n        // state\r\n        root,\r\n        helpers: new Map(),\r\n        components: new Set(),\r\n        directives: new Set(),\r\n        hoists: [],\r\n        imports: [],\r\n        constantCache: new Map(),\r\n        temps: 0,\r\n        cached: 0,\r\n        identifiers: Object.create(null),\r\n        scopes: {\r\n            vFor: 0,\r\n            vSlot: 0,\r\n            vPre: 0,\r\n            vOnce: 0\r\n        },\r\n        parent: null,\r\n        currentNode: root,\r\n        childIndex: 0,\r\n        inVOnce: false,\r\n        // methods\r\n        helper(name) {\r\n            const count = context.helpers.get(name) || 0;\r\n            context.helpers.set(name, count + 1);\r\n            return name;\r\n        },\r\n        removeHelper(name) {\r\n            const count = context.helpers.get(name);\r\n            if (count) {\r\n                const currentCount = count - 1;\r\n                if (!currentCount) {\r\n                    context.helpers.delete(name);\r\n                }\r\n                else {\r\n                    context.helpers.set(name, currentCount);\r\n                }\r\n            }\r\n        },\r\n        helperString(name) {\r\n            return `_${helperNameMap[context.helper(name)]}`;\r\n        },\r\n        replaceNode(node) {\r\n            /* istanbul ignore if */\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                if (!context.currentNode) {\r\n                    throw new Error(`Node being replaced is already removed.`);\r\n                }\r\n                if (!context.parent) {\r\n                    throw new Error(`Cannot replace root node.`);\r\n                }\r\n            }\r\n            context.parent.children[context.childIndex] = context.currentNode = node;\r\n        },\r\n        removeNode(node) {\r\n            if ((process.env.NODE_ENV !== 'production') && !context.parent) {\r\n                throw new Error(`Cannot remove root node.`);\r\n            }\r\n            const list = context.parent.children;\r\n            const removalIndex = node\r\n                ? list.indexOf(node)\r\n                : context.currentNode\r\n                    ? context.childIndex\r\n                    : -1;\r\n            /* istanbul ignore if */\r\n            if ((process.env.NODE_ENV !== 'production') && removalIndex < 0) {\r\n                throw new Error(`node being removed is not a child of current parent`);\r\n            }\r\n            if (!node || node === context.currentNode) {\r\n                // current node removed\r\n                context.currentNode = null;\r\n                context.onNodeRemoved();\r\n            }\r\n            else {\r\n                // sibling node removed\r\n                if (context.childIndex > removalIndex) {\r\n                    context.childIndex--;\r\n                    context.onNodeRemoved();\r\n                }\r\n            }\r\n            context.parent.children.splice(removalIndex, 1);\r\n        },\r\n        onNodeRemoved: () => { },\r\n        addIdentifiers(exp) {\r\n        },\r\n        removeIdentifiers(exp) {\r\n        },\r\n        hoist(exp) {\r\n            if (isString(exp))\r\n                exp = createSimpleExpression(exp);\r\n            context.hoists.push(exp);\r\n            const identifier = createSimpleExpression(`_hoisted_${context.hoists.length}`, false, exp.loc, 2 /* CAN_HOIST */);\r\n            identifier.hoisted = exp;\r\n            return identifier;\r\n        },\r\n        cache(exp, isVNode = false) {\r\n            return createCacheExpression(context.cached++, exp, isVNode);\r\n        }\r\n    };\r\n    {\r\n        context.filters = new Set();\r\n    }\r\n    return context;\r\n}\r\nfunction transform(root, options) {\r\n    const context = createTransformContext(root, options);\r\n    traverseNode(root, context);\r\n    if (options.hoistStatic) {\r\n        hoistStatic(root, context);\r\n    }\r\n    if (!options.ssr) {\r\n        createRootCodegen(root, context);\r\n    }\r\n    // finalize meta information\r\n    root.helpers = [...context.helpers.keys()];\r\n    root.components = [...context.components];\r\n    root.directives = [...context.directives];\r\n    root.imports = context.imports;\r\n    root.hoists = context.hoists;\r\n    root.temps = context.temps;\r\n    root.cached = context.cached;\r\n    {\r\n        root.filters = [...context.filters];\r\n    }\r\n}\r\nfunction createRootCodegen(root, context) {\r\n    const { helper } = context;\r\n    const { children } = root;\r\n    if (children.length === 1) {\r\n        const child = children[0];\r\n        // if the single child is an element, turn it into a block.\r\n        if (isSingleElementRoot(root, child) && child.codegenNode) {\r\n            // single element root is never hoisted so codegenNode will never be\r\n            // SimpleExpressionNode\r\n            const codegenNode = child.codegenNode;\r\n            if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n                makeBlock(codegenNode, context);\r\n            }\r\n            root.codegenNode = codegenNode;\r\n        }\r\n        else {\r\n            // - single <slot/>, IfNode, ForNode: already blocks.\r\n            // - single text node: always patched.\r\n            // root codegen falls through via genNode()\r\n            root.codegenNode = child;\r\n        }\r\n    }\r\n    else if (children.length > 1) {\r\n        // root has multiple nodes - return a fragment block.\r\n        let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n        let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n        // check if the fragment actually contains a single valid child with\r\n        // the rest being comments\r\n        if ((process.env.NODE_ENV !== 'production') &&\r\n            children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n            patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n            patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n        }\r\n        root.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, root.children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n    }\r\n    else ;\r\n}\r\nfunction traverseChildren(parent, context) {\r\n    let i = 0;\r\n    const nodeRemoved = () => {\r\n        i--;\r\n    };\r\n    for (; i < parent.children.length; i++) {\r\n        const child = parent.children[i];\r\n        if (isString(child))\r\n            continue;\r\n        context.parent = parent;\r\n        context.childIndex = i;\r\n        context.onNodeRemoved = nodeRemoved;\r\n        traverseNode(child, context);\r\n    }\r\n}\r\nfunction traverseNode(node, context) {\r\n    context.currentNode = node;\r\n    // apply transform plugins\r\n    const { nodeTransforms } = context;\r\n    const exitFns = [];\r\n    for (let i = 0; i < nodeTransforms.length; i++) {\r\n        const onExit = nodeTransforms[i](node, context);\r\n        if (onExit) {\r\n            if (isArray(onExit)) {\r\n                exitFns.push(...onExit);\r\n            }\r\n            else {\r\n                exitFns.push(onExit);\r\n            }\r\n        }\r\n        if (!context.currentNode) {\r\n            // node was removed\r\n            return;\r\n        }\r\n        else {\r\n            // node may have been replaced\r\n            node = context.currentNode;\r\n        }\r\n    }\r\n    switch (node.type) {\r\n        case 3 /* COMMENT */:\r\n            if (!context.ssr) {\r\n                // inject import for the Comment symbol, which is needed for creating\r\n                // comment nodes with `createVNode`\r\n                context.helper(CREATE_COMMENT);\r\n            }\r\n            break;\r\n        case 5 /* INTERPOLATION */:\r\n            // no need to traverse, but we need to inject toString helper\r\n            if (!context.ssr) {\r\n                context.helper(TO_DISPLAY_STRING);\r\n            }\r\n            break;\r\n        // for container types, further traverse downwards\r\n        case 9 /* IF */:\r\n            for (let i = 0; i < node.branches.length; i++) {\r\n                traverseNode(node.branches[i], context);\r\n            }\r\n            break;\r\n        case 10 /* IF_BRANCH */:\r\n        case 11 /* FOR */:\r\n        case 1 /* ELEMENT */:\r\n        case 0 /* ROOT */:\r\n            traverseChildren(node, context);\r\n            break;\r\n    }\r\n    // exit transforms\r\n    context.currentNode = node;\r\n    let i = exitFns.length;\r\n    while (i--) {\r\n        exitFns[i]();\r\n    }\r\n}\r\nfunction createStructuralDirectiveTransform(name, fn) {\r\n    const matches = isString(name)\r\n        ? (n) => n === name\r\n        : (n) => name.test(n);\r\n    return (node, context) => {\r\n        if (node.type === 1 /* ELEMENT */) {\r\n            const { props } = node;\r\n            // structural directive transforms are not concerned with slots\r\n            // as they are handled separately in vSlot.ts\r\n            if (node.tagType === 3 /* TEMPLATE */ && props.some(isVSlot)) {\r\n                return;\r\n            }\r\n            const exitFns = [];\r\n            for (let i = 0; i < props.length; i++) {\r\n                const prop = props[i];\r\n                if (prop.type === 7 /* DIRECTIVE */ && matches(prop.name)) {\r\n                    // structural directives are removed to avoid infinite recursion\r\n                    // also we remove them *before* applying so that it can further\r\n                    // traverse itself in case it moves the node around\r\n                    props.splice(i, 1);\r\n                    i--;\r\n                    const onExit = fn(node, prop, context);\r\n                    if (onExit)\r\n                        exitFns.push(onExit);\r\n                }\r\n            }\r\n            return exitFns;\r\n        }\r\n    };\r\n}\n\nconst PURE_ANNOTATION = `/*#__PURE__*/`;\r\nconst aliasHelper = (s) => `${helperNameMap[s]}: _${helperNameMap[s]}`;\r\nfunction createCodegenContext(ast, { mode = 'function', prefixIdentifiers = mode === 'module', sourceMap = false, filename = `template.vue.html`, scopeId = null, optimizeImports = false, runtimeGlobalName = `Vue`, runtimeModuleName = `vue`, ssrRuntimeModuleName = 'vue/server-renderer', ssr = false, isTS = false, inSSR = false }) {\r\n    const context = {\r\n        mode,\r\n        prefixIdentifiers,\r\n        sourceMap,\r\n        filename,\r\n        scopeId,\r\n        optimizeImports,\r\n        runtimeGlobalName,\r\n        runtimeModuleName,\r\n        ssrRuntimeModuleName,\r\n        ssr,\r\n        isTS,\r\n        inSSR,\r\n        source: ast.loc.source,\r\n        code: ``,\r\n        column: 1,\r\n        line: 1,\r\n        offset: 0,\r\n        indentLevel: 0,\r\n        pure: false,\r\n        map: undefined,\r\n        helper(key) {\r\n            return `_${helperNameMap[key]}`;\r\n        },\r\n        push(code, node) {\r\n            context.code += code;\r\n        },\r\n        indent() {\r\n            newline(++context.indentLevel);\r\n        },\r\n        deindent(withoutNewLine = false) {\r\n            if (withoutNewLine) {\r\n                --context.indentLevel;\r\n            }\r\n            else {\r\n                newline(--context.indentLevel);\r\n            }\r\n        },\r\n        newline() {\r\n            newline(context.indentLevel);\r\n        }\r\n    };\r\n    function newline(n) {\r\n        context.push('\\n' + `  `.repeat(n));\r\n    }\r\n    return context;\r\n}\r\nfunction generate(ast, options = {}) {\r\n    const context = createCodegenContext(ast, options);\r\n    if (options.onContextCreated)\r\n        options.onContextCreated(context);\r\n    const { mode, push, prefixIdentifiers, indent, deindent, newline, scopeId, ssr } = context;\r\n    const hasHelpers = ast.helpers.length > 0;\r\n    const useWithBlock = !prefixIdentifiers && mode !== 'module';\r\n    // preambles\r\n    // in setup() inline mode, the preamble is generated in a sub context\r\n    // and returned separately.\r\n    const preambleContext = context;\r\n    {\r\n        genFunctionPreamble(ast, preambleContext);\r\n    }\r\n    // enter render function\r\n    const functionName = ssr ? `ssrRender` : `render`;\r\n    const args = ssr ? ['_ctx', '_push', '_parent', '_attrs'] : ['_ctx', '_cache'];\r\n    const signature = args.join(', ');\r\n    {\r\n        push(`function ${functionName}(${signature}) {`);\r\n    }\r\n    indent();\r\n    if (useWithBlock) {\r\n        push(`with (_ctx) {`);\r\n        indent();\r\n        // function mode const declarations should be inside with block\r\n        // also they should be renamed to avoid collision with user properties\r\n        if (hasHelpers) {\r\n            push(`const { ${ast.helpers.map(aliasHelper).join(', ')} } = _Vue`);\r\n            push(`\\n`);\r\n            newline();\r\n        }\r\n    }\r\n    // generate asset resolution statements\r\n    if (ast.components.length) {\r\n        genAssets(ast.components, 'component', context);\r\n        if (ast.directives.length || ast.temps > 0) {\r\n            newline();\r\n        }\r\n    }\r\n    if (ast.directives.length) {\r\n        genAssets(ast.directives, 'directive', context);\r\n        if (ast.temps > 0) {\r\n            newline();\r\n        }\r\n    }\r\n    if (ast.filters && ast.filters.length) {\r\n        newline();\r\n        genAssets(ast.filters, 'filter', context);\r\n        newline();\r\n    }\r\n    if (ast.temps > 0) {\r\n        push(`let `);\r\n        for (let i = 0; i < ast.temps; i++) {\r\n            push(`${i > 0 ? `, ` : ``}_temp${i}`);\r\n        }\r\n    }\r\n    if (ast.components.length || ast.directives.length || ast.temps) {\r\n        push(`\\n`);\r\n        newline();\r\n    }\r\n    // generate the VNode tree expression\r\n    if (!ssr) {\r\n        push(`return `);\r\n    }\r\n    if (ast.codegenNode) {\r\n        genNode(ast.codegenNode, context);\r\n    }\r\n    else {\r\n        push(`null`);\r\n    }\r\n    if (useWithBlock) {\r\n        deindent();\r\n        push(`}`);\r\n    }\r\n    deindent();\r\n    push(`}`);\r\n    return {\r\n        ast,\r\n        code: context.code,\r\n        preamble: ``,\r\n        // SourceMapGenerator does have toJSON() method but it's not in the types\r\n        map: context.map ? context.map.toJSON() : undefined\r\n    };\r\n}\r\nfunction genFunctionPreamble(ast, context) {\r\n    const { ssr, prefixIdentifiers, push, newline, runtimeModuleName, runtimeGlobalName, ssrRuntimeModuleName } = context;\r\n    const VueBinding = runtimeGlobalName;\r\n    // Generate const declaration for helpers\r\n    // In prefix mode, we place the const declaration at top so it's done\r\n    // only once; But if we not prefixing, we place the declaration inside the\r\n    // with block so it doesn't incur the `in` check cost for every helper access.\r\n    if (ast.helpers.length > 0) {\r\n        {\r\n            // \"with\" mode.\r\n            // save Vue in a separate variable to avoid collision\r\n            push(`const _Vue = ${VueBinding}\\n`);\r\n            // in \"with\" mode, helpers are declared inside the with block to avoid\r\n            // has check cost, but hoists are lifted out of the function - we need\r\n            // to provide the helper here.\r\n            if (ast.hoists.length) {\r\n                const staticHelpers = [\r\n                    CREATE_VNODE,\r\n                    CREATE_ELEMENT_VNODE,\r\n                    CREATE_COMMENT,\r\n                    CREATE_TEXT,\r\n                    CREATE_STATIC\r\n                ]\r\n                    .filter(helper => ast.helpers.includes(helper))\r\n                    .map(aliasHelper)\r\n                    .join(', ');\r\n                push(`const { ${staticHelpers} } = _Vue\\n`);\r\n            }\r\n        }\r\n    }\r\n    genHoists(ast.hoists, context);\r\n    newline();\r\n    push(`return `);\r\n}\r\nfunction genAssets(assets, type, { helper, push, newline, isTS }) {\r\n    const resolver = helper(type === 'filter'\r\n        ? RESOLVE_FILTER\r\n        : type === 'component'\r\n            ? RESOLVE_COMPONENT\r\n            : RESOLVE_DIRECTIVE);\r\n    for (let i = 0; i < assets.length; i++) {\r\n        let id = assets[i];\r\n        // potential component implicit self-reference inferred from SFC filename\r\n        const maybeSelfReference = id.endsWith('__self');\r\n        if (maybeSelfReference) {\r\n            id = id.slice(0, -6);\r\n        }\r\n        push(`const ${toValidAssetId(id, type)} = ${resolver}(${JSON.stringify(id)}${maybeSelfReference ? `, true` : ``})${isTS ? `!` : ``}`);\r\n        if (i < assets.length - 1) {\r\n            newline();\r\n        }\r\n    }\r\n}\r\nfunction genHoists(hoists, context) {\r\n    if (!hoists.length) {\r\n        return;\r\n    }\r\n    context.pure = true;\r\n    const { push, newline, helper, scopeId, mode } = context;\r\n    newline();\r\n    for (let i = 0; i < hoists.length; i++) {\r\n        const exp = hoists[i];\r\n        if (exp) {\r\n            push(`const _hoisted_${i + 1} = ${``}`);\r\n            genNode(exp, context);\r\n            newline();\r\n        }\r\n    }\r\n    context.pure = false;\r\n}\r\nfunction isText$1(n) {\r\n    return (isString(n) ||\r\n        n.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n        n.type === 2 /* TEXT */ ||\r\n        n.type === 5 /* INTERPOLATION */ ||\r\n        n.type === 8 /* COMPOUND_EXPRESSION */);\r\n}\r\nfunction genNodeListAsArray(nodes, context) {\r\n    const multilines = nodes.length > 3 ||\r\n        (((process.env.NODE_ENV !== 'production')) && nodes.some(n => isArray(n) || !isText$1(n)));\r\n    context.push(`[`);\r\n    multilines && context.indent();\r\n    genNodeList(nodes, context, multilines);\r\n    multilines && context.deindent();\r\n    context.push(`]`);\r\n}\r\nfunction genNodeList(nodes, context, multilines = false, comma = true) {\r\n    const { push, newline } = context;\r\n    for (let i = 0; i < nodes.length; i++) {\r\n        const node = nodes[i];\r\n        if (isString(node)) {\r\n            push(node);\r\n        }\r\n        else if (isArray(node)) {\r\n            genNodeListAsArray(node, context);\r\n        }\r\n        else {\r\n            genNode(node, context);\r\n        }\r\n        if (i < nodes.length - 1) {\r\n            if (multilines) {\r\n                comma && push(',');\r\n                newline();\r\n            }\r\n            else {\r\n                comma && push(', ');\r\n            }\r\n        }\r\n    }\r\n}\r\nfunction genNode(node, context) {\r\n    if (isString(node)) {\r\n        context.push(node);\r\n        return;\r\n    }\r\n    if (isSymbol(node)) {\r\n        context.push(context.helper(node));\r\n        return;\r\n    }\r\n    switch (node.type) {\r\n        case 1 /* ELEMENT */:\r\n        case 9 /* IF */:\r\n        case 11 /* FOR */:\r\n            (process.env.NODE_ENV !== 'production') &&\r\n                assert(node.codegenNode != null, `Codegen node is missing for element/if/for node. ` +\r\n                    `Apply appropriate transforms first.`);\r\n            genNode(node.codegenNode, context);\r\n            break;\r\n        case 2 /* TEXT */:\r\n            genText(node, context);\r\n            break;\r\n        case 4 /* SIMPLE_EXPRESSION */:\r\n            genExpression(node, context);\r\n            break;\r\n        case 5 /* INTERPOLATION */:\r\n            genInterpolation(node, context);\r\n            break;\r\n        case 12 /* TEXT_CALL */:\r\n            genNode(node.codegenNode, context);\r\n            break;\r\n        case 8 /* COMPOUND_EXPRESSION */:\r\n            genCompoundExpression(node, context);\r\n            break;\r\n        case 3 /* COMMENT */:\r\n            genComment(node, context);\r\n            break;\r\n        case 13 /* VNODE_CALL */:\r\n            genVNodeCall(node, context);\r\n            break;\r\n        case 14 /* JS_CALL_EXPRESSION */:\r\n            genCallExpression(node, context);\r\n            break;\r\n        case 15 /* JS_OBJECT_EXPRESSION */:\r\n            genObjectExpression(node, context);\r\n            break;\r\n        case 17 /* JS_ARRAY_EXPRESSION */:\r\n            genArrayExpression(node, context);\r\n            break;\r\n        case 18 /* JS_FUNCTION_EXPRESSION */:\r\n            genFunctionExpression(node, context);\r\n            break;\r\n        case 19 /* JS_CONDITIONAL_EXPRESSION */:\r\n            genConditionalExpression(node, context);\r\n            break;\r\n        case 20 /* JS_CACHE_EXPRESSION */:\r\n            genCacheExpression(node, context);\r\n            break;\r\n        case 21 /* JS_BLOCK_STATEMENT */:\r\n            genNodeList(node.body, context, true, false);\r\n            break;\r\n        // SSR only types\r\n        case 22 /* JS_TEMPLATE_LITERAL */:\r\n            break;\r\n        case 23 /* JS_IF_STATEMENT */:\r\n            break;\r\n        case 24 /* JS_ASSIGNMENT_EXPRESSION */:\r\n            break;\r\n        case 25 /* JS_SEQUENCE_EXPRESSION */:\r\n            break;\r\n        case 26 /* JS_RETURN_STATEMENT */:\r\n            break;\r\n        /* istanbul ignore next */\r\n        case 10 /* IF_BRANCH */:\r\n            // noop\r\n            break;\r\n        default:\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                assert(false, `unhandled codegen node type: ${node.type}`);\r\n                // make sure we exhaust all possible types\r\n                const exhaustiveCheck = node;\r\n                return exhaustiveCheck;\r\n            }\r\n    }\r\n}\r\nfunction genText(node, context) {\r\n    context.push(JSON.stringify(node.content), node);\r\n}\r\nfunction genExpression(node, context) {\r\n    const { content, isStatic } = node;\r\n    context.push(isStatic ? JSON.stringify(content) : content, node);\r\n}\r\nfunction genInterpolation(node, context) {\r\n    const { push, helper, pure } = context;\r\n    if (pure)\r\n        push(PURE_ANNOTATION);\r\n    push(`${helper(TO_DISPLAY_STRING)}(`);\r\n    genNode(node.content, context);\r\n    push(`)`);\r\n}\r\nfunction genCompoundExpression(node, context) {\r\n    for (let i = 0; i < node.children.length; i++) {\r\n        const child = node.children[i];\r\n        if (isString(child)) {\r\n            context.push(child);\r\n        }\r\n        else {\r\n            genNode(child, context);\r\n        }\r\n    }\r\n}\r\nfunction genExpressionAsPropertyKey(node, context) {\r\n    const { push } = context;\r\n    if (node.type === 8 /* COMPOUND_EXPRESSION */) {\r\n        push(`[`);\r\n        genCompoundExpression(node, context);\r\n        push(`]`);\r\n    }\r\n    else if (node.isStatic) {\r\n        // only quote keys if necessary\r\n        const text = isSimpleIdentifier(node.content)\r\n            ? node.content\r\n            : JSON.stringify(node.content);\r\n        push(text, node);\r\n    }\r\n    else {\r\n        push(`[${node.content}]`, node);\r\n    }\r\n}\r\nfunction genComment(node, context) {\r\n    const { push, helper, pure } = context;\r\n    if (pure) {\r\n        push(PURE_ANNOTATION);\r\n    }\r\n    push(`${helper(CREATE_COMMENT)}(${JSON.stringify(node.content)})`, node);\r\n}\r\nfunction genVNodeCall(node, context) {\r\n    const { push, helper, pure } = context;\r\n    const { tag, props, children, patchFlag, dynamicProps, directives, isBlock, disableTracking, isComponent } = node;\r\n    if (directives) {\r\n        push(helper(WITH_DIRECTIVES) + `(`);\r\n    }\r\n    if (isBlock) {\r\n        push(`(${helper(OPEN_BLOCK)}(${disableTracking ? `true` : ``}), `);\r\n    }\r\n    if (pure) {\r\n        push(PURE_ANNOTATION);\r\n    }\r\n    const callHelper = isBlock\r\n        ? getVNodeBlockHelper(context.inSSR, isComponent)\r\n        : getVNodeHelper(context.inSSR, isComponent);\r\n    push(helper(callHelper) + `(`, node);\r\n    genNodeList(genNullableArgs([tag, props, children, patchFlag, dynamicProps]), context);\r\n    push(`)`);\r\n    if (isBlock) {\r\n        push(`)`);\r\n    }\r\n    if (directives) {\r\n        push(`, `);\r\n        genNode(directives, context);\r\n        push(`)`);\r\n    }\r\n}\r\nfunction genNullableArgs(args) {\r\n    let i = args.length;\r\n    while (i--) {\r\n        if (args[i] != null)\r\n            break;\r\n    }\r\n    return args.slice(0, i + 1).map(arg => arg || `null`);\r\n}\r\n// JavaScript\r\nfunction genCallExpression(node, context) {\r\n    const { push, helper, pure } = context;\r\n    const callee = isString(node.callee) ? node.callee : helper(node.callee);\r\n    if (pure) {\r\n        push(PURE_ANNOTATION);\r\n    }\r\n    push(callee + `(`, node);\r\n    genNodeList(node.arguments, context);\r\n    push(`)`);\r\n}\r\nfunction genObjectExpression(node, context) {\r\n    const { push, indent, deindent, newline } = context;\r\n    const { properties } = node;\r\n    if (!properties.length) {\r\n        push(`{}`, node);\r\n        return;\r\n    }\r\n    const multilines = properties.length > 1 ||\r\n        (((process.env.NODE_ENV !== 'production')) &&\r\n            properties.some(p => p.value.type !== 4 /* SIMPLE_EXPRESSION */));\r\n    push(multilines ? `{` : `{ `);\r\n    multilines && indent();\r\n    for (let i = 0; i < properties.length; i++) {\r\n        const { key, value } = properties[i];\r\n        // key\r\n        genExpressionAsPropertyKey(key, context);\r\n        push(`: `);\r\n        // value\r\n        genNode(value, context);\r\n        if (i < properties.length - 1) {\r\n            // will only reach this if it's multilines\r\n            push(`,`);\r\n            newline();\r\n        }\r\n    }\r\n    multilines && deindent();\r\n    push(multilines ? `}` : ` }`);\r\n}\r\nfunction genArrayExpression(node, context) {\r\n    genNodeListAsArray(node.elements, context);\r\n}\r\nfunction genFunctionExpression(node, context) {\r\n    const { push, indent, deindent } = context;\r\n    const { params, returns, body, newline, isSlot } = node;\r\n    if (isSlot) {\r\n        // wrap slot functions with owner context\r\n        push(`_${helperNameMap[WITH_CTX]}(`);\r\n    }\r\n    push(`(`, node);\r\n    if (isArray(params)) {\r\n        genNodeList(params, context);\r\n    }\r\n    else if (params) {\r\n        genNode(params, context);\r\n    }\r\n    push(`) => `);\r\n    if (newline || body) {\r\n        push(`{`);\r\n        indent();\r\n    }\r\n    if (returns) {\r\n        if (newline) {\r\n            push(`return `);\r\n        }\r\n        if (isArray(returns)) {\r\n            genNodeListAsArray(returns, context);\r\n        }\r\n        else {\r\n            genNode(returns, context);\r\n        }\r\n    }\r\n    else if (body) {\r\n        genNode(body, context);\r\n    }\r\n    if (newline || body) {\r\n        deindent();\r\n        push(`}`);\r\n    }\r\n    if (isSlot) {\r\n        if (node.isNonScopedSlot) {\r\n            push(`, undefined, true`);\r\n        }\r\n        push(`)`);\r\n    }\r\n}\r\nfunction genConditionalExpression(node, context) {\r\n    const { test, consequent, alternate, newline: needNewline } = node;\r\n    const { push, indent, deindent, newline } = context;\r\n    if (test.type === 4 /* SIMPLE_EXPRESSION */) {\r\n        const needsParens = !isSimpleIdentifier(test.content);\r\n        needsParens && push(`(`);\r\n        genExpression(test, context);\r\n        needsParens && push(`)`);\r\n    }\r\n    else {\r\n        push(`(`);\r\n        genNode(test, context);\r\n        push(`)`);\r\n    }\r\n    needNewline && indent();\r\n    context.indentLevel++;\r\n    needNewline || push(` `);\r\n    push(`? `);\r\n    genNode(consequent, context);\r\n    context.indentLevel--;\r\n    needNewline && newline();\r\n    needNewline || push(` `);\r\n    push(`: `);\r\n    const isNested = alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */;\r\n    if (!isNested) {\r\n        context.indentLevel++;\r\n    }\r\n    genNode(alternate, context);\r\n    if (!isNested) {\r\n        context.indentLevel--;\r\n    }\r\n    needNewline && deindent(true /* without newline */);\r\n}\r\nfunction genCacheExpression(node, context) {\r\n    const { push, helper, indent, deindent, newline } = context;\r\n    push(`_cache[${node.index}] || (`);\r\n    if (node.isVNode) {\r\n        indent();\r\n        push(`${helper(SET_BLOCK_TRACKING)}(-1),`);\r\n        newline();\r\n    }\r\n    push(`_cache[${node.index}] = `);\r\n    genNode(node.value, context);\r\n    if (node.isVNode) {\r\n        push(`,`);\r\n        newline();\r\n        push(`${helper(SET_BLOCK_TRACKING)}(1),`);\r\n        newline();\r\n        push(`_cache[${node.index}]`);\r\n        deindent();\r\n    }\r\n    push(`)`);\r\n}\n\nfunction walkIdentifiers(root, onIdentifier, includeAll = false, parentStack = [], knownIds = Object.create(null)) {\r\n    {\r\n        return;\r\n    }\r\n}\r\nfunction isReferencedIdentifier(id, parent, parentStack) {\r\n    {\r\n        return false;\r\n    }\r\n}\r\nfunction isInDestructureAssignment(parent, parentStack) {\r\n    if (parent &&\r\n        (parent.type === 'ObjectProperty' || parent.type === 'ArrayPattern')) {\r\n        let i = parentStack.length;\r\n        while (i--) {\r\n            const p = parentStack[i];\r\n            if (p.type === 'AssignmentExpression') {\r\n                return true;\r\n            }\r\n            else if (p.type !== 'ObjectProperty' && !p.type.endsWith('Pattern')) {\r\n                break;\r\n            }\r\n        }\r\n    }\r\n    return false;\r\n}\r\nfunction walkFunctionParams(node, onIdent) {\r\n    for (const p of node.params) {\r\n        for (const id of extractIdentifiers(p)) {\r\n            onIdent(id);\r\n        }\r\n    }\r\n}\r\nfunction walkBlockDeclarations(block, onIdent) {\r\n    for (const stmt of block.body) {\r\n        if (stmt.type === 'VariableDeclaration') {\r\n            if (stmt.declare)\r\n                continue;\r\n            for (const decl of stmt.declarations) {\r\n                for (const id of extractIdentifiers(decl.id)) {\r\n                    onIdent(id);\r\n                }\r\n            }\r\n        }\r\n        else if (stmt.type === 'FunctionDeclaration' ||\r\n            stmt.type === 'ClassDeclaration') {\r\n            if (stmt.declare || !stmt.id)\r\n                continue;\r\n            onIdent(stmt.id);\r\n        }\r\n    }\r\n}\r\nfunction extractIdentifiers(param, nodes = []) {\r\n    switch (param.type) {\r\n        case 'Identifier':\r\n            nodes.push(param);\r\n            break;\r\n        case 'MemberExpression':\r\n            let object = param;\r\n            while (object.type === 'MemberExpression') {\r\n                object = object.object;\r\n            }\r\n            nodes.push(object);\r\n            break;\r\n        case 'ObjectPattern':\r\n            for (const prop of param.properties) {\r\n                if (prop.type === 'RestElement') {\r\n                    extractIdentifiers(prop.argument, nodes);\r\n                }\r\n                else {\r\n                    extractIdentifiers(prop.value, nodes);\r\n                }\r\n            }\r\n            break;\r\n        case 'ArrayPattern':\r\n            param.elements.forEach(element => {\r\n                if (element)\r\n                    extractIdentifiers(element, nodes);\r\n            });\r\n            break;\r\n        case 'RestElement':\r\n            extractIdentifiers(param.argument, nodes);\r\n            break;\r\n        case 'AssignmentPattern':\r\n            extractIdentifiers(param.left, nodes);\r\n            break;\r\n    }\r\n    return nodes;\r\n}\r\nconst isFunctionType = (node) => {\r\n    return /Function(?:Expression|Declaration)$|Method$/.test(node.type);\r\n};\r\nconst isStaticProperty = (node) => node &&\r\n    (node.type === 'ObjectProperty' || node.type === 'ObjectMethod') &&\r\n    !node.computed;\r\nconst isStaticPropertyKey = (node, parent) => isStaticProperty(parent) && parent.key === node;\n\n// these keywords should not appear inside expressions, but operators like\r\n// typeof, instanceof and in are allowed\r\nconst prohibitedKeywordRE = new RegExp('\\\\b' +\r\n    ('do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,' +\r\n        'super,throw,while,yield,delete,export,import,return,switch,default,' +\r\n        'extends,finally,continue,debugger,function,arguments,typeof,void')\r\n        .split(',')\r\n        .join('\\\\b|\\\\b') +\r\n    '\\\\b');\r\n// strip strings in expressions\r\nconst stripStringRE = /'(?:[^'\\\\]|\\\\.)*'|\"(?:[^\"\\\\]|\\\\.)*\"|`(?:[^`\\\\]|\\\\.)*\\$\\{|\\}(?:[^`\\\\]|\\\\.)*`|`(?:[^`\\\\]|\\\\.)*`/g;\r\n/**\r\n * Validate a non-prefixed expression.\r\n * This is only called when using the in-browser runtime compiler since it\r\n * doesn't prefix expressions.\r\n */\r\nfunction validateBrowserExpression(node, context, asParams = false, asRawStatements = false) {\r\n    const exp = node.content;\r\n    // empty expressions are validated per-directive since some directives\r\n    // do allow empty expressions.\r\n    if (!exp.trim()) {\r\n        return;\r\n    }\r\n    try {\r\n        new Function(asRawStatements\r\n            ? ` ${exp} `\r\n            : `return ${asParams ? `(${exp}) => {}` : `(${exp})`}`);\r\n    }\r\n    catch (e) {\r\n        let message = e.message;\r\n        const keywordMatch = exp\r\n            .replace(stripStringRE, '')\r\n            .match(prohibitedKeywordRE);\r\n        if (keywordMatch) {\r\n            message = `avoid using JavaScript keyword as property name: \"${keywordMatch[0]}\"`;\r\n        }\r\n        context.onError(createCompilerError(44 /* X_INVALID_EXPRESSION */, node.loc, undefined, message));\r\n    }\r\n}\n\nconst transformExpression = (node, context) => {\r\n    if (node.type === 5 /* INTERPOLATION */) {\r\n        node.content = processExpression(node.content, context);\r\n    }\r\n    else if (node.type === 1 /* ELEMENT */) {\r\n        // handle directives on element\r\n        for (let i = 0; i < node.props.length; i++) {\r\n            const dir = node.props[i];\r\n            // do not process for v-on & v-for since they are special handled\r\n            if (dir.type === 7 /* DIRECTIVE */ && dir.name !== 'for') {\r\n                const exp = dir.exp;\r\n                const arg = dir.arg;\r\n                // do not process exp if this is v-on:arg - we need special handling\r\n                // for wrapping inline statements.\r\n                if (exp &&\r\n                    exp.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n                    !(dir.name === 'on' && arg)) {\r\n                    dir.exp = processExpression(exp, context, \r\n                    // slot args must be processed as function params\r\n                    dir.name === 'slot');\r\n                }\r\n                if (arg && arg.type === 4 /* SIMPLE_EXPRESSION */ && !arg.isStatic) {\r\n                    dir.arg = processExpression(arg, context);\r\n                }\r\n            }\r\n        }\r\n    }\r\n};\r\n// Important: since this function uses Node.js only dependencies, it should\r\n// always be used with a leading !true check so that it can be\r\n// tree-shaken from the browser build.\r\nfunction processExpression(node, context, \r\n// some expressions like v-slot props & v-for aliases should be parsed as\r\n// function params\r\nasParams = false, \r\n// v-on handler values may contain multiple statements\r\nasRawStatements = false, localVars = Object.create(context.identifiers)) {\r\n    {\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            // simple in-browser validation (same logic in 2.x)\r\n            validateBrowserExpression(node, context, asParams, asRawStatements);\r\n        }\r\n        return node;\r\n    }\r\n}\n\nconst transformIf = createStructuralDirectiveTransform(/^(if|else|else-if)$/, (node, dir, context) => {\r\n    return processIf(node, dir, context, (ifNode, branch, isRoot) => {\r\n        // #1587: We need to dynamically increment the key based on the current\r\n        // node's sibling nodes, since chained v-if/else branches are\r\n        // rendered at the same depth\r\n        const siblings = context.parent.children;\r\n        let i = siblings.indexOf(ifNode);\r\n        let key = 0;\r\n        while (i-- >= 0) {\r\n            const sibling = siblings[i];\r\n            if (sibling && sibling.type === 9 /* IF */) {\r\n                key += sibling.branches.length;\r\n            }\r\n        }\r\n        // Exit callback. Complete the codegenNode when all children have been\r\n        // transformed.\r\n        return () => {\r\n            if (isRoot) {\r\n                ifNode.codegenNode = createCodegenNodeForBranch(branch, key, context);\r\n            }\r\n            else {\r\n                // attach this branch's codegen node to the v-if root.\r\n                const parentCondition = getParentCondition(ifNode.codegenNode);\r\n                parentCondition.alternate = createCodegenNodeForBranch(branch, key + ifNode.branches.length - 1, context);\r\n            }\r\n        };\r\n    });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processIf(node, dir, context, processCodegen) {\r\n    if (dir.name !== 'else' &&\r\n        (!dir.exp || !dir.exp.content.trim())) {\r\n        const loc = dir.exp ? dir.exp.loc : node.loc;\r\n        context.onError(createCompilerError(28 /* X_V_IF_NO_EXPRESSION */, dir.loc));\r\n        dir.exp = createSimpleExpression(`true`, false, loc);\r\n    }\r\n    if ((process.env.NODE_ENV !== 'production') && true && dir.exp) {\r\n        validateBrowserExpression(dir.exp, context);\r\n    }\r\n    if (dir.name === 'if') {\r\n        const branch = createIfBranch(node, dir);\r\n        const ifNode = {\r\n            type: 9 /* IF */,\r\n            loc: node.loc,\r\n            branches: [branch]\r\n        };\r\n        context.replaceNode(ifNode);\r\n        if (processCodegen) {\r\n            return processCodegen(ifNode, branch, true);\r\n        }\r\n    }\r\n    else {\r\n        // locate the adjacent v-if\r\n        const siblings = context.parent.children;\r\n        const comments = [];\r\n        let i = siblings.indexOf(node);\r\n        while (i-- >= -1) {\r\n            const sibling = siblings[i];\r\n            if ((process.env.NODE_ENV !== 'production') && sibling && sibling.type === 3 /* COMMENT */) {\r\n                context.removeNode(sibling);\r\n                comments.unshift(sibling);\r\n                continue;\r\n            }\r\n            if (sibling &&\r\n                sibling.type === 2 /* TEXT */ &&\r\n                !sibling.content.trim().length) {\r\n                context.removeNode(sibling);\r\n                continue;\r\n            }\r\n            if (sibling && sibling.type === 9 /* IF */) {\r\n                // Check if v-else was followed by v-else-if\r\n                if (dir.name === 'else-if' &&\r\n                    sibling.branches[sibling.branches.length - 1].condition === undefined) {\r\n                    context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n                }\r\n                // move the node to the if node's branches\r\n                context.removeNode();\r\n                const branch = createIfBranch(node, dir);\r\n                if ((process.env.NODE_ENV !== 'production') &&\r\n                    comments.length &&\r\n                    // #3619 ignore comments if the v-if is direct child of <transition>\r\n                    !(context.parent &&\r\n                        context.parent.type === 1 /* ELEMENT */ &&\r\n                        isBuiltInType(context.parent.tag, 'transition'))) {\r\n                    branch.children = [...comments, ...branch.children];\r\n                }\r\n                // check if user is forcing same key on different branches\r\n                if ((process.env.NODE_ENV !== 'production') || !true) {\r\n                    const key = branch.userKey;\r\n                    if (key) {\r\n                        sibling.branches.forEach(({ userKey }) => {\r\n                            if (isSameKey(userKey, key)) {\r\n                                context.onError(createCompilerError(29 /* X_V_IF_SAME_KEY */, branch.userKey.loc));\r\n                            }\r\n                        });\r\n                    }\r\n                }\r\n                sibling.branches.push(branch);\r\n                const onExit = processCodegen && processCodegen(sibling, branch, false);\r\n                // since the branch was removed, it will not be traversed.\r\n                // make sure to traverse here.\r\n                traverseNode(branch, context);\r\n                // call on exit\r\n                if (onExit)\r\n                    onExit();\r\n                // make sure to reset currentNode after traversal to indicate this\r\n                // node has been removed.\r\n                context.currentNode = null;\r\n            }\r\n            else {\r\n                context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n            }\r\n            break;\r\n        }\r\n    }\r\n}\r\nfunction createIfBranch(node, dir) {\r\n    const isTemplateIf = node.tagType === 3 /* TEMPLATE */;\r\n    return {\r\n        type: 10 /* IF_BRANCH */,\r\n        loc: node.loc,\r\n        condition: dir.name === 'else' ? undefined : dir.exp,\r\n        children: isTemplateIf && !findDir(node, 'for') ? node.children : [node],\r\n        userKey: findProp(node, `key`),\r\n        isTemplateIf\r\n    };\r\n}\r\nfunction createCodegenNodeForBranch(branch, keyIndex, context) {\r\n    if (branch.condition) {\r\n        return createConditionalExpression(branch.condition, createChildrenCodegenNode(branch, keyIndex, context), \r\n        // make sure to pass in asBlock: true so that the comment node call\r\n        // closes the current block.\r\n        createCallExpression(context.helper(CREATE_COMMENT), [\r\n            (process.env.NODE_ENV !== 'production') ? '\"v-if\"' : '\"\"',\r\n            'true'\r\n        ]));\r\n    }\r\n    else {\r\n        return createChildrenCodegenNode(branch, keyIndex, context);\r\n    }\r\n}\r\nfunction createChildrenCodegenNode(branch, keyIndex, context) {\r\n    const { helper } = context;\r\n    const keyProperty = createObjectProperty(`key`, createSimpleExpression(`${keyIndex}`, false, locStub, 2 /* CAN_HOIST */));\r\n    const { children } = branch;\r\n    const firstChild = children[0];\r\n    const needFragmentWrapper = children.length !== 1 || firstChild.type !== 1 /* ELEMENT */;\r\n    if (needFragmentWrapper) {\r\n        if (children.length === 1 && firstChild.type === 11 /* FOR */) {\r\n            // optimize away nested fragments when child is a ForNode\r\n            const vnodeCall = firstChild.codegenNode;\r\n            injectProp(vnodeCall, keyProperty, context);\r\n            return vnodeCall;\r\n        }\r\n        else {\r\n            let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n            let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n            // check if the fragment actually contains a single valid child with\r\n            // the rest being comments\r\n            if ((process.env.NODE_ENV !== 'production') &&\r\n                !branch.isTemplateIf &&\r\n                children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n                patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n                patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n            }\r\n            return createVNodeCall(context, helper(FRAGMENT), createObjectExpression([keyProperty]), children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, false, false /* isComponent */, branch.loc);\r\n        }\r\n    }\r\n    else {\r\n        const ret = firstChild.codegenNode;\r\n        const vnodeCall = getMemoedVNodeCall(ret);\r\n        // Change createVNode to createBlock.\r\n        if (vnodeCall.type === 13 /* VNODE_CALL */) {\r\n            makeBlock(vnodeCall, context);\r\n        }\r\n        // inject branch key\r\n        injectProp(vnodeCall, keyProperty, context);\r\n        return ret;\r\n    }\r\n}\r\nfunction isSameKey(a, b) {\r\n    if (!a || a.type !== b.type) {\r\n        return false;\r\n    }\r\n    if (a.type === 6 /* ATTRIBUTE */) {\r\n        if (a.value.content !== b.value.content) {\r\n            return false;\r\n        }\r\n    }\r\n    else {\r\n        // directive\r\n        const exp = a.exp;\r\n        const branchExp = b.exp;\r\n        if (exp.type !== branchExp.type) {\r\n            return false;\r\n        }\r\n        if (exp.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n            exp.isStatic !== branchExp.isStatic ||\r\n            exp.content !== branchExp.content) {\r\n            return false;\r\n        }\r\n    }\r\n    return true;\r\n}\r\nfunction getParentCondition(node) {\r\n    while (true) {\r\n        if (node.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n            if (node.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n                node = node.alternate;\r\n            }\r\n            else {\r\n                return node;\r\n            }\r\n        }\r\n        else if (node.type === 20 /* JS_CACHE_EXPRESSION */) {\r\n            node = node.value;\r\n        }\r\n    }\r\n}\n\nconst transformFor = createStructuralDirectiveTransform('for', (node, dir, context) => {\r\n    const { helper, removeHelper } = context;\r\n    return processFor(node, dir, context, forNode => {\r\n        // create the loop render function expression now, and add the\r\n        // iterator on exit after all children have been traversed\r\n        const renderExp = createCallExpression(helper(RENDER_LIST), [\r\n            forNode.source\r\n        ]);\r\n        const isTemplate = isTemplateNode(node);\r\n        const memo = findDir(node, 'memo');\r\n        const keyProp = findProp(node, `key`);\r\n        const keyExp = keyProp &&\r\n            (keyProp.type === 6 /* ATTRIBUTE */\r\n                ? createSimpleExpression(keyProp.value.content, true)\r\n                : keyProp.exp);\r\n        const keyProperty = keyProp ? createObjectProperty(`key`, keyExp) : null;\r\n        const isStableFragment = forNode.source.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n            forNode.source.constType > 0 /* NOT_CONSTANT */;\r\n        const fragmentFlag = isStableFragment\r\n            ? 64 /* STABLE_FRAGMENT */\r\n            : keyProp\r\n                ? 128 /* KEYED_FRAGMENT */\r\n                : 256 /* UNKEYED_FRAGMENT */;\r\n        forNode.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, renderExp, fragmentFlag +\r\n            ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[fragmentFlag]} */` : ``), undefined, undefined, true /* isBlock */, !isStableFragment /* disableTracking */, false /* isComponent */, node.loc);\r\n        return () => {\r\n            // finish the codegen now that all children have been traversed\r\n            let childBlock;\r\n            const { children } = forNode;\r\n            // check <template v-for> key placement\r\n            if (((process.env.NODE_ENV !== 'production') || !true) && isTemplate) {\r\n                node.children.some(c => {\r\n                    if (c.type === 1 /* ELEMENT */) {\r\n                        const key = findProp(c, 'key');\r\n                        if (key) {\r\n                            context.onError(createCompilerError(33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */, key.loc));\r\n                            return true;\r\n                        }\r\n                    }\r\n                });\r\n            }\r\n            const needFragmentWrapper = children.length !== 1 || children[0].type !== 1 /* ELEMENT */;\r\n            const slotOutlet = isSlotOutlet(node)\r\n                ? node\r\n                : isTemplate &&\r\n                    node.children.length === 1 &&\r\n                    isSlotOutlet(node.children[0])\r\n                    ? node.children[0] // api-extractor somehow fails to infer this\r\n                    : null;\r\n            if (slotOutlet) {\r\n                // <slot v-for=\"...\"> or <template v-for=\"...\"><slot/></template>\r\n                childBlock = slotOutlet.codegenNode;\r\n                if (isTemplate && keyProperty) {\r\n                    // <template v-for=\"...\" :key=\"...\"><slot/></template>\r\n                    // we need to inject the key to the renderSlot() call.\r\n                    // the props for renderSlot is passed as the 3rd argument.\r\n                    injectProp(childBlock, keyProperty, context);\r\n                }\r\n            }\r\n            else if (needFragmentWrapper) {\r\n                // <template v-for=\"...\"> with text or multi-elements\r\n                // should generate a fragment block for each loop\r\n                childBlock = createVNodeCall(context, helper(FRAGMENT), keyProperty ? createObjectExpression([keyProperty]) : undefined, node.children, 64 /* STABLE_FRAGMENT */ +\r\n                    ((process.env.NODE_ENV !== 'production')\r\n                        ? ` /* ${PatchFlagNames[64 /* STABLE_FRAGMENT */]} */`\r\n                        : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n            }\r\n            else {\r\n                // Normal element v-for. Directly use the child's codegenNode\r\n                // but mark it as a block.\r\n                childBlock = children[0]\r\n                    .codegenNode;\r\n                if (isTemplate && keyProperty) {\r\n                    injectProp(childBlock, keyProperty, context);\r\n                }\r\n                if (childBlock.isBlock !== !isStableFragment) {\r\n                    if (childBlock.isBlock) {\r\n                        // switch from block to vnode\r\n                        removeHelper(OPEN_BLOCK);\r\n                        removeHelper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n                    }\r\n                    else {\r\n                        // switch from vnode to block\r\n                        removeHelper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n                    }\r\n                }\r\n                childBlock.isBlock = !isStableFragment;\r\n                if (childBlock.isBlock) {\r\n                    helper(OPEN_BLOCK);\r\n                    helper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n                }\r\n                else {\r\n                    helper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n                }\r\n            }\r\n            if (memo) {\r\n                const loop = createFunctionExpression(createForLoopParams(forNode.parseResult, [\r\n                    createSimpleExpression(`_cached`)\r\n                ]));\r\n                loop.body = createBlockStatement([\r\n                    createCompoundExpression([`const _memo = (`, memo.exp, `)`]),\r\n                    createCompoundExpression([\r\n                        `if (_cached`,\r\n                        ...(keyExp ? [` && _cached.key === `, keyExp] : []),\r\n                        ` && ${context.helperString(IS_MEMO_SAME)}(_cached, _memo)) return _cached`\r\n                    ]),\r\n                    createCompoundExpression([`const _item = `, childBlock]),\r\n                    createSimpleExpression(`_item.memo = _memo`),\r\n                    createSimpleExpression(`return _item`)\r\n                ]);\r\n                renderExp.arguments.push(loop, createSimpleExpression(`_cache`), createSimpleExpression(String(context.cached++)));\r\n            }\r\n            else {\r\n                renderExp.arguments.push(createFunctionExpression(createForLoopParams(forNode.parseResult), childBlock, true /* force newline */));\r\n            }\r\n        };\r\n    });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processFor(node, dir, context, processCodegen) {\r\n    if (!dir.exp) {\r\n        context.onError(createCompilerError(31 /* X_V_FOR_NO_EXPRESSION */, dir.loc));\r\n        return;\r\n    }\r\n    const parseResult = parseForExpression(\r\n    // can only be simple expression because vFor transform is applied\r\n    // before expression transform.\r\n    dir.exp, context);\r\n    if (!parseResult) {\r\n        context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, dir.loc));\r\n        return;\r\n    }\r\n    const { addIdentifiers, removeIdentifiers, scopes } = context;\r\n    const { source, value, key, index } = parseResult;\r\n    const forNode = {\r\n        type: 11 /* FOR */,\r\n        loc: dir.loc,\r\n        source,\r\n        valueAlias: value,\r\n        keyAlias: key,\r\n        objectIndexAlias: index,\r\n        parseResult,\r\n        children: isTemplateNode(node) ? node.children : [node]\r\n    };\r\n    context.replaceNode(forNode);\r\n    // bookkeeping\r\n    scopes.vFor++;\r\n    const onExit = processCodegen && processCodegen(forNode);\r\n    return () => {\r\n        scopes.vFor--;\r\n        if (onExit)\r\n            onExit();\r\n    };\r\n}\r\nconst forAliasRE = /([\\s\\S]*?)\\s+(?:in|of)\\s+([\\s\\S]*)/;\r\n// This regex doesn't cover the case if key or index aliases have destructuring,\r\n// but those do not make sense in the first place, so this works in practice.\r\nconst forIteratorRE = /,([^,\\}\\]]*)(?:,([^,\\}\\]]*))?$/;\r\nconst stripParensRE = /^\\(|\\)$/g;\r\nfunction parseForExpression(input, context) {\r\n    const loc = input.loc;\r\n    const exp = input.content;\r\n    const inMatch = exp.match(forAliasRE);\r\n    if (!inMatch)\r\n        return;\r\n    const [, LHS, RHS] = inMatch;\r\n    const result = {\r\n        source: createAliasExpression(loc, RHS.trim(), exp.indexOf(RHS, LHS.length)),\r\n        value: undefined,\r\n        key: undefined,\r\n        index: undefined\r\n    };\r\n    if ((process.env.NODE_ENV !== 'production') && true) {\r\n        validateBrowserExpression(result.source, context);\r\n    }\r\n    let valueContent = LHS.trim().replace(stripParensRE, '').trim();\r\n    const trimmedOffset = LHS.indexOf(valueContent);\r\n    const iteratorMatch = valueContent.match(forIteratorRE);\r\n    if (iteratorMatch) {\r\n        valueContent = valueContent.replace(forIteratorRE, '').trim();\r\n        const keyContent = iteratorMatch[1].trim();\r\n        let keyOffset;\r\n        if (keyContent) {\r\n            keyOffset = exp.indexOf(keyContent, trimmedOffset + valueContent.length);\r\n            result.key = createAliasExpression(loc, keyContent, keyOffset);\r\n            if ((process.env.NODE_ENV !== 'production') && true) {\r\n                validateBrowserExpression(result.key, context, true);\r\n            }\r\n        }\r\n        if (iteratorMatch[2]) {\r\n            const indexContent = iteratorMatch[2].trim();\r\n            if (indexContent) {\r\n                result.index = createAliasExpression(loc, indexContent, exp.indexOf(indexContent, result.key\r\n                    ? keyOffset + keyContent.length\r\n                    : trimmedOffset + valueContent.length));\r\n                if ((process.env.NODE_ENV !== 'production') && true) {\r\n                    validateBrowserExpression(result.index, context, true);\r\n                }\r\n            }\r\n        }\r\n    }\r\n    if (valueContent) {\r\n        result.value = createAliasExpression(loc, valueContent, trimmedOffset);\r\n        if ((process.env.NODE_ENV !== 'production') && true) {\r\n            validateBrowserExpression(result.value, context, true);\r\n        }\r\n    }\r\n    return result;\r\n}\r\nfunction createAliasExpression(range, content, offset) {\r\n    return createSimpleExpression(content, false, getInnerRange(range, offset, content.length));\r\n}\r\nfunction createForLoopParams({ value, key, index }, memoArgs = []) {\r\n    return createParamsList([value, key, index, ...memoArgs]);\r\n}\r\nfunction createParamsList(args) {\r\n    let i = args.length;\r\n    while (i--) {\r\n        if (args[i])\r\n            break;\r\n    }\r\n    return args\r\n        .slice(0, i + 1)\r\n        .map((arg, i) => arg || createSimpleExpression(`_`.repeat(i + 1), false));\r\n}\n\nconst defaultFallback = createSimpleExpression(`undefined`, false);\r\n// A NodeTransform that:\r\n// 1. Tracks scope identifiers for scoped slots so that they don't get prefixed\r\n//    by transformExpression. This is only applied in non-browser builds with\r\n//    { prefixIdentifiers: true }.\r\n// 2. Track v-slot depths so that we know a slot is inside another slot.\r\n//    Note the exit callback is executed before buildSlots() on the same node,\r\n//    so only nested slots see positive numbers.\r\nconst trackSlotScopes = (node, context) => {\r\n    if (node.type === 1 /* ELEMENT */ &&\r\n        (node.tagType === 1 /* COMPONENT */ ||\r\n            node.tagType === 3 /* TEMPLATE */)) {\r\n        // We are only checking non-empty v-slot here\r\n        // since we only care about slots that introduce scope variables.\r\n        const vSlot = findDir(node, 'slot');\r\n        if (vSlot) {\r\n            vSlot.exp;\r\n            context.scopes.vSlot++;\r\n            return () => {\r\n                context.scopes.vSlot--;\r\n            };\r\n        }\r\n    }\r\n};\r\n// A NodeTransform that tracks scope identifiers for scoped slots with v-for.\r\n// This transform is only applied in non-browser builds with { prefixIdentifiers: true }\r\nconst trackVForSlotScopes = (node, context) => {\r\n    let vFor;\r\n    if (isTemplateNode(node) &&\r\n        node.props.some(isVSlot) &&\r\n        (vFor = findDir(node, 'for'))) {\r\n        const result = (vFor.parseResult = parseForExpression(vFor.exp, context));\r\n        if (result) {\r\n            const { value, key, index } = result;\r\n            const { addIdentifiers, removeIdentifiers } = context;\r\n            value && addIdentifiers(value);\r\n            key && addIdentifiers(key);\r\n            index && addIdentifiers(index);\r\n            return () => {\r\n                value && removeIdentifiers(value);\r\n                key && removeIdentifiers(key);\r\n                index && removeIdentifiers(index);\r\n            };\r\n        }\r\n    }\r\n};\r\nconst buildClientSlotFn = (props, children, loc) => createFunctionExpression(props, children, false /* newline */, true /* isSlot */, children.length ? children[0].loc : loc);\r\n// Instead of being a DirectiveTransform, v-slot processing is called during\r\n// transformElement to build the slots object for a component.\r\nfunction buildSlots(node, context, buildSlotFn = buildClientSlotFn) {\r\n    context.helper(WITH_CTX);\r\n    const { children, loc } = node;\r\n    const slotsProperties = [];\r\n    const dynamicSlots = [];\r\n    // If the slot is inside a v-for or another v-slot, force it to be dynamic\r\n    // since it likely uses a scope variable.\r\n    let hasDynamicSlots = context.scopes.vSlot > 0 || context.scopes.vFor > 0;\r\n    // 1. Check for slot with slotProps on component itself.\r\n    //    <Comp v-slot=\"{ prop }\"/>\r\n    const onComponentSlot = findDir(node, 'slot', true);\r\n    if (onComponentSlot) {\r\n        const { arg, exp } = onComponentSlot;\r\n        if (arg && !isStaticExp(arg)) {\r\n            hasDynamicSlots = true;\r\n        }\r\n        slotsProperties.push(createObjectProperty(arg || createSimpleExpression('default', true), buildSlotFn(exp, children, loc)));\r\n    }\r\n    // 2. Iterate through children and check for template slots\r\n    //    <template v-slot:foo=\"{ prop }\">\r\n    let hasTemplateSlots = false;\r\n    let hasNamedDefaultSlot = false;\r\n    const implicitDefaultChildren = [];\r\n    const seenSlotNames = new Set();\r\n    for (let i = 0; i < children.length; i++) {\r\n        const slotElement = children[i];\r\n        let slotDir;\r\n        if (!isTemplateNode(slotElement) ||\r\n            !(slotDir = findDir(slotElement, 'slot', true))) {\r\n            // not a <template v-slot>, skip.\r\n            if (slotElement.type !== 3 /* COMMENT */) {\r\n                implicitDefaultChildren.push(slotElement);\r\n            }\r\n            continue;\r\n        }\r\n        if (onComponentSlot) {\r\n            // already has on-component slot - this is incorrect usage.\r\n            context.onError(createCompilerError(37 /* X_V_SLOT_MIXED_SLOT_USAGE */, slotDir.loc));\r\n            break;\r\n        }\r\n        hasTemplateSlots = true;\r\n        const { children: slotChildren, loc: slotLoc } = slotElement;\r\n        const { arg: slotName = createSimpleExpression(`default`, true), exp: slotProps, loc: dirLoc } = slotDir;\r\n        // check if name is dynamic.\r\n        let staticSlotName;\r\n        if (isStaticExp(slotName)) {\r\n            staticSlotName = slotName ? slotName.content : `default`;\r\n        }\r\n        else {\r\n            hasDynamicSlots = true;\r\n        }\r\n        const slotFunction = buildSlotFn(slotProps, slotChildren, slotLoc);\r\n        // check if this slot is conditional (v-if/v-for)\r\n        let vIf;\r\n        let vElse;\r\n        let vFor;\r\n        if ((vIf = findDir(slotElement, 'if'))) {\r\n            hasDynamicSlots = true;\r\n            dynamicSlots.push(createConditionalExpression(vIf.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback));\r\n        }\r\n        else if ((vElse = findDir(slotElement, /^else(-if)?$/, true /* allowEmpty */))) {\r\n            // find adjacent v-if\r\n            let j = i;\r\n            let prev;\r\n            while (j--) {\r\n                prev = children[j];\r\n                if (prev.type !== 3 /* COMMENT */) {\r\n                    break;\r\n                }\r\n            }\r\n            if (prev && isTemplateNode(prev) && findDir(prev, 'if')) {\r\n                // remove node\r\n                children.splice(i, 1);\r\n                i--;\r\n                // attach this slot to previous conditional\r\n                let conditional = dynamicSlots[dynamicSlots.length - 1];\r\n                while (conditional.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n                    conditional = conditional.alternate;\r\n                }\r\n                conditional.alternate = vElse.exp\r\n                    ? createConditionalExpression(vElse.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback)\r\n                    : buildDynamicSlot(slotName, slotFunction);\r\n            }\r\n            else {\r\n                context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, vElse.loc));\r\n            }\r\n        }\r\n        else if ((vFor = findDir(slotElement, 'for'))) {\r\n            hasDynamicSlots = true;\r\n            const parseResult = vFor.parseResult ||\r\n                parseForExpression(vFor.exp, context);\r\n            if (parseResult) {\r\n                // Render the dynamic slots as an array and add it to the createSlot()\r\n                // args. The runtime knows how to handle it appropriately.\r\n                dynamicSlots.push(createCallExpression(context.helper(RENDER_LIST), [\r\n                    parseResult.source,\r\n                    createFunctionExpression(createForLoopParams(parseResult), buildDynamicSlot(slotName, slotFunction), true /* force newline */)\r\n                ]));\r\n            }\r\n            else {\r\n                context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, vFor.loc));\r\n            }\r\n        }\r\n        else {\r\n            // check duplicate static names\r\n            if (staticSlotName) {\r\n                if (seenSlotNames.has(staticSlotName)) {\r\n                    context.onError(createCompilerError(38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */, dirLoc));\r\n                    continue;\r\n                }\r\n                seenSlotNames.add(staticSlotName);\r\n                if (staticSlotName === 'default') {\r\n                    hasNamedDefaultSlot = true;\r\n                }\r\n            }\r\n            slotsProperties.push(createObjectProperty(slotName, slotFunction));\r\n        }\r\n    }\r\n    if (!onComponentSlot) {\r\n        const buildDefaultSlotProperty = (props, children) => {\r\n            const fn = buildSlotFn(props, children, loc);\r\n            if (context.compatConfig) {\r\n                fn.isNonScopedSlot = true;\r\n            }\r\n            return createObjectProperty(`default`, fn);\r\n        };\r\n        if (!hasTemplateSlots) {\r\n            // implicit default slot (on component)\r\n            slotsProperties.push(buildDefaultSlotProperty(undefined, children));\r\n        }\r\n        else if (implicitDefaultChildren.length &&\r\n            // #3766\r\n            // with whitespace: 'preserve', whitespaces between slots will end up in\r\n            // implicitDefaultChildren. Ignore if all implicit children are whitespaces.\r\n            implicitDefaultChildren.some(node => isNonWhitespaceContent(node))) {\r\n            // implicit default slot (mixed with named slots)\r\n            if (hasNamedDefaultSlot) {\r\n                context.onError(createCompilerError(39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */, implicitDefaultChildren[0].loc));\r\n            }\r\n            else {\r\n                slotsProperties.push(buildDefaultSlotProperty(undefined, implicitDefaultChildren));\r\n            }\r\n        }\r\n    }\r\n    const slotFlag = hasDynamicSlots\r\n        ? 2 /* DYNAMIC */\r\n        : hasForwardedSlots(node.children)\r\n            ? 3 /* FORWARDED */\r\n            : 1 /* STABLE */;\r\n    let slots = createObjectExpression(slotsProperties.concat(createObjectProperty(`_`, \r\n    // 2 = compiled but dynamic = can skip normalization, but must run diff\r\n    // 1 = compiled and static = can skip normalization AND diff as optimized\r\n    createSimpleExpression(slotFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${slotFlagsText[slotFlag]} */` : ``), false))), loc);\r\n    if (dynamicSlots.length) {\r\n        slots = createCallExpression(context.helper(CREATE_SLOTS), [\r\n            slots,\r\n            createArrayExpression(dynamicSlots)\r\n        ]);\r\n    }\r\n    return {\r\n        slots,\r\n        hasDynamicSlots\r\n    };\r\n}\r\nfunction buildDynamicSlot(name, fn) {\r\n    return createObjectExpression([\r\n        createObjectProperty(`name`, name),\r\n        createObjectProperty(`fn`, fn)\r\n    ]);\r\n}\r\nfunction hasForwardedSlots(children) {\r\n    for (let i = 0; i < children.length; i++) {\r\n        const child = children[i];\r\n        switch (child.type) {\r\n            case 1 /* ELEMENT */:\r\n                if (child.tagType === 2 /* SLOT */ ||\r\n                    hasForwardedSlots(child.children)) {\r\n                    return true;\r\n                }\r\n                break;\r\n            case 9 /* IF */:\r\n                if (hasForwardedSlots(child.branches))\r\n                    return true;\r\n                break;\r\n            case 10 /* IF_BRANCH */:\r\n            case 11 /* FOR */:\r\n                if (hasForwardedSlots(child.children))\r\n                    return true;\r\n                break;\r\n        }\r\n    }\r\n    return false;\r\n}\r\nfunction isNonWhitespaceContent(node) {\r\n    if (node.type !== 2 /* TEXT */ && node.type !== 12 /* TEXT_CALL */)\r\n        return true;\r\n    return node.type === 2 /* TEXT */\r\n        ? !!node.content.trim()\r\n        : isNonWhitespaceContent(node.content);\r\n}\n\n// some directive transforms (e.g. v-model) may return a symbol for runtime\r\n// import, which should be used instead of a resolveDirective call.\r\nconst directiveImportMap = new WeakMap();\r\n// generate a JavaScript AST for this element's codegen\r\nconst transformElement = (node, context) => {\r\n    // perform the work on exit, after all child expressions have been\r\n    // processed and merged.\r\n    return function postTransformElement() {\r\n        node = context.currentNode;\r\n        if (!(node.type === 1 /* ELEMENT */ &&\r\n            (node.tagType === 0 /* ELEMENT */ ||\r\n                node.tagType === 1 /* COMPONENT */))) {\r\n            return;\r\n        }\r\n        const { tag, props } = node;\r\n        const isComponent = node.tagType === 1 /* COMPONENT */;\r\n        // The goal of the transform is to create a codegenNode implementing the\r\n        // VNodeCall interface.\r\n        let vnodeTag = isComponent\r\n            ? resolveComponentType(node, context)\r\n            : `\"${tag}\"`;\r\n        const isDynamicComponent = isObject(vnodeTag) && vnodeTag.callee === RESOLVE_DYNAMIC_COMPONENT;\r\n        let vnodeProps;\r\n        let vnodeChildren;\r\n        let vnodePatchFlag;\r\n        let patchFlag = 0;\r\n        let vnodeDynamicProps;\r\n        let dynamicPropNames;\r\n        let vnodeDirectives;\r\n        let shouldUseBlock = \r\n        // dynamic component may resolve to plain elements\r\n        isDynamicComponent ||\r\n            vnodeTag === TELEPORT ||\r\n            vnodeTag === SUSPENSE ||\r\n            (!isComponent &&\r\n                // <svg> and <foreignObject> must be forced into blocks so that block\r\n                // updates inside get proper isSVG flag at runtime. (#639, #643)\r\n                // This is technically web-specific, but splitting the logic out of core\r\n                // leads to too much unnecessary complexity.\r\n                (tag === 'svg' || tag === 'foreignObject'));\r\n        // props\r\n        if (props.length > 0) {\r\n            const propsBuildResult = buildProps(node, context, undefined, isComponent, isDynamicComponent);\r\n            vnodeProps = propsBuildResult.props;\r\n            patchFlag = propsBuildResult.patchFlag;\r\n            dynamicPropNames = propsBuildResult.dynamicPropNames;\r\n            const directives = propsBuildResult.directives;\r\n            vnodeDirectives =\r\n                directives && directives.length\r\n                    ? createArrayExpression(directives.map(dir => buildDirectiveArgs(dir, context)))\r\n                    : undefined;\r\n            if (propsBuildResult.shouldUseBlock) {\r\n                shouldUseBlock = true;\r\n            }\r\n        }\r\n        // children\r\n        if (node.children.length > 0) {\r\n            if (vnodeTag === KEEP_ALIVE) {\r\n                // Although a built-in component, we compile KeepAlive with raw children\r\n                // instead of slot functions so that it can be used inside Transition\r\n                // or other Transition-wrapping HOCs.\r\n                // To ensure correct updates with block optimizations, we need to:\r\n                // 1. Force keep-alive into a block. This avoids its children being\r\n                //    collected by a parent block.\r\n                shouldUseBlock = true;\r\n                // 2. Force keep-alive to always be updated, since it uses raw children.\r\n                patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n                if ((process.env.NODE_ENV !== 'production') && node.children.length > 1) {\r\n                    context.onError(createCompilerError(45 /* X_KEEP_ALIVE_INVALID_CHILDREN */, {\r\n                        start: node.children[0].loc.start,\r\n                        end: node.children[node.children.length - 1].loc.end,\r\n                        source: ''\r\n                    }));\r\n                }\r\n            }\r\n            const shouldBuildAsSlots = isComponent &&\r\n                // Teleport is not a real component and has dedicated runtime handling\r\n                vnodeTag !== TELEPORT &&\r\n                // explained above.\r\n                vnodeTag !== KEEP_ALIVE;\r\n            if (shouldBuildAsSlots) {\r\n                const { slots, hasDynamicSlots } = buildSlots(node, context);\r\n                vnodeChildren = slots;\r\n                if (hasDynamicSlots) {\r\n                    patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n                }\r\n            }\r\n            else if (node.children.length === 1 && vnodeTag !== TELEPORT) {\r\n                const child = node.children[0];\r\n                const type = child.type;\r\n                // check for dynamic text children\r\n                const hasDynamicTextChild = type === 5 /* INTERPOLATION */ ||\r\n                    type === 8 /* COMPOUND_EXPRESSION */;\r\n                if (hasDynamicTextChild &&\r\n                    getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n                    patchFlag |= 1 /* TEXT */;\r\n                }\r\n                // pass directly if the only child is a text node\r\n                // (plain / interpolation / expression)\r\n                if (hasDynamicTextChild || type === 2 /* TEXT */) {\r\n                    vnodeChildren = child;\r\n                }\r\n                else {\r\n                    vnodeChildren = node.children;\r\n                }\r\n            }\r\n            else {\r\n                vnodeChildren = node.children;\r\n            }\r\n        }\r\n        // patchFlag & dynamicPropNames\r\n        if (patchFlag !== 0) {\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                if (patchFlag < 0) {\r\n                    // special flags (negative and mutually exclusive)\r\n                    vnodePatchFlag = patchFlag + ` /* ${PatchFlagNames[patchFlag]} */`;\r\n                }\r\n                else {\r\n                    // bitwise flags\r\n                    const flagNames = Object.keys(PatchFlagNames)\r\n                        .map(Number)\r\n                        .filter(n => n > 0 && patchFlag & n)\r\n                        .map(n => PatchFlagNames[n])\r\n                        .join(`, `);\r\n                    vnodePatchFlag = patchFlag + ` /* ${flagNames} */`;\r\n                }\r\n            }\r\n            else {\r\n                vnodePatchFlag = String(patchFlag);\r\n            }\r\n            if (dynamicPropNames && dynamicPropNames.length) {\r\n                vnodeDynamicProps = stringifyDynamicPropNames(dynamicPropNames);\r\n            }\r\n        }\r\n        node.codegenNode = createVNodeCall(context, vnodeTag, vnodeProps, vnodeChildren, vnodePatchFlag, vnodeDynamicProps, vnodeDirectives, !!shouldUseBlock, false /* disableTracking */, isComponent, node.loc);\r\n    };\r\n};\r\nfunction resolveComponentType(node, context, ssr = false) {\r\n    let { tag } = node;\r\n    // 1. dynamic component\r\n    const isExplicitDynamic = isComponentTag(tag);\r\n    const isProp = findProp(node, 'is');\r\n    if (isProp) {\r\n        if (isExplicitDynamic ||\r\n            (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))) {\r\n            const exp = isProp.type === 6 /* ATTRIBUTE */\r\n                ? isProp.value && createSimpleExpression(isProp.value.content, true)\r\n                : isProp.exp;\r\n            if (exp) {\r\n                return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n                    exp\r\n                ]);\r\n            }\r\n        }\r\n        else if (isProp.type === 6 /* ATTRIBUTE */ &&\r\n            isProp.value.content.startsWith('vue:')) {\r\n            // <button is=\"vue:xxx\">\r\n            // if not <component>, only is value that starts with \"vue:\" will be\r\n            // treated as component by the parse phase and reach here, unless it's\r\n            // compat mode where all is values are considered components\r\n            tag = isProp.value.content.slice(4);\r\n        }\r\n    }\r\n    // 1.5 v-is (TODO: Deprecate)\r\n    const isDir = !isExplicitDynamic && findDir(node, 'is');\r\n    if (isDir && isDir.exp) {\r\n        return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n            isDir.exp\r\n        ]);\r\n    }\r\n    // 2. built-in components (Teleport, Transition, KeepAlive, Suspense...)\r\n    const builtIn = isCoreComponent(tag) || context.isBuiltInComponent(tag);\r\n    if (builtIn) {\r\n        // built-ins are simply fallthroughs / have special handling during ssr\r\n        // so we don't need to import their runtime equivalents\r\n        if (!ssr)\r\n            context.helper(builtIn);\r\n        return builtIn;\r\n    }\r\n    // 5. user component (resolve)\r\n    context.helper(RESOLVE_COMPONENT);\r\n    context.components.add(tag);\r\n    return toValidAssetId(tag, `component`);\r\n}\r\nfunction buildProps(node, context, props = node.props, isComponent, isDynamicComponent, ssr = false) {\r\n    const { tag, loc: elementLoc, children } = node;\r\n    let properties = [];\r\n    const mergeArgs = [];\r\n    const runtimeDirectives = [];\r\n    const hasChildren = children.length > 0;\r\n    let shouldUseBlock = false;\r\n    // patchFlag analysis\r\n    let patchFlag = 0;\r\n    let hasRef = false;\r\n    let hasClassBinding = false;\r\n    let hasStyleBinding = false;\r\n    let hasHydrationEventBinding = false;\r\n    let hasDynamicKeys = false;\r\n    let hasVnodeHook = false;\r\n    const dynamicPropNames = [];\r\n    const analyzePatchFlag = ({ key, value }) => {\r\n        if (isStaticExp(key)) {\r\n            const name = key.content;\r\n            const isEventHandler = isOn(name);\r\n            if (isEventHandler &&\r\n                (!isComponent || isDynamicComponent) &&\r\n                // omit the flag for click handlers because hydration gives click\r\n                // dedicated fast path.\r\n                name.toLowerCase() !== 'onclick' &&\r\n                // omit v-model handlers\r\n                name !== 'onUpdate:modelValue' &&\r\n                // omit onVnodeXXX hooks\r\n                !isReservedProp(name)) {\r\n                hasHydrationEventBinding = true;\r\n            }\r\n            if (isEventHandler && isReservedProp(name)) {\r\n                hasVnodeHook = true;\r\n            }\r\n            if (value.type === 20 /* JS_CACHE_EXPRESSION */ ||\r\n                ((value.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n                    value.type === 8 /* COMPOUND_EXPRESSION */) &&\r\n                    getConstantType(value, context) > 0)) {\r\n                // skip if the prop is a cached handler or has constant value\r\n                return;\r\n            }\r\n            if (name === 'ref') {\r\n                hasRef = true;\r\n            }\r\n            else if (name === 'class') {\r\n                hasClassBinding = true;\r\n            }\r\n            else if (name === 'style') {\r\n                hasStyleBinding = true;\r\n            }\r\n            else if (name !== 'key' && !dynamicPropNames.includes(name)) {\r\n                dynamicPropNames.push(name);\r\n            }\r\n            // treat the dynamic class and style binding of the component as dynamic props\r\n            if (isComponent &&\r\n                (name === 'class' || name === 'style') &&\r\n                !dynamicPropNames.includes(name)) {\r\n                dynamicPropNames.push(name);\r\n            }\r\n        }\r\n        else {\r\n            hasDynamicKeys = true;\r\n        }\r\n    };\r\n    for (let i = 0; i < props.length; i++) {\r\n        // static attribute\r\n        const prop = props[i];\r\n        if (prop.type === 6 /* ATTRIBUTE */) {\r\n            const { loc, name, value } = prop;\r\n            let isStatic = true;\r\n            if (name === 'ref') {\r\n                hasRef = true;\r\n                if (context.scopes.vFor > 0) {\r\n                    properties.push(createObjectProperty(createSimpleExpression('ref_for', true), createSimpleExpression('true')));\r\n                }\r\n            }\r\n            // skip is on <component>, or is=\"vue:xxx\"\r\n            if (name === 'is' &&\r\n                (isComponentTag(tag) ||\r\n                    (value && value.content.startsWith('vue:')) ||\r\n                    (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context)))) {\r\n                continue;\r\n            }\r\n            properties.push(createObjectProperty(createSimpleExpression(name, true, getInnerRange(loc, 0, name.length)), createSimpleExpression(value ? value.content : '', isStatic, value ? value.loc : loc)));\r\n        }\r\n        else {\r\n            // directives\r\n            const { name, arg, exp, loc } = prop;\r\n            const isVBind = name === 'bind';\r\n            const isVOn = name === 'on';\r\n            // skip v-slot - it is handled by its dedicated transform.\r\n            if (name === 'slot') {\r\n                if (!isComponent) {\r\n                    context.onError(createCompilerError(40 /* X_V_SLOT_MISPLACED */, loc));\r\n                }\r\n                continue;\r\n            }\r\n            // skip v-once/v-memo - they are handled by dedicated transforms.\r\n            if (name === 'once' || name === 'memo') {\r\n                continue;\r\n            }\r\n            // skip v-is and :is on <component>\r\n            if (name === 'is' ||\r\n                (isVBind &&\r\n                    isStaticArgOf(arg, 'is') &&\r\n                    (isComponentTag(tag) ||\r\n                        (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))))) {\r\n                continue;\r\n            }\r\n            // skip v-on in SSR compilation\r\n            if (isVOn && ssr) {\r\n                continue;\r\n            }\r\n            if (\r\n            // #938: elements with dynamic keys should be forced into blocks\r\n            (isVBind && isStaticArgOf(arg, 'key')) ||\r\n                // inline before-update hooks need to force block so that it is invoked\r\n                // before children\r\n                (isVOn && hasChildren && isStaticArgOf(arg, 'vue:before-update'))) {\r\n                shouldUseBlock = true;\r\n            }\r\n            if (isVBind && isStaticArgOf(arg, 'ref') && context.scopes.vFor > 0) {\r\n                properties.push(createObjectProperty(createSimpleExpression('ref_for', true), createSimpleExpression('true')));\r\n            }\r\n            // special case for v-bind and v-on with no argument\r\n            if (!arg && (isVBind || isVOn)) {\r\n                hasDynamicKeys = true;\r\n                if (exp) {\r\n                    if (properties.length) {\r\n                        mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n                        properties = [];\r\n                    }\r\n                    if (isVBind) {\r\n                        {\r\n                            // 2.x v-bind object order compat\r\n                            if ((process.env.NODE_ENV !== 'production')) {\r\n                                const hasOverridableKeys = mergeArgs.some(arg => {\r\n                                    if (arg.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n                                        return arg.properties.some(({ key }) => {\r\n                                            if (key.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n                                                !key.isStatic) {\r\n                                                return true;\r\n                                            }\r\n                                            return (key.content !== 'class' &&\r\n                                                key.content !== 'style' &&\r\n                                                !isOn(key.content));\r\n                                        });\r\n                                    }\r\n                                    else {\r\n                                        // dynamic expression\r\n                                        return true;\r\n                                    }\r\n                                });\r\n                                if (hasOverridableKeys) {\r\n                                    checkCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context, loc);\r\n                                }\r\n                            }\r\n                            if (isCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context)) {\r\n                                mergeArgs.unshift(exp);\r\n                                continue;\r\n                            }\r\n                        }\r\n                        mergeArgs.push(exp);\r\n                    }\r\n                    else {\r\n                        // v-on=\"obj\" -> toHandlers(obj)\r\n                        mergeArgs.push({\r\n                            type: 14 /* JS_CALL_EXPRESSION */,\r\n                            loc,\r\n                            callee: context.helper(TO_HANDLERS),\r\n                            arguments: [exp]\r\n                        });\r\n                    }\r\n                }\r\n                else {\r\n                    context.onError(createCompilerError(isVBind\r\n                        ? 34 /* X_V_BIND_NO_EXPRESSION */\r\n                        : 35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n                }\r\n                continue;\r\n            }\r\n            const directiveTransform = context.directiveTransforms[name];\r\n            if (directiveTransform) {\r\n                // has built-in directive transform.\r\n                const { props, needRuntime } = directiveTransform(prop, node, context);\r\n                !ssr && props.forEach(analyzePatchFlag);\r\n                properties.push(...props);\r\n                if (needRuntime) {\r\n                    runtimeDirectives.push(prop);\r\n                    if (isSymbol(needRuntime)) {\r\n                        directiveImportMap.set(prop, needRuntime);\r\n                    }\r\n                }\r\n            }\r\n            else if (!isBuiltInDirective(name)) {\r\n                // no built-in transform, this is a user custom directive.\r\n                runtimeDirectives.push(prop);\r\n                // custom dirs may use beforeUpdate so they need to force blocks\r\n                // to ensure before-update gets called before children update\r\n                if (hasChildren) {\r\n                    shouldUseBlock = true;\r\n                }\r\n            }\r\n        }\r\n    }\r\n    let propsExpression = undefined;\r\n    // has v-bind=\"object\" or v-on=\"object\", wrap with mergeProps\r\n    if (mergeArgs.length) {\r\n        if (properties.length) {\r\n            mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n        }\r\n        if (mergeArgs.length > 1) {\r\n            propsExpression = createCallExpression(context.helper(MERGE_PROPS), mergeArgs, elementLoc);\r\n        }\r\n        else {\r\n            // single v-bind with nothing else - no need for a mergeProps call\r\n            propsExpression = mergeArgs[0];\r\n        }\r\n    }\r\n    else if (properties.length) {\r\n        propsExpression = createObjectExpression(dedupeProperties(properties), elementLoc);\r\n    }\r\n    // patchFlag analysis\r\n    if (hasDynamicKeys) {\r\n        patchFlag |= 16 /* FULL_PROPS */;\r\n    }\r\n    else {\r\n        if (hasClassBinding && !isComponent) {\r\n            patchFlag |= 2 /* CLASS */;\r\n        }\r\n        if (hasStyleBinding && !isComponent) {\r\n            patchFlag |= 4 /* STYLE */;\r\n        }\r\n        if (dynamicPropNames.length) {\r\n            patchFlag |= 8 /* PROPS */;\r\n        }\r\n        if (hasHydrationEventBinding) {\r\n            patchFlag |= 32 /* HYDRATE_EVENTS */;\r\n        }\r\n    }\r\n    if (!shouldUseBlock &&\r\n        (patchFlag === 0 || patchFlag === 32 /* HYDRATE_EVENTS */) &&\r\n        (hasRef || hasVnodeHook || runtimeDirectives.length > 0)) {\r\n        patchFlag |= 512 /* NEED_PATCH */;\r\n    }\r\n    // pre-normalize props, SSR is skipped for now\r\n    if (!context.inSSR && propsExpression) {\r\n        switch (propsExpression.type) {\r\n            case 15 /* JS_OBJECT_EXPRESSION */:\r\n                // means that there is no v-bind,\r\n                // but still need to deal with dynamic key binding\r\n                let classKeyIndex = -1;\r\n                let styleKeyIndex = -1;\r\n                let hasDynamicKey = false;\r\n                for (let i = 0; i < propsExpression.properties.length; i++) {\r\n                    const key = propsExpression.properties[i].key;\r\n                    if (isStaticExp(key)) {\r\n                        if (key.content === 'class') {\r\n                            classKeyIndex = i;\r\n                        }\r\n                        else if (key.content === 'style') {\r\n                            styleKeyIndex = i;\r\n                        }\r\n                    }\r\n                    else if (!key.isHandlerKey) {\r\n                        hasDynamicKey = true;\r\n                    }\r\n                }\r\n                const classProp = propsExpression.properties[classKeyIndex];\r\n                const styleProp = propsExpression.properties[styleKeyIndex];\r\n                // no dynamic key\r\n                if (!hasDynamicKey) {\r\n                    if (classProp && !isStaticExp(classProp.value)) {\r\n                        classProp.value = createCallExpression(context.helper(NORMALIZE_CLASS), [classProp.value]);\r\n                    }\r\n                    if (styleProp &&\r\n                        // the static style is compiled into an object,\r\n                        // so use `hasStyleBinding` to ensure that it is a dynamic style binding\r\n                        (hasStyleBinding ||\r\n                            (styleProp.value.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n                                styleProp.value.content.trim()[0] === `[`) ||\r\n                            // v-bind:style and style both exist,\r\n                            // v-bind:style with static literal object\r\n                            styleProp.value.type === 17 /* JS_ARRAY_EXPRESSION */)) {\r\n                        styleProp.value = createCallExpression(context.helper(NORMALIZE_STYLE), [styleProp.value]);\r\n                    }\r\n                }\r\n                else {\r\n                    // dynamic key binding, wrap with `normalizeProps`\r\n                    propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [propsExpression]);\r\n                }\r\n                break;\r\n            case 14 /* JS_CALL_EXPRESSION */:\r\n                // mergeProps call, do nothing\r\n                break;\r\n            default:\r\n                // single v-bind\r\n                propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [\r\n                    createCallExpression(context.helper(GUARD_REACTIVE_PROPS), [\r\n                        propsExpression\r\n                    ])\r\n                ]);\r\n                break;\r\n        }\r\n    }\r\n    return {\r\n        props: propsExpression,\r\n        directives: runtimeDirectives,\r\n        patchFlag,\r\n        dynamicPropNames,\r\n        shouldUseBlock\r\n    };\r\n}\r\n// Dedupe props in an object literal.\r\n// Literal duplicated attributes would have been warned during the parse phase,\r\n// however, it's possible to encounter duplicated `onXXX` handlers with different\r\n// modifiers. We also need to merge static and dynamic class / style attributes.\r\n// - onXXX handlers / style: merge into array\r\n// - class: merge into single expression with concatenation\r\nfunction dedupeProperties(properties) {\r\n    const knownProps = new Map();\r\n    const deduped = [];\r\n    for (let i = 0; i < properties.length; i++) {\r\n        const prop = properties[i];\r\n        // dynamic keys are always allowed\r\n        if (prop.key.type === 8 /* COMPOUND_EXPRESSION */ || !prop.key.isStatic) {\r\n            deduped.push(prop);\r\n            continue;\r\n        }\r\n        const name = prop.key.content;\r\n        const existing = knownProps.get(name);\r\n        if (existing) {\r\n            if (name === 'style' || name === 'class' || isOn(name)) {\r\n                mergeAsArray(existing, prop);\r\n            }\r\n            // unexpected duplicate, should have emitted error during parse\r\n        }\r\n        else {\r\n            knownProps.set(name, prop);\r\n            deduped.push(prop);\r\n        }\r\n    }\r\n    return deduped;\r\n}\r\nfunction mergeAsArray(existing, incoming) {\r\n    if (existing.value.type === 17 /* JS_ARRAY_EXPRESSION */) {\r\n        existing.value.elements.push(incoming.value);\r\n    }\r\n    else {\r\n        existing.value = createArrayExpression([existing.value, incoming.value], existing.loc);\r\n    }\r\n}\r\nfunction buildDirectiveArgs(dir, context) {\r\n    const dirArgs = [];\r\n    const runtime = directiveImportMap.get(dir);\r\n    if (runtime) {\r\n        // built-in directive with runtime\r\n        dirArgs.push(context.helperString(runtime));\r\n    }\r\n    else {\r\n        {\r\n            // inject statement for resolving directive\r\n            context.helper(RESOLVE_DIRECTIVE);\r\n            context.directives.add(dir.name);\r\n            dirArgs.push(toValidAssetId(dir.name, `directive`));\r\n        }\r\n    }\r\n    const { loc } = dir;\r\n    if (dir.exp)\r\n        dirArgs.push(dir.exp);\r\n    if (dir.arg) {\r\n        if (!dir.exp) {\r\n            dirArgs.push(`void 0`);\r\n        }\r\n        dirArgs.push(dir.arg);\r\n    }\r\n    if (Object.keys(dir.modifiers).length) {\r\n        if (!dir.arg) {\r\n            if (!dir.exp) {\r\n                dirArgs.push(`void 0`);\r\n            }\r\n            dirArgs.push(`void 0`);\r\n        }\r\n        const trueExpression = createSimpleExpression(`true`, false, loc);\r\n        dirArgs.push(createObjectExpression(dir.modifiers.map(modifier => createObjectProperty(modifier, trueExpression)), loc));\r\n    }\r\n    return createArrayExpression(dirArgs, dir.loc);\r\n}\r\nfunction stringifyDynamicPropNames(props) {\r\n    let propsNamesString = `[`;\r\n    for (let i = 0, l = props.length; i < l; i++) {\r\n        propsNamesString += JSON.stringify(props[i]);\r\n        if (i < l - 1)\r\n            propsNamesString += ', ';\r\n    }\r\n    return propsNamesString + `]`;\r\n}\r\nfunction isComponentTag(tag) {\r\n    return tag === 'component' || tag === 'Component';\r\n}\n\n(process.env.NODE_ENV !== 'production')\r\n    ? Object.freeze({})\r\n    : {};\r\n(process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst cacheStringFunction = (fn) => {\r\n    const cache = Object.create(null);\r\n    return ((str) => {\r\n        const hit = cache[str];\r\n        return hit || (cache[str] = fn(str));\r\n    });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n    return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\n\nconst transformSlotOutlet = (node, context) => {\r\n    if (isSlotOutlet(node)) {\r\n        const { children, loc } = node;\r\n        const { slotName, slotProps } = processSlotOutlet(node, context);\r\n        const slotArgs = [\r\n            context.prefixIdentifiers ? `_ctx.$slots` : `$slots`,\r\n            slotName,\r\n            '{}',\r\n            'undefined',\r\n            'true'\r\n        ];\r\n        let expectedLen = 2;\r\n        if (slotProps) {\r\n            slotArgs[2] = slotProps;\r\n            expectedLen = 3;\r\n        }\r\n        if (children.length) {\r\n            slotArgs[3] = createFunctionExpression([], children, false, false, loc);\r\n            expectedLen = 4;\r\n        }\r\n        if (context.scopeId && !context.slotted) {\r\n            expectedLen = 5;\r\n        }\r\n        slotArgs.splice(expectedLen); // remove unused arguments\r\n        node.codegenNode = createCallExpression(context.helper(RENDER_SLOT), slotArgs, loc);\r\n    }\r\n};\r\nfunction processSlotOutlet(node, context) {\r\n    let slotName = `\"default\"`;\r\n    let slotProps = undefined;\r\n    const nonNameProps = [];\r\n    for (let i = 0; i < node.props.length; i++) {\r\n        const p = node.props[i];\r\n        if (p.type === 6 /* ATTRIBUTE */) {\r\n            if (p.value) {\r\n                if (p.name === 'name') {\r\n                    slotName = JSON.stringify(p.value.content);\r\n                }\r\n                else {\r\n                    p.name = camelize(p.name);\r\n                    nonNameProps.push(p);\r\n                }\r\n            }\r\n        }\r\n        else {\r\n            if (p.name === 'bind' && isStaticArgOf(p.arg, 'name')) {\r\n                if (p.exp)\r\n                    slotName = p.exp;\r\n            }\r\n            else {\r\n                if (p.name === 'bind' && p.arg && isStaticExp(p.arg)) {\r\n                    p.arg.content = camelize(p.arg.content);\r\n                }\r\n                nonNameProps.push(p);\r\n            }\r\n        }\r\n    }\r\n    if (nonNameProps.length > 0) {\r\n        const { props, directives } = buildProps(node, context, nonNameProps, false, false);\r\n        slotProps = props;\r\n        if (directives.length) {\r\n            context.onError(createCompilerError(36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */, directives[0].loc));\r\n        }\r\n    }\r\n    return {\r\n        slotName,\r\n        slotProps\r\n    };\r\n}\n\nconst fnExpRE = /^\\s*([\\w$_]+|(async\\s*)?\\([^)]*?\\))\\s*=>|^\\s*(async\\s+)?function(?:\\s+[\\w$]+)?\\s*\\(/;\r\nconst transformOn = (dir, node, context, augmentor) => {\r\n    const { loc, modifiers, arg } = dir;\r\n    if (!dir.exp && !modifiers.length) {\r\n        context.onError(createCompilerError(35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n    }\r\n    let eventName;\r\n    if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n        if (arg.isStatic) {\r\n            let rawName = arg.content;\r\n            // TODO deprecate @vnodeXXX usage\r\n            if (rawName.startsWith('vue:')) {\r\n                rawName = `vnode-${rawName.slice(4)}`;\r\n            }\r\n            // for all event listeners, auto convert it to camelCase. See issue #2249\r\n            eventName = createSimpleExpression(toHandlerKey(camelize$1(rawName)), true, arg.loc);\r\n        }\r\n        else {\r\n            // #2388\r\n            eventName = createCompoundExpression([\r\n                `${context.helperString(TO_HANDLER_KEY)}(`,\r\n                arg,\r\n                `)`\r\n            ]);\r\n        }\r\n    }\r\n    else {\r\n        // already a compound expression.\r\n        eventName = arg;\r\n        eventName.children.unshift(`${context.helperString(TO_HANDLER_KEY)}(`);\r\n        eventName.children.push(`)`);\r\n    }\r\n    // handler processing\r\n    let exp = dir.exp;\r\n    if (exp && !exp.content.trim()) {\r\n        exp = undefined;\r\n    }\r\n    let shouldCache = context.cacheHandlers && !exp && !context.inVOnce;\r\n    if (exp) {\r\n        const isMemberExp = isMemberExpression(exp.content);\r\n        const isInlineStatement = !(isMemberExp || fnExpRE.test(exp.content));\r\n        const hasMultipleStatements = exp.content.includes(`;`);\r\n        if ((process.env.NODE_ENV !== 'production') && true) {\r\n            validateBrowserExpression(exp, context, false, hasMultipleStatements);\r\n        }\r\n        if (isInlineStatement || (shouldCache && isMemberExp)) {\r\n            // wrap inline statement in a function expression\r\n            exp = createCompoundExpression([\r\n                `${isInlineStatement\r\n                    ? `$event`\r\n                    : `${``}(...args)`} => ${hasMultipleStatements ? `{` : `(`}`,\r\n                exp,\r\n                hasMultipleStatements ? `}` : `)`\r\n            ]);\r\n        }\r\n    }\r\n    let ret = {\r\n        props: [\r\n            createObjectProperty(eventName, exp || createSimpleExpression(`() => {}`, false, loc))\r\n        ]\r\n    };\r\n    // apply extended compiler augmentor\r\n    if (augmentor) {\r\n        ret = augmentor(ret);\r\n    }\r\n    if (shouldCache) {\r\n        // cache handlers so that it's always the same handler being passed down.\r\n        // this avoids unnecessary re-renders when users use inline handlers on\r\n        // components.\r\n        ret.props[0].value = context.cache(ret.props[0].value);\r\n    }\r\n    // mark the key as handler for props normalization check\r\n    ret.props.forEach(p => (p.key.isHandlerKey = true));\r\n    return ret;\r\n};\n\n// v-bind without arg is handled directly in ./transformElements.ts due to it affecting\r\n// codegen for the entire props object. This transform here is only for v-bind\r\n// *with* args.\r\nconst transformBind = (dir, _node, context) => {\r\n    const { exp, modifiers, loc } = dir;\r\n    const arg = dir.arg;\r\n    if (arg.type !== 4 /* SIMPLE_EXPRESSION */) {\r\n        arg.children.unshift(`(`);\r\n        arg.children.push(`) || \"\"`);\r\n    }\r\n    else if (!arg.isStatic) {\r\n        arg.content = `${arg.content} || \"\"`;\r\n    }\r\n    // .sync is replaced by v-model:arg\r\n    if (modifiers.includes('camel')) {\r\n        if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n            if (arg.isStatic) {\r\n                arg.content = camelize$1(arg.content);\r\n            }\r\n            else {\r\n                arg.content = `${context.helperString(CAMELIZE)}(${arg.content})`;\r\n            }\r\n        }\r\n        else {\r\n            arg.children.unshift(`${context.helperString(CAMELIZE)}(`);\r\n            arg.children.push(`)`);\r\n        }\r\n    }\r\n    if (!context.inSSR) {\r\n        if (modifiers.includes('prop')) {\r\n            injectPrefix(arg, '.');\r\n        }\r\n        if (modifiers.includes('attr')) {\r\n            injectPrefix(arg, '^');\r\n        }\r\n    }\r\n    if (!exp ||\r\n        (exp.type === 4 /* SIMPLE_EXPRESSION */ && !exp.content.trim())) {\r\n        context.onError(createCompilerError(34 /* X_V_BIND_NO_EXPRESSION */, loc));\r\n        return {\r\n            props: [createObjectProperty(arg, createSimpleExpression('', true, loc))]\r\n        };\r\n    }\r\n    return {\r\n        props: [createObjectProperty(arg, exp)]\r\n    };\r\n};\r\nconst injectPrefix = (arg, prefix) => {\r\n    if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n        if (arg.isStatic) {\r\n            arg.content = prefix + arg.content;\r\n        }\r\n        else {\r\n            arg.content = `\\`${prefix}\\${${arg.content}}\\``;\r\n        }\r\n    }\r\n    else {\r\n        arg.children.unshift(`'${prefix}' + (`);\r\n        arg.children.push(`)`);\r\n    }\r\n};\n\n// Merge adjacent text nodes and expressions into a single expression\r\n// e.g. <div>abc {{ d }} {{ e }}</div> should have a single expression node as child.\r\nconst transformText = (node, context) => {\r\n    if (node.type === 0 /* ROOT */ ||\r\n        node.type === 1 /* ELEMENT */ ||\r\n        node.type === 11 /* FOR */ ||\r\n        node.type === 10 /* IF_BRANCH */) {\r\n        // perform the transform on node exit so that all expressions have already\r\n        // been processed.\r\n        return () => {\r\n            const children = node.children;\r\n            let currentContainer = undefined;\r\n            let hasText = false;\r\n            for (let i = 0; i < children.length; i++) {\r\n                const child = children[i];\r\n                if (isText(child)) {\r\n                    hasText = true;\r\n                    for (let j = i + 1; j < children.length; j++) {\r\n                        const next = children[j];\r\n                        if (isText(next)) {\r\n                            if (!currentContainer) {\r\n                                currentContainer = children[i] = createCompoundExpression([child], child.loc);\r\n                            }\r\n                            // merge adjacent text node into current\r\n                            currentContainer.children.push(` + `, next);\r\n                            children.splice(j, 1);\r\n                            j--;\r\n                        }\r\n                        else {\r\n                            currentContainer = undefined;\r\n                            break;\r\n                        }\r\n                    }\r\n                }\r\n            }\r\n            if (!hasText ||\r\n                // if this is a plain element with a single text child, leave it\r\n                // as-is since the runtime has dedicated fast path for this by directly\r\n                // setting textContent of the element.\r\n                // for component root it's always normalized anyway.\r\n                (children.length === 1 &&\r\n                    (node.type === 0 /* ROOT */ ||\r\n                        (node.type === 1 /* ELEMENT */ &&\r\n                            node.tagType === 0 /* ELEMENT */ &&\r\n                            // #3756\r\n                            // custom directives can potentially add DOM elements arbitrarily,\r\n                            // we need to avoid setting textContent of the element at runtime\r\n                            // to avoid accidentally overwriting the DOM elements added\r\n                            // by the user through custom directives.\r\n                            !node.props.find(p => p.type === 7 /* DIRECTIVE */ &&\r\n                                !context.directiveTransforms[p.name]) &&\r\n                            // in compat mode, <template> tags with no special directives\r\n                            // will be rendered as a fragment so its children must be\r\n                            // converted into vnodes.\r\n                            !(node.tag === 'template'))))) {\r\n                return;\r\n            }\r\n            // pre-convert text nodes into createTextVNode(text) calls to avoid\r\n            // runtime normalization.\r\n            for (let i = 0; i < children.length; i++) {\r\n                const child = children[i];\r\n                if (isText(child) || child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n                    const callArgs = [];\r\n                    // createTextVNode defaults to single whitespace, so if it is a\r\n                    // single space the code could be an empty call to save bytes.\r\n                    if (child.type !== 2 /* TEXT */ || child.content !== ' ') {\r\n                        callArgs.push(child);\r\n                    }\r\n                    // mark dynamic text with flag so it gets patched inside a block\r\n                    if (!context.ssr &&\r\n                        getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n                        callArgs.push(1 /* TEXT */ +\r\n                            ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[1 /* TEXT */]} */` : ``));\r\n                    }\r\n                    children[i] = {\r\n                        type: 12 /* TEXT_CALL */,\r\n                        content: child,\r\n                        loc: child.loc,\r\n                        codegenNode: createCallExpression(context.helper(CREATE_TEXT), callArgs)\r\n                    };\r\n                }\r\n            }\r\n        };\r\n    }\r\n};\n\nconst seen = new WeakSet();\r\nconst transformOnce = (node, context) => {\r\n    if (node.type === 1 /* ELEMENT */ && findDir(node, 'once', true)) {\r\n        if (seen.has(node) || context.inVOnce) {\r\n            return;\r\n        }\r\n        seen.add(node);\r\n        context.inVOnce = true;\r\n        context.helper(SET_BLOCK_TRACKING);\r\n        return () => {\r\n            context.inVOnce = false;\r\n            const cur = context.currentNode;\r\n            if (cur.codegenNode) {\r\n                cur.codegenNode = context.cache(cur.codegenNode, true /* isVNode */);\r\n            }\r\n        };\r\n    }\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n    const { exp, arg } = dir;\r\n    if (!exp) {\r\n        context.onError(createCompilerError(41 /* X_V_MODEL_NO_EXPRESSION */, dir.loc));\r\n        return createTransformProps();\r\n    }\r\n    const rawExp = exp.loc.source;\r\n    const expString = exp.type === 4 /* SIMPLE_EXPRESSION */ ? exp.content : rawExp;\r\n    // im SFC <script setup> inline mode, the exp may have been transformed into\r\n    // _unref(exp)\r\n    context.bindingMetadata[rawExp];\r\n    const maybeRef = !true    /* SETUP_CONST */;\r\n    if (!expString.trim() ||\r\n        (!isMemberExpression(expString) && !maybeRef)) {\r\n        context.onError(createCompilerError(42 /* X_V_MODEL_MALFORMED_EXPRESSION */, exp.loc));\r\n        return createTransformProps();\r\n    }\r\n    const propName = arg ? arg : createSimpleExpression('modelValue', true);\r\n    const eventName = arg\r\n        ? isStaticExp(arg)\r\n            ? `onUpdate:${arg.content}`\r\n            : createCompoundExpression(['\"onUpdate:\" + ', arg])\r\n        : `onUpdate:modelValue`;\r\n    let assignmentExp;\r\n    const eventArg = context.isTS ? `($event: any)` : `$event`;\r\n    {\r\n        assignmentExp = createCompoundExpression([\r\n            `${eventArg} => ((`,\r\n            exp,\r\n            `) = $event)`\r\n        ]);\r\n    }\r\n    const props = [\r\n        // modelValue: foo\r\n        createObjectProperty(propName, dir.exp),\r\n        // \"onUpdate:modelValue\": $event => (foo = $event)\r\n        createObjectProperty(eventName, assignmentExp)\r\n    ];\r\n    // modelModifiers: { foo: true, \"bar-baz\": true }\r\n    if (dir.modifiers.length && node.tagType === 1 /* COMPONENT */) {\r\n        const modifiers = dir.modifiers\r\n            .map(m => (isSimpleIdentifier(m) ? m : JSON.stringify(m)) + `: true`)\r\n            .join(`, `);\r\n        const modifiersKey = arg\r\n            ? isStaticExp(arg)\r\n                ? `${arg.content}Modifiers`\r\n                : createCompoundExpression([arg, ' + \"Modifiers\"'])\r\n            : `modelModifiers`;\r\n        props.push(createObjectProperty(modifiersKey, createSimpleExpression(`{ ${modifiers} }`, false, dir.loc, 2 /* CAN_HOIST */)));\r\n    }\r\n    return createTransformProps(props);\r\n};\r\nfunction createTransformProps(props = []) {\r\n    return { props };\r\n}\n\nconst validDivisionCharRE = /[\\w).+\\-_$\\]]/;\r\nconst transformFilter = (node, context) => {\r\n    if (!isCompatEnabled(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context)) {\r\n        return;\r\n    }\r\n    if (node.type === 5 /* INTERPOLATION */) {\r\n        // filter rewrite is applied before expression transform so only\r\n        // simple expressions are possible at this stage\r\n        rewriteFilter(node.content, context);\r\n    }\r\n    if (node.type === 1 /* ELEMENT */) {\r\n        node.props.forEach((prop) => {\r\n            if (prop.type === 7 /* DIRECTIVE */ &&\r\n                prop.name !== 'for' &&\r\n                prop.exp) {\r\n                rewriteFilter(prop.exp, context);\r\n            }\r\n        });\r\n    }\r\n};\r\nfunction rewriteFilter(node, context) {\r\n    if (node.type === 4 /* SIMPLE_EXPRESSION */) {\r\n        parseFilter(node, context);\r\n    }\r\n    else {\r\n        for (let i = 0; i < node.children.length; i++) {\r\n            const child = node.children[i];\r\n            if (typeof child !== 'object')\r\n                continue;\r\n            if (child.type === 4 /* SIMPLE_EXPRESSION */) {\r\n                parseFilter(child, context);\r\n            }\r\n            else if (child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n                rewriteFilter(node, context);\r\n            }\r\n            else if (child.type === 5 /* INTERPOLATION */) {\r\n                rewriteFilter(child.content, context);\r\n            }\r\n        }\r\n    }\r\n}\r\nfunction parseFilter(node, context) {\r\n    const exp = node.content;\r\n    let inSingle = false;\r\n    let inDouble = false;\r\n    let inTemplateString = false;\r\n    let inRegex = false;\r\n    let curly = 0;\r\n    let square = 0;\r\n    let paren = 0;\r\n    let lastFilterIndex = 0;\r\n    let c, prev, i, expression, filters = [];\r\n    for (i = 0; i < exp.length; i++) {\r\n        prev = c;\r\n        c = exp.charCodeAt(i);\r\n        if (inSingle) {\r\n            if (c === 0x27 && prev !== 0x5c)\r\n                inSingle = false;\r\n        }\r\n        else if (inDouble) {\r\n            if (c === 0x22 && prev !== 0x5c)\r\n                inDouble = false;\r\n        }\r\n        else if (inTemplateString) {\r\n            if (c === 0x60 && prev !== 0x5c)\r\n                inTemplateString = false;\r\n        }\r\n        else if (inRegex) {\r\n            if (c === 0x2f && prev !== 0x5c)\r\n                inRegex = false;\r\n        }\r\n        else if (c === 0x7c && // pipe\r\n            exp.charCodeAt(i + 1) !== 0x7c &&\r\n            exp.charCodeAt(i - 1) !== 0x7c &&\r\n            !curly &&\r\n            !square &&\r\n            !paren) {\r\n            if (expression === undefined) {\r\n                // first filter, end of expression\r\n                lastFilterIndex = i + 1;\r\n                expression = exp.slice(0, i).trim();\r\n            }\r\n            else {\r\n                pushFilter();\r\n            }\r\n        }\r\n        else {\r\n            switch (c) {\r\n                case 0x22:\r\n                    inDouble = true;\r\n                    break; // \"\r\n                case 0x27:\r\n                    inSingle = true;\r\n                    break; // '\r\n                case 0x60:\r\n                    inTemplateString = true;\r\n                    break; // `\r\n                case 0x28:\r\n                    paren++;\r\n                    break; // (\r\n                case 0x29:\r\n                    paren--;\r\n                    break; // )\r\n                case 0x5b:\r\n                    square++;\r\n                    break; // [\r\n                case 0x5d:\r\n                    square--;\r\n                    break; // ]\r\n                case 0x7b:\r\n                    curly++;\r\n                    break; // {\r\n                case 0x7d:\r\n                    curly--;\r\n                    break; // }\r\n            }\r\n            if (c === 0x2f) {\r\n                // /\r\n                let j = i - 1;\r\n                let p;\r\n                // find first non-whitespace prev char\r\n                for (; j >= 0; j--) {\r\n                    p = exp.charAt(j);\r\n                    if (p !== ' ')\r\n                        break;\r\n                }\r\n                if (!p || !validDivisionCharRE.test(p)) {\r\n                    inRegex = true;\r\n                }\r\n            }\r\n        }\r\n    }\r\n    if (expression === undefined) {\r\n        expression = exp.slice(0, i).trim();\r\n    }\r\n    else if (lastFilterIndex !== 0) {\r\n        pushFilter();\r\n    }\r\n    function pushFilter() {\r\n        filters.push(exp.slice(lastFilterIndex, i).trim());\r\n        lastFilterIndex = i + 1;\r\n    }\r\n    if (filters.length) {\r\n        (process.env.NODE_ENV !== 'production') &&\r\n            warnDeprecation(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context, node.loc);\r\n        for (i = 0; i < filters.length; i++) {\r\n            expression = wrapFilter(expression, filters[i], context);\r\n        }\r\n        node.content = expression;\r\n    }\r\n}\r\nfunction wrapFilter(exp, filter, context) {\r\n    context.helper(RESOLVE_FILTER);\r\n    const i = filter.indexOf('(');\r\n    if (i < 0) {\r\n        context.filters.add(filter);\r\n        return `${toValidAssetId(filter, 'filter')}(${exp})`;\r\n    }\r\n    else {\r\n        const name = filter.slice(0, i);\r\n        const args = filter.slice(i + 1);\r\n        context.filters.add(name);\r\n        return `${toValidAssetId(name, 'filter')}(${exp}${args !== ')' ? ',' + args : args}`;\r\n    }\r\n}\n\nconst seen$1 = new WeakSet();\r\nconst transformMemo = (node, context) => {\r\n    if (node.type === 1 /* ELEMENT */) {\r\n        const dir = findDir(node, 'memo');\r\n        if (!dir || seen$1.has(node)) {\r\n            return;\r\n        }\r\n        seen$1.add(node);\r\n        return () => {\r\n            const codegenNode = node.codegenNode ||\r\n                context.currentNode.codegenNode;\r\n            if (codegenNode && codegenNode.type === 13 /* VNODE_CALL */) {\r\n                // non-component sub tree should be turned into a block\r\n                if (node.tagType !== 1 /* COMPONENT */) {\r\n                    makeBlock(codegenNode, context);\r\n                }\r\n                node.codegenNode = createCallExpression(context.helper(WITH_MEMO), [\r\n                    dir.exp,\r\n                    createFunctionExpression(undefined, codegenNode),\r\n                    `_cache`,\r\n                    String(context.cached++)\r\n                ]);\r\n            }\r\n        };\r\n    }\r\n};\n\nfunction getBaseTransformPreset(prefixIdentifiers) {\r\n    return [\r\n        [\r\n            transformOnce,\r\n            transformIf,\r\n            transformMemo,\r\n            transformFor,\r\n            ...([transformFilter] ),\r\n            ...((process.env.NODE_ENV !== 'production')\r\n                    ? [transformExpression]\r\n                    : []),\r\n            transformSlotOutlet,\r\n            transformElement,\r\n            trackSlotScopes,\r\n            transformText\r\n        ],\r\n        {\r\n            on: transformOn,\r\n            bind: transformBind,\r\n            model: transformModel\r\n        }\r\n    ];\r\n}\r\n// we name it `baseCompile` so that higher order compilers like\r\n// @vue/compiler-dom can export `compile` while re-exporting everything else.\r\nfunction baseCompile(template, options = {}) {\r\n    const onError = options.onError || defaultOnError;\r\n    const isModuleMode = options.mode === 'module';\r\n    /* istanbul ignore if */\r\n    {\r\n        if (options.prefixIdentifiers === true) {\r\n            onError(createCompilerError(46 /* X_PREFIX_ID_NOT_SUPPORTED */));\r\n        }\r\n        else if (isModuleMode) {\r\n            onError(createCompilerError(47 /* X_MODULE_MODE_NOT_SUPPORTED */));\r\n        }\r\n    }\r\n    const prefixIdentifiers = !true ;\r\n    if (options.cacheHandlers) {\r\n        onError(createCompilerError(48 /* X_CACHE_HANDLER_NOT_SUPPORTED */));\r\n    }\r\n    if (options.scopeId && !isModuleMode) {\r\n        onError(createCompilerError(49 /* X_SCOPE_ID_NOT_SUPPORTED */));\r\n    }\r\n    const ast = isString(template) ? baseParse(template, options) : template;\r\n    const [nodeTransforms, directiveTransforms] = getBaseTransformPreset();\r\n    transform(ast, extend({}, options, {\r\n        prefixIdentifiers,\r\n        nodeTransforms: [\r\n            ...nodeTransforms,\r\n            ...(options.nodeTransforms || []) // user transforms\r\n        ],\r\n        directiveTransforms: extend({}, directiveTransforms, options.directiveTransforms || {} // user transforms\r\n        )\r\n    }));\r\n    return generate(ast, extend({}, options, {\r\n        prefixIdentifiers\r\n    }));\r\n}\n\nconst noopDirectiveTransform = () => ({ props: [] });\n\nexport { BASE_TRANSITION, CAMELIZE, CAPITALIZE, CREATE_BLOCK, CREATE_COMMENT, CREATE_ELEMENT_BLOCK, CREATE_ELEMENT_VNODE, CREATE_SLOTS, CREATE_STATIC, CREATE_TEXT, CREATE_VNODE, FRAGMENT, GUARD_REACTIVE_PROPS, IS_MEMO_SAME, IS_REF, KEEP_ALIVE, MERGE_PROPS, NORMALIZE_CLASS, NORMALIZE_PROPS, NORMALIZE_STYLE, OPEN_BLOCK, POP_SCOPE_ID, PUSH_SCOPE_ID, RENDER_LIST, RENDER_SLOT, RESOLVE_COMPONENT, RESOLVE_DIRECTIVE, RESOLVE_DYNAMIC_COMPONENT, RESOLVE_FILTER, SET_BLOCK_TRACKING, SUSPENSE, TELEPORT, TO_DISPLAY_STRING, TO_HANDLERS, TO_HANDLER_KEY, UNREF, WITH_CTX, WITH_DIRECTIVES, WITH_MEMO, advancePositionWithClone, advancePositionWithMutation, assert, baseCompile, baseParse, buildDirectiveArgs, buildProps, buildSlots, checkCompatEnabled, createArrayExpression, createAssignmentExpression, createBlockStatement, createCacheExpression, createCallExpression, createCompilerError, createCompoundExpression, createConditionalExpression, createForLoopParams, createFunctionExpression, createIfStatement, createInterpolation, createObjectExpression, createObjectProperty, createReturnStatement, createRoot, createSequenceExpression, createSimpleExpression, createStructuralDirectiveTransform, createTemplateLiteral, createTransformContext, createVNodeCall, extractIdentifiers, findDir, findProp, generate, getBaseTransformPreset, getConstantType, getInnerRange, getMemoedVNodeCall, getVNodeBlockHelper, getVNodeHelper, hasDynamicKeyVBind, hasScopeRef, helperNameMap, injectProp, isBuiltInType, isCoreComponent, isFunctionType, isInDestructureAssignment, isMemberExpression, isMemberExpressionBrowser, isMemberExpressionNode, isReferencedIdentifier, isSimpleIdentifier, isSlotOutlet, isStaticArgOf, isStaticExp, isStaticProperty, isStaticPropertyKey, isTemplateNode, isText, isVSlot, locStub, makeBlock, noopDirectiveTransform, processExpression, processFor, processIf, processSlotOutlet, registerRuntimeHelpers, resolveComponentType, toValidAssetId, trackSlotScopes, trackVForSlotScopes, transform, transformBind, transformElement, transformExpression, transformModel, transformOn, traverseNode, walkBlockDeclarations, walkFunctionParams, walkIdentifiers, warnDeprecation };\n","import { registerRuntimeHelpers, isBuiltInType, createSimpleExpression, createCompilerError, createObjectProperty, getConstantType, createCallExpression, TO_DISPLAY_STRING, transformModel as transformModel$1, findProp, hasDynamicKeyVBind, transformOn as transformOn$1, createCompoundExpression, isStaticExp, checkCompatEnabled, noopDirectiveTransform, baseCompile, baseParse } from '@vue/compiler-core';\nexport * from '@vue/compiler-core';\nimport { isVoidTag, isHTMLTag, isSVGTag, makeMap, parseStringStyle, capitalize, extend } from '@vue/shared';\n\nconst V_MODEL_RADIO = Symbol((process.env.NODE_ENV !== 'production') ? `vModelRadio` : ``);\r\nconst V_MODEL_CHECKBOX = Symbol((process.env.NODE_ENV !== 'production') ? `vModelCheckbox` : ``);\r\nconst V_MODEL_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelText` : ``);\r\nconst V_MODEL_SELECT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelSelect` : ``);\r\nconst V_MODEL_DYNAMIC = Symbol((process.env.NODE_ENV !== 'production') ? `vModelDynamic` : ``);\r\nconst V_ON_WITH_MODIFIERS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnModifiersGuard` : ``);\r\nconst V_ON_WITH_KEYS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnKeysGuard` : ``);\r\nconst V_SHOW = Symbol((process.env.NODE_ENV !== 'production') ? `vShow` : ``);\r\nconst TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `Transition` : ``);\r\nconst TRANSITION_GROUP = Symbol((process.env.NODE_ENV !== 'production') ? `TransitionGroup` : ``);\r\nregisterRuntimeHelpers({\r\n    [V_MODEL_RADIO]: `vModelRadio`,\r\n    [V_MODEL_CHECKBOX]: `vModelCheckbox`,\r\n    [V_MODEL_TEXT]: `vModelText`,\r\n    [V_MODEL_SELECT]: `vModelSelect`,\r\n    [V_MODEL_DYNAMIC]: `vModelDynamic`,\r\n    [V_ON_WITH_MODIFIERS]: `withModifiers`,\r\n    [V_ON_WITH_KEYS]: `withKeys`,\r\n    [V_SHOW]: `vShow`,\r\n    [TRANSITION]: `Transition`,\r\n    [TRANSITION_GROUP]: `TransitionGroup`\r\n});\n\n/* eslint-disable no-restricted-globals */\r\nlet decoder;\r\nfunction decodeHtmlBrowser(raw, asAttr = false) {\r\n    if (!decoder) {\r\n        decoder = document.createElement('div');\r\n    }\r\n    if (asAttr) {\r\n        decoder.innerHTML = `<div foo=\"${raw.replace(/\"/g, '&quot;')}\">`;\r\n        return decoder.children[0].getAttribute('foo');\r\n    }\r\n    else {\r\n        decoder.innerHTML = raw;\r\n        return decoder.textContent;\r\n    }\r\n}\n\nconst isRawTextContainer = /*#__PURE__*/ makeMap('style,iframe,script,noscript', true);\r\nconst parserOptions = {\r\n    isVoidTag,\r\n    isNativeTag: tag => isHTMLTag(tag) || isSVGTag(tag),\r\n    isPreTag: tag => tag === 'pre',\r\n    decodeEntities: decodeHtmlBrowser ,\r\n    isBuiltInComponent: (tag) => {\r\n        if (isBuiltInType(tag, `Transition`)) {\r\n            return TRANSITION;\r\n        }\r\n        else if (isBuiltInType(tag, `TransitionGroup`)) {\r\n            return TRANSITION_GROUP;\r\n        }\r\n    },\r\n    // https://html.spec.whatwg.org/multipage/parsing.html#tree-construction-dispatcher\r\n    getNamespace(tag, parent) {\r\n        let ns = parent ? parent.ns : 0 /* HTML */;\r\n        if (parent && ns === 2 /* MATH_ML */) {\r\n            if (parent.tag === 'annotation-xml') {\r\n                if (tag === 'svg') {\r\n                    return 1 /* SVG */;\r\n                }\r\n                if (parent.props.some(a => a.type === 6 /* ATTRIBUTE */ &&\r\n                    a.name === 'encoding' &&\r\n                    a.value != null &&\r\n                    (a.value.content === 'text/html' ||\r\n                        a.value.content === 'application/xhtml+xml'))) {\r\n                    ns = 0 /* HTML */;\r\n                }\r\n            }\r\n            else if (/^m(?:[ions]|text)$/.test(parent.tag) &&\r\n                tag !== 'mglyph' &&\r\n                tag !== 'malignmark') {\r\n                ns = 0 /* HTML */;\r\n            }\r\n        }\r\n        else if (parent && ns === 1 /* SVG */) {\r\n            if (parent.tag === 'foreignObject' ||\r\n                parent.tag === 'desc' ||\r\n                parent.tag === 'title') {\r\n                ns = 0 /* HTML */;\r\n            }\r\n        }\r\n        if (ns === 0 /* HTML */) {\r\n            if (tag === 'svg') {\r\n                return 1 /* SVG */;\r\n            }\r\n            if (tag === 'math') {\r\n                return 2 /* MATH_ML */;\r\n            }\r\n        }\r\n        return ns;\r\n    },\r\n    // https://html.spec.whatwg.org/multipage/parsing.html#parsing-html-fragments\r\n    getTextMode({ tag, ns }) {\r\n        if (ns === 0 /* HTML */) {\r\n            if (tag === 'textarea' || tag === 'title') {\r\n                return 1 /* RCDATA */;\r\n            }\r\n            if (isRawTextContainer(tag)) {\r\n                return 2 /* RAWTEXT */;\r\n            }\r\n        }\r\n        return 0 /* DATA */;\r\n    }\r\n};\n\n// Parse inline CSS strings for static style attributes into an object.\r\n// This is a NodeTransform since it works on the static `style` attribute and\r\n// converts it into a dynamic equivalent:\r\n// style=\"color: red\" -> :style='{ \"color\": \"red\" }'\r\n// It is then processed by `transformElement` and included in the generated\r\n// props.\r\nconst transformStyle = node => {\r\n    if (node.type === 1 /* ELEMENT */) {\r\n        node.props.forEach((p, i) => {\r\n            if (p.type === 6 /* ATTRIBUTE */ && p.name === 'style' && p.value) {\r\n                // replace p with an expression node\r\n                node.props[i] = {\r\n                    type: 7 /* DIRECTIVE */,\r\n                    name: `bind`,\r\n                    arg: createSimpleExpression(`style`, true, p.loc),\r\n                    exp: parseInlineCSS(p.value.content, p.loc),\r\n                    modifiers: [],\r\n                    loc: p.loc\r\n                };\r\n            }\r\n        });\r\n    }\r\n};\r\nconst parseInlineCSS = (cssText, loc) => {\r\n    const normalized = parseStringStyle(cssText);\r\n    return createSimpleExpression(JSON.stringify(normalized), false, loc, 3 /* CAN_STRINGIFY */);\r\n};\n\nfunction createDOMCompilerError(code, loc) {\r\n    return createCompilerError(code, loc, (process.env.NODE_ENV !== 'production') || !true ? DOMErrorMessages : undefined);\r\n}\r\nconst DOMErrorMessages = {\r\n    [50 /* X_V_HTML_NO_EXPRESSION */]: `v-html is missing expression.`,\r\n    [51 /* X_V_HTML_WITH_CHILDREN */]: `v-html will override element children.`,\r\n    [52 /* X_V_TEXT_NO_EXPRESSION */]: `v-text is missing expression.`,\r\n    [53 /* X_V_TEXT_WITH_CHILDREN */]: `v-text will override element children.`,\r\n    [54 /* X_V_MODEL_ON_INVALID_ELEMENT */]: `v-model can only be used on <input>, <textarea> and <select> elements.`,\r\n    [55 /* X_V_MODEL_ARG_ON_ELEMENT */]: `v-model argument is not supported on plain elements.`,\r\n    [56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */]: `v-model cannot be used on file inputs since they are read-only. Use a v-on:change listener instead.`,\r\n    [57 /* X_V_MODEL_UNNECESSARY_VALUE */]: `Unnecessary value binding used alongside v-model. It will interfere with v-model's behavior.`,\r\n    [58 /* X_V_SHOW_NO_EXPRESSION */]: `v-show is missing expression.`,\r\n    [59 /* X_TRANSITION_INVALID_CHILDREN */]: `<Transition> expects exactly one child element or component.`,\r\n    [60 /* X_IGNORED_SIDE_EFFECT_TAG */]: `Tags with side effect (<script> and <style>) are ignored in client component templates.`\r\n};\n\nconst transformVHtml = (dir, node, context) => {\r\n    const { exp, loc } = dir;\r\n    if (!exp) {\r\n        context.onError(createDOMCompilerError(50 /* X_V_HTML_NO_EXPRESSION */, loc));\r\n    }\r\n    if (node.children.length) {\r\n        context.onError(createDOMCompilerError(51 /* X_V_HTML_WITH_CHILDREN */, loc));\r\n        node.children.length = 0;\r\n    }\r\n    return {\r\n        props: [\r\n            createObjectProperty(createSimpleExpression(`innerHTML`, true, loc), exp || createSimpleExpression('', true))\r\n        ]\r\n    };\r\n};\n\nconst transformVText = (dir, node, context) => {\r\n    const { exp, loc } = dir;\r\n    if (!exp) {\r\n        context.onError(createDOMCompilerError(52 /* X_V_TEXT_NO_EXPRESSION */, loc));\r\n    }\r\n    if (node.children.length) {\r\n        context.onError(createDOMCompilerError(53 /* X_V_TEXT_WITH_CHILDREN */, loc));\r\n        node.children.length = 0;\r\n    }\r\n    return {\r\n        props: [\r\n            createObjectProperty(createSimpleExpression(`textContent`, true), exp\r\n                ? getConstantType(exp, context) > 0\r\n                    ? exp\r\n                    : createCallExpression(context.helperString(TO_DISPLAY_STRING), [exp], loc)\r\n                : createSimpleExpression('', true))\r\n        ]\r\n    };\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n    const baseResult = transformModel$1(dir, node, context);\r\n    // base transform has errors OR component v-model (only need props)\r\n    if (!baseResult.props.length || node.tagType === 1 /* COMPONENT */) {\r\n        return baseResult;\r\n    }\r\n    if (dir.arg) {\r\n        context.onError(createDOMCompilerError(55 /* X_V_MODEL_ARG_ON_ELEMENT */, dir.arg.loc));\r\n    }\r\n    function checkDuplicatedValue() {\r\n        const value = findProp(node, 'value');\r\n        if (value) {\r\n            context.onError(createDOMCompilerError(57 /* X_V_MODEL_UNNECESSARY_VALUE */, value.loc));\r\n        }\r\n    }\r\n    const { tag } = node;\r\n    const isCustomElement = context.isCustomElement(tag);\r\n    if (tag === 'input' ||\r\n        tag === 'textarea' ||\r\n        tag === 'select' ||\r\n        isCustomElement) {\r\n        let directiveToUse = V_MODEL_TEXT;\r\n        let isInvalidType = false;\r\n        if (tag === 'input' || isCustomElement) {\r\n            const type = findProp(node, `type`);\r\n            if (type) {\r\n                if (type.type === 7 /* DIRECTIVE */) {\r\n                    // :type=\"foo\"\r\n                    directiveToUse = V_MODEL_DYNAMIC;\r\n                }\r\n                else if (type.value) {\r\n                    switch (type.value.content) {\r\n                        case 'radio':\r\n                            directiveToUse = V_MODEL_RADIO;\r\n                            break;\r\n                        case 'checkbox':\r\n                            directiveToUse = V_MODEL_CHECKBOX;\r\n                            break;\r\n                        case 'file':\r\n                            isInvalidType = true;\r\n                            context.onError(createDOMCompilerError(56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */, dir.loc));\r\n                            break;\r\n                        default:\r\n                            // text type\r\n                            (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n                            break;\r\n                    }\r\n                }\r\n            }\r\n            else if (hasDynamicKeyVBind(node)) {\r\n                // element has bindings with dynamic keys, which can possibly contain\r\n                // \"type\".\r\n                directiveToUse = V_MODEL_DYNAMIC;\r\n            }\r\n            else {\r\n                // text type\r\n                (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n            }\r\n        }\r\n        else if (tag === 'select') {\r\n            directiveToUse = V_MODEL_SELECT;\r\n        }\r\n        else {\r\n            // textarea\r\n            (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n        }\r\n        // inject runtime directive\r\n        // by returning the helper symbol via needRuntime\r\n        // the import will replaced a resolveDirective call.\r\n        if (!isInvalidType) {\r\n            baseResult.needRuntime = context.helper(directiveToUse);\r\n        }\r\n    }\r\n    else {\r\n        context.onError(createDOMCompilerError(54 /* X_V_MODEL_ON_INVALID_ELEMENT */, dir.loc));\r\n    }\r\n    // native vmodel doesn't need the `modelValue` props since they are also\r\n    // passed to the runtime as `binding.value`. removing it reduces code size.\r\n    baseResult.props = baseResult.props.filter(p => !(p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n        p.key.content === 'modelValue'));\r\n    return baseResult;\r\n};\n\nconst isEventOptionModifier = /*#__PURE__*/ makeMap(`passive,once,capture`);\r\nconst isNonKeyModifier = /*#__PURE__*/ makeMap(\r\n// event propagation management\r\n`stop,prevent,self,` +\r\n    // system modifiers + exact\r\n    `ctrl,shift,alt,meta,exact,` +\r\n    // mouse\r\n    `middle`);\r\n// left & right could be mouse or key modifiers based on event type\r\nconst maybeKeyModifier = /*#__PURE__*/ makeMap('left,right');\r\nconst isKeyboardEvent = /*#__PURE__*/ makeMap(`onkeyup,onkeydown,onkeypress`, true);\r\nconst resolveModifiers = (key, modifiers, context, loc) => {\r\n    const keyModifiers = [];\r\n    const nonKeyModifiers = [];\r\n    const eventOptionModifiers = [];\r\n    for (let i = 0; i < modifiers.length; i++) {\r\n        const modifier = modifiers[i];\r\n        if (modifier === 'native' &&\r\n            checkCompatEnabled(\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */, context, loc)) {\r\n            eventOptionModifiers.push(modifier);\r\n        }\r\n        else if (isEventOptionModifier(modifier)) {\r\n            // eventOptionModifiers: modifiers for addEventListener() options,\r\n            // e.g. .passive & .capture\r\n            eventOptionModifiers.push(modifier);\r\n        }\r\n        else {\r\n            // runtimeModifiers: modifiers that needs runtime guards\r\n            if (maybeKeyModifier(modifier)) {\r\n                if (isStaticExp(key)) {\r\n                    if (isKeyboardEvent(key.content)) {\r\n                        keyModifiers.push(modifier);\r\n                    }\r\n                    else {\r\n                        nonKeyModifiers.push(modifier);\r\n                    }\r\n                }\r\n                else {\r\n                    keyModifiers.push(modifier);\r\n                    nonKeyModifiers.push(modifier);\r\n                }\r\n            }\r\n            else {\r\n                if (isNonKeyModifier(modifier)) {\r\n                    nonKeyModifiers.push(modifier);\r\n                }\r\n                else {\r\n                    keyModifiers.push(modifier);\r\n                }\r\n            }\r\n        }\r\n    }\r\n    return {\r\n        keyModifiers,\r\n        nonKeyModifiers,\r\n        eventOptionModifiers\r\n    };\r\n};\r\nconst transformClick = (key, event) => {\r\n    const isStaticClick = isStaticExp(key) && key.content.toLowerCase() === 'onclick';\r\n    return isStaticClick\r\n        ? createSimpleExpression(event, true)\r\n        : key.type !== 4 /* SIMPLE_EXPRESSION */\r\n            ? createCompoundExpression([\r\n                `(`,\r\n                key,\r\n                `) === \"onClick\" ? \"${event}\" : (`,\r\n                key,\r\n                `)`\r\n            ])\r\n            : key;\r\n};\r\nconst transformOn = (dir, node, context) => {\r\n    return transformOn$1(dir, node, context, baseResult => {\r\n        const { modifiers } = dir;\r\n        if (!modifiers.length)\r\n            return baseResult;\r\n        let { key, value: handlerExp } = baseResult.props[0];\r\n        const { keyModifiers, nonKeyModifiers, eventOptionModifiers } = resolveModifiers(key, modifiers, context, dir.loc);\r\n        // normalize click.right and click.middle since they don't actually fire\r\n        if (nonKeyModifiers.includes('right')) {\r\n            key = transformClick(key, `onContextmenu`);\r\n        }\r\n        if (nonKeyModifiers.includes('middle')) {\r\n            key = transformClick(key, `onMouseup`);\r\n        }\r\n        if (nonKeyModifiers.length) {\r\n            handlerExp = createCallExpression(context.helper(V_ON_WITH_MODIFIERS), [\r\n                handlerExp,\r\n                JSON.stringify(nonKeyModifiers)\r\n            ]);\r\n        }\r\n        if (keyModifiers.length &&\r\n            // if event name is dynamic, always wrap with keys guard\r\n            (!isStaticExp(key) || isKeyboardEvent(key.content))) {\r\n            handlerExp = createCallExpression(context.helper(V_ON_WITH_KEYS), [\r\n                handlerExp,\r\n                JSON.stringify(keyModifiers)\r\n            ]);\r\n        }\r\n        if (eventOptionModifiers.length) {\r\n            const modifierPostfix = eventOptionModifiers.map(capitalize).join('');\r\n            key = isStaticExp(key)\r\n                ? createSimpleExpression(`${key.content}${modifierPostfix}`, true)\r\n                : createCompoundExpression([`(`, key, `) + \"${modifierPostfix}\"`]);\r\n        }\r\n        return {\r\n            props: [createObjectProperty(key, handlerExp)]\r\n        };\r\n    });\r\n};\n\nconst transformShow = (dir, node, context) => {\r\n    const { exp, loc } = dir;\r\n    if (!exp) {\r\n        context.onError(createDOMCompilerError(58 /* X_V_SHOW_NO_EXPRESSION */, loc));\r\n    }\r\n    return {\r\n        props: [],\r\n        needRuntime: context.helper(V_SHOW)\r\n    };\r\n};\n\nconst transformTransition = (node, context) => {\r\n    if (node.type === 1 /* ELEMENT */ &&\r\n        node.tagType === 1 /* COMPONENT */) {\r\n        const component = context.isBuiltInComponent(node.tag);\r\n        if (component === TRANSITION) {\r\n            return () => {\r\n                if (!node.children.length) {\r\n                    return;\r\n                }\r\n                // warn multiple transition children\r\n                if (hasMultipleChildren(node)) {\r\n                    context.onError(createDOMCompilerError(59 /* X_TRANSITION_INVALID_CHILDREN */, {\r\n                        start: node.children[0].loc.start,\r\n                        end: node.children[node.children.length - 1].loc.end,\r\n                        source: ''\r\n                    }));\r\n                }\r\n                // check if it's s single child w/ v-show\r\n                // if yes, inject \"persisted: true\" to the transition props\r\n                const child = node.children[0];\r\n                if (child.type === 1 /* ELEMENT */) {\r\n                    for (const p of child.props) {\r\n                        if (p.type === 7 /* DIRECTIVE */ && p.name === 'show') {\r\n                            node.props.push({\r\n                                type: 6 /* ATTRIBUTE */,\r\n                                name: 'persisted',\r\n                                value: undefined,\r\n                                loc: node.loc\r\n                            });\r\n                        }\r\n                    }\r\n                }\r\n            };\r\n        }\r\n    }\r\n};\r\nfunction hasMultipleChildren(node) {\r\n    // #1352 filter out potential comment nodes.\r\n    const children = (node.children = node.children.filter(c => c.type !== 3 /* COMMENT */ &&\r\n        !(c.type === 2 /* TEXT */ && !c.content.trim())));\r\n    const child = children[0];\r\n    return (children.length !== 1 ||\r\n        child.type === 11 /* FOR */ ||\r\n        (child.type === 9 /* IF */ && child.branches.some(hasMultipleChildren)));\r\n}\n\nconst ignoreSideEffectTags = (node, context) => {\r\n    if (node.type === 1 /* ELEMENT */ &&\r\n        node.tagType === 0 /* ELEMENT */ &&\r\n        (node.tag === 'script' || node.tag === 'style')) {\r\n        context.onError(createDOMCompilerError(60 /* X_IGNORED_SIDE_EFFECT_TAG */, node.loc));\r\n        context.removeNode();\r\n    }\r\n};\n\nconst DOMNodeTransforms = [\r\n    transformStyle,\r\n    ...((process.env.NODE_ENV !== 'production') ? [transformTransition] : [])\r\n];\r\nconst DOMDirectiveTransforms = {\r\n    cloak: noopDirectiveTransform,\r\n    html: transformVHtml,\r\n    text: transformVText,\r\n    model: transformModel,\r\n    on: transformOn,\r\n    show: transformShow\r\n};\r\nfunction compile(template, options = {}) {\r\n    return baseCompile(template, extend({}, parserOptions, options, {\r\n        nodeTransforms: [\r\n            // ignore <script> and <tag>\r\n            // this is not put inside DOMNodeTransforms because that list is used\r\n            // by compiler-ssr to generate vnode fallback branches\r\n            ignoreSideEffectTags,\r\n            ...DOMNodeTransforms,\r\n            ...(options.nodeTransforms || [])\r\n        ],\r\n        directiveTransforms: extend({}, DOMDirectiveTransforms, options.directiveTransforms || {}),\r\n        transformHoist: null \r\n    }));\r\n}\r\nfunction parse(template, options = {}) {\r\n    return baseParse(template, extend({}, parserOptions, options));\r\n}\n\nexport { DOMDirectiveTransforms, DOMNodeTransforms, TRANSITION, TRANSITION_GROUP, V_MODEL_CHECKBOX, V_MODEL_DYNAMIC, V_MODEL_RADIO, V_MODEL_SELECT, V_MODEL_TEXT, V_ON_WITH_KEYS, V_ON_WITH_MODIFIERS, V_SHOW, compile, createDOMCompilerError, parse, parserOptions, transformStyle };\n","import * as runtimeDom from '@vue/runtime-dom';\nimport { initCustomFormatter, warn, registerRuntimeCompiler } from '@vue/runtime-dom';\nexport * from '@vue/runtime-dom';\nimport { compile } from '@vue/compiler-dom';\nimport { isString, NOOP, extend, generateCodeFrame } from '@vue/shared';\n\nfunction initDev() {\r\n    {\r\n        initCustomFormatter();\r\n    }\r\n}\n\n// This entry is the \"full-build\" that includes both the runtime\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n    initDev();\r\n}\r\nconst compileCache = Object.create(null);\r\nfunction compileToFunction(template, options) {\r\n    if (!isString(template)) {\r\n        if (template.nodeType) {\r\n            template = template.innerHTML;\r\n        }\r\n        else {\r\n            (process.env.NODE_ENV !== 'production') && warn(`invalid template option: `, template);\r\n            return NOOP;\r\n        }\r\n    }\r\n    const key = template;\r\n    const cached = compileCache[key];\r\n    if (cached) {\r\n        return cached;\r\n    }\r\n    if (template[0] === '#') {\r\n        const el = document.querySelector(template);\r\n        if ((process.env.NODE_ENV !== 'production') && !el) {\r\n            warn(`Template element not found or is empty: ${template}`);\r\n        }\r\n        // __UNSAFE__\r\n        // Reason: potential execution of JS expressions in in-DOM template.\r\n        // The user must make sure the in-DOM template is trusted. If it's rendered\r\n        // by the server, the template should not contain any user data.\r\n        template = el ? el.innerHTML : ``;\r\n    }\r\n    const { code } = compile(template, extend({\r\n        hoistStatic: true,\r\n        onError: (process.env.NODE_ENV !== 'production') ? onError : undefined,\r\n        onWarn: (process.env.NODE_ENV !== 'production') ? e => onError(e, true) : NOOP\r\n    }, options));\r\n    function onError(err, asWarning = false) {\r\n        const message = asWarning\r\n            ? err.message\r\n            : `Template compilation error: ${err.message}`;\r\n        const codeFrame = err.loc &&\r\n            generateCodeFrame(template, err.loc.start.offset, err.loc.end.offset);\r\n        warn(codeFrame ? `${message}\\n${codeFrame}` : message);\r\n    }\r\n    // The wildcard import results in a huge object with every export\r\n    // with keys that cannot be mangled, and can be quite heavy size-wise.\r\n    // In the global build we know `Vue` is available globally so we can avoid\r\n    // the wildcard object.\r\n    const render = (new Function('Vue', code)(runtimeDom));\r\n    render._rc = true;\r\n    return (compileCache[key] = render);\r\n}\r\nregisterRuntimeCompiler(compileToFunction);\n\nexport { compileToFunction as compile };\n","import * as Vue from 'vue'\n\nvar isVue2 = false\nvar isVue3 = true\nvar Vue2 = undefined\n\nfunction install() {}\n\nexport function set(target, key, val) {\n  if (Array.isArray(target)) {\n    target.length = Math.max(target.length, key)\n    target.splice(key, 1, val)\n    return val\n  }\n  target[key] = val\n  return val\n}\n\nexport function del(target, key) {\n  if (Array.isArray(target)) {\n    target.splice(key, 1)\n    return\n  }\n  delete target[key]\n}\n\nexport * from 'vue'\nexport {\n  Vue,\n  Vue2,\n  isVue2,\n  isVue3,\n  install,\n}\n","/*!\n  * pinia v2.0.23\n  * (c) 2022 Eduardo San Martin Morote\n  * @license MIT\n  */\nimport { getCurrentInstance, inject, toRaw, watch, unref, markRaw, effectScope, ref, isVue2, isRef, isReactive, set, onUnmounted, reactive, toRef, del, nextTick, computed, toRefs } from 'vue-demi';\nimport { setupDevtoolsPlugin } from '@vue/devtools-api';\n\n/**\r\n * setActivePinia must be called to handle SSR at the top of functions like\r\n * `fetch`, `setup`, `serverPrefetch` and others\r\n */\r\nlet activePinia;\r\n/**\r\n * Sets or unsets the active pinia. Used in SSR and internally when calling\r\n * actions and getters\r\n *\r\n * @param pinia - Pinia instance\r\n */\r\nconst setActivePinia = (pinia) => (activePinia = pinia);\r\n/**\r\n * Get the currently active pinia if there is any.\r\n */\r\nconst getActivePinia = () => (getCurrentInstance() && inject(piniaSymbol)) || activePinia;\r\nconst piniaSymbol = ((process.env.NODE_ENV !== 'production') ? Symbol('pinia') : /* istanbul ignore next */ Symbol());\n\nfunction isPlainObject(\r\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\r\no) {\r\n    return (o &&\r\n        typeof o === 'object' &&\r\n        Object.prototype.toString.call(o) === '[object Object]' &&\r\n        typeof o.toJSON !== 'function');\r\n}\r\n// type DeepReadonly<T> = { readonly [P in keyof T]: DeepReadonly<T[P]> }\r\n// TODO: can we change these to numbers?\r\n/**\r\n * Possible types for SubscriptionCallback\r\n */\r\nvar MutationType;\r\n(function (MutationType) {\r\n    /**\r\n     * Direct mutation of the state:\r\n     *\r\n     * - `store.name = 'new name'`\r\n     * - `store.$state.name = 'new name'`\r\n     * - `store.list.push('new item')`\r\n     */\r\n    MutationType[\"direct\"] = \"direct\";\r\n    /**\r\n     * Mutated the state with `$patch` and an object\r\n     *\r\n     * - `store.$patch({ name: 'newName' })`\r\n     */\r\n    MutationType[\"patchObject\"] = \"patch object\";\r\n    /**\r\n     * Mutated the state with `$patch` and a function\r\n     *\r\n     * - `store.$patch(state => state.name = 'newName')`\r\n     */\r\n    MutationType[\"patchFunction\"] = \"patch function\";\r\n    // maybe reset? for $state = {} and $reset\r\n})(MutationType || (MutationType = {}));\n\nconst IS_CLIENT = typeof window !== 'undefined';\r\n/**\r\n * Should we add the devtools plugins.\r\n * - only if dev mode or forced through the prod devtools flag\r\n * - not in test\r\n * - only if window exists (could change in the future)\r\n */\r\nconst USE_DEVTOOLS = ((process.env.NODE_ENV !== 'production') || (typeof __VUE_PROD_DEVTOOLS__ !== 'undefined' && __VUE_PROD_DEVTOOLS__)) && !(process.env.NODE_ENV === 'test') && IS_CLIENT;\n\n/*\r\n * FileSaver.js A saveAs() FileSaver implementation.\r\n *\r\n * Originally by Eli Grey, adapted as an ESM module by Eduardo San Martin\r\n * Morote.\r\n *\r\n * License : MIT\r\n */\r\n// The one and only way of getting global scope in all environments\r\n// https://stackoverflow.com/q/3277182/1008999\r\nconst _global = /*#__PURE__*/ (() => typeof window === 'object' && window.window === window\r\n    ? window\r\n    : typeof self === 'object' && self.self === self\r\n        ? self\r\n        : typeof global === 'object' && global.global === global\r\n            ? global\r\n            : typeof globalThis === 'object'\r\n                ? globalThis\r\n                : { HTMLElement: null })();\r\nfunction bom(blob, { autoBom = false } = {}) {\r\n    // prepend BOM for UTF-8 XML and text/* types (including HTML)\r\n    // note: your browser will automatically convert UTF-16 U+FEFF to EF BB BF\r\n    if (autoBom &&\r\n        /^\\s*(?:text\\/\\S*|application\\/xml|\\S*\\/\\S*\\+xml)\\s*;.*charset\\s*=\\s*utf-8/i.test(blob.type)) {\r\n        return new Blob([String.fromCharCode(0xfeff), blob], { type: blob.type });\r\n    }\r\n    return blob;\r\n}\r\nfunction download(url, name, opts) {\r\n    const xhr = new XMLHttpRequest();\r\n    xhr.open('GET', url);\r\n    xhr.responseType = 'blob';\r\n    xhr.onload = function () {\r\n        saveAs(xhr.response, name, opts);\r\n    };\r\n    xhr.onerror = function () {\r\n        console.error('could not download file');\r\n    };\r\n    xhr.send();\r\n}\r\nfunction corsEnabled(url) {\r\n    const xhr = new XMLHttpRequest();\r\n    // use sync to avoid popup blocker\r\n    xhr.open('HEAD', url, false);\r\n    try {\r\n        xhr.send();\r\n    }\r\n    catch (e) { }\r\n    return xhr.status >= 200 && xhr.status <= 299;\r\n}\r\n// `a.click()` doesn't work for all browsers (#465)\r\nfunction click(node) {\r\n    try {\r\n        node.dispatchEvent(new MouseEvent('click'));\r\n    }\r\n    catch (e) {\r\n        const evt = document.createEvent('MouseEvents');\r\n        evt.initMouseEvent('click', true, true, window, 0, 0, 0, 80, 20, false, false, false, false, 0, null);\r\n        node.dispatchEvent(evt);\r\n    }\r\n}\r\nconst _navigator = \r\n typeof navigator === 'object' ? navigator : { userAgent: '' };\r\n// Detect WebView inside a native macOS app by ruling out all browsers\r\n// We just need to check for 'Safari' because all other browsers (besides Firefox) include that too\r\n// https://www.whatismybrowser.com/guides/the-latest-user-agent/macos\r\nconst isMacOSWebView = /*#__PURE__*/ (() => /Macintosh/.test(_navigator.userAgent) &&\r\n    /AppleWebKit/.test(_navigator.userAgent) &&\r\n    !/Safari/.test(_navigator.userAgent))();\r\nconst saveAs = !IS_CLIENT\r\n    ? () => { } // noop\r\n    : // Use download attribute first if possible (#193 Lumia mobile) unless this is a macOS WebView or mini program\r\n        typeof HTMLAnchorElement !== 'undefined' &&\r\n            'download' in HTMLAnchorElement.prototype &&\r\n            !isMacOSWebView\r\n            ? downloadSaveAs\r\n            : // Use msSaveOrOpenBlob as a second approach\r\n                'msSaveOrOpenBlob' in _navigator\r\n                    ? msSaveAs\r\n                    : // Fallback to using FileReader and a popup\r\n                        fileSaverSaveAs;\r\nfunction downloadSaveAs(blob, name = 'download', opts) {\r\n    const a = document.createElement('a');\r\n    a.download = name;\r\n    a.rel = 'noopener'; // tabnabbing\r\n    // TODO: detect chrome extensions & packaged apps\r\n    // a.target = '_blank'\r\n    if (typeof blob === 'string') {\r\n        // Support regular links\r\n        a.href = blob;\r\n        if (a.origin !== location.origin) {\r\n            if (corsEnabled(a.href)) {\r\n                download(blob, name, opts);\r\n            }\r\n            else {\r\n                a.target = '_blank';\r\n                click(a);\r\n            }\r\n        }\r\n        else {\r\n            click(a);\r\n        }\r\n    }\r\n    else {\r\n        // Support blobs\r\n        a.href = URL.createObjectURL(blob);\r\n        setTimeout(function () {\r\n            URL.revokeObjectURL(a.href);\r\n        }, 4e4); // 40s\r\n        setTimeout(function () {\r\n            click(a);\r\n        }, 0);\r\n    }\r\n}\r\nfunction msSaveAs(blob, name = 'download', opts) {\r\n    if (typeof blob === 'string') {\r\n        if (corsEnabled(blob)) {\r\n            download(blob, name, opts);\r\n        }\r\n        else {\r\n            const a = document.createElement('a');\r\n            a.href = blob;\r\n            a.target = '_blank';\r\n            setTimeout(function () {\r\n                click(a);\r\n            });\r\n        }\r\n    }\r\n    else {\r\n        // @ts-ignore: works on windows\r\n        navigator.msSaveOrOpenBlob(bom(blob, opts), name);\r\n    }\r\n}\r\nfunction fileSaverSaveAs(blob, name, opts, popup) {\r\n    // Open a popup immediately do go around popup blocker\r\n    // Mostly only available on user interaction and the fileReader is async so...\r\n    popup = popup || open('', '_blank');\r\n    if (popup) {\r\n        popup.document.title = popup.document.body.innerText = 'downloading...';\r\n    }\r\n    if (typeof blob === 'string')\r\n        return download(blob, name, opts);\r\n    const force = blob.type === 'application/octet-stream';\r\n    const isSafari = /constructor/i.test(String(_global.HTMLElement)) || 'safari' in _global;\r\n    const isChromeIOS = /CriOS\\/[\\d]+/.test(navigator.userAgent);\r\n    if ((isChromeIOS || (force && isSafari) || isMacOSWebView) &&\r\n        typeof FileReader !== 'undefined') {\r\n        // Safari doesn't allow downloading of blob URLs\r\n        const reader = new FileReader();\r\n        reader.onloadend = function () {\r\n            let url = reader.result;\r\n            if (typeof url !== 'string') {\r\n                popup = null;\r\n                throw new Error('Wrong reader.result type');\r\n            }\r\n            url = isChromeIOS\r\n                ? url\r\n                : url.replace(/^data:[^;]*;/, 'data:attachment/file;');\r\n            if (popup) {\r\n                popup.location.href = url;\r\n            }\r\n            else {\r\n                location.assign(url);\r\n            }\r\n            popup = null; // reverse-tabnabbing #460\r\n        };\r\n        reader.readAsDataURL(blob);\r\n    }\r\n    else {\r\n        const url = URL.createObjectURL(blob);\r\n        if (popup)\r\n            popup.location.assign(url);\r\n        else\r\n            location.href = url;\r\n        popup = null; // reverse-tabnabbing #460\r\n        setTimeout(function () {\r\n            URL.revokeObjectURL(url);\r\n        }, 4e4); // 40s\r\n    }\r\n}\n\n/**\r\n * Shows a toast or console.log\r\n *\r\n * @param message - message to log\r\n * @param type - different color of the tooltip\r\n */\r\nfunction toastMessage(message, type) {\r\n    const piniaMessage = '🍍 ' + message;\r\n    if (typeof __VUE_DEVTOOLS_TOAST__ === 'function') {\r\n        __VUE_DEVTOOLS_TOAST__(piniaMessage, type);\r\n    }\r\n    else if (type === 'error') {\r\n        console.error(piniaMessage);\r\n    }\r\n    else if (type === 'warn') {\r\n        console.warn(piniaMessage);\r\n    }\r\n    else {\r\n        console.log(piniaMessage);\r\n    }\r\n}\r\nfunction isPinia(o) {\r\n    return '_a' in o && 'install' in o;\r\n}\n\nfunction checkClipboardAccess() {\r\n    if (!('clipboard' in navigator)) {\r\n        toastMessage(`Your browser doesn't support the Clipboard API`, 'error');\r\n        return true;\r\n    }\r\n}\r\nfunction checkNotFocusedError(error) {\r\n    if (error instanceof Error &&\r\n        error.message.toLowerCase().includes('document is not focused')) {\r\n        toastMessage('You need to activate the \"Emulate a focused page\" setting in the \"Rendering\" panel of devtools.', 'warn');\r\n        return true;\r\n    }\r\n    return false;\r\n}\r\nasync function actionGlobalCopyState(pinia) {\r\n    if (checkClipboardAccess())\r\n        return;\r\n    try {\r\n        await navigator.clipboard.writeText(JSON.stringify(pinia.state.value));\r\n        toastMessage('Global state copied to clipboard.');\r\n    }\r\n    catch (error) {\r\n        if (checkNotFocusedError(error))\r\n            return;\r\n        toastMessage(`Failed to serialize the state. Check the console for more details.`, 'error');\r\n        console.error(error);\r\n    }\r\n}\r\nasync function actionGlobalPasteState(pinia) {\r\n    if (checkClipboardAccess())\r\n        return;\r\n    try {\r\n        pinia.state.value = JSON.parse(await navigator.clipboard.readText());\r\n        toastMessage('Global state pasted from clipboard.');\r\n    }\r\n    catch (error) {\r\n        if (checkNotFocusedError(error))\r\n            return;\r\n        toastMessage(`Failed to deserialize the state from clipboard. Check the console for more details.`, 'error');\r\n        console.error(error);\r\n    }\r\n}\r\nasync function actionGlobalSaveState(pinia) {\r\n    try {\r\n        saveAs(new Blob([JSON.stringify(pinia.state.value)], {\r\n            type: 'text/plain;charset=utf-8',\r\n        }), 'pinia-state.json');\r\n    }\r\n    catch (error) {\r\n        toastMessage(`Failed to export the state as JSON. Check the console for more details.`, 'error');\r\n        console.error(error);\r\n    }\r\n}\r\nlet fileInput;\r\nfunction getFileOpener() {\r\n    if (!fileInput) {\r\n        fileInput = document.createElement('input');\r\n        fileInput.type = 'file';\r\n        fileInput.accept = '.json';\r\n    }\r\n    function openFile() {\r\n        return new Promise((resolve, reject) => {\r\n            fileInput.onchange = async () => {\r\n                const files = fileInput.files;\r\n                if (!files)\r\n                    return resolve(null);\r\n                const file = files.item(0);\r\n                if (!file)\r\n                    return resolve(null);\r\n                return resolve({ text: await file.text(), file });\r\n            };\r\n            // @ts-ignore: TODO: changed from 4.3 to 4.4\r\n            fileInput.oncancel = () => resolve(null);\r\n            fileInput.onerror = reject;\r\n            fileInput.click();\r\n        });\r\n    }\r\n    return openFile;\r\n}\r\nasync function actionGlobalOpenStateFile(pinia) {\r\n    try {\r\n        const open = await getFileOpener();\r\n        const result = await open();\r\n        if (!result)\r\n            return;\r\n        const { text, file } = result;\r\n        pinia.state.value = JSON.parse(text);\r\n        toastMessage(`Global state imported from \"${file.name}\".`);\r\n    }\r\n    catch (error) {\r\n        toastMessage(`Failed to export the state as JSON. Check the console for more details.`, 'error');\r\n        console.error(error);\r\n    }\r\n}\n\nfunction formatDisplay(display) {\r\n    return {\r\n        _custom: {\r\n            display,\r\n        },\r\n    };\r\n}\r\nconst PINIA_ROOT_LABEL = '🍍 Pinia (root)';\r\nconst PINIA_ROOT_ID = '_root';\r\nfunction formatStoreForInspectorTree(store) {\r\n    return isPinia(store)\r\n        ? {\r\n            id: PINIA_ROOT_ID,\r\n            label: PINIA_ROOT_LABEL,\r\n        }\r\n        : {\r\n            id: store.$id,\r\n            label: store.$id,\r\n        };\r\n}\r\nfunction formatStoreForInspectorState(store) {\r\n    if (isPinia(store)) {\r\n        const storeNames = Array.from(store._s.keys());\r\n        const storeMap = store._s;\r\n        const state = {\r\n            state: storeNames.map((storeId) => ({\r\n                editable: true,\r\n                key: storeId,\r\n                value: store.state.value[storeId],\r\n            })),\r\n            getters: storeNames\r\n                .filter((id) => storeMap.get(id)._getters)\r\n                .map((id) => {\r\n                const store = storeMap.get(id);\r\n                return {\r\n                    editable: false,\r\n                    key: id,\r\n                    value: store._getters.reduce((getters, key) => {\r\n                        getters[key] = store[key];\r\n                        return getters;\r\n                    }, {}),\r\n                };\r\n            }),\r\n        };\r\n        return state;\r\n    }\r\n    const state = {\r\n        state: Object.keys(store.$state).map((key) => ({\r\n            editable: true,\r\n            key,\r\n            value: store.$state[key],\r\n        })),\r\n    };\r\n    // avoid adding empty getters\r\n    if (store._getters && store._getters.length) {\r\n        state.getters = store._getters.map((getterName) => ({\r\n            editable: false,\r\n            key: getterName,\r\n            value: store[getterName],\r\n        }));\r\n    }\r\n    if (store._customProperties.size) {\r\n        state.customProperties = Array.from(store._customProperties).map((key) => ({\r\n            editable: true,\r\n            key,\r\n            value: store[key],\r\n        }));\r\n    }\r\n    return state;\r\n}\r\nfunction formatEventData(events) {\r\n    if (!events)\r\n        return {};\r\n    if (Array.isArray(events)) {\r\n        // TODO: handle add and delete for arrays and objects\r\n        return events.reduce((data, event) => {\r\n            data.keys.push(event.key);\r\n            data.operations.push(event.type);\r\n            data.oldValue[event.key] = event.oldValue;\r\n            data.newValue[event.key] = event.newValue;\r\n            return data;\r\n        }, {\r\n            oldValue: {},\r\n            keys: [],\r\n            operations: [],\r\n            newValue: {},\r\n        });\r\n    }\r\n    else {\r\n        return {\r\n            operation: formatDisplay(events.type),\r\n            key: formatDisplay(events.key),\r\n            oldValue: events.oldValue,\r\n            newValue: events.newValue,\r\n        };\r\n    }\r\n}\r\nfunction formatMutationType(type) {\r\n    switch (type) {\r\n        case MutationType.direct:\r\n            return 'mutation';\r\n        case MutationType.patchFunction:\r\n            return '$patch';\r\n        case MutationType.patchObject:\r\n            return '$patch';\r\n        default:\r\n            return 'unknown';\r\n    }\r\n}\n\n// timeline can be paused when directly changing the state\r\nlet isTimelineActive = true;\r\nconst componentStateTypes = [];\r\nconst MUTATIONS_LAYER_ID = 'pinia:mutations';\r\nconst INSPECTOR_ID = 'pinia';\r\n/**\r\n * Gets the displayed name of a store in devtools\r\n *\r\n * @param id - id of the store\r\n * @returns a formatted string\r\n */\r\nconst getStoreType = (id) => '🍍 ' + id;\r\n/**\r\n * Add the pinia plugin without any store. Allows displaying a Pinia plugin tab\r\n * as soon as it is added to the application.\r\n *\r\n * @param app - Vue application\r\n * @param pinia - pinia instance\r\n */\r\nfunction registerPiniaDevtools(app, pinia) {\r\n    setupDevtoolsPlugin({\r\n        id: 'dev.esm.pinia',\r\n        label: 'Pinia 🍍',\r\n        logo: 'https://pinia.vuejs.org/logo.svg',\r\n        packageName: 'pinia',\r\n        homepage: 'https://pinia.vuejs.org',\r\n        componentStateTypes,\r\n        app,\r\n    }, (api) => {\r\n        if (typeof api.now !== 'function') {\r\n            toastMessage('You seem to be using an outdated version of Vue Devtools. Are you still using the Beta release instead of the stable one? You can find the links at https://devtools.vuejs.org/guide/installation.html.');\r\n        }\r\n        api.addTimelineLayer({\r\n            id: MUTATIONS_LAYER_ID,\r\n            label: `Pinia 🍍`,\r\n            color: 0xe5df88,\r\n        });\r\n        api.addInspector({\r\n            id: INSPECTOR_ID,\r\n            label: 'Pinia 🍍',\r\n            icon: 'storage',\r\n            treeFilterPlaceholder: 'Search stores',\r\n            actions: [\r\n                {\r\n                    icon: 'content_copy',\r\n                    action: () => {\r\n                        actionGlobalCopyState(pinia);\r\n                    },\r\n                    tooltip: 'Serialize and copy the state',\r\n                },\r\n                {\r\n                    icon: 'content_paste',\r\n                    action: async () => {\r\n                        await actionGlobalPasteState(pinia);\r\n                        api.sendInspectorTree(INSPECTOR_ID);\r\n                        api.sendInspectorState(INSPECTOR_ID);\r\n                    },\r\n                    tooltip: 'Replace the state with the content of your clipboard',\r\n                },\r\n                {\r\n                    icon: 'save',\r\n                    action: () => {\r\n                        actionGlobalSaveState(pinia);\r\n                    },\r\n                    tooltip: 'Save the state as a JSON file',\r\n                },\r\n                {\r\n                    icon: 'folder_open',\r\n                    action: async () => {\r\n                        await actionGlobalOpenStateFile(pinia);\r\n                        api.sendInspectorTree(INSPECTOR_ID);\r\n                        api.sendInspectorState(INSPECTOR_ID);\r\n                    },\r\n                    tooltip: 'Import the state from a JSON file',\r\n                },\r\n            ],\r\n            nodeActions: [\r\n                {\r\n                    icon: 'restore',\r\n                    tooltip: 'Reset the state (option store only)',\r\n                    action: (nodeId) => {\r\n                        const store = pinia._s.get(nodeId);\r\n                        if (!store) {\r\n                            toastMessage(`Cannot reset \"${nodeId}\" store because it wasn't found.`, 'warn');\r\n                        }\r\n                        else if (!store._isOptionsAPI) {\r\n                            toastMessage(`Cannot reset \"${nodeId}\" store because it's a setup store.`, 'warn');\r\n                        }\r\n                        else {\r\n                            store.$reset();\r\n                            toastMessage(`Store \"${nodeId}\" reset.`);\r\n                        }\r\n                    },\r\n                },\r\n            ],\r\n        });\r\n        api.on.inspectComponent((payload, ctx) => {\r\n            const proxy = (payload.componentInstance &&\r\n                payload.componentInstance.proxy);\r\n            if (proxy && proxy._pStores) {\r\n                const piniaStores = payload.componentInstance.proxy._pStores;\r\n                Object.values(piniaStores).forEach((store) => {\r\n                    payload.instanceData.state.push({\r\n                        type: getStoreType(store.$id),\r\n                        key: 'state',\r\n                        editable: true,\r\n                        value: store._isOptionsAPI\r\n                            ? {\r\n                                _custom: {\r\n                                    value: toRaw(store.$state),\r\n                                    actions: [\r\n                                        {\r\n                                            icon: 'restore',\r\n                                            tooltip: 'Reset the state of this store',\r\n                                            action: () => store.$reset(),\r\n                                        },\r\n                                    ],\r\n                                },\r\n                            }\r\n                            : // NOTE: workaround to unwrap transferred refs\r\n                                Object.keys(store.$state).reduce((state, key) => {\r\n                                    state[key] = store.$state[key];\r\n                                    return state;\r\n                                }, {}),\r\n                    });\r\n                    if (store._getters && store._getters.length) {\r\n                        payload.instanceData.state.push({\r\n                            type: getStoreType(store.$id),\r\n                            key: 'getters',\r\n                            editable: false,\r\n                            value: store._getters.reduce((getters, key) => {\r\n                                try {\r\n                                    getters[key] = store[key];\r\n                                }\r\n                                catch (error) {\r\n                                    // @ts-expect-error: we just want to show it in devtools\r\n                                    getters[key] = error;\r\n                                }\r\n                                return getters;\r\n                            }, {}),\r\n                        });\r\n                    }\r\n                });\r\n            }\r\n        });\r\n        api.on.getInspectorTree((payload) => {\r\n            if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {\r\n                let stores = [pinia];\r\n                stores = stores.concat(Array.from(pinia._s.values()));\r\n                payload.rootNodes = (payload.filter\r\n                    ? stores.filter((store) => '$id' in store\r\n                        ? store.$id\r\n                            .toLowerCase()\r\n                            .includes(payload.filter.toLowerCase())\r\n                        : PINIA_ROOT_LABEL.toLowerCase().includes(payload.filter.toLowerCase()))\r\n                    : stores).map(formatStoreForInspectorTree);\r\n            }\r\n        });\r\n        api.on.getInspectorState((payload) => {\r\n            if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {\r\n                const inspectedStore = payload.nodeId === PINIA_ROOT_ID\r\n                    ? pinia\r\n                    : pinia._s.get(payload.nodeId);\r\n                if (!inspectedStore) {\r\n                    // this could be the selected store restored for a different project\r\n                    // so it's better not to say anything here\r\n                    return;\r\n                }\r\n                if (inspectedStore) {\r\n                    payload.state = formatStoreForInspectorState(inspectedStore);\r\n                }\r\n            }\r\n        });\r\n        api.on.editInspectorState((payload, ctx) => {\r\n            if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {\r\n                const inspectedStore = payload.nodeId === PINIA_ROOT_ID\r\n                    ? pinia\r\n                    : pinia._s.get(payload.nodeId);\r\n                if (!inspectedStore) {\r\n                    return toastMessage(`store \"${payload.nodeId}\" not found`, 'error');\r\n                }\r\n                const { path } = payload;\r\n                if (!isPinia(inspectedStore)) {\r\n                    // access only the state\r\n                    if (path.length !== 1 ||\r\n                        !inspectedStore._customProperties.has(path[0]) ||\r\n                        path[0] in inspectedStore.$state) {\r\n                        path.unshift('$state');\r\n                    }\r\n                }\r\n                else {\r\n                    // Root access, we can omit the `.value` because the devtools API does it for us\r\n                    path.unshift('state');\r\n                }\r\n                isTimelineActive = false;\r\n                payload.set(inspectedStore, path, payload.state.value);\r\n                isTimelineActive = true;\r\n            }\r\n        });\r\n        api.on.editComponentState((payload) => {\r\n            if (payload.type.startsWith('🍍')) {\r\n                const storeId = payload.type.replace(/^🍍\\s*/, '');\r\n                const store = pinia._s.get(storeId);\r\n                if (!store) {\r\n                    return toastMessage(`store \"${storeId}\" not found`, 'error');\r\n                }\r\n                const { path } = payload;\r\n                if (path[0] !== 'state') {\r\n                    return toastMessage(`Invalid path for store \"${storeId}\":\\n${path}\\nOnly state can be modified.`);\r\n                }\r\n                // rewrite the first entry to be able to directly set the state as\r\n                // well as any other path\r\n                path[0] = '$state';\r\n                isTimelineActive = false;\r\n                payload.set(store, path, payload.state.value);\r\n                isTimelineActive = true;\r\n            }\r\n        });\r\n    });\r\n}\r\nfunction addStoreToDevtools(app, store) {\r\n    if (!componentStateTypes.includes(getStoreType(store.$id))) {\r\n        componentStateTypes.push(getStoreType(store.$id));\r\n    }\r\n    setupDevtoolsPlugin({\r\n        id: 'dev.esm.pinia',\r\n        label: 'Pinia 🍍',\r\n        logo: 'https://pinia.vuejs.org/logo.svg',\r\n        packageName: 'pinia',\r\n        homepage: 'https://pinia.vuejs.org',\r\n        componentStateTypes,\r\n        app,\r\n        settings: {\r\n            logStoreChanges: {\r\n                label: 'Notify about new/deleted stores',\r\n                type: 'boolean',\r\n                defaultValue: true,\r\n            },\r\n            // useEmojis: {\r\n            //   label: 'Use emojis in messages ⚡️',\r\n            //   type: 'boolean',\r\n            //   defaultValue: true,\r\n            // },\r\n        },\r\n    }, (api) => {\r\n        // gracefully handle errors\r\n        const now = typeof api.now === 'function' ? api.now.bind(api) : Date.now;\r\n        store.$onAction(({ after, onError, name, args }) => {\r\n            const groupId = runningActionId++;\r\n            api.addTimelineEvent({\r\n                layerId: MUTATIONS_LAYER_ID,\r\n                event: {\r\n                    time: now(),\r\n                    title: '🛫 ' + name,\r\n                    subtitle: 'start',\r\n                    data: {\r\n                        store: formatDisplay(store.$id),\r\n                        action: formatDisplay(name),\r\n                        args,\r\n                    },\r\n                    groupId,\r\n                },\r\n            });\r\n            after((result) => {\r\n                activeAction = undefined;\r\n                api.addTimelineEvent({\r\n                    layerId: MUTATIONS_LAYER_ID,\r\n                    event: {\r\n                        time: now(),\r\n                        title: '🛬 ' + name,\r\n                        subtitle: 'end',\r\n                        data: {\r\n                            store: formatDisplay(store.$id),\r\n                            action: formatDisplay(name),\r\n                            args,\r\n                            result,\r\n                        },\r\n                        groupId,\r\n                    },\r\n                });\r\n            });\r\n            onError((error) => {\r\n                activeAction = undefined;\r\n                api.addTimelineEvent({\r\n                    layerId: MUTATIONS_LAYER_ID,\r\n                    event: {\r\n                        time: now(),\r\n                        logType: 'error',\r\n                        title: '💥 ' + name,\r\n                        subtitle: 'end',\r\n                        data: {\r\n                            store: formatDisplay(store.$id),\r\n                            action: formatDisplay(name),\r\n                            args,\r\n                            error,\r\n                        },\r\n                        groupId,\r\n                    },\r\n                });\r\n            });\r\n        }, true);\r\n        store._customProperties.forEach((name) => {\r\n            watch(() => unref(store[name]), (newValue, oldValue) => {\r\n                api.notifyComponentUpdate();\r\n                api.sendInspectorState(INSPECTOR_ID);\r\n                if (isTimelineActive) {\r\n                    api.addTimelineEvent({\r\n                        layerId: MUTATIONS_LAYER_ID,\r\n                        event: {\r\n                            time: now(),\r\n                            title: 'Change',\r\n                            subtitle: name,\r\n                            data: {\r\n                                newValue,\r\n                                oldValue,\r\n                            },\r\n                            groupId: activeAction,\r\n                        },\r\n                    });\r\n                }\r\n            }, { deep: true });\r\n        });\r\n        store.$subscribe(({ events, type }, state) => {\r\n            api.notifyComponentUpdate();\r\n            api.sendInspectorState(INSPECTOR_ID);\r\n            if (!isTimelineActive)\r\n                return;\r\n            // rootStore.state[store.id] = state\r\n            const eventData = {\r\n                time: now(),\r\n                title: formatMutationType(type),\r\n                data: {\r\n                    store: formatDisplay(store.$id),\r\n                    ...formatEventData(events),\r\n                },\r\n                groupId: activeAction,\r\n            };\r\n            // reset for the next mutation\r\n            activeAction = undefined;\r\n            if (type === MutationType.patchFunction) {\r\n                eventData.subtitle = '⤵️';\r\n            }\r\n            else if (type === MutationType.patchObject) {\r\n                eventData.subtitle = '🧩';\r\n            }\r\n            else if (events && !Array.isArray(events)) {\r\n                eventData.subtitle = events.type;\r\n            }\r\n            if (events) {\r\n                eventData.data['rawEvent(s)'] = {\r\n                    _custom: {\r\n                        display: 'DebuggerEvent',\r\n                        type: 'object',\r\n                        tooltip: 'raw DebuggerEvent[]',\r\n                        value: events,\r\n                    },\r\n                };\r\n            }\r\n            api.addTimelineEvent({\r\n                layerId: MUTATIONS_LAYER_ID,\r\n                event: eventData,\r\n            });\r\n        }, { detached: true, flush: 'sync' });\r\n        const hotUpdate = store._hotUpdate;\r\n        store._hotUpdate = markRaw((newStore) => {\r\n            hotUpdate(newStore);\r\n            api.addTimelineEvent({\r\n                layerId: MUTATIONS_LAYER_ID,\r\n                event: {\r\n                    time: now(),\r\n                    title: '🔥 ' + store.$id,\r\n                    subtitle: 'HMR update',\r\n                    data: {\r\n                        store: formatDisplay(store.$id),\r\n                        info: formatDisplay(`HMR update`),\r\n                    },\r\n                },\r\n            });\r\n            // update the devtools too\r\n            api.notifyComponentUpdate();\r\n            api.sendInspectorTree(INSPECTOR_ID);\r\n            api.sendInspectorState(INSPECTOR_ID);\r\n        });\r\n        const { $dispose } = store;\r\n        store.$dispose = () => {\r\n            $dispose();\r\n            api.notifyComponentUpdate();\r\n            api.sendInspectorTree(INSPECTOR_ID);\r\n            api.sendInspectorState(INSPECTOR_ID);\r\n            api.getSettings().logStoreChanges &&\r\n                toastMessage(`Disposed \"${store.$id}\" store 🗑`);\r\n        };\r\n        // trigger an update so it can display new registered stores\r\n        api.notifyComponentUpdate();\r\n        api.sendInspectorTree(INSPECTOR_ID);\r\n        api.sendInspectorState(INSPECTOR_ID);\r\n        api.getSettings().logStoreChanges &&\r\n            toastMessage(`\"${store.$id}\" store installed 🆕`);\r\n    });\r\n}\r\nlet runningActionId = 0;\r\nlet activeAction;\r\n/**\r\n * Patches a store to enable action grouping in devtools by wrapping the store with a Proxy that is passed as the\r\n * context of all actions, allowing us to set `runningAction` on each access and effectively associating any state\r\n * mutation to the action.\r\n *\r\n * @param store - store to patch\r\n * @param actionNames - list of actionst to patch\r\n */\r\nfunction patchActionForGrouping(store, actionNames) {\r\n    // original actions of the store as they are given by pinia. We are going to override them\r\n    const actions = actionNames.reduce((storeActions, actionName) => {\r\n        // use toRaw to avoid tracking #541\r\n        storeActions[actionName] = toRaw(store)[actionName];\r\n        return storeActions;\r\n    }, {});\r\n    for (const actionName in actions) {\r\n        store[actionName] = function () {\r\n            // setActivePinia(store._p)\r\n            // the running action id is incremented in a before action hook\r\n            const _actionId = runningActionId;\r\n            const trackedStore = new Proxy(store, {\r\n                get(...args) {\r\n                    activeAction = _actionId;\r\n                    return Reflect.get(...args);\r\n                },\r\n                set(...args) {\r\n                    activeAction = _actionId;\r\n                    return Reflect.set(...args);\r\n                },\r\n            });\r\n            return actions[actionName].apply(trackedStore, arguments);\r\n        };\r\n    }\r\n}\r\n/**\r\n * pinia.use(devtoolsPlugin)\r\n */\r\nfunction devtoolsPlugin({ app, store, options }) {\r\n    // HMR module\r\n    if (store.$id.startsWith('__hot:')) {\r\n        return;\r\n    }\r\n    // detect option api vs setup api\r\n    if (options.state) {\r\n        store._isOptionsAPI = true;\r\n    }\r\n    // only wrap actions in option-defined stores as this technique relies on\r\n    // wrapping the context of the action with a proxy\r\n    if (typeof options.state === 'function') {\r\n        patchActionForGrouping(\r\n        // @ts-expect-error: can cast the store...\r\n        store, Object.keys(options.actions));\r\n        const originalHotUpdate = store._hotUpdate;\r\n        // Upgrade the HMR to also update the new actions\r\n        toRaw(store)._hotUpdate = function (newStore) {\r\n            originalHotUpdate.apply(this, arguments);\r\n            patchActionForGrouping(store, Object.keys(newStore._hmrPayload.actions));\r\n        };\r\n    }\r\n    addStoreToDevtools(app, \r\n    // FIXME: is there a way to allow the assignment from Store<Id, S, G, A> to StoreGeneric?\r\n    store);\r\n}\n\n/**\r\n * Creates a Pinia instance to be used by the application\r\n */\r\nfunction createPinia() {\r\n    const scope = effectScope(true);\r\n    // NOTE: here we could check the window object for a state and directly set it\r\n    // if there is anything like it with Vue 3 SSR\r\n    const state = scope.run(() => ref({}));\r\n    let _p = [];\r\n    // plugins added before calling app.use(pinia)\r\n    let toBeInstalled = [];\r\n    const pinia = markRaw({\r\n        install(app) {\r\n            // this allows calling useStore() outside of a component setup after\r\n            // installing pinia's plugin\r\n            setActivePinia(pinia);\r\n            if (!isVue2) {\r\n                pinia._a = app;\r\n                app.provide(piniaSymbol, pinia);\r\n                app.config.globalProperties.$pinia = pinia;\r\n                /* istanbul ignore else */\r\n                if (USE_DEVTOOLS) {\r\n                    registerPiniaDevtools(app, pinia);\r\n                }\r\n                toBeInstalled.forEach((plugin) => _p.push(plugin));\r\n                toBeInstalled = [];\r\n            }\r\n        },\r\n        use(plugin) {\r\n            if (!this._a && !isVue2) {\r\n                toBeInstalled.push(plugin);\r\n            }\r\n            else {\r\n                _p.push(plugin);\r\n            }\r\n            return this;\r\n        },\r\n        _p,\r\n        // it's actually undefined here\r\n        // @ts-expect-error\r\n        _a: null,\r\n        _e: scope,\r\n        _s: new Map(),\r\n        state,\r\n    });\r\n    // pinia devtools rely on dev only features so they cannot be forced unless\r\n    // the dev build of Vue is used. Avoid old browsers like IE11.\r\n    if (USE_DEVTOOLS && typeof Proxy !== 'undefined') {\r\n        pinia.use(devtoolsPlugin);\r\n    }\r\n    return pinia;\r\n}\n\n/**\r\n * Checks if a function is a `StoreDefinition`.\r\n *\r\n * @param fn - object to test\r\n * @returns true if `fn` is a StoreDefinition\r\n */\r\nconst isUseStore = (fn) => {\r\n    return typeof fn === 'function' && typeof fn.$id === 'string';\r\n};\r\n/**\r\n * Mutates in place `newState` with `oldState` to _hot update_ it. It will\r\n * remove any key not existing in `newState` and recursively merge plain\r\n * objects.\r\n *\r\n * @param newState - new state object to be patched\r\n * @param oldState - old state that should be used to patch newState\r\n * @returns - newState\r\n */\r\nfunction patchObject(newState, oldState) {\r\n    // no need to go through symbols because they cannot be serialized anyway\r\n    for (const key in oldState) {\r\n        const subPatch = oldState[key];\r\n        // skip the whole sub tree\r\n        if (!(key in newState)) {\r\n            continue;\r\n        }\r\n        const targetValue = newState[key];\r\n        if (isPlainObject(targetValue) &&\r\n            isPlainObject(subPatch) &&\r\n            !isRef(subPatch) &&\r\n            !isReactive(subPatch)) {\r\n            newState[key] = patchObject(targetValue, subPatch);\r\n        }\r\n        else {\r\n            // objects are either a bit more complex (e.g. refs) or primitives, so we\r\n            // just set the whole thing\r\n            if (isVue2) {\r\n                set(newState, key, subPatch);\r\n            }\r\n            else {\r\n                newState[key] = subPatch;\r\n            }\r\n        }\r\n    }\r\n    return newState;\r\n}\r\n/**\r\n * Creates an _accept_ function to pass to `import.meta.hot` in Vite applications.\r\n *\r\n * @example\r\n * ```js\r\n * const useUser = defineStore(...)\r\n * if (import.meta.hot) {\r\n *   import.meta.hot.accept(acceptHMRUpdate(useUser, import.meta.hot))\r\n * }\r\n * ```\r\n *\r\n * @param initialUseStore - return of the defineStore to hot update\r\n * @param hot - `import.meta.hot`\r\n */\r\nfunction acceptHMRUpdate(initialUseStore, hot) {\r\n    // strip as much as possible from iife.prod\r\n    if (!(process.env.NODE_ENV !== 'production')) {\r\n        return () => { };\r\n    }\r\n    return (newModule) => {\r\n        const pinia = hot.data.pinia || initialUseStore._pinia;\r\n        if (!pinia) {\r\n            // this store is still not used\r\n            return;\r\n        }\r\n        // preserve the pinia instance across loads\r\n        hot.data.pinia = pinia;\r\n        // console.log('got data', newStore)\r\n        for (const exportName in newModule) {\r\n            const useStore = newModule[exportName];\r\n            // console.log('checking for', exportName)\r\n            if (isUseStore(useStore) && pinia._s.has(useStore.$id)) {\r\n                // console.log('Accepting update for', useStore.$id)\r\n                const id = useStore.$id;\r\n                if (id !== initialUseStore.$id) {\r\n                    console.warn(`The id of the store changed from \"${initialUseStore.$id}\" to \"${id}\". Reloading.`);\r\n                    // return import.meta.hot.invalidate()\r\n                    return hot.invalidate();\r\n                }\r\n                const existingStore = pinia._s.get(id);\r\n                if (!existingStore) {\r\n                    console.log(`[Pinia]: skipping hmr because store doesn't exist yet`);\r\n                    return;\r\n                }\r\n                useStore(pinia, existingStore);\r\n            }\r\n        }\r\n    };\r\n}\n\nconst noop = () => { };\r\nfunction addSubscription(subscriptions, callback, detached, onCleanup = noop) {\r\n    subscriptions.push(callback);\r\n    const removeSubscription = () => {\r\n        const idx = subscriptions.indexOf(callback);\r\n        if (idx > -1) {\r\n            subscriptions.splice(idx, 1);\r\n            onCleanup();\r\n        }\r\n    };\r\n    if (!detached && getCurrentInstance()) {\r\n        onUnmounted(removeSubscription);\r\n    }\r\n    return removeSubscription;\r\n}\r\nfunction triggerSubscriptions(subscriptions, ...args) {\r\n    subscriptions.slice().forEach((callback) => {\r\n        callback(...args);\r\n    });\r\n}\n\nfunction mergeReactiveObjects(target, patchToApply) {\r\n    // Handle Map instances\r\n    if (target instanceof Map && patchToApply instanceof Map) {\r\n        patchToApply.forEach((value, key) => target.set(key, value));\r\n    }\r\n    // Handle Set instances\r\n    if (target instanceof Set && patchToApply instanceof Set) {\r\n        patchToApply.forEach(target.add, target);\r\n    }\r\n    // no need to go through symbols because they cannot be serialized anyway\r\n    for (const key in patchToApply) {\r\n        if (!patchToApply.hasOwnProperty(key))\r\n            continue;\r\n        const subPatch = patchToApply[key];\r\n        const targetValue = target[key];\r\n        if (isPlainObject(targetValue) &&\r\n            isPlainObject(subPatch) &&\r\n            target.hasOwnProperty(key) &&\r\n            !isRef(subPatch) &&\r\n            !isReactive(subPatch)) {\r\n            // NOTE: here I wanted to warn about inconsistent types but it's not possible because in setup stores one might\r\n            // start the value of a property as a certain type e.g. a Map, and then for some reason, during SSR, change that\r\n            // to `undefined`. When trying to hydrate, we want to override the Map with `undefined`.\r\n            target[key] = mergeReactiveObjects(targetValue, subPatch);\r\n        }\r\n        else {\r\n            // @ts-expect-error: subPatch is a valid value\r\n            target[key] = subPatch;\r\n        }\r\n    }\r\n    return target;\r\n}\r\nconst skipHydrateSymbol = (process.env.NODE_ENV !== 'production')\r\n    ? Symbol('pinia:skipHydration')\r\n    : /* istanbul ignore next */ Symbol();\r\nconst skipHydrateMap = /*#__PURE__*/ new WeakMap();\r\n/**\r\n * Tells Pinia to skip the hydration process of a given object. This is useful in setup stores (only) when you return a\r\n * stateful object in the store but it isn't really state. e.g. returning a router instance in a setup store.\r\n *\r\n * @param obj - target object\r\n * @returns obj\r\n */\r\nfunction skipHydrate(obj) {\r\n    return isVue2\r\n        ? // in @vue/composition-api, the refs are sealed so defineProperty doesn't work...\r\n            /* istanbul ignore next */ skipHydrateMap.set(obj, 1) && obj\r\n        : Object.defineProperty(obj, skipHydrateSymbol, {});\r\n}\r\n/**\r\n * Returns whether a value should be hydrated\r\n *\r\n * @param obj - target variable\r\n * @returns true if `obj` should be hydrated\r\n */\r\nfunction shouldHydrate(obj) {\r\n    return isVue2\r\n        ? /* istanbul ignore next */ !skipHydrateMap.has(obj)\r\n        : !isPlainObject(obj) || !obj.hasOwnProperty(skipHydrateSymbol);\r\n}\r\nconst { assign } = Object;\r\nfunction isComputed(o) {\r\n    return !!(isRef(o) && o.effect);\r\n}\r\nfunction createOptionsStore(id, options, pinia, hot) {\r\n    const { state, actions, getters } = options;\r\n    const initialState = pinia.state.value[id];\r\n    let store;\r\n    function setup() {\r\n        if (!initialState && (!(process.env.NODE_ENV !== 'production') || !hot)) {\r\n            /* istanbul ignore if */\r\n            if (isVue2) {\r\n                set(pinia.state.value, id, state ? state() : {});\r\n            }\r\n            else {\r\n                pinia.state.value[id] = state ? state() : {};\r\n            }\r\n        }\r\n        // avoid creating a state in pinia.state.value\r\n        const localState = (process.env.NODE_ENV !== 'production') && hot\r\n            ? // use ref() to unwrap refs inside state TODO: check if this is still necessary\r\n                toRefs(ref(state ? state() : {}).value)\r\n            : toRefs(pinia.state.value[id]);\r\n        return assign(localState, actions, Object.keys(getters || {}).reduce((computedGetters, name) => {\r\n            if ((process.env.NODE_ENV !== 'production') && name in localState) {\r\n                console.warn(`[🍍]: A getter cannot have the same name as another state property. Rename one of them. Found with \"${name}\" in store \"${id}\".`);\r\n            }\r\n            computedGetters[name] = markRaw(computed(() => {\r\n                setActivePinia(pinia);\r\n                // it was created just before\r\n                const store = pinia._s.get(id);\r\n                // allow cross using stores\r\n                /* istanbul ignore next */\r\n                if (isVue2 && !store._r)\r\n                    return;\r\n                // @ts-expect-error\r\n                // return getters![name].call(context, context)\r\n                // TODO: avoid reading the getter while assigning with a global variable\r\n                return getters[name].call(store, store);\r\n            }));\r\n            return computedGetters;\r\n        }, {}));\r\n    }\r\n    store = createSetupStore(id, setup, options, pinia, hot, true);\r\n    store.$reset = function $reset() {\r\n        const newState = state ? state() : {};\r\n        // we use a patch to group all changes into one single subscription\r\n        this.$patch(($state) => {\r\n            assign($state, newState);\r\n        });\r\n    };\r\n    return store;\r\n}\r\nfunction createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore) {\r\n    let scope;\r\n    const optionsForPlugin = assign({ actions: {} }, options);\r\n    /* istanbul ignore if */\r\n    // @ts-expect-error: active is an internal property\r\n    if ((process.env.NODE_ENV !== 'production') && !pinia._e.active) {\r\n        throw new Error('Pinia destroyed');\r\n    }\r\n    // watcher options for $subscribe\r\n    const $subscribeOptions = {\r\n        deep: true,\r\n        // flush: 'post',\r\n    };\r\n    /* istanbul ignore else */\r\n    if ((process.env.NODE_ENV !== 'production') && !isVue2) {\r\n        $subscribeOptions.onTrigger = (event) => {\r\n            /* istanbul ignore else */\r\n            if (isListening) {\r\n                debuggerEvents = event;\r\n                // avoid triggering this while the store is being built and the state is being set in pinia\r\n            }\r\n            else if (isListening == false && !store._hotUpdating) {\r\n                // let patch send all the events together later\r\n                /* istanbul ignore else */\r\n                if (Array.isArray(debuggerEvents)) {\r\n                    debuggerEvents.push(event);\r\n                }\r\n                else {\r\n                    console.error('🍍 debuggerEvents should be an array. This is most likely an internal Pinia bug.');\r\n                }\r\n            }\r\n        };\r\n    }\r\n    // internal state\r\n    let isListening; // set to true at the end\r\n    let isSyncListening; // set to true at the end\r\n    let subscriptions = markRaw([]);\r\n    let actionSubscriptions = markRaw([]);\r\n    let debuggerEvents;\r\n    const initialState = pinia.state.value[$id];\r\n    // avoid setting the state for option stores if it is set\r\n    // by the setup\r\n    if (!isOptionsStore && !initialState && (!(process.env.NODE_ENV !== 'production') || !hot)) {\r\n        /* istanbul ignore if */\r\n        if (isVue2) {\r\n            set(pinia.state.value, $id, {});\r\n        }\r\n        else {\r\n            pinia.state.value[$id] = {};\r\n        }\r\n    }\r\n    const hotState = ref({});\r\n    // avoid triggering too many listeners\r\n    // https://github.com/vuejs/pinia/issues/1129\r\n    let activeListener;\r\n    function $patch(partialStateOrMutator) {\r\n        let subscriptionMutation;\r\n        isListening = isSyncListening = false;\r\n        // reset the debugger events since patches are sync\r\n        /* istanbul ignore else */\r\n        if ((process.env.NODE_ENV !== 'production')) {\r\n            debuggerEvents = [];\r\n        }\r\n        if (typeof partialStateOrMutator === 'function') {\r\n            partialStateOrMutator(pinia.state.value[$id]);\r\n            subscriptionMutation = {\r\n                type: MutationType.patchFunction,\r\n                storeId: $id,\r\n                events: debuggerEvents,\r\n            };\r\n        }\r\n        else {\r\n            mergeReactiveObjects(pinia.state.value[$id], partialStateOrMutator);\r\n            subscriptionMutation = {\r\n                type: MutationType.patchObject,\r\n                payload: partialStateOrMutator,\r\n                storeId: $id,\r\n                events: debuggerEvents,\r\n            };\r\n        }\r\n        const myListenerId = (activeListener = Symbol());\r\n        nextTick().then(() => {\r\n            if (activeListener === myListenerId) {\r\n                isListening = true;\r\n            }\r\n        });\r\n        isSyncListening = true;\r\n        // because we paused the watcher, we need to manually call the subscriptions\r\n        triggerSubscriptions(subscriptions, subscriptionMutation, pinia.state.value[$id]);\r\n    }\r\n    /* istanbul ignore next */\r\n    const $reset = (process.env.NODE_ENV !== 'production')\r\n        ? () => {\r\n            throw new Error(`🍍: Store \"${$id}\" is built using the setup syntax and does not implement $reset().`);\r\n        }\r\n        : noop;\r\n    function $dispose() {\r\n        scope.stop();\r\n        subscriptions = [];\r\n        actionSubscriptions = [];\r\n        pinia._s.delete($id);\r\n    }\r\n    /**\r\n     * Wraps an action to handle subscriptions.\r\n     *\r\n     * @param name - name of the action\r\n     * @param action - action to wrap\r\n     * @returns a wrapped action to handle subscriptions\r\n     */\r\n    function wrapAction(name, action) {\r\n        return function () {\r\n            setActivePinia(pinia);\r\n            const args = Array.from(arguments);\r\n            const afterCallbackList = [];\r\n            const onErrorCallbackList = [];\r\n            function after(callback) {\r\n                afterCallbackList.push(callback);\r\n            }\r\n            function onError(callback) {\r\n                onErrorCallbackList.push(callback);\r\n            }\r\n            // @ts-expect-error\r\n            triggerSubscriptions(actionSubscriptions, {\r\n                args,\r\n                name,\r\n                store,\r\n                after,\r\n                onError,\r\n            });\r\n            let ret;\r\n            try {\r\n                ret = action.apply(this && this.$id === $id ? this : store, args);\r\n                // handle sync errors\r\n            }\r\n            catch (error) {\r\n                triggerSubscriptions(onErrorCallbackList, error);\r\n                throw error;\r\n            }\r\n            if (ret instanceof Promise) {\r\n                return ret\r\n                    .then((value) => {\r\n                    triggerSubscriptions(afterCallbackList, value);\r\n                    return value;\r\n                })\r\n                    .catch((error) => {\r\n                    triggerSubscriptions(onErrorCallbackList, error);\r\n                    return Promise.reject(error);\r\n                });\r\n            }\r\n            // allow the afterCallback to override the return value\r\n            triggerSubscriptions(afterCallbackList, ret);\r\n            return ret;\r\n        };\r\n    }\r\n    const _hmrPayload = /*#__PURE__*/ markRaw({\r\n        actions: {},\r\n        getters: {},\r\n        state: [],\r\n        hotState,\r\n    });\r\n    const partialStore = {\r\n        _p: pinia,\r\n        // _s: scope,\r\n        $id,\r\n        $onAction: addSubscription.bind(null, actionSubscriptions),\r\n        $patch,\r\n        $reset,\r\n        $subscribe(callback, options = {}) {\r\n            const removeSubscription = addSubscription(subscriptions, callback, options.detached, () => stopWatcher());\r\n            const stopWatcher = scope.run(() => watch(() => pinia.state.value[$id], (state) => {\r\n                if (options.flush === 'sync' ? isSyncListening : isListening) {\r\n                    callback({\r\n                        storeId: $id,\r\n                        type: MutationType.direct,\r\n                        events: debuggerEvents,\r\n                    }, state);\r\n                }\r\n            }, assign({}, $subscribeOptions, options)));\r\n            return removeSubscription;\r\n        },\r\n        $dispose,\r\n    };\r\n    /* istanbul ignore if */\r\n    if (isVue2) {\r\n        // start as non ready\r\n        partialStore._r = false;\r\n    }\r\n    const store = reactive((process.env.NODE_ENV !== 'production') || USE_DEVTOOLS\r\n        ? assign({\r\n            _hmrPayload,\r\n            _customProperties: markRaw(new Set()), // devtools custom properties\r\n        }, partialStore\r\n        // must be added later\r\n        // setupStore\r\n        )\r\n        : partialStore);\r\n    // store the partial store now so the setup of stores can instantiate each other before they are finished without\r\n    // creating infinite loops.\r\n    pinia._s.set($id, store);\r\n    // TODO: idea create skipSerialize that marks properties as non serializable and they are skipped\r\n    const setupStore = pinia._e.run(() => {\r\n        scope = effectScope();\r\n        return scope.run(() => setup());\r\n    });\r\n    // overwrite existing actions to support $onAction\r\n    for (const key in setupStore) {\r\n        const prop = setupStore[key];\r\n        if ((isRef(prop) && !isComputed(prop)) || isReactive(prop)) {\r\n            // mark it as a piece of state to be serialized\r\n            if ((process.env.NODE_ENV !== 'production') && hot) {\r\n                set(hotState.value, key, toRef(setupStore, key));\r\n                // createOptionStore directly sets the state in pinia.state.value so we\r\n                // can just skip that\r\n            }\r\n            else if (!isOptionsStore) {\r\n                // in setup stores we must hydrate the state and sync pinia state tree with the refs the user just created\r\n                if (initialState && shouldHydrate(prop)) {\r\n                    if (isRef(prop)) {\r\n                        prop.value = initialState[key];\r\n                    }\r\n                    else {\r\n                        // probably a reactive object, lets recursively assign\r\n                        // @ts-expect-error: prop is unknown\r\n                        mergeReactiveObjects(prop, initialState[key]);\r\n                    }\r\n                }\r\n                // transfer the ref to the pinia state to keep everything in sync\r\n                /* istanbul ignore if */\r\n                if (isVue2) {\r\n                    set(pinia.state.value[$id], key, prop);\r\n                }\r\n                else {\r\n                    pinia.state.value[$id][key] = prop;\r\n                }\r\n            }\r\n            /* istanbul ignore else */\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                _hmrPayload.state.push(key);\r\n            }\r\n            // action\r\n        }\r\n        else if (typeof prop === 'function') {\r\n            // @ts-expect-error: we are overriding the function we avoid wrapping if\r\n            const actionValue = (process.env.NODE_ENV !== 'production') && hot ? prop : wrapAction(key, prop);\r\n            // this a hot module replacement store because the hotUpdate method needs\r\n            // to do it with the right context\r\n            /* istanbul ignore if */\r\n            if (isVue2) {\r\n                set(setupStore, key, actionValue);\r\n            }\r\n            else {\r\n                // @ts-expect-error\r\n                setupStore[key] = actionValue;\r\n            }\r\n            /* istanbul ignore else */\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                _hmrPayload.actions[key] = prop;\r\n            }\r\n            // list actions so they can be used in plugins\r\n            // @ts-expect-error\r\n            optionsForPlugin.actions[key] = prop;\r\n        }\r\n        else if ((process.env.NODE_ENV !== 'production')) {\r\n            // add getters for devtools\r\n            if (isComputed(prop)) {\r\n                _hmrPayload.getters[key] = isOptionsStore\r\n                    ? // @ts-expect-error\r\n                        options.getters[key]\r\n                    : prop;\r\n                if (IS_CLIENT) {\r\n                    const getters = setupStore._getters ||\r\n                        // @ts-expect-error: same\r\n                        (setupStore._getters = markRaw([]));\r\n                    getters.push(key);\r\n                }\r\n            }\r\n        }\r\n    }\r\n    // add the state, getters, and action properties\r\n    /* istanbul ignore if */\r\n    if (isVue2) {\r\n        Object.keys(setupStore).forEach((key) => {\r\n            set(store, key, setupStore[key]);\r\n        });\r\n    }\r\n    else {\r\n        assign(store, setupStore);\r\n        // allows retrieving reactive objects with `storeToRefs()`. Must be called after assigning to the reactive object.\r\n        // Make `storeToRefs()` work with `reactive()` #799\r\n        assign(toRaw(store), setupStore);\r\n    }\r\n    // use this instead of a computed with setter to be able to create it anywhere\r\n    // without linking the computed lifespan to wherever the store is first\r\n    // created.\r\n    Object.defineProperty(store, '$state', {\r\n        get: () => ((process.env.NODE_ENV !== 'production') && hot ? hotState.value : pinia.state.value[$id]),\r\n        set: (state) => {\r\n            /* istanbul ignore if */\r\n            if ((process.env.NODE_ENV !== 'production') && hot) {\r\n                throw new Error('cannot set hotState');\r\n            }\r\n            $patch(($state) => {\r\n                assign($state, state);\r\n            });\r\n        },\r\n    });\r\n    // add the hotUpdate before plugins to allow them to override it\r\n    /* istanbul ignore else */\r\n    if ((process.env.NODE_ENV !== 'production')) {\r\n        store._hotUpdate = markRaw((newStore) => {\r\n            store._hotUpdating = true;\r\n            newStore._hmrPayload.state.forEach((stateKey) => {\r\n                if (stateKey in store.$state) {\r\n                    const newStateTarget = newStore.$state[stateKey];\r\n                    const oldStateSource = store.$state[stateKey];\r\n                    if (typeof newStateTarget === 'object' &&\r\n                        isPlainObject(newStateTarget) &&\r\n                        isPlainObject(oldStateSource)) {\r\n                        patchObject(newStateTarget, oldStateSource);\r\n                    }\r\n                    else {\r\n                        // transfer the ref\r\n                        newStore.$state[stateKey] = oldStateSource;\r\n                    }\r\n                }\r\n                // patch direct access properties to allow store.stateProperty to work as\r\n                // store.$state.stateProperty\r\n                set(store, stateKey, toRef(newStore.$state, stateKey));\r\n            });\r\n            // remove deleted state properties\r\n            Object.keys(store.$state).forEach((stateKey) => {\r\n                if (!(stateKey in newStore.$state)) {\r\n                    del(store, stateKey);\r\n                }\r\n            });\r\n            // avoid devtools logging this as a mutation\r\n            isListening = false;\r\n            isSyncListening = false;\r\n            pinia.state.value[$id] = toRef(newStore._hmrPayload, 'hotState');\r\n            isSyncListening = true;\r\n            nextTick().then(() => {\r\n                isListening = true;\r\n            });\r\n            for (const actionName in newStore._hmrPayload.actions) {\r\n                const action = newStore[actionName];\r\n                set(store, actionName, wrapAction(actionName, action));\r\n            }\r\n            // TODO: does this work in both setup and option store?\r\n            for (const getterName in newStore._hmrPayload.getters) {\r\n                const getter = newStore._hmrPayload.getters[getterName];\r\n                const getterValue = isOptionsStore\r\n                    ? // special handling of options api\r\n                        computed(() => {\r\n                            setActivePinia(pinia);\r\n                            return getter.call(store, store);\r\n                        })\r\n                    : getter;\r\n                set(store, getterName, getterValue);\r\n            }\r\n            // remove deleted getters\r\n            Object.keys(store._hmrPayload.getters).forEach((key) => {\r\n                if (!(key in newStore._hmrPayload.getters)) {\r\n                    del(store, key);\r\n                }\r\n            });\r\n            // remove old actions\r\n            Object.keys(store._hmrPayload.actions).forEach((key) => {\r\n                if (!(key in newStore._hmrPayload.actions)) {\r\n                    del(store, key);\r\n                }\r\n            });\r\n            // update the values used in devtools and to allow deleting new properties later on\r\n            store._hmrPayload = newStore._hmrPayload;\r\n            store._getters = newStore._getters;\r\n            store._hotUpdating = false;\r\n        });\r\n    }\r\n    if (USE_DEVTOOLS) {\r\n        const nonEnumerable = {\r\n            writable: true,\r\n            configurable: true,\r\n            // avoid warning on devtools trying to display this property\r\n            enumerable: false,\r\n        };\r\n        ['_p', '_hmrPayload', '_getters', '_customProperties'].forEach((p) => {\r\n            Object.defineProperty(store, p, {\r\n                value: store[p],\r\n                ...nonEnumerable,\r\n            });\r\n        });\r\n    }\r\n    /* istanbul ignore if */\r\n    if (isVue2) {\r\n        // mark the store as ready before plugins\r\n        store._r = true;\r\n    }\r\n    // apply all plugins\r\n    pinia._p.forEach((extender) => {\r\n        /* istanbul ignore else */\r\n        if (USE_DEVTOOLS) {\r\n            const extensions = scope.run(() => extender({\r\n                store,\r\n                app: pinia._a,\r\n                pinia,\r\n                options: optionsForPlugin,\r\n            }));\r\n            Object.keys(extensions || {}).forEach((key) => store._customProperties.add(key));\r\n            assign(store, extensions);\r\n        }\r\n        else {\r\n            assign(store, scope.run(() => extender({\r\n                store,\r\n                app: pinia._a,\r\n                pinia,\r\n                options: optionsForPlugin,\r\n            })));\r\n        }\r\n    });\r\n    if ((process.env.NODE_ENV !== 'production') &&\r\n        store.$state &&\r\n        typeof store.$state === 'object' &&\r\n        typeof store.$state.constructor === 'function' &&\r\n        !store.$state.constructor.toString().includes('[native code]')) {\r\n        console.warn(`[🍍]: The \"state\" must be a plain object. It cannot be\\n` +\r\n            `\\tstate: () => new MyClass()\\n` +\r\n            `Found in store \"${store.$id}\".`);\r\n    }\r\n    // only apply hydrate to option stores with an initial state in pinia\r\n    if (initialState &&\r\n        isOptionsStore &&\r\n        options.hydrate) {\r\n        options.hydrate(store.$state, initialState);\r\n    }\r\n    isListening = true;\r\n    isSyncListening = true;\r\n    return store;\r\n}\r\nfunction defineStore(\r\n// TODO: add proper types from above\r\nidOrOptions, setup, setupOptions) {\r\n    let id;\r\n    let options;\r\n    const isSetupStore = typeof setup === 'function';\r\n    if (typeof idOrOptions === 'string') {\r\n        id = idOrOptions;\r\n        // the option store setup will contain the actual options in this case\r\n        options = isSetupStore ? setupOptions : setup;\r\n    }\r\n    else {\r\n        options = idOrOptions;\r\n        id = idOrOptions.id;\r\n    }\r\n    function useStore(pinia, hot) {\r\n        const currentInstance = getCurrentInstance();\r\n        pinia =\r\n            // in test mode, ignore the argument provided as we can always retrieve a\r\n            // pinia instance with getActivePinia()\r\n            ((process.env.NODE_ENV === 'test') && activePinia && activePinia._testing ? null : pinia) ||\r\n                (currentInstance && inject(piniaSymbol));\r\n        if (pinia)\r\n            setActivePinia(pinia);\r\n        if ((process.env.NODE_ENV !== 'production') && !activePinia) {\r\n            throw new Error(`[🍍]: getActivePinia was called with no active Pinia. Did you forget to install pinia?\\n` +\r\n                `\\tconst pinia = createPinia()\\n` +\r\n                `\\tapp.use(pinia)\\n` +\r\n                `This will fail in production.`);\r\n        }\r\n        pinia = activePinia;\r\n        if (!pinia._s.has(id)) {\r\n            // creating the store registers it in `pinia._s`\r\n            if (isSetupStore) {\r\n                createSetupStore(id, setup, options, pinia);\r\n            }\r\n            else {\r\n                createOptionsStore(id, options, pinia);\r\n            }\r\n            /* istanbul ignore else */\r\n            if ((process.env.NODE_ENV !== 'production')) {\r\n                // @ts-expect-error: not the right inferred type\r\n                useStore._pinia = pinia;\r\n            }\r\n        }\r\n        const store = pinia._s.get(id);\r\n        if ((process.env.NODE_ENV !== 'production') && hot) {\r\n            const hotId = '__hot:' + id;\r\n            const newStore = isSetupStore\r\n                ? createSetupStore(hotId, setup, options, pinia, true)\r\n                : createOptionsStore(hotId, assign({}, options), pinia, true);\r\n            hot._hotUpdate(newStore);\r\n            // cleanup the state properties and the store from the cache\r\n            delete pinia.state.value[hotId];\r\n            pinia._s.delete(hotId);\r\n        }\r\n        // save stores in instances to access them devtools\r\n        if ((process.env.NODE_ENV !== 'production') &&\r\n            IS_CLIENT &&\r\n            currentInstance &&\r\n            currentInstance.proxy &&\r\n            // avoid adding stores that are just built for hot module replacement\r\n            !hot) {\r\n            const vm = currentInstance.proxy;\r\n            const cache = '_pStores' in vm ? vm._pStores : (vm._pStores = {});\r\n            cache[id] = store;\r\n        }\r\n        // StoreGeneric cannot be casted towards Store\r\n        return store;\r\n    }\r\n    useStore.$id = id;\r\n    return useStore;\r\n}\n\nlet mapStoreSuffix = 'Store';\r\n/**\r\n * Changes the suffix added by `mapStores()`. Can be set to an empty string.\r\n * Defaults to `\"Store\"`. Make sure to extend the MapStoresCustomization\r\n * interface if you are using TypeScript.\r\n *\r\n * @param suffix - new suffix\r\n */\r\nfunction setMapStoreSuffix(suffix // could be 'Store' but that would be annoying for JS\r\n) {\r\n    mapStoreSuffix = suffix;\r\n}\r\n/**\r\n * Allows using stores without the composition API (`setup()`) by generating an\r\n * object to be spread in the `computed` field of a component. It accepts a list\r\n * of store definitions.\r\n *\r\n * @example\r\n * ```js\r\n * export default {\r\n *   computed: {\r\n *     // other computed properties\r\n *     ...mapStores(useUserStore, useCartStore)\r\n *   },\r\n *\r\n *   created() {\r\n *     this.userStore // store with id \"user\"\r\n *     this.cartStore // store with id \"cart\"\r\n *   }\r\n * }\r\n * ```\r\n *\r\n * @param stores - list of stores to map to an object\r\n */\r\nfunction mapStores(...stores) {\r\n    if ((process.env.NODE_ENV !== 'production') && Array.isArray(stores[0])) {\r\n        console.warn(`[🍍]: Directly pass all stores to \"mapStores()\" without putting them in an array:\\n` +\r\n            `Replace\\n` +\r\n            `\\tmapStores([useAuthStore, useCartStore])\\n` +\r\n            `with\\n` +\r\n            `\\tmapStores(useAuthStore, useCartStore)\\n` +\r\n            `This will fail in production if not fixed.`);\r\n        stores = stores[0];\r\n    }\r\n    return stores.reduce((reduced, useStore) => {\r\n        // @ts-expect-error: $id is added by defineStore\r\n        reduced[useStore.$id + mapStoreSuffix] = function () {\r\n            return useStore(this.$pinia);\r\n        };\r\n        return reduced;\r\n    }, {});\r\n}\r\n/**\r\n * Allows using state and getters from one store without using the composition\r\n * API (`setup()`) by generating an object to be spread in the `computed` field\r\n * of a component.\r\n *\r\n * @param useStore - store to map from\r\n * @param keysOrMapper - array or object\r\n */\r\nfunction mapState(useStore, keysOrMapper) {\r\n    return Array.isArray(keysOrMapper)\r\n        ? keysOrMapper.reduce((reduced, key) => {\r\n            reduced[key] = function () {\r\n                return useStore(this.$pinia)[key];\r\n            };\r\n            return reduced;\r\n        }, {})\r\n        : Object.keys(keysOrMapper).reduce((reduced, key) => {\r\n            // @ts-expect-error\r\n            reduced[key] = function () {\r\n                const store = useStore(this.$pinia);\r\n                const storeKey = keysOrMapper[key];\r\n                // for some reason TS is unable to infer the type of storeKey to be a\r\n                // function\r\n                return typeof storeKey === 'function'\r\n                    ? storeKey.call(this, store)\r\n                    : store[storeKey];\r\n            };\r\n            return reduced;\r\n        }, {});\r\n}\r\n/**\r\n * Alias for `mapState()`. You should use `mapState()` instead.\r\n * @deprecated use `mapState()` instead.\r\n */\r\nconst mapGetters = mapState;\r\n/**\r\n * Allows directly using actions from your store without using the composition\r\n * API (`setup()`) by generating an object to be spread in the `methods` field\r\n * of a component.\r\n *\r\n * @param useStore - store to map from\r\n * @param keysOrMapper - array or object\r\n */\r\nfunction mapActions(useStore, keysOrMapper) {\r\n    return Array.isArray(keysOrMapper)\r\n        ? keysOrMapper.reduce((reduced, key) => {\r\n            // @ts-expect-error\r\n            reduced[key] = function (...args) {\r\n                return useStore(this.$pinia)[key](...args);\r\n            };\r\n            return reduced;\r\n        }, {})\r\n        : Object.keys(keysOrMapper).reduce((reduced, key) => {\r\n            // @ts-expect-error\r\n            reduced[key] = function (...args) {\r\n                return useStore(this.$pinia)[keysOrMapper[key]](...args);\r\n            };\r\n            return reduced;\r\n        }, {});\r\n}\r\n/**\r\n * Allows using state and getters from one store without using the composition\r\n * API (`setup()`) by generating an object to be spread in the `computed` field\r\n * of a component.\r\n *\r\n * @param useStore - store to map from\r\n * @param keysOrMapper - array or object\r\n */\r\nfunction mapWritableState(useStore, keysOrMapper) {\r\n    return Array.isArray(keysOrMapper)\r\n        ? keysOrMapper.reduce((reduced, key) => {\r\n            // @ts-ignore\r\n            reduced[key] = {\r\n                get() {\r\n                    return useStore(this.$pinia)[key];\r\n                },\r\n                set(value) {\r\n                    // it's easier to type it here as any\r\n                    return (useStore(this.$pinia)[key] = value);\r\n                },\r\n            };\r\n            return reduced;\r\n        }, {})\r\n        : Object.keys(keysOrMapper).reduce((reduced, key) => {\r\n            // @ts-ignore\r\n            reduced[key] = {\r\n                get() {\r\n                    return useStore(this.$pinia)[keysOrMapper[key]];\r\n                },\r\n                set(value) {\r\n                    // it's easier to type it here as any\r\n                    return (useStore(this.$pinia)[keysOrMapper[key]] = value);\r\n                },\r\n            };\r\n            return reduced;\r\n        }, {});\r\n}\n\n/**\r\n * Creates an object of references with all the state, getters, and plugin-added\r\n * state properties of the store. Similar to `toRefs()` but specifically\r\n * designed for Pinia stores so methods and non reactive properties are\r\n * completely ignored.\r\n *\r\n * @param store - store to extract the refs from\r\n */\r\nfunction storeToRefs(store) {\r\n    // See https://github.com/vuejs/pinia/issues/852\r\n    // It's easier to just use toRefs() even if it includes more stuff\r\n    if (isVue2) {\r\n        // @ts-expect-error: toRefs include methods and others\r\n        return toRefs(store);\r\n    }\r\n    else {\r\n        store = toRaw(store);\r\n        const refs = {};\r\n        for (const key in store) {\r\n            const value = store[key];\r\n            if (isRef(value) || isReactive(value)) {\r\n                // @ts-expect-error: the key is state or getter\r\n                refs[key] =\r\n                    // ---\r\n                    toRef(store, key);\r\n            }\r\n        }\r\n        return refs;\r\n    }\r\n}\n\n/**\r\n * Vue 2 Plugin that must be installed for pinia to work. Note **you don't need\r\n * this plugin if you are using Nuxt.js**. Use the `buildModule` instead:\r\n * https://pinia.vuejs.org/ssr/nuxt.html.\r\n *\r\n * @example\r\n * ```js\r\n * import Vue from 'vue'\r\n * import { PiniaVuePlugin, createPinia } from 'pinia'\r\n *\r\n * Vue.use(PiniaVuePlugin)\r\n * const pinia = createPinia()\r\n *\r\n * new Vue({\r\n *   el: '#app',\r\n *   // ...\r\n *   pinia,\r\n * })\r\n * ```\r\n *\r\n * @param _Vue - `Vue` imported from 'vue'.\r\n */\r\nconst PiniaVuePlugin = function (_Vue) {\r\n    // Equivalent of\r\n    // app.config.globalProperties.$pinia = pinia\r\n    _Vue.mixin({\r\n        beforeCreate() {\r\n            const options = this.$options;\r\n            if (options.pinia) {\r\n                const pinia = options.pinia;\r\n                // HACK: taken from provide(): https://github.com/vuejs/composition-api/blob/main/src/apis/inject.ts#L31\r\n                /* istanbul ignore else */\r\n                if (!this._provided) {\r\n                    const provideCache = {};\r\n                    Object.defineProperty(this, '_provided', {\r\n                        get: () => provideCache,\r\n                        set: (v) => Object.assign(provideCache, v),\r\n                    });\r\n                }\r\n                this._provided[piniaSymbol] = pinia;\r\n                // propagate the pinia instance in an SSR friendly way\r\n                // avoid adding it to nuxt twice\r\n                /* istanbul ignore else */\r\n                if (!this.$pinia) {\r\n                    this.$pinia = pinia;\r\n                }\r\n                pinia._a = this;\r\n                if (IS_CLIENT) {\r\n                    // this allows calling useStore() outside of a component setup after\r\n                    // installing pinia's plugin\r\n                    setActivePinia(pinia);\r\n                }\r\n                if (USE_DEVTOOLS) {\r\n                    registerPiniaDevtools(pinia._a, pinia);\r\n                }\r\n            }\r\n            else if (!this.$pinia && options.parent && options.parent.$pinia) {\r\n                this.$pinia = options.parent.$pinia;\r\n            }\r\n        },\r\n        destroyed() {\r\n            delete this._pStores;\r\n        },\r\n    });\r\n};\n\nexport { MutationType, PiniaVuePlugin, acceptHMRUpdate, createPinia, defineStore, getActivePinia, mapActions, mapGetters, mapState, mapStores, mapWritableState, setActivePinia, setMapStoreSuffix, skipHydrate, storeToRefs };\n","import { defineComponent as y, openBlock as a, createBlock as g, TransitionGroup as x, withCtx as $, renderSlot as T, createElementBlock as p, normalizeStyle as b, resolveDynamicComponent as k, Fragment as _, renderList as B, normalizeClass as D, createElementVNode as N, createCommentVNode as H } from \"vue\";\nfunction M(t) {\n  return { all: t = t || /* @__PURE__ */ new Map(), on: function(e, i) {\n    var s = t.get(e);\n    s ? s.push(i) : t.set(e, [i]);\n  }, off: function(e, i) {\n    var s = t.get(e);\n    s && (i ? s.splice(s.indexOf(i) >>> 0, 1) : t.set(e, []));\n  }, emit: function(e, i) {\n    var s = t.get(e);\n    s && s.slice().map(function(n) {\n      n(i);\n    }), (s = t.get(\"*\")) && s.slice().map(function(n) {\n      n(e, i);\n    });\n  } };\n}\nconst d = M(), C = /* @__PURE__ */ new Map(), w = {\n  x: [\"left\", \"center\", \"right\"],\n  y: [\"top\", \"bottom\"]\n}, R = ((t) => () => t++)(0), V = (t) => typeof t != \"string\" ? [] : t.split(/\\s+/gi).filter((e) => e), W = (t) => {\n  typeof t == \"string\" && (t = V(t));\n  let e = null, i = null;\n  return t.forEach((s) => {\n    w.y.indexOf(s) !== -1 && (i = s), w.x.indexOf(s) !== -1 && (e = s);\n  }), { x: e, y: i };\n};\nclass Y {\n  constructor(e, i, s) {\n    this.remaining = i, this.callback = e, this.notifyItem = s, this.resume();\n  }\n  pause() {\n    clearTimeout(this.notifyItem.timer), this.remaining -= Date.now() - this.start;\n  }\n  resume() {\n    this.start = Date.now(), clearTimeout(this.notifyItem.timer), this.notifyItem.timer = setTimeout(this.callback, this.remaining);\n  }\n}\nconst m = {\n  position: [\"top\", \"right\"],\n  cssAnimation: \"vn-fade\",\n  velocityAnimation: {\n    enter: (t) => ({\n      height: [t.clientHeight, 0],\n      opacity: [1, 0]\n    }),\n    leave: {\n      height: 0,\n      opacity: [0, 1]\n    }\n  }\n}, j = y({\n  name: \"velocity-group\",\n  emits: [\"after-leave\", \"leave\", \"enter\"],\n  methods: {\n    enter(t, e) {\n      this.$emit(\"enter\", t, e);\n    },\n    leave(t, e) {\n      this.$emit(\"leave\", t, e);\n    },\n    afterLeave() {\n      this.$emit(\"after-leave\");\n    }\n  }\n}), v = (t, e) => {\n  const i = t.__vccOpts || t;\n  for (const [s, n] of e)\n    i[s] = n;\n  return i;\n};\nfunction G(t, e, i, s, n, c) {\n  return a(), g(x, {\n    tag: \"span\",\n    css: !1,\n    onEnter: t.enter,\n    onLeave: t.leave,\n    onAfterLeave: t.afterLeave\n  }, {\n    default: $(() => [\n      T(t.$slots, \"default\")\n    ]),\n    _: 3\n  }, 8, [\"onEnter\", \"onLeave\", \"onAfterLeave\"]);\n}\nconst z = /* @__PURE__ */ v(j, [[\"render\", G]]), F = y({\n  name: \"css-group\",\n  inheritAttrs: !1,\n  props: {\n    name: { type: String, required: !0 }\n  }\n});\nfunction P(t, e, i, s, n, c) {\n  return a(), g(x, {\n    tag: \"span\",\n    name: t.name\n  }, {\n    default: $(() => [\n      T(t.$slots, \"default\")\n    ]),\n    _: 3\n  }, 8, [\"name\"]);\n}\nconst q = /* @__PURE__ */ v(F, [[\"render\", P]]), h = \"[-+]?[0-9]*.?[0-9]+\", L = [\n  {\n    name: \"px\",\n    regexp: new RegExp(`^${h}px$`)\n  },\n  {\n    name: \"%\",\n    regexp: new RegExp(`^${h}%$`)\n  },\n  /**\n   * Fallback option\n   * If no suffix specified, assigning \"px\"\n   */\n  {\n    name: \"px\",\n    regexp: new RegExp(`^${h}$`)\n  }\n], J = (t) => {\n  if (t === \"auto\")\n    return {\n      type: t,\n      value: 0\n    };\n  for (let e = 0; e < L.length; e++) {\n    const i = L[e];\n    if (i.regexp.test(t))\n      return {\n        type: i.name,\n        value: parseFloat(t)\n      };\n  }\n  return {\n    type: \"\",\n    value: t\n  };\n}, K = (t) => {\n  switch (typeof t) {\n    case \"number\":\n      return { type: \"px\", value: t };\n    case \"string\":\n      return J(t);\n    default:\n      return { type: \"\", value: t };\n  }\n}, f = {\n  IDLE: 0,\n  DESTROYED: 2\n}, Q = y({\n  name: \"notifications\",\n  components: {\n    VelocityGroup: z,\n    CssGroup: q\n  },\n  props: {\n    group: {\n      type: String,\n      default: \"\"\n    },\n    width: {\n      type: [Number, String],\n      default: 300\n    },\n    reverse: {\n      type: Boolean,\n      default: !1\n    },\n    position: {\n      type: [String, Array],\n      default: m.position\n    },\n    classes: {\n      type: String,\n      default: \"vue-notification\"\n    },\n    animationType: {\n      type: String,\n      default: \"css\"\n    },\n    animation: {\n      type: Object,\n      default: m.velocityAnimation\n    },\n    animationName: {\n      type: String,\n      default: m.cssAnimation\n    },\n    speed: {\n      type: Number,\n      default: 300\n    },\n    /* Todo */\n    cooldown: {\n      type: Number,\n      default: 0\n    },\n    duration: {\n      type: Number,\n      default: 3e3\n    },\n    delay: {\n      type: Number,\n      default: 0\n    },\n    max: {\n      type: Number,\n      default: 1 / 0\n    },\n    ignoreDuplicates: {\n      type: Boolean,\n      default: !1\n    },\n    closeOnClick: {\n      type: Boolean,\n      default: !0\n    },\n    pauseOnHover: {\n      type: Boolean,\n      default: !1\n    }\n  },\n  emits: [\"click\", \"destroy\", \"start\"],\n  data() {\n    return {\n      list: [],\n      velocity: C.get(\"velocity\"),\n      timerControl: null\n    };\n  },\n  computed: {\n    actualWidth() {\n      return K(this.width);\n    },\n    isVA() {\n      return this.animationType === \"velocity\";\n    },\n    componentName() {\n      return this.isVA ? \"velocity-group\" : \"css-group\";\n    },\n    styles() {\n      const { x: t, y: e } = W(this.position), i = this.actualWidth.value, s = this.actualWidth.type, n = {\n        width: i + s\n      };\n      return e && (n[e] = \"0px\"), t && (t === \"center\" ? n.left = `calc(50% - ${+i / 2}${s})` : n[t] = \"0px\"), n;\n    },\n    active() {\n      return this.list.filter((t) => t.state !== f.DESTROYED);\n    },\n    botToTop() {\n      return this.styles.hasOwnProperty(\"bottom\");\n    }\n  },\n  mounted() {\n    d.on(\"add\", this.addItem), d.on(\"close\", this.closeItem);\n  },\n  methods: {\n    destroyIfNecessary(t) {\n      this.$emit(\"click\", t), this.closeOnClick && this.destroy(t);\n    },\n    pauseTimeout() {\n      var t;\n      this.pauseOnHover && ((t = this.timerControl) == null || t.pause());\n    },\n    resumeTimeout() {\n      var t;\n      this.pauseOnHover && ((t = this.timerControl) == null || t.resume());\n    },\n    addItem(t = {}) {\n      if (t.group || (t.group = \"\"), t.data || (t.data = {}), this.group !== t.group)\n        return;\n      if (t.clean || t.clear) {\n        this.destroyAll();\n        return;\n      }\n      const e = typeof t.duration == \"number\" ? t.duration : this.duration, i = typeof t.speed == \"number\" ? t.speed : this.speed, s = typeof t.ignoreDuplicates == \"boolean\" ? t.ignoreDuplicates : this.ignoreDuplicates, { title: n, text: c, type: o, data: l, id: I } = t, r = {\n        id: I || R(),\n        title: n,\n        text: c,\n        type: o,\n        state: f.IDLE,\n        speed: i,\n        length: e + 2 * i,\n        data: l\n      };\n      e >= 0 && (this.timerControl = new Y(() => this.destroy(r), r.length, r));\n      const O = this.reverse ? !this.botToTop : this.botToTop;\n      let u = -1;\n      const S = this.active.some((E) => E.title === t.title && E.text === t.text);\n      (!s || !S) && (O ? (this.list.push(r), this.$emit(\"start\", r), this.active.length > this.max && (u = 0)) : (this.list.unshift(r), this.$emit(\"start\", r), this.active.length > this.max && (u = this.active.length - 1)), u !== -1 && this.destroy(this.active[u]));\n    },\n    closeItem(t) {\n      this.destroyById(t);\n    },\n    notifyClass(t) {\n      return [\n        \"vue-notification-template\",\n        this.classes,\n        t.type || \"\"\n      ];\n    },\n    notifyWrapperStyle(t) {\n      return this.isVA ? void 0 : { transition: `all ${t.speed}ms` };\n    },\n    destroy(t) {\n      clearTimeout(t.timer), t.state = f.DESTROYED, this.clean(), this.$emit(\"destroy\", t);\n    },\n    destroyById(t) {\n      const e = this.list.find((i) => i.id === t);\n      e && this.destroy(e);\n    },\n    destroyAll() {\n      this.active.forEach(this.destroy);\n    },\n    getAnimation(t, e) {\n      var s;\n      const i = (s = this.animation) == null ? void 0 : s[t];\n      return typeof i == \"function\" ? i.call(this, e) : i;\n    },\n    enter(t, e) {\n      if (!this.isVA)\n        return;\n      const i = this.getAnimation(\"enter\", t);\n      this.velocity(t, i, {\n        duration: this.speed,\n        complete: e\n      });\n    },\n    leave(t, e) {\n      if (!this.isVA)\n        return;\n      const i = this.getAnimation(\"leave\", t);\n      this.velocity(t, i, {\n        duration: this.speed,\n        complete: e\n      });\n    },\n    clean() {\n      this.list = this.list.filter((t) => t.state !== f.DESTROYED);\n    }\n  }\n});\nconst U = [\"data-id\"], X = [\"onClick\"], Z = [\"innerHTML\"], tt = [\"innerHTML\"];\nfunction et(t, e, i, s, n, c) {\n  return a(), p(\"div\", {\n    class: \"vue-notification-group\",\n    style: b(t.styles)\n  }, [\n    (a(), g(k(t.componentName), {\n      name: t.animationName,\n      onEnter: t.enter,\n      onLeave: t.leave,\n      onAfterLeave: t.clean\n    }, {\n      default: $(() => [\n        (a(!0), p(_, null, B(t.active, (o) => (a(), p(\"div\", {\n          key: o.id,\n          class: \"vue-notification-wrapper\",\n          style: b(t.notifyWrapperStyle(o)),\n          \"data-id\": o.id,\n          onMouseenter: e[0] || (e[0] = (...l) => t.pauseTimeout && t.pauseTimeout(...l)),\n          onMouseleave: e[1] || (e[1] = (...l) => t.resumeTimeout && t.resumeTimeout(...l))\n        }, [\n          T(t.$slots, \"body\", {\n            class: D([t.classes, o.type]),\n            item: o,\n            close: () => t.destroy(o)\n          }, () => [\n            N(\"div\", {\n              class: D(t.notifyClass(o)),\n              onClick: (l) => t.destroyIfNecessary(o)\n            }, [\n              o.title ? (a(), p(\"div\", {\n                key: 0,\n                class: \"notification-title\",\n                innerHTML: o.title\n              }, null, 8, Z)) : H(\"\", !0),\n              N(\"div\", {\n                class: \"notification-content\",\n                innerHTML: o.text\n              }, null, 8, tt)\n            ], 10, X)\n          ])\n        ], 44, U))), 128))\n      ]),\n      _: 3\n    }, 40, [\"name\", \"onEnter\", \"onLeave\", \"onAfterLeave\"]))\n  ], 4);\n}\nconst it = /* @__PURE__ */ v(Q, [[\"render\", et]]), A = (t) => {\n  typeof t == \"string\" && (t = { title: \"\", text: t }), typeof t == \"object\" && d.emit(\"add\", t);\n};\nA.close = (t) => {\n  d.emit(\"close\", t);\n};\nconst rt = () => ({ notify: A });\nfunction st(t, e = {}) {\n  Object.entries(e).forEach((s) => C.set(...s));\n  const i = e.name || \"notify\";\n  t.config.globalProperties[\"$\" + i] = A, t.component(e.componentName || \"Notifications\", it);\n}\nconst at = {\n  install: st\n};\nexport {\n  at as default,\n  A as notify,\n  rt as useNotification\n};\n(function(){var o;\"use strict\";try{if(typeof document!=\"undefined\"){var e=document.createElement(\"style\");e.nonce=(o=document.head.querySelector(\"meta[property=csp-nonce]\"))==null?void 0:o.content,e.appendChild(document.createTextNode(\".vue-notification-group{display:block;position:fixed;z-index:5000}.vue-notification-wrapper{display:block;overflow:hidden;width:100%;margin:0;padding:0}.notification-title{font-weight:600}.vue-notification-template{display:block;box-sizing:border-box;background:white;text-align:left}.vue-notification{display:block;box-sizing:border-box;text-align:left;font-size:12px;padding:10px;margin:0 5px 5px;color:#fff;background:#44A4FC;border-left:5px solid #187FE7}.vue-notification.warn{background:#ffb648;border-left-color:#f48a06}.vue-notification.error{background:#E54D42;border-left-color:#b82e24}.vue-notification.success{background:#68CD86;border-left-color:#42a85f}.vn-fade-enter-active,.vn-fade-leave-active,.vn-fade-move{transition:all .5s}.vn-fade-enter-from,.vn-fade-leave-to{opacity:0}\")),document.head.appendChild(e)}}catch(i){console.error(\"vite-plugin-css-injected-by-js\",i)}})();\n","\n       if (typeof window !== 'undefined') {\n         function loadSvg() {\n           var body = document.body;\n           var svgDom = document.getElementById('__svg__icons__dom__');\n           if(!svgDom) {\n             svgDom = document.createElementNS('http://www.w3.org/2000/svg', 'svg');\n             svgDom.style.position = 'absolute';\n             svgDom.style.width = '0';\n             svgDom.style.height = '0';\n             svgDom.id = '__svg__icons__dom__';\n             svgDom.setAttribute('xmlns','http://www.w3.org/2000/svg');\n             svgDom.setAttribute('xmlns:link','http://www.w3.org/1999/xlink');\n           }\n           svgDom.innerHTML = \"<symbol  fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" stroke-width=\\\"1.5\\\" stroke=\\\"currentColor\\\" class=\\\"w-6 h-6\\\" id=\\\"arrow-path\\\"><path stroke-linecap=\\\"round\\\" stroke-linejoin=\\\"round\\\" d=\\\"M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0 3.181 3.183a8.25 8.25 0 0 0 13.803-3.7M4.031 9.865a8.25 8.25 0 0 1 13.803-3.7l3.181 3.182m0-4.991v4.99\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 32 32\\\" id=\\\"bag\\\"><g fill=\\\"currentColor\\\" clip-path=\\\"url(#bag_a)\\\"><path d=\\\"m2.129 9.115 1.35 20.945h25.042l1.35-20.945H2.129Zm-.426-1.939h28.594c.884 0 1.6.695 1.6 1.552 0 .032-.001.065-.003.097l-1.4 21.721c-.053.818-.752 1.455-1.597 1.455H3.103c-.845 0-1.544-.637-1.597-1.455L.106 8.825C.051 7.97.721 7.233 1.603 7.18a1.67 1.67 0 0 1 .1-.003v-.001Z\\\" /><path d=\\\"M23.2 12.57V7.176C23.2 3.32 19.976.194 16 .194S8.8 3.32 8.8 7.176v5.394h1.6V7.176c0-2.999 2.507-5.43 5.6-5.43 3.093 0 5.6 2.431 5.6 5.43v5.394h1.6Z\\\" /></g><defs><clipPath id=\\\"bag_a\\\"><path fill=\\\"#fff\\\" d=\\\"M0 0h32v32H0z\\\" /></clipPath></defs></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 32 32\\\" id=\\\"check\\\"><path fill=\\\"currentColor\\\" d=\\\"M3.374 12.879 0 16.221l11.537 11.648L31.999 7.353l-3.363-3.354-17.088 17.133-8.174-8.253Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 32 20\\\" id=\\\"chevron-down\\\"><path fill=\\\"currentColor\\\" d=\\\"M3.561.439 0 4l16 16L32 4 28.439.439 16 12.878 3.561.439Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 32 32\\\" id=\\\"chevron-left\\\"><path fill=\\\"currentColor\\\" d=\\\"M24.561 3.561 21 0 5 16l16 16 3.561-3.561L12.122 16 24.561 3.561Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 32 32\\\" id=\\\"chevron-right\\\"><path fill=\\\"currentColor\\\" d=\\\"M7 28.439 10.561 32l16-16-16-16L7 3.561 19.439 16 7 28.439Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 32 32\\\" id=\\\"close\\\"><path fill=\\\"currentColor\\\" d=\\\"m.843 2.72 28.436 28.444 1.886-1.885L2.729.835.843 2.72Z\\\" /><path fill=\\\"currentColor\\\" d=\\\"M29.284.839.84 29.275l1.885 1.886L31.169 2.725 29.284.839Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 36 36\\\" id=\\\"edit\\\"><g clip-path=\\\"url(#edit_a)\\\"><path fill=\\\"#000\\\" d=\\\"M33.87 8.32 28 2.42a2.07 2.07 0 0 0-2.92 0L4.27 23.2l-1.9 8.2a2.06 2.06 0 0 0 2 2.5c.143.014.287.014.43 0l8.29-1.9 20.78-20.76a2.07 2.07 0 0 0 0-2.92ZM12.09 30.2l-7.77 1.63 1.77-7.62L21.66 8.7l6 6-15.57 15.5ZM29 13.25l-6-6 3.48-3.46 5.9 6L29 13.25Z\\\" /></g><defs><clipPath id=\\\"edit_a\\\"><path fill=\\\"#fff\\\" d=\\\"M0 0h36v36H0z\\\" /></clipPath></defs></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" id=\\\"facebook\\\"><path fill=\\\"currentColor\\\" d=\\\"M20 3H4a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h8.615v-6.96h-2.338v-2.725h2.338v-2c0-2.325 1.42-3.592 3.5-3.592.699-.002 1.399.034 2.095.107v2.42h-1.435c-1.128 0-1.348.538-1.348 1.325v1.735h2.697l-.35 2.725h-2.348V21H20a1 1 0 0 0 1-1V4a1 1 0 0 0-1-1Z\\\" /></symbol><symbol  fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" stroke-width=\\\"1.5\\\" stroke=\\\"currentColor\\\" class=\\\"w-6 h-6\\\" id=\\\"home\\\"><path stroke-linecap=\\\"round\\\" stroke-linejoin=\\\"round\\\" d=\\\"m2.25 12 8.954-8.955a1.126 1.126 0 0 1 1.591 0L21.75 12M4.5 9.75v10.125c0 .621.504 1.125 1.125 1.125H9.75v-4.875c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21h4.125c.621 0 1.125-.504 1.125-1.125V9.75M8.25 21h8.25\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" id=\\\"instagram\\\"><path fill=\\\"currentColor\\\" d=\\\"M20.947 8.305a6.531 6.531 0 0 0-.419-2.216 4.61 4.61 0 0 0-2.633-2.633 6.606 6.606 0 0 0-2.186-.42c-.962-.043-1.267-.055-3.709-.055s-2.755 0-3.71.055a6.606 6.606 0 0 0-2.185.42 4.607 4.607 0 0 0-2.633 2.633 6.554 6.554 0 0 0-.419 2.185c-.043.963-.056 1.268-.056 3.71s0 2.754.056 3.71c.015.748.156 1.486.419 2.187a4.61 4.61 0 0 0 2.634 2.632 6.586 6.586 0 0 0 2.185.45c.963.043 1.268.056 3.71.056s2.755 0 3.71-.056a6.592 6.592 0 0 0 2.186-.419 4.618 4.618 0 0 0 2.633-2.633c.263-.7.404-1.438.419-2.187.043-.962.056-1.267.056-3.71-.002-2.442-.002-2.752-.058-3.709Zm-8.953 8.297a4.622 4.622 0 0 1-4.623-4.623 4.622 4.622 0 1 1 4.623 4.623Zm4.807-8.339a1.077 1.077 0 1 1-.002-2.155 1.077 1.077 0 0 1 .002 2.155Z\\\" /><path fill=\\\"currentColor\\\" d=\\\"M11.994 14.982a3.003 3.003 0 1 0 0-6.006 3.003 3.003 0 0 0 0 6.006Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" id=\\\"linkedin\\\"><path fill=\\\"currentColor\\\" d=\\\"M20 3H4a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h16a1 1 0 0 0 1-1V4a1 1 0 0 0-1-1ZM8.339 18.337H5.667v-8.59h2.672v8.59ZM7.003 8.574a1.548 1.548 0 1 1 0-3.096 1.548 1.548 0 0 1 0 3.096Zm11.335 9.763h-2.669V14.16c0-.996-.018-2.277-1.388-2.277-1.39 0-1.601 1.086-1.601 2.207v4.248h-2.667v-8.59h2.56v1.174h.037c.355-.675 1.227-1.387 2.524-1.387 2.704 0 3.203 1.778 3.203 4.092v4.71h.001Z\\\" /></symbol><symbol  fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" stroke-width=\\\"1.5\\\" stroke=\\\"currentColor\\\" class=\\\"w-6 h-6\\\" id=\\\"minus\\\"><path stroke-linecap=\\\"round\\\" stroke-linejoin=\\\"round\\\" d=\\\"M19.5 12h-15\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 28 16\\\" id=\\\"navigation-left\\\"><g fill=\\\"currentColor\\\" clip-path=\\\"url(#navigation-left_a)\\\"><path d=\\\"M9.319 1.742 7.905.328.42 7.812l7.484 7.484 1.414-1.414-6.07-6.07 6.07-6.07Z\\\" /><path d=\\\"M2.416 8.814h25.17v-2H2.417v2Z\\\" /><path d=\\\"M9.319 1.742 7.905.328.42 7.812l7.484 7.484 1.414-1.414-6.07-6.07 6.07-6.07Z\\\" /><path d=\\\"M2.416 8.814h25.17v-2H2.417v2Z\\\" /></g><defs><clipPath id=\\\"navigation-left_a\\\"><path fill=\\\"#fff\\\" d=\\\"M0 0h28v16H0z\\\" transform=\\\"rotate(-180 14 8)\\\" /></clipPath></defs></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 28 16\\\" id=\\\"navigation-right\\\"><g fill=\\\"currentColor\\\" clip-path=\\\"url(#navigation-right_a)\\\"><path d=\\\"m18.681 14.258 1.414 1.414 7.484-7.484L20.095.704l-1.414 1.414 6.07 6.07-6.07 6.07Z\\\" /><path d=\\\"M25.584 7.186H.414v2h25.17v-2Z\\\" /><path d=\\\"m18.681 14.258 1.414 1.414 7.484-7.484L20.095.704l-1.414 1.414 6.07 6.07-6.07 6.07Z\\\" /><path d=\\\"M25.584 7.186H.414v2h25.17v-2Z\\\" /></g><defs><clipPath id=\\\"navigation-right_a\\\"><path fill=\\\"#fff\\\" d=\\\"M0 0h28v16H0z\\\" /></clipPath></defs></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" id=\\\"pinterest\\\"><path fill=\\\"currentColor\\\" d=\\\"M11.99 2C6.472 2 2 6.473 2 11.99c0 4.232 2.633 7.85 6.35 9.306-.088-.79-.166-2.006.034-2.868.182-.78 1.172-4.966 1.172-4.966s-.299-.599-.299-1.484c0-1.388.805-2.425 1.808-2.425.853 0 1.264.64 1.264 1.407 0 .858-.546 2.139-.827 3.327-.235.994.499 1.805 1.479 1.805 1.775 0 3.141-1.872 3.141-4.575 0-2.392-1.719-4.064-4.173-4.064-2.843 0-4.512 2.132-4.512 4.335 0 .858.331 1.779.744 2.28a.3.3 0 0 1 .069.286c-.076.315-.245.994-.277 1.133-.044.183-.145.222-.335.134-1.247-.581-2.027-2.405-2.027-3.871 0-3.151 2.289-6.045 6.601-6.045 3.466 0 6.159 2.469 6.159 5.77 0 3.444-2.171 6.213-5.184 6.213-1.013 0-1.964-.525-2.29-1.146l-.623 2.374c-.225.868-.834 1.956-1.241 2.62a10 10 0 0 0 2.958.445c5.517 0 9.99-4.473 9.99-9.99S17.507 2 11.99 2Z\\\" /></symbol><symbol  fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" stroke-width=\\\"1.5\\\" stroke=\\\"currentColor\\\" class=\\\"w-6 h-6\\\" id=\\\"plus\\\"><path stroke-linecap=\\\"round\\\" stroke-linejoin=\\\"round\\\" d=\\\"M12 4.5v15m7.5-7.5h-15\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 559 553\\\" id=\\\"postnl\\\"><path fill=\\\"#BCBCBE\\\" d=\\\"M368.768 82.291C296.962 42.666 189.095.018 121.955.018c-17.614 0-31.802 2.905-42.162 8.61-25.077 13.846-46.047 51.188-60.677 108.031C6.978 163.907 0 222.038 0 276.126c0 107.642 24.972 237.258 79.793 267.525 11.216 6.188 26.22 9.334 44.607 9.334 69.367 0 174.986-44.721 244.368-83.013C445.189 427.801 558.883 341.391 559 276.126c-.105-61.331-111.288-150.266-190.232-193.835Zm-9.021 374.154c-110.137 60.776-227.104 95.714-270.055 72.044C42.33 502.333 18.612 377.351 18.6 277.794c.012-98.785 25.19-225.336 71.092-250.68 40.29-22.242 162.589 12.722 270.055 72.023 93.134 51.409 180.565 132.06 180.644 178.657-.088 48.848-86.039 126.446-180.644 178.651Z\\\" /><path fill=\\\"#313237\\\" d=\\\"M359.747 456.445c-110.137 60.776-227.104 95.714-270.055 72.044C42.33 502.334 18.612 377.351 18.6 277.794c.012-98.784 25.19-225.336 71.092-250.68 40.29-22.242 162.589 12.722 270.055 72.023 93.134 51.409 180.565 132.06 180.644 178.657-.088 48.848-86.039 126.446-180.644 178.651Z\\\" /><path fill=\\\"url(#postnl_a)\\\" d=\\\"M359.747 456.445c-110.137 60.776-227.104 95.714-270.055 72.044C42.33 502.334 18.612 377.351 18.6 277.794c.012-98.784 25.19-225.336 71.092-250.68 40.29-22.242 162.589 12.722 270.055 72.023 93.134 51.409 180.565 132.06 180.644 178.657-.088 48.848-86.039 126.446-180.644 178.651Z\\\" /><path fill=\\\"#001C87\\\" d=\\\"M188.043 245.699c-22.31 0-40.266 12.39-40.266 40.292 0 27.262 17.956 40.286 40.266 40.286 22.23 0 40.221-13.024 40.221-40.286-.003-27.881-17.991-40.292-40.221-40.292Zm0 61.412c-9.961 0-17.437-7.581-17.437-21.111 0-14.722 7.476-21.163 17.437-21.163 9.926 0 17.392 6.438 17.392 21.163-.003 13.53-7.466 21.111-17.392 21.111Zm165.118-.691c-.747 0-5.829 1.992-9.072 1.992-6.9 0-11.026-3.259-11.026-14.191v-28.473c0-.407.322-.748.747-.748h18.64a.734.734 0 0 0 .747-.751h.012l-.012-14.656a2.45 2.45 0 0 0-2.438-2.437H333.81a.724.724 0 0 1-.531-.213.74.74 0 0 1-.216-.529v-20.159c0-.615-.271-.796-.92-.796-1.495 0-13.099 7.457-16.701 11.419a17.364 17.364 0 0 0-4.416 11.53v49.526c0 21.489 12.398 28.207 25.738 28.207 7.629 0 12.81-1.122 15.885-2.781a2.458 2.458 0 0 0 1.272-2.157v-14.031a.758.758 0 0 0-.76-.752ZM95.639 247.156h-29.34a2.48 2.48 0 0 0-2.313 1.52 2.489 2.489 0 0 0-.195.953v90.166a17.412 17.412 0 0 0 4.416 11.536c3.626 3.976 15.224 11.419 16.732 11.419.648 0 .907-.175.907-.8v-36.331c0-.431.322-.763.753-.763h8.578c27.511 0 44.224-15.536 44.224-37.969-.003-22.403-14.932-39.731-43.762-39.731Zm0 57.518h-9.055a.756.756 0 0 1-.526-.222.743.743 0 0 1-.215-.529v-35.858c0-.407.322-.751.741-.751h8.612c16.264 0 22.434 8.936 22.434 18.472.003 5.406-2.61 18.888-21.991 18.888ZM290.316 282.6c-4.557-2.993-10.112-4.212-15.489-5.376-.959-.223-4.534-1.023-5.339-1.21-6.564-1.454-11.746-2.609-11.746-6.869 0-3.677 3.551-6.076 9.013-6.076 6.923 0 16.523 1.391 27.021 5.325.525.193 1.248-.115 1.284-.821v-15.225a2.578 2.578 0 0 0-1.808-2.429c-3.668-1.164-14.582-4.214-23.818-4.214-10.26 0-18.814 2.292-24.713 6.667-5.974 4.362-9.13 10.67-9.13 18.251 0 17.111 14.01 20.358 27.251 23.492 2.038.477 1.718.404 2.496.567 6.046 1.321 12.31 2.712 12.31 7.696 0 1.499-.555 2.715-1.685 3.858-1.694 1.681-4.292 2.429-9.278 2.429-8.448 0-24.297-3.949-29.201-5.509a1.213 1.213 0 0 0-.322-.06.903.903 0 0 0-.659.255.898.898 0 0 0-.279.65v15.256a2.5 2.5 0 0 0 1.694 2.374c.106.057 13.989 4.655 27.085 4.655 22.92 0 34.663-8.978 34.663-25.344 0-8.23-3.074-14.206-9.35-18.342Z\\\" /><path fill=\\\"#fff\\\" d=\\\"M188.019 147.258c-.407 0-.813-.169-1.278-.51a49.666 49.666 0 0 1-8.415-8.495c-.247-.371-.844-1.092-.036-1.997a47.717 47.717 0 0 1 8.943-8.846c.382-.229.584-.28.789-.28.229 0 .446.051.823.28a46.699 46.699 0 0 1 8.907 8.846c.729.787.389 1.454-.012 1.997a50.127 50.127 0 0 1-8.425 8.495 2.092 2.092 0 0 1-1.272.51h-.024Zm-36.588 76.952v-8.353a3.53 3.53 0 0 1 3.478-3.476h66.305c.92.01 1.799.378 2.452 1.027a3.532 3.532 0 0 1 1.038 2.449v8.353c0 2.166-.789 3.08-2.637 3.08h-68.023c-1.824 0-2.613-.914-2.613-3.08Zm41.269-20.33h-9.338c-1.612 0-1.75-1.76-1.759-1.881l-.001-.005c-.015-.362-.494-39.209-.569-44.488 0-.392.111-1.273.666-1.816a1.572 1.572 0 0 1 1.154-.447c.754-.051 2.773-.132 5.157-.132a89.986 89.986 0 0 1 5.194.132c.429-.011.846.147 1.16.441.531.549.66 1.43.66 1.822-.081 5.279-.576 44.126-.576 44.488 0 .025-.111 1.886-1.748 1.886Zm28.737-43.888c2.309.688 4.741 1.514 7.219 2.419 7.466 2.797 7.165 8.191 5.7 13.648-.889 3.322-5.263 15.524-7.882 22.822-.552 1.539-1.025 2.845-1.348 3.735-.316.857-.982 1.258-2.131 1.258h-9.024c-.702 0-1.184-.187-1.438-.528-.274-.383-.31-1.005-.063-1.822 2.215-6.848 9.645-27.652 9.721-27.86.476-1.331-.03-3.207-1.432-3.726l-3.732-1.228a2.516 2.516 0 0 0-.747-.114c-.72 0-1.136.362-1.32.709-1.546 3.442-2.396 5.825-3.596 9.898-.205.687-.76 1.034-1.73 1.034h-7.3c-.549 0-.926-.15-1.125-.422-.235-.281-.265-.685-.111-1.246 1.878-6.764 3.813-12.182 6.504-18.143.464-1.05 1.619-2.787 4.09-2.787a6.63 6.63 0 0 1 1.444.187l.06.009c2.466.585 5.287 1.237 8.241 2.157Zm-68.376 43.888c-1.16 0-1.847-.407-2.161-1.261-.322-.89-.774-2.196-1.353-3.732l-.088-.245c-2.628-7.325-6.921-19.289-7.788-22.58-1.456-5.457-1.76-10.851 5.721-13.645a122.883 122.883 0 0 1 7.213-2.422c2.935-.917 5.745-1.569 8.252-2.157l.058-.009a6.147 6.147 0 0 1 1.425-.187c2.49 0 3.638 1.734 4.109 2.79 2.658 5.958 4.596 11.383 6.474 18.14.16.558.142.969-.081 1.249-.199.272-.582.419-1.137.419h-7.312c-.959 0-1.507-.347-1.718-1.031-1.176-4.073-2.071-6.477-3.602-9.901-.163-.347-.582-.709-1.323-.709a2.54 2.54 0 0 0-.724.114l-3.749 1.225c-1.396.525-1.908 2.395-1.438 3.729.09.208 7.514 21.012 9.708 27.86.26.817.242 1.439-.042 1.822-.247.344-.735.531-1.419.531h-9.025Zm245.448 45.255c5.196-1.976 10.748-3.114 15.288-3.114 16.849 0 25.749 9.684 25.749 28.023v50.076c0 .272-.192.462-.47.462h-20.58a.466.466 0 0 1-.464-.462v-46.299c0-10.296-3.497-14.682-11.68-14.682-2.915 0-6.46 1.083-9.956 3.083-3.481 2.018-6.236 3.707-7.195 4.293-.253.157-.56.63-.56 1.016v52.586c0 .247-.229.462-.489.462H367.53c-.266 0-.489-.215-.489-.462v-74.481a2.215 2.215 0 0 1 1.392-2.038 2.23 2.23 0 0 1 .851-.159h18.88a.49.49 0 0 1 .489.48v5.847a.635.635 0 0 0 .194.455.631.631 0 0 0 .46.184c.141 0 .304-.087.352-.099l.63-.486c2.309-1.783 5.83-3.78 8.22-4.685Zm58.227-39.602c1.302 0 12.783 7.232 16.497 11.331a16.984 16.984 0 0 1 4.34 11.353l.006 91.9a.482.482 0 0 1-.473.462h-20.548a.46.46 0 0 1-.452-.462l-.024-114.05c0-.407.106-.534.654-.534Z\\\" /><defs><radialGradient id=\\\"postnl_a\\\" cx=\\\"0\\\" cy=\\\"0\\\" r=\\\"1\\\" gradientTransform=\\\"matrix(133.076 364.60132 -368.86706 134.63296 146.42 171.353)\\\" gradientUnits=\\\"userSpaceOnUse\\\"><stop offset=\\\".172\\\" stop-color=\\\"#FAB001\\\" /><stop offset=\\\"1\\\" stop-color=\\\"#E76218\\\" /></radialGradient></defs></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 32 32\\\" id=\\\"search\\\"><path fill=\\\"currentColor\\\" d=\\\"M15.222 27.778c-7.487 0-13.556-6.069-13.556-13.556C1.666 6.735 7.735.666 15.222.666c7.487 0 13.556 6.069 13.556 13.556 0 7.487-6.069 13.556-13.556 13.556Zm0-2.222c6.259 0 11.333-5.074 11.333-11.333S21.481 2.89 15.222 2.89 3.889 7.964 3.889 14.223s5.074 11.333 11.333 11.333Z\\\" /><path fill=\\\"currentColor\\\" d=\\\"m21.926 24.275 7.621 7.621 1.571-1.571-7.621-7.621-1.571 1.571Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" id=\\\"tiktok\\\"><path fill=\\\"currentColor\\\" d=\\\"M19.59 6.69a4.83 4.83 0 0 1-3.77-4.25V2h-3.45v13.67a2.89 2.89 0 0 1-5.2 1.74 2.89 2.89 0 0 1 2.31-4.64 2.93 2.93 0 0 1 .88.13V9.4a6.84 6.84 0 0 0-1-.05A6.33 6.33 0 0 0 5 20.1a6.34 6.34 0 0 0 10.86-4.43v-7a8.16 8.16 0 0 0 4.77 1.52v-3.4a4.85 4.85 0 0 1-1-.1h-.04Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" id=\\\"twitter\\\"><path fill=\\\"currentColor\\\" d=\\\"M19.633 7.997c.013.175.013.349.013.523 0 5.325-4.053 11.461-11.46 11.461-2.282 0-4.402-.661-6.186-1.809.324.037.636.05.973.05a8.07 8.07 0 0 0 5.001-1.721 4.036 4.036 0 0 1-3.767-2.793c.249.037.499.062.761.062.361 0 .724-.05 1.061-.137a4.026 4.026 0 0 1-3.23-3.953v-.05c.537.299 1.16.486 1.82.511a4.021 4.021 0 0 1-1.796-3.354c0-.748.199-1.434.548-2.032a11.457 11.457 0 0 0 8.306 4.215c-.062-.3-.1-.611-.1-.923a4.024 4.024 0 0 1 4.028-4.028c1.16 0 2.207.486 2.943 1.272a7.957 7.957 0 0 0 2.556-.973c-.3.93-.93 1.72-1.771 2.22a8.073 8.073 0 0 0 2.319-.624 8.646 8.646 0 0 1-2.019 2.083Z\\\" /></symbol><symbol fill=\\\"none\\\" viewBox=\\\"0 0 24 24\\\" id=\\\"whatsapp\\\"><path fill=\\\"currentColor\\\" fill-rule=\\\"evenodd\\\" d=\\\"M18.403 5.633A8.918 8.918 0 0 0 12.053 3c-4.948 0-8.976 4.027-8.978 8.977 0 1.582.413 3.126 1.198 4.488L3 21.116l4.759-1.249a8.98 8.98 0 0 0 4.29 1.093h.004c4.947 0 8.975-4.027 8.977-8.977a8.926 8.926 0 0 0-2.627-6.35Zm-2.257 8.223c-.225-.113-1.327-.655-1.533-.73-.205-.075-.354-.112-.504.112-.15.224-.58.729-.711.879-.131.15-.262.168-.486.056-.224-.112-.947-.349-1.804-1.113-.667-.595-1.117-1.329-1.248-1.554-.131-.225-.014-.346.099-.458.101-.1.224-.262.336-.393.112-.131.149-.224.224-.374.075-.15.038-.281-.019-.393-.056-.113-.505-1.217-.692-1.666-.181-.435-.366-.377-.504-.383a9.649 9.649 0 0 0-.429-.008.826.826 0 0 0-.599.28c-.206.225-.785.767-.785 1.871s.804 2.171.916 2.321c.112.15 1.582 2.415 3.832 3.387.536.231.954.369 1.279.473.537.171 1.026.146 1.413.089.431-.064 1.327-.542 1.514-1.066.187-.524.187-.973.131-1.067-.056-.094-.207-.151-.43-.263Z\\\" clip-rule=\\\"evenodd\\\" /></symbol>\";\n           body.insertBefore(svgDom, body.lastChild);\n         }\n         if(document.readyState === 'loading') {\n           document.addEventListener('DOMContentLoaded', loadSvg);\n         } else {\n           loadSvg()\n         }\n      }\n        \nexport default {}","/*!\n  * shared v9.5.0\n  * (c) 2023 kazuya kawaguchi\n  * Released under the MIT License.\n  */\n/**\n * Original Utilities\n * written by kazuya kawaguchi\n */\nconst inBrowser = typeof window !== 'undefined';\nlet mark;\nlet measure;\nif ((process.env.NODE_ENV !== 'production')) {\n    const perf = inBrowser && window.performance;\n    if (perf &&\n        perf.mark &&\n        perf.measure &&\n        perf.clearMarks &&\n        // @ts-ignore browser compat\n        perf.clearMeasures) {\n        mark = (tag) => {\n            perf.mark(tag);\n        };\n        measure = (name, startTag, endTag) => {\n            perf.measure(name, startTag, endTag);\n            perf.clearMarks(startTag);\n            perf.clearMarks(endTag);\n        };\n    }\n}\nconst RE_ARGS = /\\{([0-9a-zA-Z]+)\\}/g;\n/* eslint-disable */\nfunction format(message, ...args) {\n    if (args.length === 1 && isObject(args[0])) {\n        args = args[0];\n    }\n    if (!args || !args.hasOwnProperty) {\n        args = {};\n    }\n    return message.replace(RE_ARGS, (match, identifier) => {\n        return args.hasOwnProperty(identifier) ? args[identifier] : '';\n    });\n}\nconst makeSymbol = (name, shareable = false) => !shareable ? Symbol(name) : Symbol.for(name);\nconst generateFormatCacheKey = (locale, key, source) => friendlyJSONstringify({ l: locale, k: key, s: source });\nconst friendlyJSONstringify = (json) => JSON.stringify(json)\n    .replace(/\\u2028/g, '\\\\u2028')\n    .replace(/\\u2029/g, '\\\\u2029')\n    .replace(/\\u0027/g, '\\\\u0027');\nconst isNumber = (val) => typeof val === 'number' && isFinite(val);\nconst isDate = (val) => toTypeString(val) === '[object Date]';\nconst isRegExp = (val) => toTypeString(val) === '[object RegExp]';\nconst isEmptyObject = (val) => isPlainObject(val) && Object.keys(val).length === 0;\nconst assign = Object.assign;\nlet _globalThis;\nconst getGlobalThis = () => {\n    // prettier-ignore\n    return (_globalThis ||\n        (_globalThis =\n            typeof globalThis !== 'undefined'\n                ? globalThis\n                : typeof self !== 'undefined'\n                    ? self\n                    : typeof window !== 'undefined'\n                        ? window\n                        : typeof global !== 'undefined'\n                            ? global\n                            : {}));\n};\nfunction escapeHtml(rawText) {\n    return rawText\n        .replace(/</g, '&lt;')\n        .replace(/>/g, '&gt;')\n        .replace(/\"/g, '&quot;')\n        .replace(/'/g, '&apos;');\n}\nconst hasOwnProperty = Object.prototype.hasOwnProperty;\nfunction hasOwn(obj, key) {\n    return hasOwnProperty.call(obj, key);\n}\n/* eslint-enable */\n/**\n * Useful Utilities By Evan you\n * Modified by kazuya kawaguchi\n * MIT License\n * https://github.com/vuejs/vue-next/blob/master/packages/shared/src/index.ts\n * https://github.com/vuejs/vue-next/blob/master/packages/shared/src/codeframe.ts\n */\nconst isArray = Array.isArray;\nconst isFunction = (val) => typeof val === 'function';\nconst isString = (val) => typeof val === 'string';\nconst isBoolean = (val) => typeof val === 'boolean';\nconst isSymbol = (val) => typeof val === 'symbol';\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst isObject = (val) => val !== null && typeof val === 'object';\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst isPromise = (val) => {\n    return isObject(val) && isFunction(val.then) && isFunction(val.catch);\n};\nconst objectToString = Object.prototype.toString;\nconst toTypeString = (value) => objectToString.call(value);\nconst isPlainObject = (val) => {\n    if (!isObject(val))\n        return false;\n    const proto = Object.getPrototypeOf(val);\n    return proto === null || proto.constructor === Object;\n};\n// for converting list and named values to displayed strings.\nconst toDisplayString = (val) => {\n    return val == null\n        ? ''\n        : isArray(val) || (isPlainObject(val) && val.toString === objectToString)\n            ? JSON.stringify(val, null, 2)\n            : String(val);\n};\nfunction join(items, separator = '') {\n    return items.reduce((str, item, index) => (index === 0 ? str + item : str + separator + item), '');\n}\nconst RANGE = 2;\nfunction generateCodeFrame(source, start = 0, end = source.length) {\n    const lines = source.split(/\\r?\\n/);\n    let count = 0;\n    const res = [];\n    for (let i = 0; i < lines.length; i++) {\n        count += lines[i].length + 1;\n        if (count >= start) {\n            for (let j = i - RANGE; j <= i + RANGE || end > count; j++) {\n                if (j < 0 || j >= lines.length)\n                    continue;\n                const line = j + 1;\n                res.push(`${line}${' '.repeat(3 - String(line).length)}|  ${lines[j]}`);\n                const lineLength = lines[j].length;\n                if (j === i) {\n                    // push underline\n                    const pad = start - (count - lineLength) + 1;\n                    const length = Math.max(1, end > count ? lineLength - pad : end - start);\n                    res.push(`   |  ` + ' '.repeat(pad) + '^'.repeat(length));\n                }\n                else if (j > i) {\n                    if (end > count) {\n                        const length = Math.max(Math.min(end - count, lineLength), 1);\n                        res.push(`   |  ` + '^'.repeat(length));\n                    }\n                    count += lineLength + 1;\n                }\n            }\n            break;\n        }\n    }\n    return res.join('\\n');\n}\nfunction incrementer(code) {\n    let current = code;\n    return () => ++current;\n}\n\nfunction warn(msg, err) {\n    if (typeof console !== 'undefined') {\n        console.warn(`[intlify] ` + msg);\n        /* istanbul ignore if */\n        if (err) {\n            console.warn(err.stack);\n        }\n    }\n}\nconst hasWarned = {};\nfunction warnOnce(msg) {\n    if (!hasWarned[msg]) {\n        hasWarned[msg] = true;\n        warn(msg);\n    }\n}\n\n/**\n * Event emitter, forked from the below:\n * - original repository url: https://github.com/developit/mitt\n * - code url: https://github.com/developit/mitt/blob/master/src/index.ts\n * - author: Jason Miller (https://github.com/developit)\n * - license: MIT\n */\n/**\n * Create a event emitter\n *\n * @returns An event emitter\n */\nfunction createEmitter() {\n    const events = new Map();\n    const emitter = {\n        events,\n        on(event, handler) {\n            const handlers = events.get(event);\n            const added = handlers && handlers.push(handler);\n            if (!added) {\n                events.set(event, [handler]);\n            }\n        },\n        off(event, handler) {\n            const handlers = events.get(event);\n            if (handlers) {\n                handlers.splice(handlers.indexOf(handler) >>> 0, 1);\n            }\n        },\n        emit(event, payload) {\n            (events.get(event) || [])\n                .slice()\n                .map(handler => handler(payload));\n            (events.get('*') || [])\n                .slice()\n                .map(handler => handler(event, payload));\n        }\n    };\n    return emitter;\n}\n\nexport { assign, createEmitter, escapeHtml, format, friendlyJSONstringify, generateCodeFrame, generateFormatCacheKey, getGlobalThis, hasOwn, inBrowser, incrementer, isArray, isBoolean, isDate, isEmptyObject, isFunction, isNumber, isObject, isPlainObject, isPromise, isRegExp, isString, isSymbol, join, makeSymbol, mark, measure, objectToString, toDisplayString, toTypeString, warn, warnOnce };\n","/*!\n  * message-compiler v9.5.0\n  * (c) 2023 kazuya kawaguchi\n  * Released under the MIT License.\n  */\nconst LOCATION_STUB = {\n    start: { line: 1, column: 1, offset: 0 },\n    end: { line: 1, column: 1, offset: 0 }\n};\nfunction createPosition(line, column, offset) {\n    return { line, column, offset };\n}\nfunction createLocation(start, end, source) {\n    const loc = { start, end };\n    if (source != null) {\n        loc.source = source;\n    }\n    return loc;\n}\n\n/**\n * Original Utilities\n * written by kazuya kawaguchi\n */\nconst RE_ARGS = /\\{([0-9a-zA-Z]+)\\}/g;\n/* eslint-disable */\nfunction format(message, ...args) {\n    if (args.length === 1 && isObject(args[0])) {\n        args = args[0];\n    }\n    if (!args || !args.hasOwnProperty) {\n        args = {};\n    }\n    return message.replace(RE_ARGS, (match, identifier) => {\n        return args.hasOwnProperty(identifier) ? args[identifier] : '';\n    });\n}\nconst assign = Object.assign;\nconst isString = (val) => typeof val === 'string';\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst isObject = (val) => val !== null && typeof val === 'object';\nfunction join(items, separator = '') {\n    return items.reduce((str, item, index) => (index === 0 ? str + item : str + separator + item), '');\n}\n\nconst CompileErrorCodes = {\n    // tokenizer error codes\n    EXPECTED_TOKEN: 1,\n    INVALID_TOKEN_IN_PLACEHOLDER: 2,\n    UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER: 3,\n    UNKNOWN_ESCAPE_SEQUENCE: 4,\n    INVALID_UNICODE_ESCAPE_SEQUENCE: 5,\n    UNBALANCED_CLOSING_BRACE: 6,\n    UNTERMINATED_CLOSING_BRACE: 7,\n    EMPTY_PLACEHOLDER: 8,\n    NOT_ALLOW_NEST_PLACEHOLDER: 9,\n    INVALID_LINKED_FORMAT: 10,\n    // parser error codes\n    MUST_HAVE_MESSAGES_IN_PLURAL: 11,\n    UNEXPECTED_EMPTY_LINKED_MODIFIER: 12,\n    UNEXPECTED_EMPTY_LINKED_KEY: 13,\n    UNEXPECTED_LEXICAL_ANALYSIS: 14,\n    // generator error codes\n    UNHANDLED_CODEGEN_NODE_TYPE: 15,\n    // minifier error codes\n    UNHANDLED_MINIFIER_NODE_TYPE: 16,\n    // Special value for higher-order compilers to pick up the last code\n    // to avoid collision of error codes. This should always be kept as the last\n    // item.\n    __EXTEND_POINT__: 17\n};\n/** @internal */\nconst errorMessages = {\n    // tokenizer error messages\n    [CompileErrorCodes.EXPECTED_TOKEN]: `Expected token: '{0}'`,\n    [CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER]: `Invalid token in placeholder: '{0}'`,\n    [CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER]: `Unterminated single quote in placeholder`,\n    [CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE]: `Unknown escape sequence: \\\\{0}`,\n    [CompileErrorCodes.INVALID_UNICODE_ESCAPE_SEQUENCE]: `Invalid unicode escape sequence: {0}`,\n    [CompileErrorCodes.UNBALANCED_CLOSING_BRACE]: `Unbalanced closing brace`,\n    [CompileErrorCodes.UNTERMINATED_CLOSING_BRACE]: `Unterminated closing brace`,\n    [CompileErrorCodes.EMPTY_PLACEHOLDER]: `Empty placeholder`,\n    [CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER]: `Not allowed nest placeholder`,\n    [CompileErrorCodes.INVALID_LINKED_FORMAT]: `Invalid linked format`,\n    // parser error messages\n    [CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL]: `Plural must have messages`,\n    [CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER]: `Unexpected empty linked modifier`,\n    [CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY]: `Unexpected empty linked key`,\n    [CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS]: `Unexpected lexical analysis in token: '{0}'`,\n    // generator error messages\n    [CompileErrorCodes.UNHANDLED_CODEGEN_NODE_TYPE]: `unhandled codegen node type: '{0}'`,\n    // minimizer error messages\n    [CompileErrorCodes.UNHANDLED_MINIFIER_NODE_TYPE]: `unhandled mimifier node type: '{0}'`\n};\nfunction createCompileError(code, loc, options = {}) {\n    const { domain, messages, args } = options;\n    const msg = format((messages || errorMessages)[code] || '', ...(args || []))\n        ;\n    const error = new SyntaxError(String(msg));\n    error.code = code;\n    if (loc) {\n        error.location = loc;\n    }\n    error.domain = domain;\n    return error;\n}\n/** @internal */\nfunction defaultOnError(error) {\n    throw error;\n}\n\nconst RE_HTML_TAG = /<\\/?[\\w\\s=\"/.':;#-\\/]+>/;\nconst detectHtmlTag = (source) => RE_HTML_TAG.test(source);\n\nconst CHAR_SP = ' ';\nconst CHAR_CR = '\\r';\nconst CHAR_LF = '\\n';\nconst CHAR_LS = String.fromCharCode(0x2028);\nconst CHAR_PS = String.fromCharCode(0x2029);\nfunction createScanner(str) {\n    const _buf = str;\n    let _index = 0;\n    let _line = 1;\n    let _column = 1;\n    let _peekOffset = 0;\n    const isCRLF = (index) => _buf[index] === CHAR_CR && _buf[index + 1] === CHAR_LF;\n    const isLF = (index) => _buf[index] === CHAR_LF;\n    const isPS = (index) => _buf[index] === CHAR_PS;\n    const isLS = (index) => _buf[index] === CHAR_LS;\n    const isLineEnd = (index) => isCRLF(index) || isLF(index) || isPS(index) || isLS(index);\n    const index = () => _index;\n    const line = () => _line;\n    const column = () => _column;\n    const peekOffset = () => _peekOffset;\n    const charAt = (offset) => isCRLF(offset) || isPS(offset) || isLS(offset) ? CHAR_LF : _buf[offset];\n    const currentChar = () => charAt(_index);\n    const currentPeek = () => charAt(_index + _peekOffset);\n    function next() {\n        _peekOffset = 0;\n        if (isLineEnd(_index)) {\n            _line++;\n            _column = 0;\n        }\n        if (isCRLF(_index)) {\n            _index++;\n        }\n        _index++;\n        _column++;\n        return _buf[_index];\n    }\n    function peek() {\n        if (isCRLF(_index + _peekOffset)) {\n            _peekOffset++;\n        }\n        _peekOffset++;\n        return _buf[_index + _peekOffset];\n    }\n    function reset() {\n        _index = 0;\n        _line = 1;\n        _column = 1;\n        _peekOffset = 0;\n    }\n    function resetPeek(offset = 0) {\n        _peekOffset = offset;\n    }\n    function skipToPeek() {\n        const target = _index + _peekOffset;\n        // eslint-disable-next-line no-unmodified-loop-condition\n        while (target !== _index) {\n            next();\n        }\n        _peekOffset = 0;\n    }\n    return {\n        index,\n        line,\n        column,\n        peekOffset,\n        charAt,\n        currentChar,\n        currentPeek,\n        next,\n        peek,\n        reset,\n        resetPeek,\n        skipToPeek\n    };\n}\n\nconst EOF = undefined;\nconst DOT = '.';\nconst LITERAL_DELIMITER = \"'\";\nconst ERROR_DOMAIN$3 = 'tokenizer';\nfunction createTokenizer(source, options = {}) {\n    const location = options.location !== false;\n    const _scnr = createScanner(source);\n    const currentOffset = () => _scnr.index();\n    const currentPosition = () => createPosition(_scnr.line(), _scnr.column(), _scnr.index());\n    const _initLoc = currentPosition();\n    const _initOffset = currentOffset();\n    const _context = {\n        currentType: 14 /* TokenTypes.EOF */,\n        offset: _initOffset,\n        startLoc: _initLoc,\n        endLoc: _initLoc,\n        lastType: 14 /* TokenTypes.EOF */,\n        lastOffset: _initOffset,\n        lastStartLoc: _initLoc,\n        lastEndLoc: _initLoc,\n        braceNest: 0,\n        inLinked: false,\n        text: ''\n    };\n    const context = () => _context;\n    const { onError } = options;\n    function emitError(code, pos, offset, ...args) {\n        const ctx = context();\n        pos.column += offset;\n        pos.offset += offset;\n        if (onError) {\n            const loc = location ? createLocation(ctx.startLoc, pos) : null;\n            const err = createCompileError(code, loc, {\n                domain: ERROR_DOMAIN$3,\n                args\n            });\n            onError(err);\n        }\n    }\n    function getToken(context, type, value) {\n        context.endLoc = currentPosition();\n        context.currentType = type;\n        const token = { type };\n        if (location) {\n            token.loc = createLocation(context.startLoc, context.endLoc);\n        }\n        if (value != null) {\n            token.value = value;\n        }\n        return token;\n    }\n    const getEndToken = (context) => getToken(context, 14 /* TokenTypes.EOF */);\n    function eat(scnr, ch) {\n        if (scnr.currentChar() === ch) {\n            scnr.next();\n            return ch;\n        }\n        else {\n            emitError(CompileErrorCodes.EXPECTED_TOKEN, currentPosition(), 0, ch);\n            return '';\n        }\n    }\n    function peekSpaces(scnr) {\n        let buf = '';\n        while (scnr.currentPeek() === CHAR_SP || scnr.currentPeek() === CHAR_LF) {\n            buf += scnr.currentPeek();\n            scnr.peek();\n        }\n        return buf;\n    }\n    function skipSpaces(scnr) {\n        const buf = peekSpaces(scnr);\n        scnr.skipToPeek();\n        return buf;\n    }\n    function isIdentifierStart(ch) {\n        if (ch === EOF) {\n            return false;\n        }\n        const cc = ch.charCodeAt(0);\n        return ((cc >= 97 && cc <= 122) || // a-z\n            (cc >= 65 && cc <= 90) || // A-Z\n            cc === 95 // _\n        );\n    }\n    function isNumberStart(ch) {\n        if (ch === EOF) {\n            return false;\n        }\n        const cc = ch.charCodeAt(0);\n        return cc >= 48 && cc <= 57; // 0-9\n    }\n    function isNamedIdentifierStart(scnr, context) {\n        const { currentType } = context;\n        if (currentType !== 2 /* TokenTypes.BraceLeft */) {\n            return false;\n        }\n        peekSpaces(scnr);\n        const ret = isIdentifierStart(scnr.currentPeek());\n        scnr.resetPeek();\n        return ret;\n    }\n    function isListIdentifierStart(scnr, context) {\n        const { currentType } = context;\n        if (currentType !== 2 /* TokenTypes.BraceLeft */) {\n            return false;\n        }\n        peekSpaces(scnr);\n        const ch = scnr.currentPeek() === '-' ? scnr.peek() : scnr.currentPeek();\n        const ret = isNumberStart(ch);\n        scnr.resetPeek();\n        return ret;\n    }\n    function isLiteralStart(scnr, context) {\n        const { currentType } = context;\n        if (currentType !== 2 /* TokenTypes.BraceLeft */) {\n            return false;\n        }\n        peekSpaces(scnr);\n        const ret = scnr.currentPeek() === LITERAL_DELIMITER;\n        scnr.resetPeek();\n        return ret;\n    }\n    function isLinkedDotStart(scnr, context) {\n        const { currentType } = context;\n        if (currentType !== 8 /* TokenTypes.LinkedAlias */) {\n            return false;\n        }\n        peekSpaces(scnr);\n        const ret = scnr.currentPeek() === \".\" /* TokenChars.LinkedDot */;\n        scnr.resetPeek();\n        return ret;\n    }\n    function isLinkedModifierStart(scnr, context) {\n        const { currentType } = context;\n        if (currentType !== 9 /* TokenTypes.LinkedDot */) {\n            return false;\n        }\n        peekSpaces(scnr);\n        const ret = isIdentifierStart(scnr.currentPeek());\n        scnr.resetPeek();\n        return ret;\n    }\n    function isLinkedDelimiterStart(scnr, context) {\n        const { currentType } = context;\n        if (!(currentType === 8 /* TokenTypes.LinkedAlias */ ||\n            currentType === 12 /* TokenTypes.LinkedModifier */)) {\n            return false;\n        }\n        peekSpaces(scnr);\n        const ret = scnr.currentPeek() === \":\" /* TokenChars.LinkedDelimiter */;\n        scnr.resetPeek();\n        return ret;\n    }\n    function isLinkedReferStart(scnr, context) {\n        const { currentType } = context;\n        if (currentType !== 10 /* TokenTypes.LinkedDelimiter */) {\n            return false;\n        }\n        const fn = () => {\n            const ch = scnr.currentPeek();\n            if (ch === \"{\" /* TokenChars.BraceLeft */) {\n                return isIdentifierStart(scnr.peek());\n            }\n            else if (ch === \"@\" /* TokenChars.LinkedAlias */ ||\n                ch === \"%\" /* TokenChars.Modulo */ ||\n                ch === \"|\" /* TokenChars.Pipe */ ||\n                ch === \":\" /* TokenChars.LinkedDelimiter */ ||\n                ch === \".\" /* TokenChars.LinkedDot */ ||\n                ch === CHAR_SP ||\n                !ch) {\n                return false;\n            }\n            else if (ch === CHAR_LF) {\n                scnr.peek();\n                return fn();\n            }\n            else {\n                // other characters\n                return isIdentifierStart(ch);\n            }\n        };\n        const ret = fn();\n        scnr.resetPeek();\n        return ret;\n    }\n    function isPluralStart(scnr) {\n        peekSpaces(scnr);\n        const ret = scnr.currentPeek() === \"|\" /* TokenChars.Pipe */;\n        scnr.resetPeek();\n        return ret;\n    }\n    function detectModuloStart(scnr) {\n        const spaces = peekSpaces(scnr);\n        const ret = scnr.currentPeek() === \"%\" /* TokenChars.Modulo */ &&\n            scnr.peek() === \"{\" /* TokenChars.BraceLeft */;\n        scnr.resetPeek();\n        return {\n            isModulo: ret,\n            hasSpace: spaces.length > 0\n        };\n    }\n    function isTextStart(scnr, reset = true) {\n        const fn = (hasSpace = false, prev = '', detectModulo = false) => {\n            const ch = scnr.currentPeek();\n            if (ch === \"{\" /* TokenChars.BraceLeft */) {\n                return prev === \"%\" /* TokenChars.Modulo */ ? false : hasSpace;\n            }\n            else if (ch === \"@\" /* TokenChars.LinkedAlias */ || !ch) {\n                return prev === \"%\" /* TokenChars.Modulo */ ? true : hasSpace;\n            }\n            else if (ch === \"%\" /* TokenChars.Modulo */) {\n                scnr.peek();\n                return fn(hasSpace, \"%\" /* TokenChars.Modulo */, true);\n            }\n            else if (ch === \"|\" /* TokenChars.Pipe */) {\n                return prev === \"%\" /* TokenChars.Modulo */ || detectModulo\n                    ? true\n                    : !(prev === CHAR_SP || prev === CHAR_LF);\n            }\n            else if (ch === CHAR_SP) {\n                scnr.peek();\n                return fn(true, CHAR_SP, detectModulo);\n            }\n            else if (ch === CHAR_LF) {\n                scnr.peek();\n                return fn(true, CHAR_LF, detectModulo);\n            }\n            else {\n                return true;\n            }\n        };\n        const ret = fn();\n        reset && scnr.resetPeek();\n        return ret;\n    }\n    function takeChar(scnr, fn) {\n        const ch = scnr.currentChar();\n        if (ch === EOF) {\n            return EOF;\n        }\n        if (fn(ch)) {\n            scnr.next();\n            return ch;\n        }\n        return null;\n    }\n    function takeIdentifierChar(scnr) {\n        const closure = (ch) => {\n            const cc = ch.charCodeAt(0);\n            return ((cc >= 97 && cc <= 122) || // a-z\n                (cc >= 65 && cc <= 90) || // A-Z\n                (cc >= 48 && cc <= 57) || // 0-9\n                cc === 95 || // _\n                cc === 36 // $\n            );\n        };\n        return takeChar(scnr, closure);\n    }\n    function takeDigit(scnr) {\n        const closure = (ch) => {\n            const cc = ch.charCodeAt(0);\n            return cc >= 48 && cc <= 57; // 0-9\n        };\n        return takeChar(scnr, closure);\n    }\n    function takeHexDigit(scnr) {\n        const closure = (ch) => {\n            const cc = ch.charCodeAt(0);\n            return ((cc >= 48 && cc <= 57) || // 0-9\n                (cc >= 65 && cc <= 70) || // A-F\n                (cc >= 97 && cc <= 102)); // a-f\n        };\n        return takeChar(scnr, closure);\n    }\n    function getDigits(scnr) {\n        let ch = '';\n        let num = '';\n        while ((ch = takeDigit(scnr))) {\n            num += ch;\n        }\n        return num;\n    }\n    function readModulo(scnr) {\n        skipSpaces(scnr);\n        const ch = scnr.currentChar();\n        if (ch !== \"%\" /* TokenChars.Modulo */) {\n            emitError(CompileErrorCodes.EXPECTED_TOKEN, currentPosition(), 0, ch);\n        }\n        scnr.next();\n        return \"%\" /* TokenChars.Modulo */;\n    }\n    function readText(scnr) {\n        let buf = '';\n        while (true) {\n            const ch = scnr.currentChar();\n            if (ch === \"{\" /* TokenChars.BraceLeft */ ||\n                ch === \"}\" /* TokenChars.BraceRight */ ||\n                ch === \"@\" /* TokenChars.LinkedAlias */ ||\n                ch === \"|\" /* TokenChars.Pipe */ ||\n                !ch) {\n                break;\n            }\n            else if (ch === \"%\" /* TokenChars.Modulo */) {\n                if (isTextStart(scnr)) {\n                    buf += ch;\n                    scnr.next();\n                }\n                else {\n                    break;\n                }\n            }\n            else if (ch === CHAR_SP || ch === CHAR_LF) {\n                if (isTextStart(scnr)) {\n                    buf += ch;\n                    scnr.next();\n                }\n                else if (isPluralStart(scnr)) {\n                    break;\n                }\n                else {\n                    buf += ch;\n                    scnr.next();\n                }\n            }\n            else {\n                buf += ch;\n                scnr.next();\n            }\n        }\n        return buf;\n    }\n    function readNamedIdentifier(scnr) {\n        skipSpaces(scnr);\n        let ch = '';\n        let name = '';\n        while ((ch = takeIdentifierChar(scnr))) {\n            name += ch;\n        }\n        if (scnr.currentChar() === EOF) {\n            emitError(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, currentPosition(), 0);\n        }\n        return name;\n    }\n    function readListIdentifier(scnr) {\n        skipSpaces(scnr);\n        let value = '';\n        if (scnr.currentChar() === '-') {\n            scnr.next();\n            value += `-${getDigits(scnr)}`;\n        }\n        else {\n            value += getDigits(scnr);\n        }\n        if (scnr.currentChar() === EOF) {\n            emitError(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, currentPosition(), 0);\n        }\n        return value;\n    }\n    function readLiteral(scnr) {\n        skipSpaces(scnr);\n        eat(scnr, `\\'`);\n        let ch = '';\n        let literal = '';\n        const fn = (x) => x !== LITERAL_DELIMITER && x !== CHAR_LF;\n        while ((ch = takeChar(scnr, fn))) {\n            if (ch === '\\\\') {\n                literal += readEscapeSequence(scnr);\n            }\n            else {\n                literal += ch;\n            }\n        }\n        const current = scnr.currentChar();\n        if (current === CHAR_LF || current === EOF) {\n            emitError(CompileErrorCodes.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER, currentPosition(), 0);\n            // TODO: Is it correct really?\n            if (current === CHAR_LF) {\n                scnr.next();\n                eat(scnr, `\\'`);\n            }\n            return literal;\n        }\n        eat(scnr, `\\'`);\n        return literal;\n    }\n    function readEscapeSequence(scnr) {\n        const ch = scnr.currentChar();\n        switch (ch) {\n            case '\\\\':\n            case `\\'`:\n                scnr.next();\n                return `\\\\${ch}`;\n            case 'u':\n                return readUnicodeEscapeSequence(scnr, ch, 4);\n            case 'U':\n                return readUnicodeEscapeSequence(scnr, ch, 6);\n            default:\n                emitError(CompileErrorCodes.UNKNOWN_ESCAPE_SEQUENCE, currentPosition(), 0, ch);\n                return '';\n        }\n    }\n    function readUnicodeEscapeSequence(scnr, unicode, digits) {\n        eat(scnr, unicode);\n        let sequence = '';\n        for (let i = 0; i < digits; i++) {\n            const ch = takeHexDigit(scnr);\n            if (!ch) {\n                emitError(CompileErrorCodes.INVALID_UNICODE_ESCAPE_SEQUENCE, currentPosition(), 0, `\\\\${unicode}${sequence}${scnr.currentChar()}`);\n                break;\n            }\n            sequence += ch;\n        }\n        return `\\\\${unicode}${sequence}`;\n    }\n    function readInvalidIdentifier(scnr) {\n        skipSpaces(scnr);\n        let ch = '';\n        let identifiers = '';\n        const closure = (ch) => ch !== \"{\" /* TokenChars.BraceLeft */ &&\n            ch !== \"}\" /* TokenChars.BraceRight */ &&\n            ch !== CHAR_SP &&\n            ch !== CHAR_LF;\n        while ((ch = takeChar(scnr, closure))) {\n            identifiers += ch;\n        }\n        return identifiers;\n    }\n    function readLinkedModifier(scnr) {\n        let ch = '';\n        let name = '';\n        while ((ch = takeIdentifierChar(scnr))) {\n            name += ch;\n        }\n        return name;\n    }\n    function readLinkedRefer(scnr) {\n        const fn = (detect = false, buf) => {\n            const ch = scnr.currentChar();\n            if (ch === \"{\" /* TokenChars.BraceLeft */ ||\n                ch === \"%\" /* TokenChars.Modulo */ ||\n                ch === \"@\" /* TokenChars.LinkedAlias */ ||\n                ch === \"|\" /* TokenChars.Pipe */ ||\n                ch === \"(\" /* TokenChars.ParenLeft */ ||\n                ch === \")\" /* TokenChars.ParenRight */ ||\n                !ch) {\n                return buf;\n            }\n            else if (ch === CHAR_SP) {\n                return buf;\n            }\n            else if (ch === CHAR_LF || ch === DOT) {\n                buf += ch;\n                scnr.next();\n                return fn(detect, buf);\n            }\n            else {\n                buf += ch;\n                scnr.next();\n                return fn(true, buf);\n            }\n        };\n        return fn(false, '');\n    }\n    function readPlural(scnr) {\n        skipSpaces(scnr);\n        const plural = eat(scnr, \"|\" /* TokenChars.Pipe */);\n        skipSpaces(scnr);\n        return plural;\n    }\n    // TODO: We need refactoring of token parsing ...\n    function readTokenInPlaceholder(scnr, context) {\n        let token = null;\n        const ch = scnr.currentChar();\n        switch (ch) {\n            case \"{\" /* TokenChars.BraceLeft */:\n                if (context.braceNest >= 1) {\n                    emitError(CompileErrorCodes.NOT_ALLOW_NEST_PLACEHOLDER, currentPosition(), 0);\n                }\n                scnr.next();\n                token = getToken(context, 2 /* TokenTypes.BraceLeft */, \"{\" /* TokenChars.BraceLeft */);\n                skipSpaces(scnr);\n                context.braceNest++;\n                return token;\n            case \"}\" /* TokenChars.BraceRight */:\n                if (context.braceNest > 0 &&\n                    context.currentType === 2 /* TokenTypes.BraceLeft */) {\n                    emitError(CompileErrorCodes.EMPTY_PLACEHOLDER, currentPosition(), 0);\n                }\n                scnr.next();\n                token = getToken(context, 3 /* TokenTypes.BraceRight */, \"}\" /* TokenChars.BraceRight */);\n                context.braceNest--;\n                context.braceNest > 0 && skipSpaces(scnr);\n                if (context.inLinked && context.braceNest === 0) {\n                    context.inLinked = false;\n                }\n                return token;\n            case \"@\" /* TokenChars.LinkedAlias */:\n                if (context.braceNest > 0) {\n                    emitError(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, currentPosition(), 0);\n                }\n                token = readTokenInLinked(scnr, context) || getEndToken(context);\n                context.braceNest = 0;\n                return token;\n            default:\n                let validNamedIdentifier = true;\n                let validListIdentifier = true;\n                let validLiteral = true;\n                if (isPluralStart(scnr)) {\n                    if (context.braceNest > 0) {\n                        emitError(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, currentPosition(), 0);\n                    }\n                    token = getToken(context, 1 /* TokenTypes.Pipe */, readPlural(scnr));\n                    // reset\n                    context.braceNest = 0;\n                    context.inLinked = false;\n                    return token;\n                }\n                if (context.braceNest > 0 &&\n                    (context.currentType === 5 /* TokenTypes.Named */ ||\n                        context.currentType === 6 /* TokenTypes.List */ ||\n                        context.currentType === 7 /* TokenTypes.Literal */)) {\n                    emitError(CompileErrorCodes.UNTERMINATED_CLOSING_BRACE, currentPosition(), 0);\n                    context.braceNest = 0;\n                    return readToken(scnr, context);\n                }\n                if ((validNamedIdentifier = isNamedIdentifierStart(scnr, context))) {\n                    token = getToken(context, 5 /* TokenTypes.Named */, readNamedIdentifier(scnr));\n                    skipSpaces(scnr);\n                    return token;\n                }\n                if ((validListIdentifier = isListIdentifierStart(scnr, context))) {\n                    token = getToken(context, 6 /* TokenTypes.List */, readListIdentifier(scnr));\n                    skipSpaces(scnr);\n                    return token;\n                }\n                if ((validLiteral = isLiteralStart(scnr, context))) {\n                    token = getToken(context, 7 /* TokenTypes.Literal */, readLiteral(scnr));\n                    skipSpaces(scnr);\n                    return token;\n                }\n                if (!validNamedIdentifier && !validListIdentifier && !validLiteral) {\n                    // TODO: we should be re-designed invalid cases, when we will extend message syntax near the future ...\n                    token = getToken(context, 13 /* TokenTypes.InvalidPlace */, readInvalidIdentifier(scnr));\n                    emitError(CompileErrorCodes.INVALID_TOKEN_IN_PLACEHOLDER, currentPosition(), 0, token.value);\n                    skipSpaces(scnr);\n                    return token;\n                }\n                break;\n        }\n        return token;\n    }\n    // TODO: We need refactoring of token parsing ...\n    function readTokenInLinked(scnr, context) {\n        const { currentType } = context;\n        let token = null;\n        const ch = scnr.currentChar();\n        if ((currentType === 8 /* TokenTypes.LinkedAlias */ ||\n            currentType === 9 /* TokenTypes.LinkedDot */ ||\n            currentType === 12 /* TokenTypes.LinkedModifier */ ||\n            currentType === 10 /* TokenTypes.LinkedDelimiter */) &&\n            (ch === CHAR_LF || ch === CHAR_SP)) {\n            emitError(CompileErrorCodes.INVALID_LINKED_FORMAT, currentPosition(), 0);\n        }\n        switch (ch) {\n            case \"@\" /* TokenChars.LinkedAlias */:\n                scnr.next();\n                token = getToken(context, 8 /* TokenTypes.LinkedAlias */, \"@\" /* TokenChars.LinkedAlias */);\n                context.inLinked = true;\n                return token;\n            case \".\" /* TokenChars.LinkedDot */:\n                skipSpaces(scnr);\n                scnr.next();\n                return getToken(context, 9 /* TokenTypes.LinkedDot */, \".\" /* TokenChars.LinkedDot */);\n            case \":\" /* TokenChars.LinkedDelimiter */:\n                skipSpaces(scnr);\n                scnr.next();\n                return getToken(context, 10 /* TokenTypes.LinkedDelimiter */, \":\" /* TokenChars.LinkedDelimiter */);\n            default:\n                if (isPluralStart(scnr)) {\n                    token = getToken(context, 1 /* TokenTypes.Pipe */, readPlural(scnr));\n                    // reset\n                    context.braceNest = 0;\n                    context.inLinked = false;\n                    return token;\n                }\n                if (isLinkedDotStart(scnr, context) ||\n                    isLinkedDelimiterStart(scnr, context)) {\n                    skipSpaces(scnr);\n                    return readTokenInLinked(scnr, context);\n                }\n                if (isLinkedModifierStart(scnr, context)) {\n                    skipSpaces(scnr);\n                    return getToken(context, 12 /* TokenTypes.LinkedModifier */, readLinkedModifier(scnr));\n                }\n                if (isLinkedReferStart(scnr, context)) {\n                    skipSpaces(scnr);\n                    if (ch === \"{\" /* TokenChars.BraceLeft */) {\n                        // scan the placeholder\n                        return readTokenInPlaceholder(scnr, context) || token;\n                    }\n                    else {\n                        return getToken(context, 11 /* TokenTypes.LinkedKey */, readLinkedRefer(scnr));\n                    }\n                }\n                if (currentType === 8 /* TokenTypes.LinkedAlias */) {\n                    emitError(CompileErrorCodes.INVALID_LINKED_FORMAT, currentPosition(), 0);\n                }\n                context.braceNest = 0;\n                context.inLinked = false;\n                return readToken(scnr, context);\n        }\n    }\n    // TODO: We need refactoring of token parsing ...\n    function readToken(scnr, context) {\n        let token = { type: 14 /* TokenTypes.EOF */ };\n        if (context.braceNest > 0) {\n            return readTokenInPlaceholder(scnr, context) || getEndToken(context);\n        }\n        if (context.inLinked) {\n            return readTokenInLinked(scnr, context) || getEndToken(context);\n        }\n        const ch = scnr.currentChar();\n        switch (ch) {\n            case \"{\" /* TokenChars.BraceLeft */:\n                return readTokenInPlaceholder(scnr, context) || getEndToken(context);\n            case \"}\" /* TokenChars.BraceRight */:\n                emitError(CompileErrorCodes.UNBALANCED_CLOSING_BRACE, currentPosition(), 0);\n                scnr.next();\n                return getToken(context, 3 /* TokenTypes.BraceRight */, \"}\" /* TokenChars.BraceRight */);\n            case \"@\" /* TokenChars.LinkedAlias */:\n                return readTokenInLinked(scnr, context) || getEndToken(context);\n            default:\n                if (isPluralStart(scnr)) {\n                    token = getToken(context, 1 /* TokenTypes.Pipe */, readPlural(scnr));\n                    // reset\n                    context.braceNest = 0;\n                    context.inLinked = false;\n                    return token;\n                }\n                const { isModulo, hasSpace } = detectModuloStart(scnr);\n                if (isModulo) {\n                    return hasSpace\n                        ? getToken(context, 0 /* TokenTypes.Text */, readText(scnr))\n                        : getToken(context, 4 /* TokenTypes.Modulo */, readModulo(scnr));\n                }\n                if (isTextStart(scnr)) {\n                    return getToken(context, 0 /* TokenTypes.Text */, readText(scnr));\n                }\n                break;\n        }\n        return token;\n    }\n    function nextToken() {\n        const { currentType, offset, startLoc, endLoc } = _context;\n        _context.lastType = currentType;\n        _context.lastOffset = offset;\n        _context.lastStartLoc = startLoc;\n        _context.lastEndLoc = endLoc;\n        _context.offset = currentOffset();\n        _context.startLoc = currentPosition();\n        if (_scnr.currentChar() === EOF) {\n            return getToken(_context, 14 /* TokenTypes.EOF */);\n        }\n        return readToken(_scnr, _context);\n    }\n    return {\n        nextToken,\n        currentOffset,\n        currentPosition,\n        context\n    };\n}\n\nconst ERROR_DOMAIN$2 = 'parser';\n// Backslash backslash, backslash quote, uHHHH, UHHHHHH.\nconst KNOWN_ESCAPES = /(?:\\\\\\\\|\\\\'|\\\\u([0-9a-fA-F]{4})|\\\\U([0-9a-fA-F]{6}))/g;\nfunction fromEscapeSequence(match, codePoint4, codePoint6) {\n    switch (match) {\n        case `\\\\\\\\`:\n            return `\\\\`;\n        case `\\\\\\'`:\n            return `\\'`;\n        default: {\n            const codePoint = parseInt(codePoint4 || codePoint6, 16);\n            if (codePoint <= 0xd7ff || codePoint >= 0xe000) {\n                return String.fromCodePoint(codePoint);\n            }\n            // invalid ...\n            // Replace them with U+FFFD REPLACEMENT CHARACTER.\n            return '�';\n        }\n    }\n}\nfunction createParser(options = {}) {\n    const location = options.location !== false;\n    const { onError } = options;\n    function emitError(tokenzer, code, start, offset, ...args) {\n        const end = tokenzer.currentPosition();\n        end.offset += offset;\n        end.column += offset;\n        if (onError) {\n            const loc = location ? createLocation(start, end) : null;\n            const err = createCompileError(code, loc, {\n                domain: ERROR_DOMAIN$2,\n                args\n            });\n            onError(err);\n        }\n    }\n    function startNode(type, offset, loc) {\n        const node = { type };\n        if (location) {\n            node.start = offset;\n            node.end = offset;\n            node.loc = { start: loc, end: loc };\n        }\n        return node;\n    }\n    function endNode(node, offset, pos, type) {\n        if (type) {\n            node.type = type;\n        }\n        if (location) {\n            node.end = offset;\n            if (node.loc) {\n                node.loc.end = pos;\n            }\n        }\n    }\n    function parseText(tokenizer, value) {\n        const context = tokenizer.context();\n        const node = startNode(3 /* NodeTypes.Text */, context.offset, context.startLoc);\n        node.value = value;\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return node;\n    }\n    function parseList(tokenizer, index) {\n        const context = tokenizer.context();\n        const { lastOffset: offset, lastStartLoc: loc } = context; // get brace left loc\n        const node = startNode(5 /* NodeTypes.List */, offset, loc);\n        node.index = parseInt(index, 10);\n        tokenizer.nextToken(); // skip brach right\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return node;\n    }\n    function parseNamed(tokenizer, key) {\n        const context = tokenizer.context();\n        const { lastOffset: offset, lastStartLoc: loc } = context; // get brace left loc\n        const node = startNode(4 /* NodeTypes.Named */, offset, loc);\n        node.key = key;\n        tokenizer.nextToken(); // skip brach right\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return node;\n    }\n    function parseLiteral(tokenizer, value) {\n        const context = tokenizer.context();\n        const { lastOffset: offset, lastStartLoc: loc } = context; // get brace left loc\n        const node = startNode(9 /* NodeTypes.Literal */, offset, loc);\n        node.value = value.replace(KNOWN_ESCAPES, fromEscapeSequence);\n        tokenizer.nextToken(); // skip brach right\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return node;\n    }\n    function parseLinkedModifier(tokenizer) {\n        const token = tokenizer.nextToken();\n        const context = tokenizer.context();\n        const { lastOffset: offset, lastStartLoc: loc } = context; // get linked dot loc\n        const node = startNode(8 /* NodeTypes.LinkedModifier */, offset, loc);\n        if (token.type !== 12 /* TokenTypes.LinkedModifier */) {\n            // empty modifier\n            emitError(tokenizer, CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_MODIFIER, context.lastStartLoc, 0);\n            node.value = '';\n            endNode(node, offset, loc);\n            return {\n                nextConsumeToken: token,\n                node\n            };\n        }\n        // check token\n        if (token.value == null) {\n            emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n        }\n        node.value = token.value || '';\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return {\n            node\n        };\n    }\n    function parseLinkedKey(tokenizer, value) {\n        const context = tokenizer.context();\n        const node = startNode(7 /* NodeTypes.LinkedKey */, context.offset, context.startLoc);\n        node.value = value;\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return node;\n    }\n    function parseLinked(tokenizer) {\n        const context = tokenizer.context();\n        const linkedNode = startNode(6 /* NodeTypes.Linked */, context.offset, context.startLoc);\n        let token = tokenizer.nextToken();\n        if (token.type === 9 /* TokenTypes.LinkedDot */) {\n            const parsed = parseLinkedModifier(tokenizer);\n            linkedNode.modifier = parsed.node;\n            token = parsed.nextConsumeToken || tokenizer.nextToken();\n        }\n        // asset check token\n        if (token.type !== 10 /* TokenTypes.LinkedDelimiter */) {\n            emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n        }\n        token = tokenizer.nextToken();\n        // skip brace left\n        if (token.type === 2 /* TokenTypes.BraceLeft */) {\n            token = tokenizer.nextToken();\n        }\n        switch (token.type) {\n            case 11 /* TokenTypes.LinkedKey */:\n                if (token.value == null) {\n                    emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                }\n                linkedNode.key = parseLinkedKey(tokenizer, token.value || '');\n                break;\n            case 5 /* TokenTypes.Named */:\n                if (token.value == null) {\n                    emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                }\n                linkedNode.key = parseNamed(tokenizer, token.value || '');\n                break;\n            case 6 /* TokenTypes.List */:\n                if (token.value == null) {\n                    emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                }\n                linkedNode.key = parseList(tokenizer, token.value || '');\n                break;\n            case 7 /* TokenTypes.Literal */:\n                if (token.value == null) {\n                    emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                }\n                linkedNode.key = parseLiteral(tokenizer, token.value || '');\n                break;\n            default:\n                // empty key\n                emitError(tokenizer, CompileErrorCodes.UNEXPECTED_EMPTY_LINKED_KEY, context.lastStartLoc, 0);\n                const nextContext = tokenizer.context();\n                const emptyLinkedKeyNode = startNode(7 /* NodeTypes.LinkedKey */, nextContext.offset, nextContext.startLoc);\n                emptyLinkedKeyNode.value = '';\n                endNode(emptyLinkedKeyNode, nextContext.offset, nextContext.startLoc);\n                linkedNode.key = emptyLinkedKeyNode;\n                endNode(linkedNode, nextContext.offset, nextContext.startLoc);\n                return {\n                    nextConsumeToken: token,\n                    node: linkedNode\n                };\n        }\n        endNode(linkedNode, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return {\n            node: linkedNode\n        };\n    }\n    function parseMessage(tokenizer) {\n        const context = tokenizer.context();\n        const startOffset = context.currentType === 1 /* TokenTypes.Pipe */\n            ? tokenizer.currentOffset()\n            : context.offset;\n        const startLoc = context.currentType === 1 /* TokenTypes.Pipe */\n            ? context.endLoc\n            : context.startLoc;\n        const node = startNode(2 /* NodeTypes.Message */, startOffset, startLoc);\n        node.items = [];\n        let nextToken = null;\n        do {\n            const token = nextToken || tokenizer.nextToken();\n            nextToken = null;\n            switch (token.type) {\n                case 0 /* TokenTypes.Text */:\n                    if (token.value == null) {\n                        emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                    }\n                    node.items.push(parseText(tokenizer, token.value || ''));\n                    break;\n                case 6 /* TokenTypes.List */:\n                    if (token.value == null) {\n                        emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                    }\n                    node.items.push(parseList(tokenizer, token.value || ''));\n                    break;\n                case 5 /* TokenTypes.Named */:\n                    if (token.value == null) {\n                        emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                    }\n                    node.items.push(parseNamed(tokenizer, token.value || ''));\n                    break;\n                case 7 /* TokenTypes.Literal */:\n                    if (token.value == null) {\n                        emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, getTokenCaption(token));\n                    }\n                    node.items.push(parseLiteral(tokenizer, token.value || ''));\n                    break;\n                case 8 /* TokenTypes.LinkedAlias */:\n                    const parsed = parseLinked(tokenizer);\n                    node.items.push(parsed.node);\n                    nextToken = parsed.nextConsumeToken || null;\n                    break;\n            }\n        } while (context.currentType !== 14 /* TokenTypes.EOF */ &&\n            context.currentType !== 1 /* TokenTypes.Pipe */);\n        // adjust message node loc\n        const endOffset = context.currentType === 1 /* TokenTypes.Pipe */\n            ? context.lastOffset\n            : tokenizer.currentOffset();\n        const endLoc = context.currentType === 1 /* TokenTypes.Pipe */\n            ? context.lastEndLoc\n            : tokenizer.currentPosition();\n        endNode(node, endOffset, endLoc);\n        return node;\n    }\n    function parsePlural(tokenizer, offset, loc, msgNode) {\n        const context = tokenizer.context();\n        let hasEmptyMessage = msgNode.items.length === 0;\n        const node = startNode(1 /* NodeTypes.Plural */, offset, loc);\n        node.cases = [];\n        node.cases.push(msgNode);\n        do {\n            const msg = parseMessage(tokenizer);\n            if (!hasEmptyMessage) {\n                hasEmptyMessage = msg.items.length === 0;\n            }\n            node.cases.push(msg);\n        } while (context.currentType !== 14 /* TokenTypes.EOF */);\n        if (hasEmptyMessage) {\n            emitError(tokenizer, CompileErrorCodes.MUST_HAVE_MESSAGES_IN_PLURAL, loc, 0);\n        }\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return node;\n    }\n    function parseResource(tokenizer) {\n        const context = tokenizer.context();\n        const { offset, startLoc } = context;\n        const msgNode = parseMessage(tokenizer);\n        if (context.currentType === 14 /* TokenTypes.EOF */) {\n            return msgNode;\n        }\n        else {\n            return parsePlural(tokenizer, offset, startLoc, msgNode);\n        }\n    }\n    function parse(source) {\n        const tokenizer = createTokenizer(source, assign({}, options));\n        const context = tokenizer.context();\n        const node = startNode(0 /* NodeTypes.Resource */, context.offset, context.startLoc);\n        if (location && node.loc) {\n            node.loc.source = source;\n        }\n        node.body = parseResource(tokenizer);\n        if (options.onCacheKey) {\n            node.cacheKey = options.onCacheKey(source);\n        }\n        // assert whether achieved to EOF\n        if (context.currentType !== 14 /* TokenTypes.EOF */) {\n            emitError(tokenizer, CompileErrorCodes.UNEXPECTED_LEXICAL_ANALYSIS, context.lastStartLoc, 0, source[context.offset] || '');\n        }\n        endNode(node, tokenizer.currentOffset(), tokenizer.currentPosition());\n        return node;\n    }\n    return { parse };\n}\nfunction getTokenCaption(token) {\n    if (token.type === 14 /* TokenTypes.EOF */) {\n        return 'EOF';\n    }\n    const name = (token.value || '').replace(/\\r?\\n/gu, '\\\\n');\n    return name.length > 10 ? name.slice(0, 9) + '…' : name;\n}\n\nfunction createTransformer(ast, options = {} // eslint-disable-line\n) {\n    const _context = {\n        ast,\n        helpers: new Set()\n    };\n    const context = () => _context;\n    const helper = (name) => {\n        _context.helpers.add(name);\n        return name;\n    };\n    return { context, helper };\n}\nfunction traverseNodes(nodes, transformer) {\n    for (let i = 0; i < nodes.length; i++) {\n        traverseNode(nodes[i], transformer);\n    }\n}\nfunction traverseNode(node, transformer) {\n    // TODO: if we need pre-hook of transform, should be implemented to here\n    switch (node.type) {\n        case 1 /* NodeTypes.Plural */:\n            traverseNodes(node.cases, transformer);\n            transformer.helper(\"plural\" /* HelperNameMap.PLURAL */);\n            break;\n        case 2 /* NodeTypes.Message */:\n            traverseNodes(node.items, transformer);\n            break;\n        case 6 /* NodeTypes.Linked */:\n            const linked = node;\n            traverseNode(linked.key, transformer);\n            transformer.helper(\"linked\" /* HelperNameMap.LINKED */);\n            transformer.helper(\"type\" /* HelperNameMap.TYPE */);\n            break;\n        case 5 /* NodeTypes.List */:\n            transformer.helper(\"interpolate\" /* HelperNameMap.INTERPOLATE */);\n            transformer.helper(\"list\" /* HelperNameMap.LIST */);\n            break;\n        case 4 /* NodeTypes.Named */:\n            transformer.helper(\"interpolate\" /* HelperNameMap.INTERPOLATE */);\n            transformer.helper(\"named\" /* HelperNameMap.NAMED */);\n            break;\n    }\n    // TODO: if we need post-hook of transform, should be implemented to here\n}\n// transform AST\nfunction transform(ast, options = {} // eslint-disable-line\n) {\n    const transformer = createTransformer(ast);\n    transformer.helper(\"normalize\" /* HelperNameMap.NORMALIZE */);\n    // traverse\n    ast.body && traverseNode(ast.body, transformer);\n    // set meta information\n    const context = transformer.context();\n    ast.helpers = Array.from(context.helpers);\n}\n\nfunction optimize(ast) {\n    const body = ast.body;\n    if (body.type === 2 /* NodeTypes.Message */) {\n        optimizeMessageNode(body);\n    }\n    else {\n        body.cases.forEach(c => optimizeMessageNode(c));\n    }\n    return ast;\n}\nfunction optimizeMessageNode(message) {\n    if (message.items.length === 1) {\n        const item = message.items[0];\n        if (item.type === 3 /* NodeTypes.Text */ || item.type === 9 /* NodeTypes.Literal */) {\n            message.static = item.value;\n            delete item.value; // optimization for size\n        }\n    }\n    else {\n        const values = [];\n        for (let i = 0; i < message.items.length; i++) {\n            const item = message.items[i];\n            if (!(item.type === 3 /* NodeTypes.Text */ || item.type === 9 /* NodeTypes.Literal */)) {\n                break;\n            }\n            if (item.value == null) {\n                break;\n            }\n            values.push(item.value);\n        }\n        if (values.length === message.items.length) {\n            message.static = join(values);\n            for (let i = 0; i < message.items.length; i++) {\n                const item = message.items[i];\n                if (item.type === 3 /* NodeTypes.Text */ || item.type === 9 /* NodeTypes.Literal */) {\n                    delete item.value; // optimization for size\n                }\n            }\n        }\n    }\n}\n\nconst ERROR_DOMAIN$1 = 'minifier';\n/* eslint-disable @typescript-eslint/no-explicit-any */\nfunction minify(node) {\n    node.t = node.type;\n    switch (node.type) {\n        case 0 /* NodeTypes.Resource */:\n            const resource = node;\n            minify(resource.body);\n            resource.b = resource.body;\n            delete resource.body;\n            break;\n        case 1 /* NodeTypes.Plural */:\n            const plural = node;\n            const cases = plural.cases;\n            for (let i = 0; i < cases.length; i++) {\n                minify(cases[i]);\n            }\n            plural.c = cases;\n            delete plural.cases;\n            break;\n        case 2 /* NodeTypes.Message */:\n            const message = node;\n            const items = message.items;\n            for (let i = 0; i < items.length; i++) {\n                minify(items[i]);\n            }\n            message.i = items;\n            delete message.items;\n            if (message.static) {\n                message.s = message.static;\n                delete message.static;\n            }\n            break;\n        case 3 /* NodeTypes.Text */:\n        case 9 /* NodeTypes.Literal */:\n        case 8 /* NodeTypes.LinkedModifier */:\n        case 7 /* NodeTypes.LinkedKey */:\n            const valueNode = node;\n            if (valueNode.value) {\n                valueNode.v = valueNode.value;\n                delete valueNode.value;\n            }\n            break;\n        case 6 /* NodeTypes.Linked */:\n            const linked = node;\n            minify(linked.key);\n            linked.k = linked.key;\n            delete linked.key;\n            if (linked.modifier) {\n                minify(linked.modifier);\n                linked.m = linked.modifier;\n                delete linked.modifier;\n            }\n            break;\n        case 5 /* NodeTypes.List */:\n            const list = node;\n            list.i = list.index;\n            delete list.index;\n            break;\n        case 4 /* NodeTypes.Named */:\n            const named = node;\n            named.k = named.key;\n            delete named.key;\n            break;\n        default:\n            {\n                throw createCompileError(CompileErrorCodes.UNHANDLED_MINIFIER_NODE_TYPE, null, {\n                    domain: ERROR_DOMAIN$1,\n                    args: [node.type]\n                });\n            }\n    }\n    delete node.type;\n}\n/* eslint-enable @typescript-eslint/no-explicit-any */\n\nconst ERROR_DOMAIN = 'parser';\nfunction createCodeGenerator(ast, options) {\n    const { sourceMap, filename, breakLineCode, needIndent: _needIndent } = options;\n    const location = options.location !== false;\n    const _context = {\n        filename,\n        code: '',\n        column: 1,\n        line: 1,\n        offset: 0,\n        map: undefined,\n        breakLineCode,\n        needIndent: _needIndent,\n        indentLevel: 0\n    };\n    if (location && ast.loc) {\n        _context.source = ast.loc.source;\n    }\n    const context = () => _context;\n    function push(code, node) {\n        _context.code += code;\n    }\n    function _newline(n, withBreakLine = true) {\n        const _breakLineCode = withBreakLine ? breakLineCode : '';\n        push(_needIndent ? _breakLineCode + `  `.repeat(n) : _breakLineCode);\n    }\n    function indent(withNewLine = true) {\n        const level = ++_context.indentLevel;\n        withNewLine && _newline(level);\n    }\n    function deindent(withNewLine = true) {\n        const level = --_context.indentLevel;\n        withNewLine && _newline(level);\n    }\n    function newline() {\n        _newline(_context.indentLevel);\n    }\n    const helper = (key) => `_${key}`;\n    const needIndent = () => _context.needIndent;\n    return {\n        context,\n        push,\n        indent,\n        deindent,\n        newline,\n        helper,\n        needIndent\n    };\n}\nfunction generateLinkedNode(generator, node) {\n    const { helper } = generator;\n    generator.push(`${helper(\"linked\" /* HelperNameMap.LINKED */)}(`);\n    generateNode(generator, node.key);\n    if (node.modifier) {\n        generator.push(`, `);\n        generateNode(generator, node.modifier);\n        generator.push(`, _type`);\n    }\n    else {\n        generator.push(`, undefined, _type`);\n    }\n    generator.push(`)`);\n}\nfunction generateMessageNode(generator, node) {\n    const { helper, needIndent } = generator;\n    generator.push(`${helper(\"normalize\" /* HelperNameMap.NORMALIZE */)}([`);\n    generator.indent(needIndent());\n    const length = node.items.length;\n    for (let i = 0; i < length; i++) {\n        generateNode(generator, node.items[i]);\n        if (i === length - 1) {\n            break;\n        }\n        generator.push(', ');\n    }\n    generator.deindent(needIndent());\n    generator.push('])');\n}\nfunction generatePluralNode(generator, node) {\n    const { helper, needIndent } = generator;\n    if (node.cases.length > 1) {\n        generator.push(`${helper(\"plural\" /* HelperNameMap.PLURAL */)}([`);\n        generator.indent(needIndent());\n        const length = node.cases.length;\n        for (let i = 0; i < length; i++) {\n            generateNode(generator, node.cases[i]);\n            if (i === length - 1) {\n                break;\n            }\n            generator.push(', ');\n        }\n        generator.deindent(needIndent());\n        generator.push(`])`);\n    }\n}\nfunction generateResource(generator, node) {\n    if (node.body) {\n        generateNode(generator, node.body);\n    }\n    else {\n        generator.push('null');\n    }\n}\nfunction generateNode(generator, node) {\n    const { helper } = generator;\n    switch (node.type) {\n        case 0 /* NodeTypes.Resource */:\n            generateResource(generator, node);\n            break;\n        case 1 /* NodeTypes.Plural */:\n            generatePluralNode(generator, node);\n            break;\n        case 2 /* NodeTypes.Message */:\n            generateMessageNode(generator, node);\n            break;\n        case 6 /* NodeTypes.Linked */:\n            generateLinkedNode(generator, node);\n            break;\n        case 8 /* NodeTypes.LinkedModifier */:\n            generator.push(JSON.stringify(node.value), node);\n            break;\n        case 7 /* NodeTypes.LinkedKey */:\n            generator.push(JSON.stringify(node.value), node);\n            break;\n        case 5 /* NodeTypes.List */:\n            generator.push(`${helper(\"interpolate\" /* HelperNameMap.INTERPOLATE */)}(${helper(\"list\" /* HelperNameMap.LIST */)}(${node.index}))`, node);\n            break;\n        case 4 /* NodeTypes.Named */:\n            generator.push(`${helper(\"interpolate\" /* HelperNameMap.INTERPOLATE */)}(${helper(\"named\" /* HelperNameMap.NAMED */)}(${JSON.stringify(node.key)}))`, node);\n            break;\n        case 9 /* NodeTypes.Literal */:\n            generator.push(JSON.stringify(node.value), node);\n            break;\n        case 3 /* NodeTypes.Text */:\n            generator.push(JSON.stringify(node.value), node);\n            break;\n        default:\n            {\n                throw createCompileError(CompileErrorCodes.UNHANDLED_CODEGEN_NODE_TYPE, null, {\n                    domain: ERROR_DOMAIN,\n                    args: [node.type]\n                });\n            }\n    }\n}\n// generate code from AST\nconst generate = (ast, options = {} // eslint-disable-line\n) => {\n    const mode = isString(options.mode) ? options.mode : 'normal';\n    const filename = isString(options.filename)\n        ? options.filename\n        : 'message.intl';\n    const sourceMap = !!options.sourceMap;\n    // prettier-ignore\n    const breakLineCode = options.breakLineCode != null\n        ? options.breakLineCode\n        : mode === 'arrow'\n            ? ';'\n            : '\\n';\n    const needIndent = options.needIndent ? options.needIndent : mode !== 'arrow';\n    const helpers = ast.helpers || [];\n    const generator = createCodeGenerator(ast, {\n        mode,\n        filename,\n        sourceMap,\n        breakLineCode,\n        needIndent\n    });\n    generator.push(mode === 'normal' ? `function __msg__ (ctx) {` : `(ctx) => {`);\n    generator.indent(needIndent);\n    if (helpers.length > 0) {\n        generator.push(`const { ${join(helpers.map(s => `${s}: _${s}`), ', ')} } = ctx`);\n        generator.newline();\n    }\n    generator.push(`return `);\n    generateNode(generator, ast);\n    generator.deindent(needIndent);\n    generator.push(`}`);\n    delete ast.helpers;\n    const { code, map } = generator.context();\n    return {\n        ast,\n        code,\n        map: map ? map.toJSON() : undefined // eslint-disable-line @typescript-eslint/no-explicit-any\n    };\n};\n\nfunction baseCompile(source, options = {}) {\n    const assignedOptions = assign({}, options);\n    const jit = !!assignedOptions.jit;\n    const enalbeMinify = !!assignedOptions.minify;\n    const enambeOptimize = assignedOptions.optimize == null ? true : assignedOptions.optimize;\n    // parse source codes\n    const parser = createParser(assignedOptions);\n    const ast = parser.parse(source);\n    if (!jit) {\n        // transform ASTs\n        transform(ast, assignedOptions);\n        // generate javascript codes\n        return generate(ast, assignedOptions);\n    }\n    else {\n        // optimize ASTs\n        enambeOptimize && optimize(ast);\n        // minimize ASTs\n        enalbeMinify && minify(ast);\n        // In JIT mode, no ast transform, no code generation.\n        return { ast, code: '' };\n    }\n}\n\nexport { CompileErrorCodes, ERROR_DOMAIN$2 as ERROR_DOMAIN, LOCATION_STUB, baseCompile, createCompileError, createLocation, createParser, createPosition, defaultOnError, detectHtmlTag, errorMessages };\n","/*!\n  * core-base v9.5.0\n  * (c) 2023 kazuya kawaguchi\n  * Released under the MIT License.\n  */\nimport { getGlobalThis, isObject, isString, isFunction, isNumber, isPlainObject, assign, join, toDisplayString, isArray, format as format$1, isBoolean, warn, isRegExp, warnOnce, incrementer, escapeHtml, inBrowser, mark, measure, isEmptyObject, generateCodeFrame, generateFormatCacheKey, isDate } from '@intlify/shared';\nimport { CompileErrorCodes, createCompileError, detectHtmlTag, defaultOnError, baseCompile as baseCompile$1 } from '@intlify/message-compiler';\nexport { CompileErrorCodes, createCompileError } from '@intlify/message-compiler';\n\n/**\n * This is only called in esm-bundler builds.\n * istanbul-ignore-next\n */\nfunction initFeatureFlags() {\n    if (typeof __INTLIFY_PROD_DEVTOOLS__ !== 'boolean') {\n        getGlobalThis().__INTLIFY_PROD_DEVTOOLS__ = false;\n    }\n    if (typeof __INTLIFY_JIT_COMPILATION__ !== 'boolean') {\n        getGlobalThis().__INTLIFY_JIT_COMPILATION__ = false;\n    }\n    if (typeof __INTLIFY_DROP_MESSAGE_COMPILER__ !== 'boolean') {\n        getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__ = false;\n    }\n}\n\nconst pathStateMachine =  [];\npathStateMachine[0 /* States.BEFORE_PATH */] = {\n    [\"w\" /* PathCharTypes.WORKSPACE */]: [0 /* States.BEFORE_PATH */],\n    [\"i\" /* PathCharTypes.IDENT */]: [3 /* States.IN_IDENT */, 0 /* Actions.APPEND */],\n    [\"[\" /* PathCharTypes.LEFT_BRACKET */]: [4 /* States.IN_SUB_PATH */],\n    [\"o\" /* PathCharTypes.END_OF_FAIL */]: [7 /* States.AFTER_PATH */]\n};\npathStateMachine[1 /* States.IN_PATH */] = {\n    [\"w\" /* PathCharTypes.WORKSPACE */]: [1 /* States.IN_PATH */],\n    [\".\" /* PathCharTypes.DOT */]: [2 /* States.BEFORE_IDENT */],\n    [\"[\" /* PathCharTypes.LEFT_BRACKET */]: [4 /* States.IN_SUB_PATH */],\n    [\"o\" /* PathCharTypes.END_OF_FAIL */]: [7 /* States.AFTER_PATH */]\n};\npathStateMachine[2 /* States.BEFORE_IDENT */] = {\n    [\"w\" /* PathCharTypes.WORKSPACE */]: [2 /* States.BEFORE_IDENT */],\n    [\"i\" /* PathCharTypes.IDENT */]: [3 /* States.IN_IDENT */, 0 /* Actions.APPEND */],\n    [\"0\" /* PathCharTypes.ZERO */]: [3 /* States.IN_IDENT */, 0 /* Actions.APPEND */]\n};\npathStateMachine[3 /* States.IN_IDENT */] = {\n    [\"i\" /* PathCharTypes.IDENT */]: [3 /* States.IN_IDENT */, 0 /* Actions.APPEND */],\n    [\"0\" /* PathCharTypes.ZERO */]: [3 /* States.IN_IDENT */, 0 /* Actions.APPEND */],\n    [\"w\" /* PathCharTypes.WORKSPACE */]: [1 /* States.IN_PATH */, 1 /* Actions.PUSH */],\n    [\".\" /* PathCharTypes.DOT */]: [2 /* States.BEFORE_IDENT */, 1 /* Actions.PUSH */],\n    [\"[\" /* PathCharTypes.LEFT_BRACKET */]: [4 /* States.IN_SUB_PATH */, 1 /* Actions.PUSH */],\n    [\"o\" /* PathCharTypes.END_OF_FAIL */]: [7 /* States.AFTER_PATH */, 1 /* Actions.PUSH */]\n};\npathStateMachine[4 /* States.IN_SUB_PATH */] = {\n    [\"'\" /* PathCharTypes.SINGLE_QUOTE */]: [5 /* States.IN_SINGLE_QUOTE */, 0 /* Actions.APPEND */],\n    [\"\\\"\" /* PathCharTypes.DOUBLE_QUOTE */]: [6 /* States.IN_DOUBLE_QUOTE */, 0 /* Actions.APPEND */],\n    [\"[\" /* PathCharTypes.LEFT_BRACKET */]: [\n        4 /* States.IN_SUB_PATH */,\n        2 /* Actions.INC_SUB_PATH_DEPTH */\n    ],\n    [\"]\" /* PathCharTypes.RIGHT_BRACKET */]: [1 /* States.IN_PATH */, 3 /* Actions.PUSH_SUB_PATH */],\n    [\"o\" /* PathCharTypes.END_OF_FAIL */]: 8 /* States.ERROR */,\n    [\"l\" /* PathCharTypes.ELSE */]: [4 /* States.IN_SUB_PATH */, 0 /* Actions.APPEND */]\n};\npathStateMachine[5 /* States.IN_SINGLE_QUOTE */] = {\n    [\"'\" /* PathCharTypes.SINGLE_QUOTE */]: [4 /* States.IN_SUB_PATH */, 0 /* Actions.APPEND */],\n    [\"o\" /* PathCharTypes.END_OF_FAIL */]: 8 /* States.ERROR */,\n    [\"l\" /* PathCharTypes.ELSE */]: [5 /* States.IN_SINGLE_QUOTE */, 0 /* Actions.APPEND */]\n};\npathStateMachine[6 /* States.IN_DOUBLE_QUOTE */] = {\n    [\"\\\"\" /* PathCharTypes.DOUBLE_QUOTE */]: [4 /* States.IN_SUB_PATH */, 0 /* Actions.APPEND */],\n    [\"o\" /* PathCharTypes.END_OF_FAIL */]: 8 /* States.ERROR */,\n    [\"l\" /* PathCharTypes.ELSE */]: [6 /* States.IN_DOUBLE_QUOTE */, 0 /* Actions.APPEND */]\n};\n/**\n * Check if an expression is a literal value.\n */\nconst literalValueRE = /^\\s?(?:true|false|-?[\\d.]+|'[^']*'|\"[^\"]*\")\\s?$/;\nfunction isLiteral(exp) {\n    return literalValueRE.test(exp);\n}\n/**\n * Strip quotes from a string\n */\nfunction stripQuotes(str) {\n    const a = str.charCodeAt(0);\n    const b = str.charCodeAt(str.length - 1);\n    return a === b && (a === 0x22 || a === 0x27) ? str.slice(1, -1) : str;\n}\n/**\n * Determine the type of a character in a keypath.\n */\nfunction getPathCharType(ch) {\n    if (ch === undefined || ch === null) {\n        return \"o\" /* PathCharTypes.END_OF_FAIL */;\n    }\n    const code = ch.charCodeAt(0);\n    switch (code) {\n        case 0x5b: // [\n        case 0x5d: // ]\n        case 0x2e: // .\n        case 0x22: // \"\n        case 0x27: // '\n            return ch;\n        case 0x5f: // _\n        case 0x24: // $\n        case 0x2d: // -\n            return \"i\" /* PathCharTypes.IDENT */;\n        case 0x09: // Tab (HT)\n        case 0x0a: // Newline (LF)\n        case 0x0d: // Return (CR)\n        case 0xa0: // No-break space (NBSP)\n        case 0xfeff: // Byte Order Mark (BOM)\n        case 0x2028: // Line Separator (LS)\n        case 0x2029: // Paragraph Separator (PS)\n            return \"w\" /* PathCharTypes.WORKSPACE */;\n    }\n    return \"i\" /* PathCharTypes.IDENT */;\n}\n/**\n * Format a subPath, return its plain form if it is\n * a literal string or number. Otherwise prepend the\n * dynamic indicator (*).\n */\nfunction formatSubPath(path) {\n    const trimmed = path.trim();\n    // invalid leading 0\n    if (path.charAt(0) === '0' && isNaN(parseInt(path))) {\n        return false;\n    }\n    return isLiteral(trimmed)\n        ? stripQuotes(trimmed)\n        : \"*\" /* PathCharTypes.ASTARISK */ + trimmed;\n}\n/**\n * Parse a string path into an array of segments\n */\nfunction parse(path) {\n    const keys = [];\n    let index = -1;\n    let mode = 0 /* States.BEFORE_PATH */;\n    let subPathDepth = 0;\n    let c;\n    let key; // eslint-disable-line\n    let newChar;\n    let type;\n    let transition;\n    let action;\n    let typeMap;\n    const actions = [];\n    actions[0 /* Actions.APPEND */] = () => {\n        if (key === undefined) {\n            key = newChar;\n        }\n        else {\n            key += newChar;\n        }\n    };\n    actions[1 /* Actions.PUSH */] = () => {\n        if (key !== undefined) {\n            keys.push(key);\n            key = undefined;\n        }\n    };\n    actions[2 /* Actions.INC_SUB_PATH_DEPTH */] = () => {\n        actions[0 /* Actions.APPEND */]();\n        subPathDepth++;\n    };\n    actions[3 /* Actions.PUSH_SUB_PATH */] = () => {\n        if (subPathDepth > 0) {\n            subPathDepth--;\n            mode = 4 /* States.IN_SUB_PATH */;\n            actions[0 /* Actions.APPEND */]();\n        }\n        else {\n            subPathDepth = 0;\n            if (key === undefined) {\n                return false;\n            }\n            key = formatSubPath(key);\n            if (key === false) {\n                return false;\n            }\n            else {\n                actions[1 /* Actions.PUSH */]();\n            }\n        }\n    };\n    function maybeUnescapeQuote() {\n        const nextChar = path[index + 1];\n        if ((mode === 5 /* States.IN_SINGLE_QUOTE */ &&\n            nextChar === \"'\" /* PathCharTypes.SINGLE_QUOTE */) ||\n            (mode === 6 /* States.IN_DOUBLE_QUOTE */ &&\n                nextChar === \"\\\"\" /* PathCharTypes.DOUBLE_QUOTE */)) {\n            index++;\n            newChar = '\\\\' + nextChar;\n            actions[0 /* Actions.APPEND */]();\n            return true;\n        }\n    }\n    while (mode !== null) {\n        index++;\n        c = path[index];\n        if (c === '\\\\' && maybeUnescapeQuote()) {\n            continue;\n        }\n        type = getPathCharType(c);\n        typeMap = pathStateMachine[mode];\n        transition = typeMap[type] || typeMap[\"l\" /* PathCharTypes.ELSE */] || 8 /* States.ERROR */;\n        // check parse error\n        if (transition === 8 /* States.ERROR */) {\n            return;\n        }\n        mode = transition[0];\n        if (transition[1] !== undefined) {\n            action = actions[transition[1]];\n            if (action) {\n                newChar = c;\n                if (action() === false) {\n                    return;\n                }\n            }\n        }\n        // check parse finish\n        if (mode === 7 /* States.AFTER_PATH */) {\n            return keys;\n        }\n    }\n}\n// path token cache\nconst cache = new Map();\n/**\n * key-value message resolver\n *\n * @remarks\n * Resolves messages with the key-value structure. Note that messages with a hierarchical structure such as objects cannot be resolved\n *\n * @param obj - A target object to be resolved with path\n * @param path - A {@link Path | path} to resolve the value of message\n *\n * @returns A resolved {@link PathValue | path value}\n *\n * @VueI18nGeneral\n */\nfunction resolveWithKeyValue(obj, path) {\n    return isObject(obj) ? obj[path] : null;\n}\n/**\n * message resolver\n *\n * @remarks\n * Resolves messages. messages with a hierarchical structure such as objects can be resolved. This resolver is used in VueI18n as default.\n *\n * @param obj - A target object to be resolved with path\n * @param path - A {@link Path | path} to resolve the value of message\n *\n * @returns A resolved {@link PathValue | path value}\n *\n * @VueI18nGeneral\n */\nfunction resolveValue(obj, path) {\n    // check object\n    if (!isObject(obj)) {\n        return null;\n    }\n    // parse path\n    let hit = cache.get(path);\n    if (!hit) {\n        hit = parse(path);\n        if (hit) {\n            cache.set(path, hit);\n        }\n    }\n    // check hit\n    if (!hit) {\n        return null;\n    }\n    // resolve path value\n    const len = hit.length;\n    let last = obj;\n    let i = 0;\n    while (i < len) {\n        const val = last[hit[i]];\n        if (val === undefined) {\n            return null;\n        }\n        last = val;\n        i++;\n    }\n    return last;\n}\n\nconst DEFAULT_MODIFIER = (str) => str;\nconst DEFAULT_MESSAGE = (ctx) => ''; // eslint-disable-line\nconst DEFAULT_MESSAGE_DATA_TYPE = 'text';\nconst DEFAULT_NORMALIZE = (values) => values.length === 0 ? '' : join(values);\nconst DEFAULT_INTERPOLATE = toDisplayString;\nfunction pluralDefault(choice, choicesLength) {\n    choice = Math.abs(choice);\n    if (choicesLength === 2) {\n        // prettier-ignore\n        return choice\n            ? choice > 1\n                ? 1\n                : 0\n            : 1;\n    }\n    return choice ? Math.min(choice, 2) : 0;\n}\nfunction getPluralIndex(options) {\n    // prettier-ignore\n    const index = isNumber(options.pluralIndex)\n        ? options.pluralIndex\n        : -1;\n    // prettier-ignore\n    return options.named && (isNumber(options.named.count) || isNumber(options.named.n))\n        ? isNumber(options.named.count)\n            ? options.named.count\n            : isNumber(options.named.n)\n                ? options.named.n\n                : index\n        : index;\n}\nfunction normalizeNamed(pluralIndex, props) {\n    if (!props.count) {\n        props.count = pluralIndex;\n    }\n    if (!props.n) {\n        props.n = pluralIndex;\n    }\n}\nfunction createMessageContext(options = {}) {\n    const locale = options.locale;\n    const pluralIndex = getPluralIndex(options);\n    const pluralRule = isObject(options.pluralRules) &&\n        isString(locale) &&\n        isFunction(options.pluralRules[locale])\n        ? options.pluralRules[locale]\n        : pluralDefault;\n    const orgPluralRule = isObject(options.pluralRules) &&\n        isString(locale) &&\n        isFunction(options.pluralRules[locale])\n        ? pluralDefault\n        : undefined;\n    const plural = (messages) => {\n        return messages[pluralRule(pluralIndex, messages.length, orgPluralRule)];\n    };\n    const _list = options.list || [];\n    const list = (index) => _list[index];\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    const _named = options.named || {};\n    isNumber(options.pluralIndex) && normalizeNamed(pluralIndex, _named);\n    const named = (key) => _named[key];\n    function message(key) {\n        // prettier-ignore\n        const msg = isFunction(options.messages)\n            ? options.messages(key)\n            : isObject(options.messages)\n                ? options.messages[key]\n                : false;\n        return !msg\n            ? options.parent\n                ? options.parent.message(key) // resolve from parent messages\n                : DEFAULT_MESSAGE\n            : msg;\n    }\n    const _modifier = (name) => options.modifiers\n        ? options.modifiers[name]\n        : DEFAULT_MODIFIER;\n    const normalize = isPlainObject(options.processor) && isFunction(options.processor.normalize)\n        ? options.processor.normalize\n        : DEFAULT_NORMALIZE;\n    const interpolate = isPlainObject(options.processor) &&\n        isFunction(options.processor.interpolate)\n        ? options.processor.interpolate\n        : DEFAULT_INTERPOLATE;\n    const type = isPlainObject(options.processor) && isString(options.processor.type)\n        ? options.processor.type\n        : DEFAULT_MESSAGE_DATA_TYPE;\n    const linked = (key, ...args) => {\n        const [arg1, arg2] = args;\n        let type = 'text';\n        let modifier = '';\n        if (args.length === 1) {\n            if (isObject(arg1)) {\n                modifier = arg1.modifier || modifier;\n                type = arg1.type || type;\n            }\n            else if (isString(arg1)) {\n                modifier = arg1 || modifier;\n            }\n        }\n        else if (args.length === 2) {\n            if (isString(arg1)) {\n                modifier = arg1 || modifier;\n            }\n            if (isString(arg2)) {\n                type = arg2 || type;\n            }\n        }\n        const ret = message(key)(ctx);\n        const msg = \n        // The message in vnode resolved with linked are returned as an array by processor.nomalize\n        type === 'vnode' && isArray(ret) && modifier\n            ? ret[0]\n            : ret;\n        return modifier ? _modifier(modifier)(msg, type) : msg;\n    };\n    const ctx = {\n        [\"list\" /* HelperNameMap.LIST */]: list,\n        [\"named\" /* HelperNameMap.NAMED */]: named,\n        [\"plural\" /* HelperNameMap.PLURAL */]: plural,\n        [\"linked\" /* HelperNameMap.LINKED */]: linked,\n        [\"message\" /* HelperNameMap.MESSAGE */]: message,\n        [\"type\" /* HelperNameMap.TYPE */]: type,\n        [\"interpolate\" /* HelperNameMap.INTERPOLATE */]: interpolate,\n        [\"normalize\" /* HelperNameMap.NORMALIZE */]: normalize,\n        [\"values\" /* HelperNameMap.VALUES */]: assign({}, _list, _named)\n    };\n    return ctx;\n}\n\nlet devtools = null;\nfunction setDevToolsHook(hook) {\n    devtools = hook;\n}\nfunction getDevToolsHook() {\n    return devtools;\n}\nfunction initI18nDevTools(i18n, version, meta) {\n    // TODO: queue if devtools is undefined\n    devtools &&\n        devtools.emit(\"i18n:init\" /* IntlifyDevToolsHooks.I18nInit */, {\n            timestamp: Date.now(),\n            i18n,\n            version,\n            meta\n        });\n}\nconst translateDevTools = /* #__PURE__*/ createDevToolsHook(\"function:translate\" /* IntlifyDevToolsHooks.FunctionTranslate */);\nfunction createDevToolsHook(hook) {\n    return (payloads) => devtools && devtools.emit(hook, payloads);\n}\n\nconst CoreWarnCodes = {\n    NOT_FOUND_KEY: 1,\n    FALLBACK_TO_TRANSLATE: 2,\n    CANNOT_FORMAT_NUMBER: 3,\n    FALLBACK_TO_NUMBER_FORMAT: 4,\n    CANNOT_FORMAT_DATE: 5,\n    FALLBACK_TO_DATE_FORMAT: 6,\n    EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER: 7,\n    __EXTEND_POINT__: 8\n};\n/** @internal */\nconst warnMessages = {\n    [CoreWarnCodes.NOT_FOUND_KEY]: `Not found '{key}' key in '{locale}' locale messages.`,\n    [CoreWarnCodes.FALLBACK_TO_TRANSLATE]: `Fall back to translate '{key}' key with '{target}' locale.`,\n    [CoreWarnCodes.CANNOT_FORMAT_NUMBER]: `Cannot format a number value due to not supported Intl.NumberFormat.`,\n    [CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT]: `Fall back to number format '{key}' key with '{target}' locale.`,\n    [CoreWarnCodes.CANNOT_FORMAT_DATE]: `Cannot format a date value due to not supported Intl.DateTimeFormat.`,\n    [CoreWarnCodes.FALLBACK_TO_DATE_FORMAT]: `Fall back to datetime format '{key}' key with '{target}' locale.`,\n    [CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER]: `This project is using Custom Message Compiler, which is an experimental feature. It may receive breaking changes or be removed in the future.`\n};\nfunction getWarnMessage(code, ...args) {\n    return format$1(warnMessages[code], ...args);\n}\n\n/** @internal */\nfunction getLocale(context, options) {\n    return options.locale != null\n        ? resolveLocale(options.locale)\n        : resolveLocale(context.locale);\n}\nlet _resolveLocale;\n/** @internal */\nfunction resolveLocale(locale) {\n    // prettier-ignore\n    return isString(locale)\n        ? locale\n        : _resolveLocale != null && locale.resolvedOnce\n            ? _resolveLocale\n            : (_resolveLocale = locale());\n}\n/**\n * Fallback with simple implemenation\n *\n * @remarks\n * A fallback locale function implemented with a simple fallback algorithm.\n *\n * Basically, it returns the value as specified in the `fallbackLocale` props, and is processed with the fallback inside intlify.\n *\n * @param ctx - A {@link CoreContext | context}\n * @param fallback - A {@link FallbackLocale | fallback locale}\n * @param start - A starting {@link Locale | locale}\n *\n * @returns Fallback locales\n *\n * @VueI18nGeneral\n */\nfunction fallbackWithSimple(ctx, fallback, start // eslint-disable-line @typescript-eslint/no-unused-vars\n) {\n    // prettier-ignore\n    return [...new Set([\n            start,\n            ...(isArray(fallback)\n                ? fallback\n                : isObject(fallback)\n                    ? Object.keys(fallback)\n                    : isString(fallback)\n                        ? [fallback]\n                        : [start])\n        ])];\n}\n/**\n * Fallback with locale chain\n *\n * @remarks\n * A fallback locale function implemented with a fallback chain algorithm. It's used in VueI18n as default.\n *\n * @param ctx - A {@link CoreContext | context}\n * @param fallback - A {@link FallbackLocale | fallback locale}\n * @param start - A starting {@link Locale | locale}\n *\n * @returns Fallback locales\n *\n * @VueI18nSee [Fallbacking](../guide/essentials/fallback)\n *\n * @VueI18nGeneral\n */\nfunction fallbackWithLocaleChain(ctx, fallback, start) {\n    const startLocale = isString(start) ? start : DEFAULT_LOCALE;\n    const context = ctx;\n    if (!context.__localeChainCache) {\n        context.__localeChainCache = new Map();\n    }\n    let chain = context.__localeChainCache.get(startLocale);\n    if (!chain) {\n        chain = [];\n        // first block defined by start\n        let block = [start];\n        // while any intervening block found\n        while (isArray(block)) {\n            block = appendBlockToChain(chain, block, fallback);\n        }\n        // prettier-ignore\n        // last block defined by default\n        const defaults = isArray(fallback) || !isPlainObject(fallback)\n            ? fallback\n            : fallback['default']\n                ? fallback['default']\n                : null;\n        // convert defaults to array\n        block = isString(defaults) ? [defaults] : defaults;\n        if (isArray(block)) {\n            appendBlockToChain(chain, block, false);\n        }\n        context.__localeChainCache.set(startLocale, chain);\n    }\n    return chain;\n}\nfunction appendBlockToChain(chain, block, blocks) {\n    let follow = true;\n    for (let i = 0; i < block.length && isBoolean(follow); i++) {\n        const locale = block[i];\n        if (isString(locale)) {\n            follow = appendLocaleToChain(chain, block[i], blocks);\n        }\n    }\n    return follow;\n}\nfunction appendLocaleToChain(chain, locale, blocks) {\n    let follow;\n    const tokens = locale.split('-');\n    do {\n        const target = tokens.join('-');\n        follow = appendItemToChain(chain, target, blocks);\n        tokens.splice(-1, 1);\n    } while (tokens.length && follow === true);\n    return follow;\n}\nfunction appendItemToChain(chain, target, blocks) {\n    let follow = false;\n    if (!chain.includes(target)) {\n        follow = true;\n        if (target) {\n            follow = target[target.length - 1] !== '!';\n            const locale = target.replace(/!/g, '');\n            chain.push(locale);\n            if ((isArray(blocks) || isPlainObject(blocks)) &&\n                blocks[locale] // eslint-disable-line @typescript-eslint/no-explicit-any\n            ) {\n                // eslint-disable-next-line @typescript-eslint/no-explicit-any\n                follow = blocks[locale];\n            }\n        }\n    }\n    return follow;\n}\n\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/**\n * Intlify core-base version\n * @internal\n */\nconst VERSION = '9.5.0';\nconst NOT_REOSLVED = -1;\nconst DEFAULT_LOCALE = 'en-US';\nconst MISSING_RESOLVE_VALUE = '';\nconst capitalize = (str) => `${str.charAt(0).toLocaleUpperCase()}${str.substr(1)}`;\nfunction getDefaultLinkedModifiers() {\n    return {\n        upper: (val, type) => {\n            // prettier-ignore\n            return type === 'text' && isString(val)\n                ? val.toUpperCase()\n                : type === 'vnode' && isObject(val) && '__v_isVNode' in val\n                    ? val.children.toUpperCase()\n                    : val;\n        },\n        lower: (val, type) => {\n            // prettier-ignore\n            return type === 'text' && isString(val)\n                ? val.toLowerCase()\n                : type === 'vnode' && isObject(val) && '__v_isVNode' in val\n                    ? val.children.toLowerCase()\n                    : val;\n        },\n        capitalize: (val, type) => {\n            // prettier-ignore\n            return (type === 'text' && isString(val)\n                ? capitalize(val)\n                : type === 'vnode' && isObject(val) && '__v_isVNode' in val\n                    ? capitalize(val.children)\n                    : val);\n        }\n    };\n}\nlet _compiler;\nfunction registerMessageCompiler(compiler) {\n    _compiler = compiler;\n}\nlet _resolver;\n/**\n * Register the message resolver\n *\n * @param resolver - A {@link MessageResolver} function\n *\n * @VueI18nGeneral\n */\nfunction registerMessageResolver(resolver) {\n    _resolver = resolver;\n}\nlet _fallbacker;\n/**\n * Register the locale fallbacker\n *\n * @param fallbacker - A {@link LocaleFallbacker} function\n *\n * @VueI18nGeneral\n */\nfunction registerLocaleFallbacker(fallbacker) {\n    _fallbacker = fallbacker;\n}\n// Additional Meta for Intlify DevTools\nlet _additionalMeta =  null;\nconst setAdditionalMeta = /* #__PURE__*/ (meta) => {\n    _additionalMeta = meta;\n};\nconst getAdditionalMeta = /* #__PURE__*/ () => _additionalMeta;\nlet _fallbackContext = null;\nconst setFallbackContext = (context) => {\n    _fallbackContext = context;\n};\nconst getFallbackContext = () => _fallbackContext;\n// ID for CoreContext\nlet _cid = 0;\nfunction createCoreContext(options = {}) {\n    // setup options\n    const onWarn = isFunction(options.onWarn) ? options.onWarn : warn;\n    const version = isString(options.version) ? options.version : VERSION;\n    const locale = isString(options.locale) || isFunction(options.locale)\n        ? options.locale\n        : DEFAULT_LOCALE;\n    const _locale = isFunction(locale) ? DEFAULT_LOCALE : locale;\n    const fallbackLocale = isArray(options.fallbackLocale) ||\n        isPlainObject(options.fallbackLocale) ||\n        isString(options.fallbackLocale) ||\n        options.fallbackLocale === false\n        ? options.fallbackLocale\n        : _locale;\n    const messages = isPlainObject(options.messages)\n        ? options.messages\n        : { [_locale]: {} };\n    const datetimeFormats = isPlainObject(options.datetimeFormats)\n            ? options.datetimeFormats\n            : { [_locale]: {} }\n        ;\n    const numberFormats = isPlainObject(options.numberFormats)\n            ? options.numberFormats\n            : { [_locale]: {} }\n        ;\n    const modifiers = assign({}, options.modifiers || {}, getDefaultLinkedModifiers());\n    const pluralRules = options.pluralRules || {};\n    const missing = isFunction(options.missing) ? options.missing : null;\n    const missingWarn = isBoolean(options.missingWarn) || isRegExp(options.missingWarn)\n        ? options.missingWarn\n        : true;\n    const fallbackWarn = isBoolean(options.fallbackWarn) || isRegExp(options.fallbackWarn)\n        ? options.fallbackWarn\n        : true;\n    const fallbackFormat = !!options.fallbackFormat;\n    const unresolving = !!options.unresolving;\n    const postTranslation = isFunction(options.postTranslation)\n        ? options.postTranslation\n        : null;\n    const processor = isPlainObject(options.processor) ? options.processor : null;\n    const warnHtmlMessage = isBoolean(options.warnHtmlMessage)\n        ? options.warnHtmlMessage\n        : true;\n    const escapeParameter = !!options.escapeParameter;\n    const messageCompiler = isFunction(options.messageCompiler)\n        ? options.messageCompiler\n        : _compiler;\n    if ((process.env.NODE_ENV !== 'production') &&\n        !false &&\n        !false &&\n        isFunction(options.messageCompiler)) {\n        warnOnce(getWarnMessage(CoreWarnCodes.EXPERIMENTAL_CUSTOM_MESSAGE_COMPILER));\n    }\n    const messageResolver = isFunction(options.messageResolver)\n        ? options.messageResolver\n        : _resolver || resolveWithKeyValue;\n    const localeFallbacker = isFunction(options.localeFallbacker)\n        ? options.localeFallbacker\n        : _fallbacker || fallbackWithSimple;\n    const fallbackContext = isObject(options.fallbackContext)\n        ? options.fallbackContext\n        : undefined;\n    // setup internal options\n    const internalOptions = options;\n    const __datetimeFormatters = isObject(internalOptions.__datetimeFormatters)\n            ? internalOptions.__datetimeFormatters\n            : new Map()\n        ;\n    const __numberFormatters = isObject(internalOptions.__numberFormatters)\n            ? internalOptions.__numberFormatters\n            : new Map()\n        ;\n    const __meta = isObject(internalOptions.__meta) ? internalOptions.__meta : {};\n    _cid++;\n    const context = {\n        version,\n        cid: _cid,\n        locale,\n        fallbackLocale,\n        messages,\n        modifiers,\n        pluralRules,\n        missing,\n        missingWarn,\n        fallbackWarn,\n        fallbackFormat,\n        unresolving,\n        postTranslation,\n        processor,\n        warnHtmlMessage,\n        escapeParameter,\n        messageCompiler,\n        messageResolver,\n        localeFallbacker,\n        fallbackContext,\n        onWarn,\n        __meta\n    };\n    {\n        context.datetimeFormats = datetimeFormats;\n        context.numberFormats = numberFormats;\n        context.__datetimeFormatters = __datetimeFormatters;\n        context.__numberFormatters = __numberFormatters;\n    }\n    // for vue-devtools timeline event\n    if ((process.env.NODE_ENV !== 'production')) {\n        context.__v_emitter =\n            internalOptions.__v_emitter != null\n                ? internalOptions.__v_emitter\n                : undefined;\n    }\n    // NOTE: experimental !!\n    if ((process.env.NODE_ENV !== 'production') || __INTLIFY_PROD_DEVTOOLS__) {\n        initI18nDevTools(context, version, __meta);\n    }\n    return context;\n}\n/** @internal */\nfunction isTranslateFallbackWarn(fallback, key) {\n    return fallback instanceof RegExp ? fallback.test(key) : fallback;\n}\n/** @internal */\nfunction isTranslateMissingWarn(missing, key) {\n    return missing instanceof RegExp ? missing.test(key) : missing;\n}\n/** @internal */\nfunction handleMissing(context, key, locale, missingWarn, type) {\n    const { missing, onWarn } = context;\n    // for vue-devtools timeline event\n    if ((process.env.NODE_ENV !== 'production')) {\n        const emitter = context.__v_emitter;\n        if (emitter) {\n            emitter.emit(\"missing\" /* VueDevToolsTimelineEvents.MISSING */, {\n                locale,\n                key,\n                type,\n                groupId: `${type}:${key}`\n            });\n        }\n    }\n    if (missing !== null) {\n        const ret = missing(context, locale, key, type);\n        return isString(ret) ? ret : key;\n    }\n    else {\n        if ((process.env.NODE_ENV !== 'production') && isTranslateMissingWarn(missingWarn, key)) {\n            onWarn(getWarnMessage(CoreWarnCodes.NOT_FOUND_KEY, { key, locale }));\n        }\n        return key;\n    }\n}\n/** @internal */\nfunction updateFallbackLocale(ctx, locale, fallback) {\n    const context = ctx;\n    context.__localeChainCache = new Map();\n    ctx.localeFallbacker(ctx, fallback, locale);\n}\n/* eslint-enable @typescript-eslint/no-explicit-any */\n\nfunction format(ast) {\n    const msg = (ctx) => formatParts(ctx, ast);\n    return msg;\n}\nfunction formatParts(ctx, ast) {\n    const body = ast.b || ast.body;\n    if ((body.t || body.type) === 1 /* NodeTypes.Plural */) {\n        const plural = body;\n        const cases = plural.c || plural.cases;\n        return ctx.plural(cases.reduce((messages, c) => [\n            ...messages,\n            formatMessageParts(ctx, c)\n        ], []));\n    }\n    else {\n        return formatMessageParts(ctx, body);\n    }\n}\nfunction formatMessageParts(ctx, node) {\n    const _static = node.s || node.static;\n    if (_static) {\n        return ctx.type === 'text'\n            ? _static\n            : ctx.normalize([_static]);\n    }\n    else {\n        const messages = (node.i || node.items).reduce((acm, c) => [...acm, formatMessagePart(ctx, c)], []);\n        return ctx.normalize(messages);\n    }\n}\nfunction formatMessagePart(ctx, node) {\n    const type = node.t || node.type;\n    switch (type) {\n        case 3 /* NodeTypes.Text */:\n            const text = node;\n            return (text.v || text.value);\n        case 9 /* NodeTypes.Literal */:\n            const literal = node;\n            return (literal.v || literal.value);\n        case 4 /* NodeTypes.Named */:\n            const named = node;\n            return ctx.interpolate(ctx.named(named.k || named.key));\n        case 5 /* NodeTypes.List */:\n            const list = node;\n            return ctx.interpolate(ctx.list(list.i != null ? list.i : list.index));\n        case 6 /* NodeTypes.Linked */:\n            const linked = node;\n            const modifier = linked.m || linked.modifier;\n            return ctx.linked(formatMessagePart(ctx, linked.k || linked.key), modifier ? formatMessagePart(ctx, modifier) : undefined, ctx.type);\n        case 7 /* NodeTypes.LinkedKey */:\n            const linkedKey = node;\n            return (linkedKey.v || linkedKey.value);\n        case 8 /* NodeTypes.LinkedModifier */:\n            const linkedModifier = node;\n            return (linkedModifier.v || linkedModifier.value);\n        default:\n            throw new Error(`unhandled node type on format message part: ${type}`);\n    }\n}\n\nconst code = CompileErrorCodes.__EXTEND_POINT__;\nconst inc = incrementer(code);\nconst CoreErrorCodes = {\n    INVALID_ARGUMENT: code,\n    INVALID_DATE_ARGUMENT: inc(),\n    INVALID_ISO_DATE_ARGUMENT: inc(),\n    NOT_SUPPORT_NON_STRING_MESSAGE: inc(),\n    __EXTEND_POINT__: inc() // 22\n};\nfunction createCoreError(code) {\n    return createCompileError(code, null, (process.env.NODE_ENV !== 'production') ? { messages: errorMessages } : undefined);\n}\n/** @internal */\nconst errorMessages = {\n    [CoreErrorCodes.INVALID_ARGUMENT]: 'Invalid arguments',\n    [CoreErrorCodes.INVALID_DATE_ARGUMENT]: 'The date provided is an invalid Date object.' +\n        'Make sure your Date represents a valid date.',\n    [CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT]: 'The argument provided is not a valid ISO date string',\n    [CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE]: 'Not support non-string message'\n};\n\nconst WARN_MESSAGE = `Detected HTML in '{source}' message. Recommend not using HTML messages to avoid XSS.`;\nfunction checkHtmlMessage(source, warnHtmlMessage) {\n    if (warnHtmlMessage && detectHtmlTag(source)) {\n        warn(format$1(WARN_MESSAGE, { source }));\n    }\n}\nconst defaultOnCacheKey = (message) => message;\nlet compileCache = Object.create(null);\nfunction clearCompileCache() {\n    compileCache = Object.create(null);\n}\nconst isMessageAST = (val) => isObject(val) &&\n    (val.t === 0 || val.type === 0) &&\n    ('b' in val || 'body' in val);\nfunction baseCompile(message, options = {}) {\n    // error detecting on compile\n    let detectError = false;\n    const onError = options.onError || defaultOnError;\n    options.onError = (err) => {\n        detectError = true;\n        onError(err);\n    };\n    // compile with mesasge-compiler\n    return { ...baseCompile$1(message, options), detectError };\n}\nconst compileToFunction = /* #__PURE__*/ (message, context) => {\n    if (!isString(message)) {\n        throw createCoreError(CoreErrorCodes.NOT_SUPPORT_NON_STRING_MESSAGE);\n    }\n    {\n        // check HTML message\n        const warnHtmlMessage = isBoolean(context.warnHtmlMessage)\n            ? context.warnHtmlMessage\n            : true;\n        (process.env.NODE_ENV !== 'production') && checkHtmlMessage(message, warnHtmlMessage);\n        // check caches\n        const onCacheKey = context.onCacheKey || defaultOnCacheKey;\n        const cacheKey = onCacheKey(message);\n        const cached = compileCache[cacheKey];\n        if (cached) {\n            return cached;\n        }\n        // compile\n        const { code, detectError } = baseCompile(message, context);\n        // evaluate function\n        const msg = new Function(`return ${code}`)();\n        // if occurred compile error, don't cache\n        return !detectError\n            ? (compileCache[cacheKey] = msg)\n            : msg;\n    }\n};\nfunction compile(message, context) {\n    if (((__INTLIFY_JIT_COMPILATION__ && !__INTLIFY_DROP_MESSAGE_COMPILER__)) &&\n        isString(message)) {\n        // check HTML message\n        const warnHtmlMessage = isBoolean(context.warnHtmlMessage)\n            ? context.warnHtmlMessage\n            : true;\n        (process.env.NODE_ENV !== 'production') && checkHtmlMessage(message, warnHtmlMessage);\n        // check caches\n        const onCacheKey = context.onCacheKey || defaultOnCacheKey;\n        const cacheKey = onCacheKey(message);\n        const cached = compileCache[cacheKey];\n        if (cached) {\n            return cached;\n        }\n        // compile with JIT mode\n        const { ast, detectError } = baseCompile(message, {\n            ...context,\n            location: (process.env.NODE_ENV !== 'production'),\n            jit: true\n        });\n        // compose message function from AST\n        const msg = format(ast);\n        // if occurred compile error, don't cache\n        return !detectError\n            ? (compileCache[cacheKey] = msg)\n            : msg;\n    }\n    else {\n        if ((process.env.NODE_ENV !== 'production') && !isMessageAST(message)) {\n            warn(`the message that is resolve with key '${context.key}' is not supported for jit compilation`);\n            return (() => message);\n        }\n        // AST case (passed from bundler)\n        const cacheKey = message.cacheKey;\n        if (cacheKey) {\n            const cached = compileCache[cacheKey];\n            if (cached) {\n                return cached;\n            }\n            // compose message function from message (AST)\n            return (compileCache[cacheKey] =\n                format(message));\n        }\n        else {\n            return format(message);\n        }\n    }\n}\n\nconst NOOP_MESSAGE_FUNCTION = () => '';\nconst isMessageFunction = (val) => isFunction(val);\n// implementation of `translate` function\nfunction translate(context, ...args) {\n    const { fallbackFormat, postTranslation, unresolving, messageCompiler, fallbackLocale, messages } = context;\n    const [key, options] = parseTranslateArgs(...args);\n    const missingWarn = isBoolean(options.missingWarn)\n        ? options.missingWarn\n        : context.missingWarn;\n    const fallbackWarn = isBoolean(options.fallbackWarn)\n        ? options.fallbackWarn\n        : context.fallbackWarn;\n    const escapeParameter = isBoolean(options.escapeParameter)\n        ? options.escapeParameter\n        : context.escapeParameter;\n    const resolvedMessage = !!options.resolvedMessage;\n    // prettier-ignore\n    const defaultMsgOrKey = isString(options.default) || isBoolean(options.default) // default by function option\n        ? !isBoolean(options.default)\n            ? options.default\n            : (!messageCompiler ? () => key : key)\n        : fallbackFormat // default by `fallbackFormat` option\n            ? (!messageCompiler ? () => key : key)\n            : '';\n    const enableDefaultMsg = fallbackFormat || defaultMsgOrKey !== '';\n    const locale = getLocale(context, options);\n    // escape params\n    escapeParameter && escapeParams(options);\n    // resolve message format\n    // eslint-disable-next-line prefer-const\n    let [formatScope, targetLocale, message] = !resolvedMessage\n        ? resolveMessageFormat(context, key, locale, fallbackLocale, fallbackWarn, missingWarn)\n        : [\n            key,\n            locale,\n            messages[locale] || {}\n        ];\n    // NOTE:\n    //  Fix to work around `ssrTransfrom` bug in Vite.\n    //  https://github.com/vitejs/vite/issues/4306\n    //  To get around this, use temporary variables.\n    //  https://github.com/nuxt/framework/issues/1461#issuecomment-954606243\n    let format = formatScope;\n    // if you use default message, set it as message format!\n    let cacheBaseKey = key;\n    if (!resolvedMessage &&\n        !(isString(format) ||\n            isMessageAST(format) ||\n            isMessageFunction(format))) {\n        if (enableDefaultMsg) {\n            format = defaultMsgOrKey;\n            cacheBaseKey = format;\n        }\n    }\n    // checking message format and target locale\n    if (!resolvedMessage &&\n        (!(isString(format) ||\n            isMessageAST(format) ||\n            isMessageFunction(format)) ||\n            !isString(targetLocale))) {\n        return unresolving ? NOT_REOSLVED : key;\n    }\n    // TODO: refactor\n    if ((process.env.NODE_ENV !== 'production') && isString(format) && context.messageCompiler == null) {\n        warn(`The message format compilation is not supported in this build. ` +\n            `Because message compiler isn't included. ` +\n            `You need to pre-compilation all message format. ` +\n            `So translate function return '${key}'.`);\n        return key;\n    }\n    // setup compile error detecting\n    let occurred = false;\n    const onError = () => {\n        occurred = true;\n    };\n    // compile message format\n    const msg = !isMessageFunction(format)\n        ? compileMessageFormat(context, key, targetLocale, format, cacheBaseKey, onError)\n        : format;\n    // if occurred compile error, return the message format\n    if (occurred) {\n        return format;\n    }\n    // evaluate message with context\n    const ctxOptions = getMessageContextOptions(context, targetLocale, message, options);\n    const msgContext = createMessageContext(ctxOptions);\n    const messaged = evaluateMessage(context, msg, msgContext);\n    // if use post translation option, proceed it with handler\n    const ret = postTranslation\n        ? postTranslation(messaged, key)\n        : messaged;\n    // NOTE: experimental !!\n    if ((process.env.NODE_ENV !== 'production') || __INTLIFY_PROD_DEVTOOLS__) {\n        // prettier-ignore\n        const payloads = {\n            timestamp: Date.now(),\n            key: isString(key)\n                ? key\n                : isMessageFunction(format)\n                    ? format.key\n                    : '',\n            locale: targetLocale || (isMessageFunction(format)\n                ? format.locale\n                : ''),\n            format: isString(format)\n                ? format\n                : isMessageFunction(format)\n                    ? format.source\n                    : '',\n            message: ret\n        };\n        payloads.meta = assign({}, context.__meta, getAdditionalMeta() || {});\n        translateDevTools(payloads);\n    }\n    return ret;\n}\nfunction escapeParams(options) {\n    if (isArray(options.list)) {\n        options.list = options.list.map(item => isString(item) ? escapeHtml(item) : item);\n    }\n    else if (isObject(options.named)) {\n        Object.keys(options.named).forEach(key => {\n            if (isString(options.named[key])) {\n                options.named[key] = escapeHtml(options.named[key]);\n            }\n        });\n    }\n}\nfunction resolveMessageFormat(context, key, locale, fallbackLocale, fallbackWarn, missingWarn) {\n    const { messages, onWarn, messageResolver: resolveValue, localeFallbacker } = context;\n    const locales = localeFallbacker(context, fallbackLocale, locale); // eslint-disable-line @typescript-eslint/no-explicit-any\n    let message = {};\n    let targetLocale;\n    let format = null;\n    let from = locale;\n    let to = null;\n    const type = 'translate';\n    for (let i = 0; i < locales.length; i++) {\n        targetLocale = to = locales[i];\n        if ((process.env.NODE_ENV !== 'production') &&\n            locale !== targetLocale &&\n            isTranslateFallbackWarn(fallbackWarn, key)) {\n            onWarn(getWarnMessage(CoreWarnCodes.FALLBACK_TO_TRANSLATE, {\n                key,\n                target: targetLocale\n            }));\n        }\n        // for vue-devtools timeline event\n        if ((process.env.NODE_ENV !== 'production') && locale !== targetLocale) {\n            const emitter = context.__v_emitter;\n            if (emitter) {\n                emitter.emit(\"fallback\" /* VueDevToolsTimelineEvents.FALBACK */, {\n                    type,\n                    key,\n                    from,\n                    to,\n                    groupId: `${type}:${key}`\n                });\n            }\n        }\n        message =\n            messages[targetLocale] || {};\n        // for vue-devtools timeline event\n        let start = null;\n        let startTag;\n        let endTag;\n        if ((process.env.NODE_ENV !== 'production') && inBrowser) {\n            start = window.performance.now();\n            startTag = 'intlify-message-resolve-start';\n            endTag = 'intlify-message-resolve-end';\n            mark && mark(startTag);\n        }\n        if ((format = resolveValue(message, key)) === null) {\n            // if null, resolve with object key path\n            format = message[key]; // eslint-disable-line @typescript-eslint/no-explicit-any\n        }\n        // for vue-devtools timeline event\n        if ((process.env.NODE_ENV !== 'production') && inBrowser) {\n            const end = window.performance.now();\n            const emitter = context.__v_emitter;\n            if (emitter && start && format) {\n                emitter.emit(\"message-resolve\" /* VueDevToolsTimelineEvents.MESSAGE_RESOLVE */, {\n                    type: \"message-resolve\" /* VueDevToolsTimelineEvents.MESSAGE_RESOLVE */,\n                    key,\n                    message: format,\n                    time: end - start,\n                    groupId: `${type}:${key}`\n                });\n            }\n            if (startTag && endTag && mark && measure) {\n                mark(endTag);\n                measure('intlify message resolve', startTag, endTag);\n            }\n        }\n        if (isString(format) || isMessageAST(format) || isMessageFunction(format)) {\n            break;\n        }\n        const missingRet = handleMissing(context, // eslint-disable-line @typescript-eslint/no-explicit-any\n        key, targetLocale, missingWarn, type);\n        if (missingRet !== key) {\n            format = missingRet;\n        }\n        from = to;\n    }\n    return [format, targetLocale, message];\n}\nfunction compileMessageFormat(context, key, targetLocale, format, cacheBaseKey, onError) {\n    const { messageCompiler, warnHtmlMessage } = context;\n    if (isMessageFunction(format)) {\n        const msg = format;\n        msg.locale = msg.locale || targetLocale;\n        msg.key = msg.key || key;\n        return msg;\n    }\n    if (messageCompiler == null) {\n        const msg = (() => format);\n        msg.locale = targetLocale;\n        msg.key = key;\n        return msg;\n    }\n    // for vue-devtools timeline event\n    let start = null;\n    let startTag;\n    let endTag;\n    if ((process.env.NODE_ENV !== 'production') && inBrowser) {\n        start = window.performance.now();\n        startTag = 'intlify-message-compilation-start';\n        endTag = 'intlify-message-compilation-end';\n        mark && mark(startTag);\n    }\n    const msg = messageCompiler(format, getCompileContext(context, targetLocale, cacheBaseKey, format, warnHtmlMessage, onError));\n    // for vue-devtools timeline event\n    if ((process.env.NODE_ENV !== 'production') && inBrowser) {\n        const end = window.performance.now();\n        const emitter = context.__v_emitter;\n        if (emitter && start) {\n            emitter.emit(\"message-compilation\" /* VueDevToolsTimelineEvents.MESSAGE_COMPILATION */, {\n                type: \"message-compilation\" /* VueDevToolsTimelineEvents.MESSAGE_COMPILATION */,\n                message: format,\n                time: end - start,\n                groupId: `${'translate'}:${key}`\n            });\n        }\n        if (startTag && endTag && mark && measure) {\n            mark(endTag);\n            measure('intlify message compilation', startTag, endTag);\n        }\n    }\n    msg.locale = targetLocale;\n    msg.key = key;\n    msg.source = format;\n    return msg;\n}\nfunction evaluateMessage(context, msg, msgCtx) {\n    // for vue-devtools timeline event\n    let start = null;\n    let startTag;\n    let endTag;\n    if ((process.env.NODE_ENV !== 'production') && inBrowser) {\n        start = window.performance.now();\n        startTag = 'intlify-message-evaluation-start';\n        endTag = 'intlify-message-evaluation-end';\n        mark && mark(startTag);\n    }\n    const messaged = msg(msgCtx);\n    // for vue-devtools timeline event\n    if ((process.env.NODE_ENV !== 'production') && inBrowser) {\n        const end = window.performance.now();\n        const emitter = context.__v_emitter;\n        if (emitter && start) {\n            emitter.emit(\"message-evaluation\" /* VueDevToolsTimelineEvents.MESSAGE_EVALUATION */, {\n                type: \"message-evaluation\" /* VueDevToolsTimelineEvents.MESSAGE_EVALUATION */,\n                value: messaged,\n                time: end - start,\n                groupId: `${'translate'}:${msg.key}`\n            });\n        }\n        if (startTag && endTag && mark && measure) {\n            mark(endTag);\n            measure('intlify message evaluation', startTag, endTag);\n        }\n    }\n    return messaged;\n}\n/** @internal */\nfunction parseTranslateArgs(...args) {\n    const [arg1, arg2, arg3] = args;\n    const options = {};\n    if (!isString(arg1) &&\n        !isNumber(arg1) &&\n        !isMessageFunction(arg1) &&\n        !isMessageAST(arg1)) {\n        throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);\n    }\n    // prettier-ignore\n    const key = isNumber(arg1)\n        ? String(arg1)\n        : isMessageFunction(arg1)\n            ? arg1\n            : arg1;\n    if (isNumber(arg2)) {\n        options.plural = arg2;\n    }\n    else if (isString(arg2)) {\n        options.default = arg2;\n    }\n    else if (isPlainObject(arg2) && !isEmptyObject(arg2)) {\n        options.named = arg2;\n    }\n    else if (isArray(arg2)) {\n        options.list = arg2;\n    }\n    if (isNumber(arg3)) {\n        options.plural = arg3;\n    }\n    else if (isString(arg3)) {\n        options.default = arg3;\n    }\n    else if (isPlainObject(arg3)) {\n        assign(options, arg3);\n    }\n    return [key, options];\n}\nfunction getCompileContext(context, locale, key, source, warnHtmlMessage, onError) {\n    return {\n        locale,\n        key,\n        warnHtmlMessage,\n        onError: (err) => {\n            onError && onError(err);\n            if ((process.env.NODE_ENV !== 'production')) {\n                const _source = getSourceForCodeFrame(source);\n                const message = `Message compilation error: ${err.message}`;\n                const codeFrame = err.location &&\n                    _source &&\n                    generateCodeFrame(_source, err.location.start.offset, err.location.end.offset);\n                const emitter = context.__v_emitter;\n                if (emitter && _source) {\n                    emitter.emit(\"compile-error\" /* VueDevToolsTimelineEvents.COMPILE_ERROR */, {\n                        message: _source,\n                        error: err.message,\n                        start: err.location && err.location.start.offset,\n                        end: err.location && err.location.end.offset,\n                        groupId: `${'translate'}:${key}`\n                    });\n                }\n                console.error(codeFrame ? `${message}\\n${codeFrame}` : message);\n            }\n            else {\n                throw err;\n            }\n        },\n        onCacheKey: (source) => generateFormatCacheKey(locale, key, source)\n    };\n}\nfunction getSourceForCodeFrame(source) {\n    if (isString(source)) ;\n    else {\n        if (source.loc?.source) {\n            return source.loc.source;\n        }\n    }\n}\nfunction getMessageContextOptions(context, locale, message, options) {\n    const { modifiers, pluralRules, messageResolver: resolveValue, fallbackLocale, fallbackWarn, missingWarn, fallbackContext } = context;\n    const resolveMessage = (key) => {\n        let val = resolveValue(message, key);\n        // fallback to root context\n        if (val == null && fallbackContext) {\n            const [, , message] = resolveMessageFormat(fallbackContext, key, locale, fallbackLocale, fallbackWarn, missingWarn);\n            val = resolveValue(message, key);\n        }\n        if (isString(val) || isMessageAST(val)) {\n            let occurred = false;\n            const onError = () => {\n                occurred = true;\n            };\n            const msg = compileMessageFormat(context, key, locale, val, key, onError);\n            return !occurred\n                ? msg\n                : NOOP_MESSAGE_FUNCTION;\n        }\n        else if (isMessageFunction(val)) {\n            return val;\n        }\n        else {\n            // TODO: should be implemented warning message\n            return NOOP_MESSAGE_FUNCTION;\n        }\n    };\n    const ctxOptions = {\n        locale,\n        modifiers,\n        pluralRules,\n        messages: resolveMessage\n    };\n    if (context.processor) {\n        ctxOptions.processor = context.processor;\n    }\n    if (options.list) {\n        ctxOptions.list = options.list;\n    }\n    if (options.named) {\n        ctxOptions.named = options.named;\n    }\n    if (isNumber(options.plural)) {\n        ctxOptions.pluralIndex = options.plural;\n    }\n    return ctxOptions;\n}\n\nconst intlDefined = typeof Intl !== 'undefined';\nconst Availabilities = {\n    dateTimeFormat: intlDefined && typeof Intl.DateTimeFormat !== 'undefined',\n    numberFormat: intlDefined && typeof Intl.NumberFormat !== 'undefined'\n};\n\n// implementation of `datetime` function\nfunction datetime(context, ...args) {\n    const { datetimeFormats, unresolving, fallbackLocale, onWarn, localeFallbacker } = context;\n    const { __datetimeFormatters } = context;\n    if ((process.env.NODE_ENV !== 'production') && !Availabilities.dateTimeFormat) {\n        onWarn(getWarnMessage(CoreWarnCodes.CANNOT_FORMAT_DATE));\n        return MISSING_RESOLVE_VALUE;\n    }\n    const [key, value, options, overrides] = parseDateTimeArgs(...args);\n    const missingWarn = isBoolean(options.missingWarn)\n        ? options.missingWarn\n        : context.missingWarn;\n    const fallbackWarn = isBoolean(options.fallbackWarn)\n        ? options.fallbackWarn\n        : context.fallbackWarn;\n    const part = !!options.part;\n    const locale = getLocale(context, options);\n    const locales = localeFallbacker(context, // eslint-disable-line @typescript-eslint/no-explicit-any\n    fallbackLocale, locale);\n    if (!isString(key) || key === '') {\n        return new Intl.DateTimeFormat(locale, overrides).format(value);\n    }\n    // resolve format\n    let datetimeFormat = {};\n    let targetLocale;\n    let format = null;\n    let from = locale;\n    let to = null;\n    const type = 'datetime format';\n    for (let i = 0; i < locales.length; i++) {\n        targetLocale = to = locales[i];\n        if ((process.env.NODE_ENV !== 'production') &&\n            locale !== targetLocale &&\n            isTranslateFallbackWarn(fallbackWarn, key)) {\n            onWarn(getWarnMessage(CoreWarnCodes.FALLBACK_TO_DATE_FORMAT, {\n                key,\n                target: targetLocale\n            }));\n        }\n        // for vue-devtools timeline event\n        if ((process.env.NODE_ENV !== 'production') && locale !== targetLocale) {\n            const emitter = context.__v_emitter;\n            if (emitter) {\n                emitter.emit(\"fallback\" /* VueDevToolsTimelineEvents.FALBACK */, {\n                    type,\n                    key,\n                    from,\n                    to,\n                    groupId: `${type}:${key}`\n                });\n            }\n        }\n        datetimeFormat =\n            datetimeFormats[targetLocale] || {};\n        format = datetimeFormat[key];\n        if (isPlainObject(format))\n            break;\n        handleMissing(context, key, targetLocale, missingWarn, type); // eslint-disable-line @typescript-eslint/no-explicit-any\n        from = to;\n    }\n    // checking format and target locale\n    if (!isPlainObject(format) || !isString(targetLocale)) {\n        return unresolving ? NOT_REOSLVED : key;\n    }\n    let id = `${targetLocale}__${key}`;\n    if (!isEmptyObject(overrides)) {\n        id = `${id}__${JSON.stringify(overrides)}`;\n    }\n    let formatter = __datetimeFormatters.get(id);\n    if (!formatter) {\n        formatter = new Intl.DateTimeFormat(targetLocale, assign({}, format, overrides));\n        __datetimeFormatters.set(id, formatter);\n    }\n    return !part ? formatter.format(value) : formatter.formatToParts(value);\n}\n/** @internal */\nconst DATETIME_FORMAT_OPTIONS_KEYS = [\n    'localeMatcher',\n    'weekday',\n    'era',\n    'year',\n    'month',\n    'day',\n    'hour',\n    'minute',\n    'second',\n    'timeZoneName',\n    'formatMatcher',\n    'hour12',\n    'timeZone',\n    'dateStyle',\n    'timeStyle',\n    'calendar',\n    'dayPeriod',\n    'numberingSystem',\n    'hourCycle',\n    'fractionalSecondDigits'\n];\n/** @internal */\nfunction parseDateTimeArgs(...args) {\n    const [arg1, arg2, arg3, arg4] = args;\n    const options = {};\n    let overrides = {};\n    let value;\n    if (isString(arg1)) {\n        // Only allow ISO strings - other date formats are often supported,\n        // but may cause different results in different browsers.\n        const matches = arg1.match(/(\\d{4}-\\d{2}-\\d{2})(T|\\s)?(.*)/);\n        if (!matches) {\n            throw createCoreError(CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT);\n        }\n        // Some browsers can not parse the iso datetime separated by space,\n        // this is a compromise solution by replace the 'T'/' ' with 'T'\n        const dateTime = matches[3]\n            ? matches[3].trim().startsWith('T')\n                ? `${matches[1].trim()}${matches[3].trim()}`\n                : `${matches[1].trim()}T${matches[3].trim()}`\n            : matches[1].trim();\n        value = new Date(dateTime);\n        try {\n            // This will fail if the date is not valid\n            value.toISOString();\n        }\n        catch (e) {\n            throw createCoreError(CoreErrorCodes.INVALID_ISO_DATE_ARGUMENT);\n        }\n    }\n    else if (isDate(arg1)) {\n        if (isNaN(arg1.getTime())) {\n            throw createCoreError(CoreErrorCodes.INVALID_DATE_ARGUMENT);\n        }\n        value = arg1;\n    }\n    else if (isNumber(arg1)) {\n        value = arg1;\n    }\n    else {\n        throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);\n    }\n    if (isString(arg2)) {\n        options.key = arg2;\n    }\n    else if (isPlainObject(arg2)) {\n        Object.keys(arg2).forEach(key => {\n            if (DATETIME_FORMAT_OPTIONS_KEYS.includes(key)) {\n                overrides[key] = arg2[key];\n            }\n            else {\n                options[key] = arg2[key];\n            }\n        });\n    }\n    if (isString(arg3)) {\n        options.locale = arg3;\n    }\n    else if (isPlainObject(arg3)) {\n        overrides = arg3;\n    }\n    if (isPlainObject(arg4)) {\n        overrides = arg4;\n    }\n    return [options.key || '', value, options, overrides];\n}\n/** @internal */\nfunction clearDateTimeFormat(ctx, locale, format) {\n    const context = ctx;\n    for (const key in format) {\n        const id = `${locale}__${key}`;\n        if (!context.__datetimeFormatters.has(id)) {\n            continue;\n        }\n        context.__datetimeFormatters.delete(id);\n    }\n}\n\n// implementation of `number` function\nfunction number(context, ...args) {\n    const { numberFormats, unresolving, fallbackLocale, onWarn, localeFallbacker } = context;\n    const { __numberFormatters } = context;\n    if ((process.env.NODE_ENV !== 'production') && !Availabilities.numberFormat) {\n        onWarn(getWarnMessage(CoreWarnCodes.CANNOT_FORMAT_NUMBER));\n        return MISSING_RESOLVE_VALUE;\n    }\n    const [key, value, options, overrides] = parseNumberArgs(...args);\n    const missingWarn = isBoolean(options.missingWarn)\n        ? options.missingWarn\n        : context.missingWarn;\n    const fallbackWarn = isBoolean(options.fallbackWarn)\n        ? options.fallbackWarn\n        : context.fallbackWarn;\n    const part = !!options.part;\n    const locale = getLocale(context, options);\n    const locales = localeFallbacker(context, // eslint-disable-line @typescript-eslint/no-explicit-any\n    fallbackLocale, locale);\n    if (!isString(key) || key === '') {\n        return new Intl.NumberFormat(locale, overrides).format(value);\n    }\n    // resolve format\n    let numberFormat = {};\n    let targetLocale;\n    let format = null;\n    let from = locale;\n    let to = null;\n    const type = 'number format';\n    for (let i = 0; i < locales.length; i++) {\n        targetLocale = to = locales[i];\n        if ((process.env.NODE_ENV !== 'production') &&\n            locale !== targetLocale &&\n            isTranslateFallbackWarn(fallbackWarn, key)) {\n            onWarn(getWarnMessage(CoreWarnCodes.FALLBACK_TO_NUMBER_FORMAT, {\n                key,\n                target: targetLocale\n            }));\n        }\n        // for vue-devtools timeline event\n        if ((process.env.NODE_ENV !== 'production') && locale !== targetLocale) {\n            const emitter = context.__v_emitter;\n            if (emitter) {\n                emitter.emit(\"fallback\" /* VueDevToolsTimelineEvents.FALBACK */, {\n                    type,\n                    key,\n                    from,\n                    to,\n                    groupId: `${type}:${key}`\n                });\n            }\n        }\n        numberFormat =\n            numberFormats[targetLocale] || {};\n        format = numberFormat[key];\n        if (isPlainObject(format))\n            break;\n        handleMissing(context, key, targetLocale, missingWarn, type); // eslint-disable-line @typescript-eslint/no-explicit-any\n        from = to;\n    }\n    // checking format and target locale\n    if (!isPlainObject(format) || !isString(targetLocale)) {\n        return unresolving ? NOT_REOSLVED : key;\n    }\n    let id = `${targetLocale}__${key}`;\n    if (!isEmptyObject(overrides)) {\n        id = `${id}__${JSON.stringify(overrides)}`;\n    }\n    let formatter = __numberFormatters.get(id);\n    if (!formatter) {\n        formatter = new Intl.NumberFormat(targetLocale, assign({}, format, overrides));\n        __numberFormatters.set(id, formatter);\n    }\n    return !part ? formatter.format(value) : formatter.formatToParts(value);\n}\n/** @internal */\nconst NUMBER_FORMAT_OPTIONS_KEYS = [\n    'localeMatcher',\n    'style',\n    'currency',\n    'currencyDisplay',\n    'currencySign',\n    'useGrouping',\n    'minimumIntegerDigits',\n    'minimumFractionDigits',\n    'maximumFractionDigits',\n    'minimumSignificantDigits',\n    'maximumSignificantDigits',\n    'compactDisplay',\n    'notation',\n    'signDisplay',\n    'unit',\n    'unitDisplay',\n    'roundingMode',\n    'roundingPriority',\n    'roundingIncrement',\n    'trailingZeroDisplay'\n];\n/** @internal */\nfunction parseNumberArgs(...args) {\n    const [arg1, arg2, arg3, arg4] = args;\n    const options = {};\n    let overrides = {};\n    if (!isNumber(arg1)) {\n        throw createCoreError(CoreErrorCodes.INVALID_ARGUMENT);\n    }\n    const value = arg1;\n    if (isString(arg2)) {\n        options.key = arg2;\n    }\n    else if (isPlainObject(arg2)) {\n        Object.keys(arg2).forEach(key => {\n            if (NUMBER_FORMAT_OPTIONS_KEYS.includes(key)) {\n                overrides[key] = arg2[key];\n            }\n            else {\n                options[key] = arg2[key];\n            }\n        });\n    }\n    if (isString(arg3)) {\n        options.locale = arg3;\n    }\n    else if (isPlainObject(arg3)) {\n        overrides = arg3;\n    }\n    if (isPlainObject(arg4)) {\n        overrides = arg4;\n    }\n    return [options.key || '', value, options, overrides];\n}\n/** @internal */\nfunction clearNumberFormat(ctx, locale, format) {\n    const context = ctx;\n    for (const key in format) {\n        const id = `${locale}__${key}`;\n        if (!context.__numberFormatters.has(id)) {\n            continue;\n        }\n        context.__numberFormatters.delete(id);\n    }\n}\n\n{\n    initFeatureFlags();\n}\n\nexport { CoreErrorCodes, CoreWarnCodes, DATETIME_FORMAT_OPTIONS_KEYS, DEFAULT_LOCALE, DEFAULT_MESSAGE_DATA_TYPE, MISSING_RESOLVE_VALUE, NOT_REOSLVED, NUMBER_FORMAT_OPTIONS_KEYS, VERSION, clearCompileCache, clearDateTimeFormat, clearNumberFormat, compile, compileToFunction, createCoreContext, createCoreError, createMessageContext, datetime, fallbackWithLocaleChain, fallbackWithSimple, getAdditionalMeta, getDevToolsHook, getFallbackContext, getLocale, getWarnMessage, handleMissing, initI18nDevTools, isMessageAST, isMessageFunction, isTranslateFallbackWarn, isTranslateMissingWarn, number, parse, parseDateTimeArgs, parseNumberArgs, parseTranslateArgs, registerLocaleFallbacker, registerMessageCompiler, registerMessageResolver, resolveLocale, resolveValue, resolveWithKeyValue, setAdditionalMeta, setDevToolsHook, setFallbackContext, translate, translateDevTools, updateFallbackLocale };\n","/*!\n  * vue-i18n v9.5.0\n  * (c) 2023 kazuya kawaguchi\n  * Released under the MIT License.\n  */\nimport { getGlobalThis, incrementer, format, makeSymbol, isPlainObject, isArray, isString, hasOwn, isObject, warn, isBoolean, isRegExp, isFunction, inBrowser, assign, isNumber, createEmitter, isEmptyObject } from '@intlify/shared';\nimport { CoreWarnCodes, CoreErrorCodes, createCompileError, DEFAULT_LOCALE, updateFallbackLocale, setFallbackContext, createCoreContext, clearDateTimeFormat, clearNumberFormat, setAdditionalMeta, getFallbackContext, NOT_REOSLVED, isTranslateFallbackWarn, isTranslateMissingWarn, parseTranslateArgs, translate, MISSING_RESOLVE_VALUE, parseDateTimeArgs, datetime, parseNumberArgs, number, fallbackWithLocaleChain, NUMBER_FORMAT_OPTIONS_KEYS, DATETIME_FORMAT_OPTIONS_KEYS, isMessageAST, registerMessageCompiler, compile, compileToFunction, registerMessageResolver, resolveValue, registerLocaleFallbacker, setDevToolsHook } from '@intlify/core-base';\nimport { createVNode, Text, ref, computed, watch, getCurrentInstance, Fragment, defineComponent, h, effectScope, inject, onMounted, onUnmounted, shallowRef, onBeforeMount, isRef } from 'vue';\nimport { setupDevtoolsPlugin } from '@vue/devtools-api';\n\n/**\n * Vue I18n Version\n *\n * @remarks\n * Semver format. Same format as the package.json `version` field.\n *\n * @VueI18nGeneral\n */\nconst VERSION = '9.5.0';\n/**\n * This is only called in esm-bundler builds.\n * istanbul-ignore-next\n */\nfunction initFeatureFlags() {\n    if (typeof __VUE_I18N_FULL_INSTALL__ !== 'boolean') {\n        getGlobalThis().__VUE_I18N_FULL_INSTALL__ = true;\n    }\n    if (typeof __VUE_I18N_LEGACY_API__ !== 'boolean') {\n        getGlobalThis().__VUE_I18N_LEGACY_API__ = true;\n    }\n    if (typeof __INTLIFY_JIT_COMPILATION__ !== 'boolean') {\n        getGlobalThis().__INTLIFY_JIT_COMPILATION__ = false;\n    }\n    if (typeof __INTLIFY_DROP_MESSAGE_COMPILER__ !== 'boolean') {\n        getGlobalThis().__INTLIFY_DROP_MESSAGE_COMPILER__ = false;\n    }\n    if (typeof __INTLIFY_PROD_DEVTOOLS__ !== 'boolean') {\n        getGlobalThis().__INTLIFY_PROD_DEVTOOLS__ = false;\n    }\n}\n\nconst code$1 = CoreWarnCodes.__EXTEND_POINT__;\nconst inc$1 = incrementer(code$1);\nconst I18nWarnCodes = {\n    FALLBACK_TO_ROOT: code$1,\n    NOT_SUPPORTED_PRESERVE: inc$1(),\n    NOT_SUPPORTED_FORMATTER: inc$1(),\n    NOT_SUPPORTED_PRESERVE_DIRECTIVE: inc$1(),\n    NOT_SUPPORTED_GET_CHOICE_INDEX: inc$1(),\n    COMPONENT_NAME_LEGACY_COMPATIBLE: inc$1(),\n    NOT_FOUND_PARENT_SCOPE: inc$1(),\n    IGNORE_OBJ_FLATTEN: inc$1(),\n    NOTICE_DROP_ALLOW_COMPOSITION: inc$1() // 17\n};\nconst warnMessages = {\n    [I18nWarnCodes.FALLBACK_TO_ROOT]: `Fall back to {type} '{key}' with root locale.`,\n    [I18nWarnCodes.NOT_SUPPORTED_PRESERVE]: `Not supported 'preserve'.`,\n    [I18nWarnCodes.NOT_SUPPORTED_FORMATTER]: `Not supported 'formatter'.`,\n    [I18nWarnCodes.NOT_SUPPORTED_PRESERVE_DIRECTIVE]: `Not supported 'preserveDirectiveContent'.`,\n    [I18nWarnCodes.NOT_SUPPORTED_GET_CHOICE_INDEX]: `Not supported 'getChoiceIndex'.`,\n    [I18nWarnCodes.COMPONENT_NAME_LEGACY_COMPATIBLE]: `Component name legacy compatible: '{name}' -> 'i18n'`,\n    [I18nWarnCodes.NOT_FOUND_PARENT_SCOPE]: `Not found parent scope. use the global scope.`,\n    [I18nWarnCodes.IGNORE_OBJ_FLATTEN]: `Ignore object flatten: '{key}' key has an string value`,\n    [I18nWarnCodes.NOTICE_DROP_ALLOW_COMPOSITION]: `'allowComposition' option will be dropped in the next major version. For more information, please see 👉 https://tinyurl.com/2p97mcze`\n};\nfunction getWarnMessage(code, ...args) {\n    return format(warnMessages[code], ...args);\n}\n\nconst code = CoreErrorCodes.__EXTEND_POINT__;\nconst inc = incrementer(code);\nconst I18nErrorCodes = {\n    // composer module errors\n    UNEXPECTED_RETURN_TYPE: code,\n    // legacy module errors\n    INVALID_ARGUMENT: inc(),\n    // i18n module errors\n    MUST_BE_CALL_SETUP_TOP: inc(),\n    NOT_INSTALLED: inc(),\n    NOT_AVAILABLE_IN_LEGACY_MODE: inc(),\n    // directive module errors\n    REQUIRED_VALUE: inc(),\n    INVALID_VALUE: inc(),\n    // vue-devtools errors\n    CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN: inc(),\n    NOT_INSTALLED_WITH_PROVIDE: inc(),\n    // unexpected error\n    UNEXPECTED_ERROR: inc(),\n    // not compatible legacy vue-i18n constructor\n    NOT_COMPATIBLE_LEGACY_VUE_I18N: inc(),\n    // bridge support vue 2.x only\n    BRIDGE_SUPPORT_VUE_2_ONLY: inc(),\n    // need to define `i18n` option in `allowComposition: true` and `useScope: 'local' at `useI18n``\n    MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION: inc(),\n    // Not available Compostion API in Legacy API mode. Please make sure that the legacy API mode is working properly\n    NOT_AVAILABLE_COMPOSITION_IN_LEGACY: inc(),\n    // for enhancement\n    __EXTEND_POINT__: inc() // 37\n};\nfunction createI18nError(code, ...args) {\n    return createCompileError(code, null, (process.env.NODE_ENV !== 'production') ? { messages: errorMessages, args } : undefined);\n}\nconst errorMessages = {\n    [I18nErrorCodes.UNEXPECTED_RETURN_TYPE]: 'Unexpected return type in composer',\n    [I18nErrorCodes.INVALID_ARGUMENT]: 'Invalid argument',\n    [I18nErrorCodes.MUST_BE_CALL_SETUP_TOP]: 'Must be called at the top of a `setup` function',\n    [I18nErrorCodes.NOT_INSTALLED]: 'Need to install with `app.use` function',\n    [I18nErrorCodes.UNEXPECTED_ERROR]: 'Unexpected error',\n    [I18nErrorCodes.NOT_AVAILABLE_IN_LEGACY_MODE]: 'Not available in legacy mode',\n    [I18nErrorCodes.REQUIRED_VALUE]: `Required in value: {0}`,\n    [I18nErrorCodes.INVALID_VALUE]: `Invalid value`,\n    [I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN]: `Cannot setup vue-devtools plugin`,\n    [I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE]: 'Need to install with `provide` function',\n    [I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N]: 'Not compatible legacy VueI18n.',\n    [I18nErrorCodes.BRIDGE_SUPPORT_VUE_2_ONLY]: 'vue-i18n-bridge support Vue 2.x only',\n    [I18nErrorCodes.MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION]: 'Must define ‘i18n’ option or custom block in Composition API with using local scope in Legacy API mode',\n    [I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY]: 'Not available Compostion API in Legacy API mode. Please make sure that the legacy API mode is working properly'\n};\n\nconst TranslateVNodeSymbol = \n/* #__PURE__*/ makeSymbol('__translateVNode');\nconst DatetimePartsSymbol = /* #__PURE__*/ makeSymbol('__datetimeParts');\nconst NumberPartsSymbol = /* #__PURE__*/ makeSymbol('__numberParts');\nconst EnableEmitter = /* #__PURE__*/ makeSymbol('__enableEmitter');\nconst DisableEmitter = /* #__PURE__*/ makeSymbol('__disableEmitter');\nconst SetPluralRulesSymbol = makeSymbol('__setPluralRules');\nmakeSymbol('__intlifyMeta');\nconst InejctWithOptionSymbol = \n/* #__PURE__*/ makeSymbol('__injectWithOption');\nconst DisposeSymbol = /* #__PURE__*/ makeSymbol('__dispose');\nconst __VUE_I18N_BRIDGE__ =  '__VUE_I18N_BRIDGE__';\n\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/**\n * Transform flat json in obj to normal json in obj\n */\nfunction handleFlatJson(obj) {\n    // check obj\n    if (!isObject(obj)) {\n        return obj;\n    }\n    for (const key in obj) {\n        // check key\n        if (!hasOwn(obj, key)) {\n            continue;\n        }\n        // handle for normal json\n        if (!key.includes('.')) {\n            // recursive process value if value is also a object\n            if (isObject(obj[key])) {\n                handleFlatJson(obj[key]);\n            }\n        }\n        // handle for flat json, transform to normal json\n        else {\n            // go to the last object\n            const subKeys = key.split('.');\n            const lastIndex = subKeys.length - 1;\n            let currentObj = obj;\n            let hasStringValue = false;\n            for (let i = 0; i < lastIndex; i++) {\n                if (!(subKeys[i] in currentObj)) {\n                    currentObj[subKeys[i]] = {};\n                }\n                if (!isObject(currentObj[subKeys[i]])) {\n                    (process.env.NODE_ENV !== 'production') &&\n                        warn(getWarnMessage(I18nWarnCodes.IGNORE_OBJ_FLATTEN, {\n                            key: subKeys[i]\n                        }));\n                    hasStringValue = true;\n                    break;\n                }\n                currentObj = currentObj[subKeys[i]];\n            }\n            // update last object value, delete old property\n            if (!hasStringValue) {\n                currentObj[subKeys[lastIndex]] = obj[key];\n                delete obj[key];\n            }\n            // recursive process value if value is also a object\n            if (isObject(currentObj[subKeys[lastIndex]])) {\n                handleFlatJson(currentObj[subKeys[lastIndex]]);\n            }\n        }\n    }\n    return obj;\n}\nfunction getLocaleMessages(locale, options) {\n    const { messages, __i18n, messageResolver, flatJson } = options;\n    // prettier-ignore\n    const ret = (isPlainObject(messages)\n        ? messages\n        : isArray(__i18n)\n            ? {}\n            : { [locale]: {} });\n    // merge locale messages of i18n custom block\n    if (isArray(__i18n)) {\n        __i18n.forEach(custom => {\n            if ('locale' in custom && 'resource' in custom) {\n                const { locale, resource } = custom;\n                if (locale) {\n                    ret[locale] = ret[locale] || {};\n                    deepCopy(resource, ret[locale]);\n                }\n                else {\n                    deepCopy(resource, ret);\n                }\n            }\n            else {\n                isString(custom) && deepCopy(JSON.parse(custom), ret);\n            }\n        });\n    }\n    // handle messages for flat json\n    if (messageResolver == null && flatJson) {\n        for (const key in ret) {\n            if (hasOwn(ret, key)) {\n                handleFlatJson(ret[key]);\n            }\n        }\n    }\n    return ret;\n}\nconst isNotObjectOrIsArray = (val) => !isObject(val) || isArray(val);\n// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/explicit-module-boundary-types\nfunction deepCopy(src, des) {\n    // src and des should both be objects, and non of then can be a array\n    if (isNotObjectOrIsArray(src) || isNotObjectOrIsArray(des)) {\n        throw createI18nError(I18nErrorCodes.INVALID_VALUE);\n    }\n    for (const key in src) {\n        if (hasOwn(src, key)) {\n            if (isNotObjectOrIsArray(src[key]) || isNotObjectOrIsArray(des[key])) {\n                // replace with src[key] when:\n                // src[key] or des[key] is not a object, or\n                // src[key] or des[key] is a array\n                des[key] = src[key];\n            }\n            else {\n                // src[key] and des[key] are both object, merge them\n                deepCopy(src[key], des[key]);\n            }\n        }\n    }\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getComponentOptions(instance) {\n    return instance.type ;\n}\nfunction adjustI18nResources(gl, options, componentOptions // eslint-disable-line @typescript-eslint/no-explicit-any\n) {\n    let messages = isObject(options.messages) ? options.messages : {};\n    if ('__i18nGlobal' in componentOptions) {\n        messages = getLocaleMessages(gl.locale.value, {\n            messages,\n            __i18n: componentOptions.__i18nGlobal\n        });\n    }\n    // merge locale messages\n    const locales = Object.keys(messages);\n    if (locales.length) {\n        locales.forEach(locale => {\n            gl.mergeLocaleMessage(locale, messages[locale]);\n        });\n    }\n    {\n        // merge datetime formats\n        if (isObject(options.datetimeFormats)) {\n            const locales = Object.keys(options.datetimeFormats);\n            if (locales.length) {\n                locales.forEach(locale => {\n                    gl.mergeDateTimeFormat(locale, options.datetimeFormats[locale]);\n                });\n            }\n        }\n        // merge number formats\n        if (isObject(options.numberFormats)) {\n            const locales = Object.keys(options.numberFormats);\n            if (locales.length) {\n                locales.forEach(locale => {\n                    gl.mergeNumberFormat(locale, options.numberFormats[locale]);\n                });\n            }\n        }\n    }\n}\nfunction createTextNode(key) {\n    return createVNode(Text, null, key, 0)\n        ;\n}\n/* eslint-enable @typescript-eslint/no-explicit-any */\n\n/* eslint-disable @typescript-eslint/no-explicit-any */\n// extend VNode interface\nconst DEVTOOLS_META = '__INTLIFY_META__';\nlet composerID = 0;\nfunction defineCoreMissingHandler(missing) {\n    return ((ctx, locale, key, type) => {\n        return missing(locale, key, getCurrentInstance() || undefined, type);\n    });\n}\n// for Intlify DevTools\nconst getMetaInfo = /* #__PURE__*/ () => {\n    const instance = getCurrentInstance();\n    let meta = null; // eslint-disable-line @typescript-eslint/no-explicit-any\n    return instance && (meta = getComponentOptions(instance)[DEVTOOLS_META])\n        ? { [DEVTOOLS_META]: meta } // eslint-disable-line @typescript-eslint/no-explicit-any\n        : null;\n};\n/**\n * Create composer interface factory\n *\n * @internal\n */\n// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\nfunction createComposer(options = {}, VueI18nLegacy) {\n    const { __root, __injectWithOption } = options;\n    const _isGlobal = __root === undefined;\n    let _inheritLocale = isBoolean(options.inheritLocale)\n        ? options.inheritLocale\n        : true;\n    const _locale = ref(\n    // prettier-ignore\n    __root && _inheritLocale\n        ? __root.locale.value\n        : isString(options.locale)\n            ? options.locale\n            : DEFAULT_LOCALE);\n    const _fallbackLocale = ref(\n    // prettier-ignore\n    __root && _inheritLocale\n        ? __root.fallbackLocale.value\n        : isString(options.fallbackLocale) ||\n            isArray(options.fallbackLocale) ||\n            isPlainObject(options.fallbackLocale) ||\n            options.fallbackLocale === false\n            ? options.fallbackLocale\n            : _locale.value);\n    const _messages = ref(getLocaleMessages(_locale.value, options));\n    // prettier-ignore\n    const _datetimeFormats = ref(isPlainObject(options.datetimeFormats)\n            ? options.datetimeFormats\n            : { [_locale.value]: {} })\n        ;\n    // prettier-ignore\n    const _numberFormats = ref(isPlainObject(options.numberFormats)\n            ? options.numberFormats\n            : { [_locale.value]: {} })\n        ;\n    // warning suppress options\n    // prettier-ignore\n    let _missingWarn = __root\n        ? __root.missingWarn\n        : isBoolean(options.missingWarn) || isRegExp(options.missingWarn)\n            ? options.missingWarn\n            : true;\n    // prettier-ignore\n    let _fallbackWarn = __root\n        ? __root.fallbackWarn\n        : isBoolean(options.fallbackWarn) || isRegExp(options.fallbackWarn)\n            ? options.fallbackWarn\n            : true;\n    // prettier-ignore\n    let _fallbackRoot = __root\n        ? __root.fallbackRoot\n        : isBoolean(options.fallbackRoot)\n            ? options.fallbackRoot\n            : true;\n    // configure fall back to root\n    let _fallbackFormat = !!options.fallbackFormat;\n    // runtime missing\n    let _missing = isFunction(options.missing) ? options.missing : null;\n    let _runtimeMissing = isFunction(options.missing)\n        ? defineCoreMissingHandler(options.missing)\n        : null;\n    // postTranslation handler\n    let _postTranslation = isFunction(options.postTranslation)\n        ? options.postTranslation\n        : null;\n    // prettier-ignore\n    let _warnHtmlMessage = __root\n        ? __root.warnHtmlMessage\n        : isBoolean(options.warnHtmlMessage)\n            ? options.warnHtmlMessage\n            : true;\n    let _escapeParameter = !!options.escapeParameter;\n    // custom linked modifiers\n    // prettier-ignore\n    const _modifiers = __root\n        ? __root.modifiers\n        : isPlainObject(options.modifiers)\n            ? options.modifiers\n            : {};\n    // pluralRules\n    let _pluralRules = options.pluralRules || (__root && __root.pluralRules);\n    // runtime context\n    // eslint-disable-next-line prefer-const\n    let _context;\n    const getCoreContext = () => {\n        _isGlobal && setFallbackContext(null);\n        const ctxOptions = {\n            version: VERSION,\n            locale: _locale.value,\n            fallbackLocale: _fallbackLocale.value,\n            messages: _messages.value,\n            modifiers: _modifiers,\n            pluralRules: _pluralRules,\n            missing: _runtimeMissing === null ? undefined : _runtimeMissing,\n            missingWarn: _missingWarn,\n            fallbackWarn: _fallbackWarn,\n            fallbackFormat: _fallbackFormat,\n            unresolving: true,\n            postTranslation: _postTranslation === null ? undefined : _postTranslation,\n            warnHtmlMessage: _warnHtmlMessage,\n            escapeParameter: _escapeParameter,\n            messageResolver: options.messageResolver,\n            messageCompiler: options.messageCompiler,\n            __meta: { framework: 'vue' }\n        };\n        {\n            ctxOptions.datetimeFormats = _datetimeFormats.value;\n            ctxOptions.numberFormats = _numberFormats.value;\n            ctxOptions.__datetimeFormatters = isPlainObject(_context)\n                ? _context.__datetimeFormatters\n                : undefined;\n            ctxOptions.__numberFormatters = isPlainObject(_context)\n                ? _context.__numberFormatters\n                : undefined;\n        }\n        if ((process.env.NODE_ENV !== 'production')) {\n            ctxOptions.__v_emitter = isPlainObject(_context)\n                ? _context.__v_emitter\n                : undefined;\n        }\n        const ctx = createCoreContext(ctxOptions);\n        _isGlobal && setFallbackContext(ctx);\n        return ctx;\n    };\n    _context = getCoreContext();\n    updateFallbackLocale(_context, _locale.value, _fallbackLocale.value);\n    // track reactivity\n    function trackReactivityValues() {\n        return [\n                _locale.value,\n                _fallbackLocale.value,\n                _messages.value,\n                _datetimeFormats.value,\n                _numberFormats.value\n            ]\n            ;\n    }\n    // locale\n    const locale = computed({\n        get: () => _locale.value,\n        set: val => {\n            _locale.value = val;\n            _context.locale = _locale.value;\n        }\n    });\n    // fallbackLocale\n    const fallbackLocale = computed({\n        get: () => _fallbackLocale.value,\n        set: val => {\n            _fallbackLocale.value = val;\n            _context.fallbackLocale = _fallbackLocale.value;\n            updateFallbackLocale(_context, _locale.value, val);\n        }\n    });\n    // messages\n    const messages = computed(() => _messages.value);\n    // datetimeFormats\n    const datetimeFormats = /* #__PURE__*/ computed(() => _datetimeFormats.value);\n    // numberFormats\n    const numberFormats = /* #__PURE__*/ computed(() => _numberFormats.value);\n    // getPostTranslationHandler\n    function getPostTranslationHandler() {\n        return isFunction(_postTranslation) ? _postTranslation : null;\n    }\n    // setPostTranslationHandler\n    function setPostTranslationHandler(handler) {\n        _postTranslation = handler;\n        _context.postTranslation = handler;\n    }\n    // getMissingHandler\n    function getMissingHandler() {\n        return _missing;\n    }\n    // setMissingHandler\n    function setMissingHandler(handler) {\n        if (handler !== null) {\n            _runtimeMissing = defineCoreMissingHandler(handler);\n        }\n        _missing = handler;\n        _context.missing = _runtimeMissing;\n    }\n    function isResolvedTranslateMessage(type, arg // eslint-disable-line @typescript-eslint/no-explicit-any\n    ) {\n        return type !== 'translate' || !arg.resolvedMessage;\n    }\n    const wrapWithDeps = (fn, argumentParser, warnType, fallbackSuccess, fallbackFail, successCondition) => {\n        trackReactivityValues(); // track reactive dependency\n        // NOTE: experimental !!\n        let ret;\n        try {\n            if ((process.env.NODE_ENV !== 'production') || __INTLIFY_PROD_DEVTOOLS__) {\n                setAdditionalMeta(getMetaInfo());\n            }\n            if (!_isGlobal) {\n                _context.fallbackContext = __root\n                    ? getFallbackContext()\n                    : undefined;\n            }\n            ret = fn(_context);\n        }\n        finally {\n            if ((process.env.NODE_ENV !== 'production') || __INTLIFY_PROD_DEVTOOLS__) {\n                setAdditionalMeta(null);\n            }\n            if (!_isGlobal) {\n                _context.fallbackContext = undefined;\n            }\n        }\n        if (isNumber(ret) && ret === NOT_REOSLVED) {\n            const [key, arg2] = argumentParser();\n            if ((process.env.NODE_ENV !== 'production') &&\n                __root &&\n                isString(key) &&\n                isResolvedTranslateMessage(warnType, arg2)) {\n                if (_fallbackRoot &&\n                    (isTranslateFallbackWarn(_fallbackWarn, key) ||\n                        isTranslateMissingWarn(_missingWarn, key))) {\n                    warn(getWarnMessage(I18nWarnCodes.FALLBACK_TO_ROOT, {\n                        key,\n                        type: warnType\n                    }));\n                }\n                // for vue-devtools timeline event\n                if ((process.env.NODE_ENV !== 'production')) {\n                    const { __v_emitter: emitter } = _context;\n                    if (emitter && _fallbackRoot) {\n                        emitter.emit(\"fallback\" /* VueDevToolsTimelineEvents.FALBACK */, {\n                            type: warnType,\n                            key,\n                            to: 'global',\n                            groupId: `${warnType}:${key}`\n                        });\n                    }\n                }\n            }\n            return __root && _fallbackRoot\n                ? fallbackSuccess(__root)\n                : fallbackFail(key);\n        }\n        else if (successCondition(ret)) {\n            return ret;\n        }\n        else {\n            /* istanbul ignore next */\n            throw createI18nError(I18nErrorCodes.UNEXPECTED_RETURN_TYPE);\n        }\n    };\n    // t\n    function t(...args) {\n        return wrapWithDeps(context => Reflect.apply(translate, null, [context, ...args]), () => parseTranslateArgs(...args), 'translate', root => Reflect.apply(root.t, root, [...args]), key => key, val => isString(val));\n    }\n    // rt\n    function rt(...args) {\n        const [arg1, arg2, arg3] = args;\n        if (arg3 && !isObject(arg3)) {\n            throw createI18nError(I18nErrorCodes.INVALID_ARGUMENT);\n        }\n        return t(...[arg1, arg2, assign({ resolvedMessage: true }, arg3 || {})]);\n    }\n    // d\n    function d(...args) {\n        return wrapWithDeps(context => Reflect.apply(datetime, null, [context, ...args]), () => parseDateTimeArgs(...args), 'datetime format', root => Reflect.apply(root.d, root, [...args]), () => MISSING_RESOLVE_VALUE, val => isString(val));\n    }\n    // n\n    function n(...args) {\n        return wrapWithDeps(context => Reflect.apply(number, null, [context, ...args]), () => parseNumberArgs(...args), 'number format', root => Reflect.apply(root.n, root, [...args]), () => MISSING_RESOLVE_VALUE, val => isString(val));\n    }\n    // for custom processor\n    function normalize(values) {\n        return values.map(val => isString(val) || isNumber(val) || isBoolean(val)\n            ? createTextNode(String(val))\n            : val);\n    }\n    const interpolate = (val) => val;\n    const processor = {\n        normalize,\n        interpolate,\n        type: 'vnode'\n    };\n    // translateVNode, using for `i18n-t` component\n    function translateVNode(...args) {\n        return wrapWithDeps(context => {\n            let ret;\n            const _context = context;\n            try {\n                _context.processor = processor;\n                ret = Reflect.apply(translate, null, [_context, ...args]);\n            }\n            finally {\n                _context.processor = null;\n            }\n            return ret;\n        }, () => parseTranslateArgs(...args), 'translate', \n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        root => root[TranslateVNodeSymbol](...args), key => [createTextNode(key)], val => isArray(val));\n    }\n    // numberParts, using for `i18n-n` component\n    function numberParts(...args) {\n        return wrapWithDeps(context => Reflect.apply(number, null, [context, ...args]), () => parseNumberArgs(...args), 'number format', \n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        root => root[NumberPartsSymbol](...args), () => [], val => isString(val) || isArray(val));\n    }\n    // datetimeParts, using for `i18n-d` component\n    function datetimeParts(...args) {\n        return wrapWithDeps(context => Reflect.apply(datetime, null, [context, ...args]), () => parseDateTimeArgs(...args), 'datetime format', \n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        root => root[DatetimePartsSymbol](...args), () => [], val => isString(val) || isArray(val));\n    }\n    function setPluralRules(rules) {\n        _pluralRules = rules;\n        _context.pluralRules = _pluralRules;\n    }\n    // te\n    function te(key, locale) {\n        if (!key)\n            return false;\n        const targetLocale = isString(locale) ? locale : _locale.value;\n        const message = getLocaleMessage(targetLocale);\n        return _context.messageResolver(message, key) !== null;\n    }\n    function resolveMessages(key) {\n        let messages = null;\n        const locales = fallbackWithLocaleChain(_context, _fallbackLocale.value, _locale.value);\n        for (let i = 0; i < locales.length; i++) {\n            const targetLocaleMessages = _messages.value[locales[i]] || {};\n            const messageValue = _context.messageResolver(targetLocaleMessages, key);\n            if (messageValue != null) {\n                messages = messageValue;\n                break;\n            }\n        }\n        return messages;\n    }\n    // tm\n    function tm(key) {\n        const messages = resolveMessages(key);\n        // prettier-ignore\n        return messages != null\n            ? messages\n            : __root\n                ? __root.tm(key) || {}\n                : {};\n    }\n    // getLocaleMessage\n    function getLocaleMessage(locale) {\n        return (_messages.value[locale] || {});\n    }\n    // setLocaleMessage\n    function setLocaleMessage(locale, message) {\n        _messages.value[locale] = message;\n        _context.messages = _messages.value;\n    }\n    // mergeLocaleMessage\n    function mergeLocaleMessage(locale, message) {\n        _messages.value[locale] = _messages.value[locale] || {};\n        deepCopy(message, _messages.value[locale]);\n        _context.messages = _messages.value;\n    }\n    // getDateTimeFormat\n    function getDateTimeFormat(locale) {\n        return _datetimeFormats.value[locale] || {};\n    }\n    // setDateTimeFormat\n    function setDateTimeFormat(locale, format) {\n        _datetimeFormats.value[locale] = format;\n        _context.datetimeFormats = _datetimeFormats.value;\n        clearDateTimeFormat(_context, locale, format);\n    }\n    // mergeDateTimeFormat\n    function mergeDateTimeFormat(locale, format) {\n        _datetimeFormats.value[locale] = assign(_datetimeFormats.value[locale] || {}, format);\n        _context.datetimeFormats = _datetimeFormats.value;\n        clearDateTimeFormat(_context, locale, format);\n    }\n    // getNumberFormat\n    function getNumberFormat(locale) {\n        return _numberFormats.value[locale] || {};\n    }\n    // setNumberFormat\n    function setNumberFormat(locale, format) {\n        _numberFormats.value[locale] = format;\n        _context.numberFormats = _numberFormats.value;\n        clearNumberFormat(_context, locale, format);\n    }\n    // mergeNumberFormat\n    function mergeNumberFormat(locale, format) {\n        _numberFormats.value[locale] = assign(_numberFormats.value[locale] || {}, format);\n        _context.numberFormats = _numberFormats.value;\n        clearNumberFormat(_context, locale, format);\n    }\n    // for debug\n    composerID++;\n    // watch root locale & fallbackLocale\n    if (__root && inBrowser) {\n        watch(__root.locale, (val) => {\n            if (_inheritLocale) {\n                _locale.value = val;\n                _context.locale = val;\n                updateFallbackLocale(_context, _locale.value, _fallbackLocale.value);\n            }\n        });\n        watch(__root.fallbackLocale, (val) => {\n            if (_inheritLocale) {\n                _fallbackLocale.value = val;\n                _context.fallbackLocale = val;\n                updateFallbackLocale(_context, _locale.value, _fallbackLocale.value);\n            }\n        });\n    }\n    // define basic composition API!\n    const composer = {\n        id: composerID,\n        locale,\n        fallbackLocale,\n        get inheritLocale() {\n            return _inheritLocale;\n        },\n        set inheritLocale(val) {\n            _inheritLocale = val;\n            if (val && __root) {\n                _locale.value = __root.locale.value;\n                _fallbackLocale.value = __root.fallbackLocale.value;\n                updateFallbackLocale(_context, _locale.value, _fallbackLocale.value);\n            }\n        },\n        get availableLocales() {\n            return Object.keys(_messages.value).sort();\n        },\n        messages,\n        get modifiers() {\n            return _modifiers;\n        },\n        get pluralRules() {\n            return _pluralRules || {};\n        },\n        get isGlobal() {\n            return _isGlobal;\n        },\n        get missingWarn() {\n            return _missingWarn;\n        },\n        set missingWarn(val) {\n            _missingWarn = val;\n            _context.missingWarn = _missingWarn;\n        },\n        get fallbackWarn() {\n            return _fallbackWarn;\n        },\n        set fallbackWarn(val) {\n            _fallbackWarn = val;\n            _context.fallbackWarn = _fallbackWarn;\n        },\n        get fallbackRoot() {\n            return _fallbackRoot;\n        },\n        set fallbackRoot(val) {\n            _fallbackRoot = val;\n        },\n        get fallbackFormat() {\n            return _fallbackFormat;\n        },\n        set fallbackFormat(val) {\n            _fallbackFormat = val;\n            _context.fallbackFormat = _fallbackFormat;\n        },\n        get warnHtmlMessage() {\n            return _warnHtmlMessage;\n        },\n        set warnHtmlMessage(val) {\n            _warnHtmlMessage = val;\n            _context.warnHtmlMessage = val;\n        },\n        get escapeParameter() {\n            return _escapeParameter;\n        },\n        set escapeParameter(val) {\n            _escapeParameter = val;\n            _context.escapeParameter = val;\n        },\n        t,\n        getLocaleMessage,\n        setLocaleMessage,\n        mergeLocaleMessage,\n        getPostTranslationHandler,\n        setPostTranslationHandler,\n        getMissingHandler,\n        setMissingHandler,\n        [SetPluralRulesSymbol]: setPluralRules\n    };\n    {\n        composer.datetimeFormats = datetimeFormats;\n        composer.numberFormats = numberFormats;\n        composer.rt = rt;\n        composer.te = te;\n        composer.tm = tm;\n        composer.d = d;\n        composer.n = n;\n        composer.getDateTimeFormat = getDateTimeFormat;\n        composer.setDateTimeFormat = setDateTimeFormat;\n        composer.mergeDateTimeFormat = mergeDateTimeFormat;\n        composer.getNumberFormat = getNumberFormat;\n        composer.setNumberFormat = setNumberFormat;\n        composer.mergeNumberFormat = mergeNumberFormat;\n        composer[InejctWithOptionSymbol] = __injectWithOption;\n        composer[TranslateVNodeSymbol] = translateVNode;\n        composer[DatetimePartsSymbol] = datetimeParts;\n        composer[NumberPartsSymbol] = numberParts;\n    }\n    // for vue-devtools timeline event\n    if ((process.env.NODE_ENV !== 'production')) {\n        composer[EnableEmitter] = (emitter) => {\n            _context.__v_emitter = emitter;\n        };\n        composer[DisableEmitter] = () => {\n            _context.__v_emitter = undefined;\n        };\n    }\n    return composer;\n}\n/* eslint-enable @typescript-eslint/no-explicit-any */\n\n/* eslint-disable @typescript-eslint/no-explicit-any */\n/**\n * Convert to I18n Composer Options from VueI18n Options\n *\n * @internal\n */\nfunction convertComposerOptions(options) {\n    const locale = isString(options.locale) ? options.locale : DEFAULT_LOCALE;\n    const fallbackLocale = isString(options.fallbackLocale) ||\n        isArray(options.fallbackLocale) ||\n        isPlainObject(options.fallbackLocale) ||\n        options.fallbackLocale === false\n        ? options.fallbackLocale\n        : locale;\n    const missing = isFunction(options.missing) ? options.missing : undefined;\n    const missingWarn = isBoolean(options.silentTranslationWarn) ||\n        isRegExp(options.silentTranslationWarn)\n        ? !options.silentTranslationWarn\n        : true;\n    const fallbackWarn = isBoolean(options.silentFallbackWarn) ||\n        isRegExp(options.silentFallbackWarn)\n        ? !options.silentFallbackWarn\n        : true;\n    const fallbackRoot = isBoolean(options.fallbackRoot)\n        ? options.fallbackRoot\n        : true;\n    const fallbackFormat = !!options.formatFallbackMessages;\n    const modifiers = isPlainObject(options.modifiers) ? options.modifiers : {};\n    const pluralizationRules = options.pluralizationRules;\n    const postTranslation = isFunction(options.postTranslation)\n        ? options.postTranslation\n        : undefined;\n    const warnHtmlMessage = isString(options.warnHtmlInMessage)\n        ? options.warnHtmlInMessage !== 'off'\n        : true;\n    const escapeParameter = !!options.escapeParameterHtml;\n    const inheritLocale = isBoolean(options.sync) ? options.sync : true;\n    if ((process.env.NODE_ENV !== 'production') && options.formatter) {\n        warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_FORMATTER));\n    }\n    if ((process.env.NODE_ENV !== 'production') && options.preserveDirectiveContent) {\n        warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_PRESERVE_DIRECTIVE));\n    }\n    let messages = options.messages;\n    if (isPlainObject(options.sharedMessages)) {\n        const sharedMessages = options.sharedMessages;\n        const locales = Object.keys(sharedMessages);\n        messages = locales.reduce((messages, locale) => {\n            const message = messages[locale] || (messages[locale] = {});\n            assign(message, sharedMessages[locale]);\n            return messages;\n        }, (messages || {}));\n    }\n    const { __i18n, __root, __injectWithOption } = options;\n    const datetimeFormats = options.datetimeFormats;\n    const numberFormats = options.numberFormats;\n    const flatJson = options.flatJson;\n    return {\n        locale,\n        fallbackLocale,\n        messages,\n        flatJson,\n        datetimeFormats,\n        numberFormats,\n        missing,\n        missingWarn,\n        fallbackWarn,\n        fallbackRoot,\n        fallbackFormat,\n        modifiers,\n        pluralRules: pluralizationRules,\n        postTranslation,\n        warnHtmlMessage,\n        escapeParameter,\n        messageResolver: options.messageResolver,\n        inheritLocale,\n        __i18n,\n        __root,\n        __injectWithOption\n    };\n}\n/**\n * create VueI18n interface factory\n *\n * @internal\n */\n// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\nfunction createVueI18n(options = {}, VueI18nLegacy) {\n    {\n        const composer = createComposer(convertComposerOptions(options));\n        const { __extender } = options;\n        // defines VueI18n\n        const vueI18n = {\n            // id\n            id: composer.id,\n            // locale\n            get locale() {\n                return composer.locale.value;\n            },\n            set locale(val) {\n                composer.locale.value = val;\n            },\n            // fallbackLocale\n            get fallbackLocale() {\n                return composer.fallbackLocale.value;\n            },\n            set fallbackLocale(val) {\n                composer.fallbackLocale.value = val;\n            },\n            // messages\n            get messages() {\n                return composer.messages.value;\n            },\n            // datetimeFormats\n            get datetimeFormats() {\n                return composer.datetimeFormats.value;\n            },\n            // numberFormats\n            get numberFormats() {\n                return composer.numberFormats.value;\n            },\n            // availableLocales\n            get availableLocales() {\n                return composer.availableLocales;\n            },\n            // formatter\n            get formatter() {\n                (process.env.NODE_ENV !== 'production') && warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_FORMATTER));\n                // dummy\n                return {\n                    interpolate() {\n                        return [];\n                    }\n                };\n            },\n            set formatter(val) {\n                (process.env.NODE_ENV !== 'production') && warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_FORMATTER));\n            },\n            // missing\n            get missing() {\n                return composer.getMissingHandler();\n            },\n            set missing(handler) {\n                composer.setMissingHandler(handler);\n            },\n            // silentTranslationWarn\n            get silentTranslationWarn() {\n                return isBoolean(composer.missingWarn)\n                    ? !composer.missingWarn\n                    : composer.missingWarn;\n            },\n            set silentTranslationWarn(val) {\n                composer.missingWarn = isBoolean(val) ? !val : val;\n            },\n            // silentFallbackWarn\n            get silentFallbackWarn() {\n                return isBoolean(composer.fallbackWarn)\n                    ? !composer.fallbackWarn\n                    : composer.fallbackWarn;\n            },\n            set silentFallbackWarn(val) {\n                composer.fallbackWarn = isBoolean(val) ? !val : val;\n            },\n            // modifiers\n            get modifiers() {\n                return composer.modifiers;\n            },\n            // formatFallbackMessages\n            get formatFallbackMessages() {\n                return composer.fallbackFormat;\n            },\n            set formatFallbackMessages(val) {\n                composer.fallbackFormat = val;\n            },\n            // postTranslation\n            get postTranslation() {\n                return composer.getPostTranslationHandler();\n            },\n            set postTranslation(handler) {\n                composer.setPostTranslationHandler(handler);\n            },\n            // sync\n            get sync() {\n                return composer.inheritLocale;\n            },\n            set sync(val) {\n                composer.inheritLocale = val;\n            },\n            // warnInHtmlMessage\n            get warnHtmlInMessage() {\n                return composer.warnHtmlMessage ? 'warn' : 'off';\n            },\n            set warnHtmlInMessage(val) {\n                composer.warnHtmlMessage = val !== 'off';\n            },\n            // escapeParameterHtml\n            get escapeParameterHtml() {\n                return composer.escapeParameter;\n            },\n            set escapeParameterHtml(val) {\n                composer.escapeParameter = val;\n            },\n            // preserveDirectiveContent\n            get preserveDirectiveContent() {\n                (process.env.NODE_ENV !== 'production') &&\n                    warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_PRESERVE_DIRECTIVE));\n                return true;\n            },\n            set preserveDirectiveContent(val) {\n                (process.env.NODE_ENV !== 'production') &&\n                    warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_PRESERVE_DIRECTIVE));\n            },\n            // pluralizationRules\n            get pluralizationRules() {\n                return composer.pluralRules || {};\n            },\n            // for internal\n            __composer: composer,\n            // t\n            t(...args) {\n                const [arg1, arg2, arg3] = args;\n                const options = {};\n                let list = null;\n                let named = null;\n                if (!isString(arg1)) {\n                    throw createI18nError(I18nErrorCodes.INVALID_ARGUMENT);\n                }\n                const key = arg1;\n                if (isString(arg2)) {\n                    options.locale = arg2;\n                }\n                else if (isArray(arg2)) {\n                    list = arg2;\n                }\n                else if (isPlainObject(arg2)) {\n                    named = arg2;\n                }\n                if (isArray(arg3)) {\n                    list = arg3;\n                }\n                else if (isPlainObject(arg3)) {\n                    named = arg3;\n                }\n                // return composer.t(key, (list || named || {}) as any, options)\n                return Reflect.apply(composer.t, composer, [\n                    key,\n                    (list || named || {}),\n                    options\n                ]);\n            },\n            rt(...args) {\n                return Reflect.apply(composer.rt, composer, [...args]);\n            },\n            // tc\n            tc(...args) {\n                const [arg1, arg2, arg3] = args;\n                const options = { plural: 1 };\n                let list = null;\n                let named = null;\n                if (!isString(arg1)) {\n                    throw createI18nError(I18nErrorCodes.INVALID_ARGUMENT);\n                }\n                const key = arg1;\n                if (isString(arg2)) {\n                    options.locale = arg2;\n                }\n                else if (isNumber(arg2)) {\n                    options.plural = arg2;\n                }\n                else if (isArray(arg2)) {\n                    list = arg2;\n                }\n                else if (isPlainObject(arg2)) {\n                    named = arg2;\n                }\n                if (isString(arg3)) {\n                    options.locale = arg3;\n                }\n                else if (isArray(arg3)) {\n                    list = arg3;\n                }\n                else if (isPlainObject(arg3)) {\n                    named = arg3;\n                }\n                // return composer.t(key, (list || named || {}) as any, options)\n                return Reflect.apply(composer.t, composer, [\n                    key,\n                    (list || named || {}),\n                    options\n                ]);\n            },\n            // te\n            te(key, locale) {\n                return composer.te(key, locale);\n            },\n            // tm\n            tm(key) {\n                return composer.tm(key);\n            },\n            // getLocaleMessage\n            getLocaleMessage(locale) {\n                return composer.getLocaleMessage(locale);\n            },\n            // setLocaleMessage\n            setLocaleMessage(locale, message) {\n                composer.setLocaleMessage(locale, message);\n            },\n            // mergeLocaleMessage\n            mergeLocaleMessage(locale, message) {\n                composer.mergeLocaleMessage(locale, message);\n            },\n            // d\n            d(...args) {\n                return Reflect.apply(composer.d, composer, [...args]);\n            },\n            // getDateTimeFormat\n            getDateTimeFormat(locale) {\n                return composer.getDateTimeFormat(locale);\n            },\n            // setDateTimeFormat\n            setDateTimeFormat(locale, format) {\n                composer.setDateTimeFormat(locale, format);\n            },\n            // mergeDateTimeFormat\n            mergeDateTimeFormat(locale, format) {\n                composer.mergeDateTimeFormat(locale, format);\n            },\n            // n\n            n(...args) {\n                return Reflect.apply(composer.n, composer, [...args]);\n            },\n            // getNumberFormat\n            getNumberFormat(locale) {\n                return composer.getNumberFormat(locale);\n            },\n            // setNumberFormat\n            setNumberFormat(locale, format) {\n                composer.setNumberFormat(locale, format);\n            },\n            // mergeNumberFormat\n            mergeNumberFormat(locale, format) {\n                composer.mergeNumberFormat(locale, format);\n            },\n            // getChoiceIndex\n            // eslint-disable-next-line @typescript-eslint/no-unused-vars\n            getChoiceIndex(choice, choicesLength) {\n                (process.env.NODE_ENV !== 'production') &&\n                    warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_GET_CHOICE_INDEX));\n                return -1;\n            }\n        };\n        vueI18n.__extender = __extender;\n        // for vue-devtools timeline event\n        if ((process.env.NODE_ENV !== 'production')) {\n            vueI18n.__enableEmitter = (emitter) => {\n                const __composer = composer;\n                __composer[EnableEmitter] && __composer[EnableEmitter](emitter);\n            };\n            vueI18n.__disableEmitter = () => {\n                const __composer = composer;\n                __composer[DisableEmitter] && __composer[DisableEmitter]();\n            };\n        }\n        return vueI18n;\n    }\n}\n/* eslint-enable @typescript-eslint/no-explicit-any */\n\nconst baseFormatProps = {\n    tag: {\n        type: [String, Object]\n    },\n    locale: {\n        type: String\n    },\n    scope: {\n        type: String,\n        // NOTE: avoid https://github.com/microsoft/rushstack/issues/1050\n        validator: (val /* ComponentI18nScope */) => val === 'parent' || val === 'global',\n        default: 'parent' /* ComponentI18nScope */\n    },\n    i18n: {\n        type: Object\n    }\n};\n\nfunction getInterpolateArg(\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\n{ slots }, // SetupContext,\nkeys) {\n    if (keys.length === 1 && keys[0] === 'default') {\n        // default slot with list\n        const ret = slots.default ? slots.default() : [];\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        return ret.reduce((slot, current) => {\n            return [\n                ...slot,\n                // prettier-ignore\n                ...(current.type === Fragment ? current.children : [current]\n                    )\n            ];\n        }, []);\n    }\n    else {\n        // named slots\n        return keys.reduce((arg, key) => {\n            const slot = slots[key];\n            if (slot) {\n                arg[key] = slot();\n            }\n            return arg;\n        }, {});\n    }\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getFragmentableTag(tag) {\n    return Fragment ;\n}\n\nconst TranslationImpl = /*#__PURE__*/ defineComponent({\n    /* eslint-disable */\n    name: 'i18n-t',\n    props: assign({\n        keypath: {\n            type: String,\n            required: true\n        },\n        plural: {\n            type: [Number, String],\n            // eslint-disable-next-line @typescript-eslint/no-explicit-any\n            validator: (val) => isNumber(val) || !isNaN(val)\n        }\n    }, baseFormatProps),\n    /* eslint-enable */\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    setup(props, context) {\n        const { slots, attrs } = context;\n        // NOTE: avoid https://github.com/microsoft/rushstack/issues/1050\n        const i18n = props.i18n ||\n            useI18n({\n                useScope: props.scope,\n                __useComponent: true\n            });\n        return () => {\n            const keys = Object.keys(slots).filter(key => key !== '_');\n            const options = {};\n            if (props.locale) {\n                options.locale = props.locale;\n            }\n            if (props.plural !== undefined) {\n                options.plural = isString(props.plural) ? +props.plural : props.plural;\n            }\n            const arg = getInterpolateArg(context, keys);\n            // eslint-disable-next-line @typescript-eslint/no-explicit-any\n            const children = i18n[TranslateVNodeSymbol](props.keypath, arg, options);\n            const assignedAttrs = assign({}, attrs);\n            const tag = isString(props.tag) || isObject(props.tag)\n                ? props.tag\n                : getFragmentableTag();\n            return h(tag, assignedAttrs, children);\n        };\n    }\n});\n/**\n * export the public type for h/tsx inference\n * also to avoid inline import() in generated d.ts files\n */\n/**\n * Translation Component\n *\n * @remarks\n * See the following items for property about details\n *\n * @VueI18nSee [TranslationProps](component#translationprops)\n * @VueI18nSee [BaseFormatProps](component#baseformatprops)\n * @VueI18nSee [Component Interpolation](../guide/advanced/component)\n *\n * @example\n * ```html\n * <div id=\"app\">\n *   <!-- ... -->\n *   <i18n keypath=\"term\" tag=\"label\" for=\"tos\">\n *     <a :href=\"url\" target=\"_blank\">{{ $t('tos') }}</a>\n *   </i18n>\n *   <!-- ... -->\n * </div>\n * ```\n * ```js\n * import { createApp } from 'vue'\n * import { createI18n } from 'vue-i18n'\n *\n * const messages = {\n *   en: {\n *     tos: 'Term of Service',\n *     term: 'I accept xxx {0}.'\n *   },\n *   ja: {\n *     tos: '利用規約',\n *     term: '私は xxx の{0}に同意します。'\n *   }\n * }\n *\n * const i18n = createI18n({\n *   locale: 'en',\n *   messages\n * })\n *\n * const app = createApp({\n *   data: {\n *     url: '/term'\n *   }\n * }).use(i18n).mount('#app')\n * ```\n *\n * @VueI18nComponent\n */\nconst Translation = TranslationImpl;\nconst I18nT = Translation;\n\nfunction isVNode(target) {\n    return isArray(target) && !isString(target[0]);\n}\nfunction renderFormatter(props, context, slotKeys, partFormatter) {\n    const { slots, attrs } = context;\n    return () => {\n        const options = { part: true };\n        let overrides = {};\n        if (props.locale) {\n            options.locale = props.locale;\n        }\n        if (isString(props.format)) {\n            options.key = props.format;\n        }\n        else if (isObject(props.format)) {\n            // eslint-disable-next-line @typescript-eslint/no-explicit-any\n            if (isString(props.format.key)) {\n                // eslint-disable-next-line @typescript-eslint/no-explicit-any\n                options.key = props.format.key;\n            }\n            // Filter out number format options only\n            overrides = Object.keys(props.format).reduce((options, prop) => {\n                return slotKeys.includes(prop)\n                    ? assign({}, options, { [prop]: props.format[prop] }) // eslint-disable-line @typescript-eslint/no-explicit-any\n                    : options;\n            }, {});\n        }\n        const parts = partFormatter(...[props.value, options, overrides]);\n        let children = [options.key];\n        if (isArray(parts)) {\n            children = parts.map((part, index) => {\n                const slot = slots[part.type];\n                const node = slot\n                    ? slot({ [part.type]: part.value, index, parts })\n                    : [part.value];\n                if (isVNode(node)) {\n                    node[0].key = `${part.type}-${index}`;\n                }\n                return node;\n            });\n        }\n        else if (isString(parts)) {\n            children = [parts];\n        }\n        const assignedAttrs = assign({}, attrs);\n        const tag = isString(props.tag) || isObject(props.tag)\n            ? props.tag\n            : getFragmentableTag();\n        return h(tag, assignedAttrs, children);\n    };\n}\n\nconst NumberFormatImpl = /*#__PURE__*/ defineComponent({\n    /* eslint-disable */\n    name: 'i18n-n',\n    props: assign({\n        value: {\n            type: Number,\n            required: true\n        },\n        format: {\n            type: [String, Object]\n        }\n    }, baseFormatProps),\n    /* eslint-enable */\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    setup(props, context) {\n        const i18n = props.i18n ||\n            useI18n({\n                useScope: 'parent',\n                __useComponent: true\n            });\n        return renderFormatter(props, context, NUMBER_FORMAT_OPTIONS_KEYS, (...args) => \n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        i18n[NumberPartsSymbol](...args));\n    }\n});\n/**\n * export the public type for h/tsx inference\n * also to avoid inline import() in generated d.ts files\n */\n/**\n * Number Format Component\n *\n * @remarks\n * See the following items for property about details\n *\n * @VueI18nSee [FormattableProps](component#formattableprops)\n * @VueI18nSee [BaseFormatProps](component#baseformatprops)\n * @VueI18nSee [Custom Formatting](../guide/essentials/number#custom-formatting)\n *\n * @VueI18nDanger\n * Not supported IE, due to no support `Intl.NumberFormat#formatToParts` in [IE](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/formatToParts)\n *\n * If you want to use it, you need to use [polyfill](https://github.com/formatjs/formatjs/tree/main/packages/intl-numberformat)\n *\n * @VueI18nComponent\n */\nconst NumberFormat = NumberFormatImpl;\nconst I18nN = NumberFormat;\n\nconst DatetimeFormatImpl = /* #__PURE__*/ defineComponent({\n    /* eslint-disable */\n    name: 'i18n-d',\n    props: assign({\n        value: {\n            type: [Number, Date],\n            required: true\n        },\n        format: {\n            type: [String, Object]\n        }\n    }, baseFormatProps),\n    /* eslint-enable */\n    // eslint-disable-next-line @typescript-eslint/no-explicit-any\n    setup(props, context) {\n        const i18n = props.i18n ||\n            useI18n({\n                useScope: 'parent',\n                __useComponent: true\n            });\n        return renderFormatter(props, context, DATETIME_FORMAT_OPTIONS_KEYS, (...args) => \n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        i18n[DatetimePartsSymbol](...args));\n    }\n});\n/**\n * Datetime Format Component\n *\n * @remarks\n * See the following items for property about details\n *\n * @VueI18nSee [FormattableProps](component#formattableprops)\n * @VueI18nSee [BaseFormatProps](component#baseformatprops)\n * @VueI18nSee [Custom Formatting](../guide/essentials/datetime#custom-formatting)\n *\n * @VueI18nDanger\n * Not supported IE, due to no support `Intl.DateTimeFormat#formatToParts` in [IE](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/DateTimeFormat/formatToParts)\n *\n * If you want to use it, you need to use [polyfill](https://github.com/formatjs/formatjs/tree/main/packages/intl-datetimeformat)\n *\n * @VueI18nComponent\n */\nconst DatetimeFormat = DatetimeFormatImpl;\nconst I18nD = DatetimeFormat;\n\nfunction getComposer$2(i18n, instance) {\n    const i18nInternal = i18n;\n    if (i18n.mode === 'composition') {\n        return (i18nInternal.__getInstance(instance) || i18n.global);\n    }\n    else {\n        const vueI18n = i18nInternal.__getInstance(instance);\n        return vueI18n != null\n            ? vueI18n.__composer\n            : i18n.global.__composer;\n    }\n}\nfunction vTDirective(i18n) {\n    const _process = (binding) => {\n        const { instance, modifiers, value } = binding;\n        /* istanbul ignore if */\n        if (!instance || !instance.$) {\n            throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);\n        }\n        const composer = getComposer$2(i18n, instance.$);\n        if ((process.env.NODE_ENV !== 'production') && modifiers.preserve) {\n            warn(getWarnMessage(I18nWarnCodes.NOT_SUPPORTED_PRESERVE));\n        }\n        const parsedValue = parseValue(value);\n        return [\n            Reflect.apply(composer.t, composer, [...makeParams(parsedValue)]),\n            composer\n        ];\n    };\n    const register = (el, binding) => {\n        const [textContent, composer] = _process(binding);\n        if (inBrowser && i18n.global === composer) {\n            // global scope only\n            el.__i18nWatcher = watch(composer.locale, () => {\n                binding.instance && binding.instance.$forceUpdate();\n            });\n        }\n        el.__composer = composer;\n        el.textContent = textContent;\n    };\n    const unregister = (el) => {\n        if (inBrowser && el.__i18nWatcher) {\n            el.__i18nWatcher();\n            el.__i18nWatcher = undefined;\n            delete el.__i18nWatcher;\n        }\n        if (el.__composer) {\n            el.__composer = undefined;\n            delete el.__composer;\n        }\n    };\n    const update = (el, { value }) => {\n        if (el.__composer) {\n            const composer = el.__composer;\n            const parsedValue = parseValue(value);\n            el.textContent = Reflect.apply(composer.t, composer, [\n                ...makeParams(parsedValue)\n            ]);\n        }\n    };\n    const getSSRProps = (binding) => {\n        const [textContent] = _process(binding);\n        return { textContent };\n    };\n    return {\n        created: register,\n        unmounted: unregister,\n        beforeUpdate: update,\n        getSSRProps\n    };\n}\nfunction parseValue(value) {\n    if (isString(value)) {\n        return { path: value };\n    }\n    else if (isPlainObject(value)) {\n        if (!('path' in value)) {\n            throw createI18nError(I18nErrorCodes.REQUIRED_VALUE, 'path');\n        }\n        return value;\n    }\n    else {\n        throw createI18nError(I18nErrorCodes.INVALID_VALUE);\n    }\n}\nfunction makeParams(value) {\n    const { path, locale, args, choice, plural } = value;\n    const options = {};\n    const named = args || {};\n    if (isString(locale)) {\n        options.locale = locale;\n    }\n    if (isNumber(choice)) {\n        options.plural = choice;\n    }\n    if (isNumber(plural)) {\n        options.plural = plural;\n    }\n    return [path, named, options];\n}\n\nfunction apply(app, i18n, ...options) {\n    const pluginOptions = isPlainObject(options[0])\n        ? options[0]\n        : {};\n    const useI18nComponentName = !!pluginOptions.useI18nComponentName;\n    const globalInstall = isBoolean(pluginOptions.globalInstall)\n        ? pluginOptions.globalInstall\n        : true;\n    if ((process.env.NODE_ENV !== 'production') && globalInstall && useI18nComponentName) {\n        warn(getWarnMessage(I18nWarnCodes.COMPONENT_NAME_LEGACY_COMPATIBLE, {\n            name: Translation.name\n        }));\n    }\n    if (globalInstall) {\n        [!useI18nComponentName ? Translation.name : 'i18n', 'I18nT'].forEach(name => app.component(name, Translation));\n        [NumberFormat.name, 'I18nN'].forEach(name => app.component(name, NumberFormat));\n        [DatetimeFormat.name, 'I18nD'].forEach(name => app.component(name, DatetimeFormat));\n    }\n    // install directive\n    {\n        app.directive('t', vTDirective(i18n));\n    }\n}\n\nconst VueDevToolsLabels = {\n    [\"vue-devtools-plugin-vue-i18n\" /* VueDevToolsIDs.PLUGIN */]: 'Vue I18n devtools',\n    [\"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */]: 'I18n Resources',\n    [\"vue-i18n-timeline\" /* VueDevToolsIDs.TIMELINE */]: 'Vue I18n'\n};\nconst VueDevToolsPlaceholders = {\n    [\"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */]: 'Search for scopes ...'\n};\nconst VueDevToolsTimelineColors = {\n    [\"vue-i18n-timeline\" /* VueDevToolsIDs.TIMELINE */]: 0xffcd19\n};\n\nconst VUE_I18N_COMPONENT_TYPES = 'vue-i18n: composer properties';\nlet devtoolsApi;\nasync function enableDevTools(app, i18n) {\n    return new Promise((resolve, reject) => {\n        try {\n            setupDevtoolsPlugin({\n                id: \"vue-devtools-plugin-vue-i18n\" /* VueDevToolsIDs.PLUGIN */,\n                label: VueDevToolsLabels[\"vue-devtools-plugin-vue-i18n\" /* VueDevToolsIDs.PLUGIN */],\n                packageName: 'vue-i18n',\n                homepage: 'https://vue-i18n.intlify.dev',\n                logo: 'https://vue-i18n.intlify.dev/vue-i18n-devtools-logo.png',\n                componentStateTypes: [VUE_I18N_COMPONENT_TYPES],\n                app: app // eslint-disable-line @typescript-eslint/no-explicit-any\n            }, api => {\n                devtoolsApi = api;\n                api.on.visitComponentTree(({ componentInstance, treeNode }) => {\n                    updateComponentTreeTags(componentInstance, treeNode, i18n);\n                });\n                api.on.inspectComponent(({ componentInstance, instanceData }) => {\n                    if (componentInstance.vnode.el &&\n                        componentInstance.vnode.el.__VUE_I18N__ &&\n                        instanceData) {\n                        if (i18n.mode === 'legacy') {\n                            // ignore global scope on legacy mode\n                            if (componentInstance.vnode.el.__VUE_I18N__ !==\n                                i18n.global.__composer) {\n                                inspectComposer(instanceData, componentInstance.vnode.el.__VUE_I18N__);\n                            }\n                        }\n                        else {\n                            inspectComposer(instanceData, componentInstance.vnode.el.__VUE_I18N__);\n                        }\n                    }\n                });\n                api.addInspector({\n                    id: \"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */,\n                    label: VueDevToolsLabels[\"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */],\n                    icon: 'language',\n                    treeFilterPlaceholder: VueDevToolsPlaceholders[\"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */]\n                });\n                api.on.getInspectorTree(payload => {\n                    if (payload.app === app &&\n                        payload.inspectorId === \"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */) {\n                        registerScope(payload, i18n);\n                    }\n                });\n                const roots = new Map();\n                api.on.getInspectorState(async (payload) => {\n                    if (payload.app === app &&\n                        payload.inspectorId === \"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */) {\n                        api.unhighlightElement();\n                        inspectScope(payload, i18n);\n                        if (payload.nodeId === 'global') {\n                            if (!roots.has(payload.app)) {\n                                const [root] = await api.getComponentInstances(payload.app);\n                                roots.set(payload.app, root);\n                            }\n                            api.highlightElement(roots.get(payload.app));\n                        }\n                        else {\n                            const instance = getComponentInstance(payload.nodeId, i18n);\n                            instance && api.highlightElement(instance);\n                        }\n                    }\n                });\n                api.on.editInspectorState(payload => {\n                    if (payload.app === app &&\n                        payload.inspectorId === \"vue-i18n-resource-inspector\" /* VueDevToolsIDs.CUSTOM_INSPECTOR */) {\n                        editScope(payload, i18n);\n                    }\n                });\n                api.addTimelineLayer({\n                    id: \"vue-i18n-timeline\" /* VueDevToolsIDs.TIMELINE */,\n                    label: VueDevToolsLabels[\"vue-i18n-timeline\" /* VueDevToolsIDs.TIMELINE */],\n                    color: VueDevToolsTimelineColors[\"vue-i18n-timeline\" /* VueDevToolsIDs.TIMELINE */]\n                });\n                resolve(true);\n            });\n        }\n        catch (e) {\n            console.error(e);\n            reject(false);\n        }\n    });\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getI18nScopeLable(instance) {\n    return (instance.type.name ||\n        instance.type.displayName ||\n        instance.type.__file ||\n        'Anonymous');\n}\nfunction updateComponentTreeTags(instance, // eslint-disable-line @typescript-eslint/no-explicit-any\ntreeNode, i18n) {\n    // prettier-ignore\n    const global = i18n.mode === 'composition'\n        ? i18n.global\n        : i18n.global.__composer;\n    if (instance && instance.vnode.el && instance.vnode.el.__VUE_I18N__) {\n        // add custom tags local scope only\n        if (instance.vnode.el.__VUE_I18N__ !== global) {\n            const tag = {\n                label: `i18n (${getI18nScopeLable(instance)} Scope)`,\n                textColor: 0x000000,\n                backgroundColor: 0xffcd19\n            };\n            treeNode.tags.push(tag);\n        }\n    }\n}\nfunction inspectComposer(instanceData, composer) {\n    const type = VUE_I18N_COMPONENT_TYPES;\n    instanceData.state.push({\n        type,\n        key: 'locale',\n        editable: true,\n        value: composer.locale.value\n    });\n    instanceData.state.push({\n        type,\n        key: 'availableLocales',\n        editable: false,\n        value: composer.availableLocales\n    });\n    instanceData.state.push({\n        type,\n        key: 'fallbackLocale',\n        editable: true,\n        value: composer.fallbackLocale.value\n    });\n    instanceData.state.push({\n        type,\n        key: 'inheritLocale',\n        editable: true,\n        value: composer.inheritLocale\n    });\n    instanceData.state.push({\n        type,\n        key: 'messages',\n        editable: false,\n        value: getLocaleMessageValue(composer.messages.value)\n    });\n    {\n        instanceData.state.push({\n            type,\n            key: 'datetimeFormats',\n            editable: false,\n            value: composer.datetimeFormats.value\n        });\n        instanceData.state.push({\n            type,\n            key: 'numberFormats',\n            editable: false,\n            value: composer.numberFormats.value\n        });\n    }\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getLocaleMessageValue(messages) {\n    const value = {};\n    Object.keys(messages).forEach((key) => {\n        const v = messages[key];\n        if (isFunction(v) && 'source' in v) {\n            value[key] = getMessageFunctionDetails(v);\n        }\n        else if (isMessageAST(v) && v.loc && v.loc.source) {\n            value[key] = v.loc.source;\n        }\n        else if (isObject(v)) {\n            value[key] = getLocaleMessageValue(v);\n        }\n        else {\n            value[key] = v;\n        }\n    });\n    return value;\n}\nconst ESC = {\n    '<': '&lt;',\n    '>': '&gt;',\n    '\"': '&quot;',\n    '&': '&amp;'\n};\nfunction escape(s) {\n    return s.replace(/[<>\"&]/g, escapeChar);\n}\nfunction escapeChar(a) {\n    return ESC[a] || a;\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getMessageFunctionDetails(func) {\n    const argString = func.source ? `(\"${escape(func.source)}\")` : `(?)`;\n    return {\n        _custom: {\n            type: 'function',\n            display: `<span>ƒ</span> ${argString}`\n        }\n    };\n}\nfunction registerScope(payload, i18n) {\n    payload.rootNodes.push({\n        id: 'global',\n        label: 'Global Scope'\n    });\n    // prettier-ignore\n    const global = i18n.mode === 'composition'\n        ? i18n.global\n        : i18n.global.__composer;\n    for (const [keyInstance, instance] of i18n.__instances) {\n        // prettier-ignore\n        const composer = i18n.mode === 'composition'\n            ? instance\n            : instance.__composer;\n        if (global === composer) {\n            continue;\n        }\n        payload.rootNodes.push({\n            id: composer.id.toString(),\n            label: `${getI18nScopeLable(keyInstance)} Scope`\n        });\n    }\n}\nfunction getComponentInstance(nodeId, i18n) {\n    let instance = null;\n    if (nodeId !== 'global') {\n        for (const [component, composer] of i18n.__instances.entries()) {\n            if (composer.id.toString() === nodeId) {\n                instance = component;\n                break;\n            }\n        }\n    }\n    return instance;\n}\nfunction getComposer$1(nodeId, i18n) {\n    if (nodeId === 'global') {\n        return i18n.mode === 'composition'\n            ? i18n.global\n            : i18n.global.__composer;\n    }\n    else {\n        const instance = Array.from(i18n.__instances.values()).find(item => item.id.toString() === nodeId);\n        if (instance) {\n            return i18n.mode === 'composition'\n                ? instance\n                : instance.__composer;\n        }\n        else {\n            return null;\n        }\n    }\n}\nfunction inspectScope(payload, i18n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\n) {\n    const composer = getComposer$1(payload.nodeId, i18n);\n    if (composer) {\n        // TODO:\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        payload.state = makeScopeInspectState(composer);\n    }\n    return null;\n}\nfunction makeScopeInspectState(composer) {\n    const state = {};\n    const localeType = 'Locale related info';\n    const localeStates = [\n        {\n            type: localeType,\n            key: 'locale',\n            editable: true,\n            value: composer.locale.value\n        },\n        {\n            type: localeType,\n            key: 'fallbackLocale',\n            editable: true,\n            value: composer.fallbackLocale.value\n        },\n        {\n            type: localeType,\n            key: 'availableLocales',\n            editable: false,\n            value: composer.availableLocales\n        },\n        {\n            type: localeType,\n            key: 'inheritLocale',\n            editable: true,\n            value: composer.inheritLocale\n        }\n    ];\n    state[localeType] = localeStates;\n    const localeMessagesType = 'Locale messages info';\n    const localeMessagesStates = [\n        {\n            type: localeMessagesType,\n            key: 'messages',\n            editable: false,\n            value: getLocaleMessageValue(composer.messages.value)\n        }\n    ];\n    state[localeMessagesType] = localeMessagesStates;\n    {\n        const datetimeFormatsType = 'Datetime formats info';\n        const datetimeFormatsStates = [\n            {\n                type: datetimeFormatsType,\n                key: 'datetimeFormats',\n                editable: false,\n                value: composer.datetimeFormats.value\n            }\n        ];\n        state[datetimeFormatsType] = datetimeFormatsStates;\n        const numberFormatsType = 'Datetime formats info';\n        const numberFormatsStates = [\n            {\n                type: numberFormatsType,\n                key: 'numberFormats',\n                editable: false,\n                value: composer.numberFormats.value\n            }\n        ];\n        state[numberFormatsType] = numberFormatsStates;\n    }\n    return state;\n}\nfunction addTimelineEvent(event, payload) {\n    if (devtoolsApi) {\n        let groupId;\n        if (payload && 'groupId' in payload) {\n            groupId = payload.groupId;\n            delete payload.groupId;\n        }\n        devtoolsApi.addTimelineEvent({\n            layerId: \"vue-i18n-timeline\" /* VueDevToolsIDs.TIMELINE */,\n            event: {\n                title: event,\n                groupId,\n                time: Date.now(),\n                meta: {},\n                data: payload || {},\n                logType: event === \"compile-error\" /* VueDevToolsTimelineEvents.COMPILE_ERROR */\n                    ? 'error'\n                    : event === \"fallback\" /* VueDevToolsTimelineEvents.FALBACK */ ||\n                        event === \"missing\" /* VueDevToolsTimelineEvents.MISSING */\n                        ? 'warning'\n                        : 'default'\n            }\n        });\n    }\n}\nfunction editScope(payload, i18n) {\n    const composer = getComposer$1(payload.nodeId, i18n);\n    if (composer) {\n        const [field] = payload.path;\n        if (field === 'locale' && isString(payload.state.value)) {\n            composer.locale.value = payload.state.value;\n        }\n        else if (field === 'fallbackLocale' &&\n            (isString(payload.state.value) ||\n                isArray(payload.state.value) ||\n                isObject(payload.state.value))) {\n            composer.fallbackLocale.value = payload.state.value;\n        }\n        else if (field === 'inheritLocale' && isBoolean(payload.state.value)) {\n            composer.inheritLocale = payload.state.value;\n        }\n    }\n}\n\n/**\n * Supports compatibility for legacy vue-i18n APIs\n * This mixin is used when we use vue-i18n@v9.x or later\n */\nfunction defineMixin(vuei18n, composer, i18n) {\n    return {\n        beforeCreate() {\n            const instance = getCurrentInstance();\n            /* istanbul ignore if */\n            if (!instance) {\n                throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);\n            }\n            const options = this.$options;\n            if (options.i18n) {\n                const optionsI18n = options.i18n;\n                if (options.__i18n) {\n                    optionsI18n.__i18n = options.__i18n;\n                }\n                optionsI18n.__root = composer;\n                if (this === this.$root) {\n                    // merge option and gttach global\n                    this.$i18n = mergeToGlobal(vuei18n, optionsI18n);\n                }\n                else {\n                    optionsI18n.__injectWithOption = true;\n                    optionsI18n.__extender = i18n.__vueI18nExtend;\n                    // atttach local VueI18n instance\n                    this.$i18n = createVueI18n(optionsI18n);\n                    // extend VueI18n instance\n                    const _vueI18n = this.$i18n;\n                    if (_vueI18n.__extender) {\n                        _vueI18n.__disposer = _vueI18n.__extender(this.$i18n);\n                    }\n                }\n            }\n            else if (options.__i18n) {\n                if (this === this.$root) {\n                    // merge option and gttach global\n                    this.$i18n = mergeToGlobal(vuei18n, options);\n                }\n                else {\n                    // atttach local VueI18n instance\n                    this.$i18n = createVueI18n({\n                        __i18n: options.__i18n,\n                        __injectWithOption: true,\n                        __extender: i18n.__vueI18nExtend,\n                        __root: composer\n                    });\n                    // extend VueI18n instance\n                    const _vueI18n = this.$i18n;\n                    if (_vueI18n.__extender) {\n                        _vueI18n.__disposer = _vueI18n.__extender(this.$i18n);\n                    }\n                }\n            }\n            else {\n                // attach global VueI18n instance\n                this.$i18n = vuei18n;\n            }\n            if (options.__i18nGlobal) {\n                adjustI18nResources(composer, options, options);\n            }\n            // defines vue-i18n legacy APIs\n            this.$t = (...args) => this.$i18n.t(...args);\n            this.$rt = (...args) => this.$i18n.rt(...args);\n            this.$tc = (...args) => this.$i18n.tc(...args);\n            this.$te = (key, locale) => this.$i18n.te(key, locale);\n            this.$d = (...args) => this.$i18n.d(...args);\n            this.$n = (...args) => this.$i18n.n(...args);\n            this.$tm = (key) => this.$i18n.tm(key);\n            i18n.__setInstance(instance, this.$i18n);\n        },\n        mounted() {\n            /* istanbul ignore if */\n            if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) &&\n                !false &&\n                this.$el &&\n                this.$i18n) {\n                const _vueI18n = this.$i18n;\n                this.$el.__VUE_I18N__ = _vueI18n.__composer;\n                const emitter = (this.__v_emitter =\n                    createEmitter());\n                _vueI18n.__enableEmitter && _vueI18n.__enableEmitter(emitter);\n                emitter.on('*', addTimelineEvent);\n            }\n        },\n        unmounted() {\n            const instance = getCurrentInstance();\n            /* istanbul ignore if */\n            if (!instance) {\n                throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);\n            }\n            const _vueI18n = this.$i18n;\n            /* istanbul ignore if */\n            if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) &&\n                !false &&\n                this.$el &&\n                this.$el.__VUE_I18N__) {\n                if (this.__v_emitter) {\n                    this.__v_emitter.off('*', addTimelineEvent);\n                    delete this.__v_emitter;\n                }\n                if (this.$i18n) {\n                    _vueI18n.__disableEmitter && _vueI18n.__disableEmitter();\n                    delete this.$el.__VUE_I18N__;\n                }\n            }\n            delete this.$t;\n            delete this.$rt;\n            delete this.$tc;\n            delete this.$te;\n            delete this.$d;\n            delete this.$n;\n            delete this.$tm;\n            if (_vueI18n.__disposer) {\n                _vueI18n.__disposer();\n                delete _vueI18n.__disposer;\n                delete _vueI18n.__extender;\n            }\n            i18n.__deleteInstance(instance);\n            delete this.$i18n;\n        }\n    };\n}\nfunction mergeToGlobal(g, options) {\n    g.locale = options.locale || g.locale;\n    g.fallbackLocale = options.fallbackLocale || g.fallbackLocale;\n    g.missing = options.missing || g.missing;\n    g.silentTranslationWarn =\n        options.silentTranslationWarn || g.silentFallbackWarn;\n    g.silentFallbackWarn = options.silentFallbackWarn || g.silentFallbackWarn;\n    g.formatFallbackMessages =\n        options.formatFallbackMessages || g.formatFallbackMessages;\n    g.postTranslation = options.postTranslation || g.postTranslation;\n    g.warnHtmlInMessage = options.warnHtmlInMessage || g.warnHtmlInMessage;\n    g.escapeParameterHtml = options.escapeParameterHtml || g.escapeParameterHtml;\n    g.sync = options.sync || g.sync;\n    g.__composer[SetPluralRulesSymbol](options.pluralizationRules || g.pluralizationRules);\n    const messages = getLocaleMessages(g.locale, {\n        messages: options.messages,\n        __i18n: options.__i18n\n    });\n    Object.keys(messages).forEach(locale => g.mergeLocaleMessage(locale, messages[locale]));\n    if (options.datetimeFormats) {\n        Object.keys(options.datetimeFormats).forEach(locale => g.mergeDateTimeFormat(locale, options.datetimeFormats[locale]));\n    }\n    if (options.numberFormats) {\n        Object.keys(options.numberFormats).forEach(locale => g.mergeNumberFormat(locale, options.numberFormats[locale]));\n    }\n    return g;\n}\n\n/**\n * Injection key for {@link useI18n}\n *\n * @remarks\n * The global injection key for I18n instances with `useI18n`. this injection key is used in Web Components.\n * Specify the i18n instance created by {@link createI18n} together with `provide` function.\n *\n * @VueI18nGeneral\n */\nconst I18nInjectionKey = \n/* #__PURE__*/ makeSymbol('global-vue-i18n');\n// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/explicit-module-boundary-types\nfunction createI18n(options = {}, VueI18nLegacy) {\n    // prettier-ignore\n    const __legacyMode = __VUE_I18N_LEGACY_API__ && isBoolean(options.legacy)\n            ? options.legacy\n            : __VUE_I18N_LEGACY_API__;\n    // prettier-ignore\n    const __globalInjection = isBoolean(options.globalInjection)\n        ? options.globalInjection\n        : true;\n    // prettier-ignore\n    const __allowComposition = __VUE_I18N_LEGACY_API__ && __legacyMode\n            ? !!options.allowComposition\n            : true;\n    const __instances = new Map();\n    const [globalScope, __global] = createGlobal(options, __legacyMode);\n    const symbol = /* #__PURE__*/ makeSymbol((process.env.NODE_ENV !== 'production') ? 'vue-i18n' : '');\n    if ((process.env.NODE_ENV !== 'production')) {\n        if (__legacyMode && __allowComposition && !false) {\n            warn(getWarnMessage(I18nWarnCodes.NOTICE_DROP_ALLOW_COMPOSITION));\n        }\n    }\n    function __getInstance(component) {\n        return __instances.get(component) || null;\n    }\n    function __setInstance(component, instance) {\n        __instances.set(component, instance);\n    }\n    function __deleteInstance(component) {\n        __instances.delete(component);\n    }\n    {\n        const i18n = {\n            // mode\n            get mode() {\n                return __VUE_I18N_LEGACY_API__ && __legacyMode\n                    ? 'legacy'\n                    : 'composition';\n            },\n            // allowComposition\n            get allowComposition() {\n                return __allowComposition;\n            },\n            // install plugin\n            async install(app, ...options) {\n                if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) &&\n                    !false) {\n                    app.__VUE_I18N__ = i18n;\n                }\n                // setup global provider\n                app.__VUE_I18N_SYMBOL__ = symbol;\n                app.provide(app.__VUE_I18N_SYMBOL__, i18n);\n                // set composer & vuei18n extend hook options from plugin options\n                if (isPlainObject(options[0])) {\n                    const opts = options[0];\n                    i18n.__composerExtend =\n                        opts.__composerExtend;\n                    i18n.__vueI18nExtend =\n                        opts.__vueI18nExtend;\n                }\n                // global method and properties injection for Composition API\n                let globalReleaseHandler = null;\n                if (!__legacyMode && __globalInjection) {\n                    globalReleaseHandler = injectGlobalFields(app, i18n.global);\n                }\n                // install built-in components and directive\n                if (__VUE_I18N_FULL_INSTALL__) {\n                    apply(app, i18n, ...options);\n                }\n                // setup mixin for Legacy API\n                if (__VUE_I18N_LEGACY_API__ && __legacyMode) {\n                    app.mixin(defineMixin(__global, __global.__composer, i18n));\n                }\n                // release global scope\n                const unmountApp = app.unmount;\n                app.unmount = () => {\n                    globalReleaseHandler && globalReleaseHandler();\n                    i18n.dispose();\n                    unmountApp();\n                };\n                // setup vue-devtools plugin\n                if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) && !false) {\n                    const ret = await enableDevTools(app, i18n);\n                    if (!ret) {\n                        throw createI18nError(I18nErrorCodes.CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN);\n                    }\n                    const emitter = createEmitter();\n                    if (__legacyMode) {\n                        const _vueI18n = __global;\n                        _vueI18n.__enableEmitter && _vueI18n.__enableEmitter(emitter);\n                    }\n                    else {\n                        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n                        const _composer = __global;\n                        _composer[EnableEmitter] && _composer[EnableEmitter](emitter);\n                    }\n                    emitter.on('*', addTimelineEvent);\n                }\n            },\n            // global accessor\n            get global() {\n                return __global;\n            },\n            dispose() {\n                globalScope.stop();\n            },\n            // @internal\n            __instances,\n            // @internal\n            __getInstance,\n            // @internal\n            __setInstance,\n            // @internal\n            __deleteInstance\n        };\n        return i18n;\n    }\n}\n// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types\nfunction useI18n(options = {}) {\n    const instance = getCurrentInstance();\n    if (instance == null) {\n        throw createI18nError(I18nErrorCodes.MUST_BE_CALL_SETUP_TOP);\n    }\n    if (!instance.isCE &&\n        instance.appContext.app != null &&\n        !instance.appContext.app.__VUE_I18N_SYMBOL__) {\n        throw createI18nError(I18nErrorCodes.NOT_INSTALLED);\n    }\n    const i18n = getI18nInstance(instance);\n    const gl = getGlobalComposer(i18n);\n    const componentOptions = getComponentOptions(instance);\n    const scope = getScope(options, componentOptions);\n    if (__VUE_I18N_LEGACY_API__) {\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        if (i18n.mode === 'legacy' && !options.__useComponent) {\n            if (!i18n.allowComposition) {\n                throw createI18nError(I18nErrorCodes.NOT_AVAILABLE_IN_LEGACY_MODE);\n            }\n            return useI18nForLegacy(instance, scope, gl, options);\n        }\n    }\n    if (scope === 'global') {\n        adjustI18nResources(gl, options, componentOptions);\n        return gl;\n    }\n    if (scope === 'parent') {\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        let composer = getComposer(i18n, instance, options.__useComponent);\n        if (composer == null) {\n            if ((process.env.NODE_ENV !== 'production')) {\n                warn(getWarnMessage(I18nWarnCodes.NOT_FOUND_PARENT_SCOPE));\n            }\n            composer = gl;\n        }\n        return composer;\n    }\n    const i18nInternal = i18n;\n    let composer = i18nInternal.__getInstance(instance);\n    if (composer == null) {\n        const composerOptions = assign({}, options);\n        if ('__i18n' in componentOptions) {\n            composerOptions.__i18n = componentOptions.__i18n;\n        }\n        if (gl) {\n            composerOptions.__root = gl;\n        }\n        composer = createComposer(composerOptions);\n        if (i18nInternal.__composerExtend) {\n            composer[DisposeSymbol] =\n                i18nInternal.__composerExtend(composer);\n        }\n        setupLifeCycle(i18nInternal, instance, composer);\n        i18nInternal.__setInstance(instance, composer);\n    }\n    return composer;\n}\n/**\n * Cast to VueI18n legacy compatible type\n *\n * @remarks\n * This API is provided only with [vue-i18n-bridge](https://vue-i18n.intlify.dev/guide/migration/ways.html#what-is-vue-i18n-bridge).\n *\n * The purpose of this function is to convert an {@link I18n} instance created with {@link createI18n | createI18n(legacy: true)} into a `vue-i18n@v8.x` compatible instance of `new VueI18n` in a TypeScript environment.\n *\n * @param i18n - An instance of {@link I18n}\n * @returns A i18n instance which is casted to {@link VueI18n} type\n *\n * @VueI18nTip\n * :new: provided by **vue-i18n-bridge only**\n *\n * @VueI18nGeneral\n */\nconst castToVueI18n = /* #__PURE__*/ (i18n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\n) => {\n    if (!(__VUE_I18N_BRIDGE__ in i18n)) {\n        throw createI18nError(I18nErrorCodes.NOT_COMPATIBLE_LEGACY_VUE_I18N);\n    }\n    return i18n;\n};\nfunction createGlobal(options, legacyMode, VueI18nLegacy // eslint-disable-line @typescript-eslint/no-explicit-any\n) {\n    const scope = effectScope();\n    {\n        const obj = __VUE_I18N_LEGACY_API__ && legacyMode\n            ? scope.run(() => createVueI18n(options))\n            : scope.run(() => createComposer(options));\n        if (obj == null) {\n            throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);\n        }\n        return [scope, obj];\n    }\n}\nfunction getI18nInstance(instance) {\n    {\n        const i18n = inject(!instance.isCE\n            ? instance.appContext.app.__VUE_I18N_SYMBOL__\n            : I18nInjectionKey);\n        /* istanbul ignore if */\n        if (!i18n) {\n            throw createI18nError(!instance.isCE\n                ? I18nErrorCodes.UNEXPECTED_ERROR\n                : I18nErrorCodes.NOT_INSTALLED_WITH_PROVIDE);\n        }\n        return i18n;\n    }\n}\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction getScope(options, componentOptions) {\n    // prettier-ignore\n    return isEmptyObject(options)\n        ? ('__i18n' in componentOptions)\n            ? 'local'\n            : 'global'\n        : !options.useScope\n            ? 'local'\n            : options.useScope;\n}\nfunction getGlobalComposer(i18n) {\n    // prettier-ignore\n    return i18n.mode === 'composition'\n            ? i18n.global\n            : i18n.global.__composer\n        ;\n}\nfunction getComposer(i18n, target, useComponent = false) {\n    let composer = null;\n    const root = target.root;\n    let current = getParentComponentInstance(target, useComponent);\n    while (current != null) {\n        const i18nInternal = i18n;\n        if (i18n.mode === 'composition') {\n            composer = i18nInternal.__getInstance(current);\n        }\n        else {\n            if (__VUE_I18N_LEGACY_API__) {\n                const vueI18n = i18nInternal.__getInstance(current);\n                if (vueI18n != null) {\n                    composer = vueI18n\n                        .__composer;\n                    if (useComponent &&\n                        composer &&\n                        !composer[InejctWithOptionSymbol] // eslint-disable-line @typescript-eslint/no-explicit-any\n                    ) {\n                        composer = null;\n                    }\n                }\n            }\n        }\n        if (composer != null) {\n            break;\n        }\n        if (root === current) {\n            break;\n        }\n        current = current.parent;\n    }\n    return composer;\n}\nfunction getParentComponentInstance(target, useComponent = false) {\n    if (target == null) {\n        return null;\n    }\n    {\n        // if `useComponent: true` will be specified, we get lexical scope owner instance for use-case slots\n        return !useComponent\n            ? target.parent\n            : target.vnode.ctx || target.parent; // eslint-disable-line @typescript-eslint/no-explicit-any\n    }\n}\nfunction setupLifeCycle(i18n, target, composer) {\n    let emitter = null;\n    {\n        onMounted(() => {\n            // inject composer instance to DOM for intlify-devtools\n            if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) &&\n                !false &&\n                target.vnode.el) {\n                target.vnode.el.__VUE_I18N__ = composer;\n                emitter = createEmitter();\n                // eslint-disable-next-line @typescript-eslint/no-explicit-any\n                const _composer = composer;\n                _composer[EnableEmitter] && _composer[EnableEmitter](emitter);\n                emitter.on('*', addTimelineEvent);\n            }\n        }, target);\n        onUnmounted(() => {\n            // eslint-disable-next-line @typescript-eslint/no-explicit-any\n            const _composer = composer;\n            // remove composer instance from DOM for intlify-devtools\n            if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) &&\n                !false &&\n                target.vnode.el &&\n                target.vnode.el.__VUE_I18N__) {\n                emitter && emitter.off('*', addTimelineEvent);\n                _composer[DisableEmitter] && _composer[DisableEmitter]();\n                delete target.vnode.el.__VUE_I18N__;\n            }\n            i18n.__deleteInstance(target);\n            // dispose extended resources\n            const dispose = _composer[DisposeSymbol];\n            if (dispose) {\n                dispose();\n                delete _composer[DisposeSymbol];\n            }\n        }, target);\n    }\n}\nfunction useI18nForLegacy(instance, scope, root, options = {} // eslint-disable-line @typescript-eslint/no-explicit-any\n) {\n    const isLocalScope = scope === 'local';\n    const _composer = shallowRef(null);\n    if (isLocalScope &&\n        instance.proxy &&\n        !(instance.proxy.$options.i18n || instance.proxy.$options.__i18n)) {\n        throw createI18nError(I18nErrorCodes.MUST_DEFINE_I18N_OPTION_IN_ALLOW_COMPOSITION);\n    }\n    const _inheritLocale = isBoolean(options.inheritLocale)\n        ? options.inheritLocale\n        : !isString(options.locale);\n    const _locale = ref(\n    // prettier-ignore\n    !isLocalScope || _inheritLocale\n        ? root.locale.value\n        : isString(options.locale)\n            ? options.locale\n            : DEFAULT_LOCALE);\n    const _fallbackLocale = ref(\n    // prettier-ignore\n    !isLocalScope || _inheritLocale\n        ? root.fallbackLocale.value\n        : isString(options.fallbackLocale) ||\n            isArray(options.fallbackLocale) ||\n            isPlainObject(options.fallbackLocale) ||\n            options.fallbackLocale === false\n            ? options.fallbackLocale\n            : _locale.value);\n    const _messages = ref(getLocaleMessages(_locale.value, options));\n    // prettier-ignore\n    const _datetimeFormats = ref(isPlainObject(options.datetimeFormats)\n        ? options.datetimeFormats\n        : { [_locale.value]: {} });\n    // prettier-ignore\n    const _numberFormats = ref(isPlainObject(options.numberFormats)\n        ? options.numberFormats\n        : { [_locale.value]: {} });\n    // prettier-ignore\n    const _missingWarn = isLocalScope\n        ? root.missingWarn\n        : isBoolean(options.missingWarn) || isRegExp(options.missingWarn)\n            ? options.missingWarn\n            : true;\n    // prettier-ignore\n    const _fallbackWarn = isLocalScope\n        ? root.fallbackWarn\n        : isBoolean(options.fallbackWarn) || isRegExp(options.fallbackWarn)\n            ? options.fallbackWarn\n            : true;\n    // prettier-ignore\n    const _fallbackRoot = isLocalScope\n        ? root.fallbackRoot\n        : isBoolean(options.fallbackRoot)\n            ? options.fallbackRoot\n            : true;\n    // configure fall back to root\n    const _fallbackFormat = !!options.fallbackFormat;\n    // runtime missing\n    const _missing = isFunction(options.missing) ? options.missing : null;\n    // postTranslation handler\n    const _postTranslation = isFunction(options.postTranslation)\n        ? options.postTranslation\n        : null;\n    // prettier-ignore\n    const _warnHtmlMessage = isLocalScope\n        ? root.warnHtmlMessage\n        : isBoolean(options.warnHtmlMessage)\n            ? options.warnHtmlMessage\n            : true;\n    const _escapeParameter = !!options.escapeParameter;\n    // prettier-ignore\n    const _modifiers = isLocalScope\n        ? root.modifiers\n        : isPlainObject(options.modifiers)\n            ? options.modifiers\n            : {};\n    // pluralRules\n    const _pluralRules = options.pluralRules || (isLocalScope && root.pluralRules);\n    // track reactivity\n    function trackReactivityValues() {\n        return [\n            _locale.value,\n            _fallbackLocale.value,\n            _messages.value,\n            _datetimeFormats.value,\n            _numberFormats.value\n        ];\n    }\n    // locale\n    const locale = computed({\n        get: () => {\n            return _composer.value ? _composer.value.locale.value : _locale.value;\n        },\n        set: val => {\n            if (_composer.value) {\n                _composer.value.locale.value = val;\n            }\n            _locale.value = val;\n        }\n    });\n    // fallbackLocale\n    const fallbackLocale = computed({\n        get: () => {\n            return _composer.value\n                ? _composer.value.fallbackLocale.value\n                : _fallbackLocale.value;\n        },\n        set: val => {\n            if (_composer.value) {\n                _composer.value.fallbackLocale.value = val;\n            }\n            _fallbackLocale.value = val;\n        }\n    });\n    // messages\n    const messages = computed(() => {\n        if (_composer.value) {\n            // eslint-disable-next-line @typescript-eslint/no-explicit-any\n            return _composer.value.messages.value;\n        }\n        else {\n            // eslint-disable-next-line @typescript-eslint/no-explicit-any\n            return _messages.value;\n        }\n    });\n    const datetimeFormats = computed(() => _datetimeFormats.value);\n    const numberFormats = computed(() => _numberFormats.value);\n    function getPostTranslationHandler() {\n        return _composer.value\n            ? _composer.value.getPostTranslationHandler()\n            : _postTranslation;\n    }\n    function setPostTranslationHandler(handler) {\n        if (_composer.value) {\n            _composer.value.setPostTranslationHandler(handler);\n        }\n    }\n    function getMissingHandler() {\n        return _composer.value ? _composer.value.getMissingHandler() : _missing;\n    }\n    function setMissingHandler(handler) {\n        if (_composer.value) {\n            _composer.value.setMissingHandler(handler);\n        }\n    }\n    function warpWithDeps(fn) {\n        trackReactivityValues();\n        return fn();\n    }\n    function t(...args) {\n        return _composer.value\n            ? warpWithDeps(() => Reflect.apply(_composer.value.t, null, [...args]))\n            : warpWithDeps(() => '');\n    }\n    function rt(...args) {\n        return _composer.value\n            ? Reflect.apply(_composer.value.rt, null, [...args])\n            : '';\n    }\n    function d(...args) {\n        return _composer.value\n            ? warpWithDeps(() => Reflect.apply(_composer.value.d, null, [...args]))\n            : warpWithDeps(() => '');\n    }\n    function n(...args) {\n        return _composer.value\n            ? warpWithDeps(() => Reflect.apply(_composer.value.n, null, [...args]))\n            : warpWithDeps(() => '');\n    }\n    function tm(key) {\n        return _composer.value ? _composer.value.tm(key) : {};\n    }\n    function te(key, locale) {\n        return _composer.value ? _composer.value.te(key, locale) : false;\n    }\n    function getLocaleMessage(locale) {\n        return _composer.value ? _composer.value.getLocaleMessage(locale) : {};\n    }\n    function setLocaleMessage(locale, message) {\n        if (_composer.value) {\n            _composer.value.setLocaleMessage(locale, message);\n            _messages.value[locale] = message;\n        }\n    }\n    function mergeLocaleMessage(locale, message) {\n        if (_composer.value) {\n            _composer.value.mergeLocaleMessage(locale, message);\n        }\n    }\n    function getDateTimeFormat(locale) {\n        return _composer.value ? _composer.value.getDateTimeFormat(locale) : {};\n    }\n    function setDateTimeFormat(locale, format) {\n        if (_composer.value) {\n            _composer.value.setDateTimeFormat(locale, format);\n            _datetimeFormats.value[locale] = format;\n        }\n    }\n    function mergeDateTimeFormat(locale, format) {\n        if (_composer.value) {\n            _composer.value.mergeDateTimeFormat(locale, format);\n        }\n    }\n    function getNumberFormat(locale) {\n        return _composer.value ? _composer.value.getNumberFormat(locale) : {};\n    }\n    function setNumberFormat(locale, format) {\n        if (_composer.value) {\n            _composer.value.setNumberFormat(locale, format);\n            _numberFormats.value[locale] = format;\n        }\n    }\n    function mergeNumberFormat(locale, format) {\n        if (_composer.value) {\n            _composer.value.mergeNumberFormat(locale, format);\n        }\n    }\n    const wrapper = {\n        get id() {\n            return _composer.value ? _composer.value.id : -1;\n        },\n        locale,\n        fallbackLocale,\n        messages,\n        datetimeFormats,\n        numberFormats,\n        get inheritLocale() {\n            return _composer.value ? _composer.value.inheritLocale : _inheritLocale;\n        },\n        set inheritLocale(val) {\n            if (_composer.value) {\n                _composer.value.inheritLocale = val;\n            }\n        },\n        get availableLocales() {\n            return _composer.value\n                ? _composer.value.availableLocales\n                : Object.keys(_messages.value);\n        },\n        get modifiers() {\n            return (_composer.value ? _composer.value.modifiers : _modifiers);\n        },\n        get pluralRules() {\n            return (_composer.value ? _composer.value.pluralRules : _pluralRules);\n        },\n        get isGlobal() {\n            return _composer.value ? _composer.value.isGlobal : false;\n        },\n        get missingWarn() {\n            return _composer.value ? _composer.value.missingWarn : _missingWarn;\n        },\n        set missingWarn(val) {\n            if (_composer.value) {\n                _composer.value.missingWarn = val;\n            }\n        },\n        get fallbackWarn() {\n            return _composer.value ? _composer.value.fallbackWarn : _fallbackWarn;\n        },\n        set fallbackWarn(val) {\n            if (_composer.value) {\n                _composer.value.missingWarn = val;\n            }\n        },\n        get fallbackRoot() {\n            return _composer.value ? _composer.value.fallbackRoot : _fallbackRoot;\n        },\n        set fallbackRoot(val) {\n            if (_composer.value) {\n                _composer.value.fallbackRoot = val;\n            }\n        },\n        get fallbackFormat() {\n            return _composer.value ? _composer.value.fallbackFormat : _fallbackFormat;\n        },\n        set fallbackFormat(val) {\n            if (_composer.value) {\n                _composer.value.fallbackFormat = val;\n            }\n        },\n        get warnHtmlMessage() {\n            return _composer.value\n                ? _composer.value.warnHtmlMessage\n                : _warnHtmlMessage;\n        },\n        set warnHtmlMessage(val) {\n            if (_composer.value) {\n                _composer.value.warnHtmlMessage = val;\n            }\n        },\n        get escapeParameter() {\n            return _composer.value\n                ? _composer.value.escapeParameter\n                : _escapeParameter;\n        },\n        set escapeParameter(val) {\n            if (_composer.value) {\n                _composer.value.escapeParameter = val;\n            }\n        },\n        t,\n        getPostTranslationHandler,\n        setPostTranslationHandler,\n        getMissingHandler,\n        setMissingHandler,\n        rt,\n        d,\n        n,\n        tm,\n        te,\n        getLocaleMessage,\n        setLocaleMessage,\n        mergeLocaleMessage,\n        getDateTimeFormat,\n        setDateTimeFormat,\n        mergeDateTimeFormat,\n        getNumberFormat,\n        setNumberFormat,\n        mergeNumberFormat\n    };\n    function sync(composer) {\n        composer.locale.value = _locale.value;\n        composer.fallbackLocale.value = _fallbackLocale.value;\n        Object.keys(_messages.value).forEach(locale => {\n            composer.mergeLocaleMessage(locale, _messages.value[locale]);\n        });\n        Object.keys(_datetimeFormats.value).forEach(locale => {\n            composer.mergeDateTimeFormat(locale, _datetimeFormats.value[locale]);\n        });\n        Object.keys(_numberFormats.value).forEach(locale => {\n            composer.mergeNumberFormat(locale, _numberFormats.value[locale]);\n        });\n        composer.escapeParameter = _escapeParameter;\n        composer.fallbackFormat = _fallbackFormat;\n        composer.fallbackRoot = _fallbackRoot;\n        composer.fallbackWarn = _fallbackWarn;\n        composer.missingWarn = _missingWarn;\n        composer.warnHtmlMessage = _warnHtmlMessage;\n    }\n    onBeforeMount(() => {\n        if (instance.proxy == null || instance.proxy.$i18n == null) {\n            throw createI18nError(I18nErrorCodes.NOT_AVAILABLE_COMPOSITION_IN_LEGACY);\n        }\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        const composer = (_composer.value = instance.proxy.$i18n\n            .__composer);\n        if (scope === 'global') {\n            _locale.value = composer.locale.value;\n            _fallbackLocale.value = composer.fallbackLocale.value;\n            _messages.value = composer.messages.value;\n            _datetimeFormats.value = composer.datetimeFormats.value;\n            _numberFormats.value = composer.numberFormats.value;\n        }\n        else if (isLocalScope) {\n            sync(composer);\n        }\n    });\n    return wrapper;\n}\nconst globalExportProps = [\n    'locale',\n    'fallbackLocale',\n    'availableLocales'\n];\nconst globalExportMethods = ['t', 'rt', 'd', 'n', 'tm', 'te']\n    ;\nfunction injectGlobalFields(app, composer) {\n    const i18n = Object.create(null);\n    globalExportProps.forEach(prop => {\n        const desc = Object.getOwnPropertyDescriptor(composer, prop);\n        if (!desc) {\n            throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);\n        }\n        const wrap = isRef(desc.value) // check computed props\n            ? {\n                get() {\n                    return desc.value.value;\n                },\n                // eslint-disable-next-line @typescript-eslint/no-explicit-any\n                set(val) {\n                    desc.value.value = val;\n                }\n            }\n            : {\n                get() {\n                    return desc.get && desc.get();\n                }\n            };\n        Object.defineProperty(i18n, prop, wrap);\n    });\n    app.config.globalProperties.$i18n = i18n;\n    globalExportMethods.forEach(method => {\n        const desc = Object.getOwnPropertyDescriptor(composer, method);\n        if (!desc || !desc.value) {\n            throw createI18nError(I18nErrorCodes.UNEXPECTED_ERROR);\n        }\n        Object.defineProperty(app.config.globalProperties, `$${method}`, desc);\n    });\n    const dispose = () => {\n        // eslint-disable-next-line @typescript-eslint/no-explicit-any\n        delete app.config.globalProperties.$i18n;\n        globalExportMethods.forEach(method => {\n            // eslint-disable-next-line @typescript-eslint/no-explicit-any\n            delete app.config.globalProperties[`$${method}`];\n        });\n    };\n    return dispose;\n}\n\n{\n    initFeatureFlags();\n}\n// register message compiler at vue-i18n\nif (__INTLIFY_JIT_COMPILATION__) {\n    registerMessageCompiler(compile);\n}\nelse {\n    registerMessageCompiler(compileToFunction);\n}\n// register message resolver at vue-i18n\nregisterMessageResolver(resolveValue);\n// register fallback locale at vue-i18n\nregisterLocaleFallbacker(fallbackWithLocaleChain);\n// NOTE: experimental !!\nif ((process.env.NODE_ENV !== 'production') || __INTLIFY_PROD_DEVTOOLS__) {\n    const target = getGlobalThis();\n    target.__INTLIFY__ = true;\n    setDevToolsHook(target.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__);\n}\nif ((process.env.NODE_ENV !== 'production')) ;\n\nexport { DatetimeFormat, I18nD, I18nInjectionKey, I18nN, I18nT, NumberFormat, Translation, VERSION, castToVueI18n, createI18n, useI18n, vTDirective };\n","import { createI18n } from 'vue-i18n'\n\nimport en from './locale/en.json'\nimport nl from './locale/nl.json'\n\nconst instance = createI18n({\n    legacy: false,\n    locale: document.documentElement.lang ?? 'nl',\n    fallbackLocale: 'en',\n    messages: {\n        en: en,\n        nl: nl,\n    },\n    globalInjection: true,\n})\n\nexport default instance\n","/**\n * what-input - A global utility for tracking the current input method (mouse, keyboard or touch).\n * @version v5.2.12\n * @link https://github.com/ten1seven/what-input\n * @license MIT\n */\n(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine(\"whatInput\", [], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"whatInput\"] = factory();\n\telse\n\t\troot[\"whatInput\"] = factory();\n})(this, function() {\nreturn /******/ (function(modules) { // webpackBootstrap\n/******/ \t// The module cache\n/******/ \tvar installedModules = {};\n\n/******/ \t// The require function\n/******/ \tfunction __webpack_require__(moduleId) {\n\n/******/ \t\t// Check if module is in cache\n/******/ \t\tif(installedModules[moduleId])\n/******/ \t\t\treturn installedModules[moduleId].exports;\n\n/******/ \t\t// Create a new module (and put it into the cache)\n/******/ \t\tvar module = installedModules[moduleId] = {\n/******/ \t\t\texports: {},\n/******/ \t\t\tid: moduleId,\n/******/ \t\t\tloaded: false\n/******/ \t\t};\n\n/******/ \t\t// Execute the module function\n/******/ \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n/******/ \t\t// Flag the module as loaded\n/******/ \t\tmodule.loaded = true;\n\n/******/ \t\t// Return the exports of the module\n/******/ \t\treturn module.exports;\n/******/ \t}\n\n\n/******/ \t// expose the modules object (__webpack_modules__)\n/******/ \t__webpack_require__.m = modules;\n\n/******/ \t// expose the module cache\n/******/ \t__webpack_require__.c = installedModules;\n\n/******/ \t// __webpack_public_path__\n/******/ \t__webpack_require__.p = \"\";\n\n/******/ \t// Load entry module and return exports\n/******/ \treturn __webpack_require__(0);\n/******/ })\n/************************************************************************/\n/******/ ([\n/* 0 */\n/***/ (function(module, exports) {\n\n\t'use strict';\n\n\tmodule.exports = function () {\n\t  /*\n\t   * bail out if there is no document or window\n\t   * (i.e. in a node/non-DOM environment)\n\t   *\n\t   * Return a stubbed API instead\n\t   */\n\t  if (typeof document === 'undefined' || typeof window === 'undefined') {\n\t    return {\n\t      // always return \"initial\" because no interaction will ever be detected\n\t      ask: function ask() {\n\t        return 'initial';\n\t      },\n\n\t      // always return null\n\t      element: function element() {\n\t        return null;\n\t      },\n\n\t      // no-op\n\t      ignoreKeys: function ignoreKeys() {},\n\n\t      // no-op\n\t      specificKeys: function specificKeys() {},\n\n\t      // no-op\n\t      registerOnChange: function registerOnChange() {},\n\n\t      // no-op\n\t      unRegisterOnChange: function unRegisterOnChange() {}\n\t    };\n\t  }\n\n\t  /*\n\t   * variables\n\t   */\n\n\t  // cache document.documentElement\n\t  var docElem = document.documentElement;\n\n\t  // currently focused dom element\n\t  var currentElement = null;\n\n\t  // last used input type\n\t  var currentInput = 'initial';\n\n\t  // last used input intent\n\t  var currentIntent = currentInput;\n\n\t  // UNIX timestamp of current event\n\t  var currentTimestamp = Date.now();\n\n\t  // check for a `data-whatpersist` attribute on either the `html` or `body` elements, defaults to `true`\n\t  var shouldPersist = false;\n\n\t  // form input types\n\t  var formInputs = ['button', 'input', 'select', 'textarea'];\n\n\t  // empty array for holding callback functions\n\t  var functionList = [];\n\n\t  // list of modifier keys commonly used with the mouse and\n\t  // can be safely ignored to prevent false keyboard detection\n\t  var ignoreMap = [16, // shift\n\t  17, // control\n\t  18, // alt\n\t  91, // Windows key / left Apple cmd\n\t  93 // Windows menu / right Apple cmd\n\t  ];\n\n\t  var specificMap = [];\n\n\t  // mapping of events to input types\n\t  var inputMap = {\n\t    keydown: 'keyboard',\n\t    keyup: 'keyboard',\n\t    mousedown: 'mouse',\n\t    mousemove: 'mouse',\n\t    MSPointerDown: 'pointer',\n\t    MSPointerMove: 'pointer',\n\t    pointerdown: 'pointer',\n\t    pointermove: 'pointer',\n\t    touchstart: 'touch',\n\t    touchend: 'touch'\n\n\t    // boolean: true if the page is being scrolled\n\t  };var isScrolling = false;\n\n\t  // store current mouse position\n\t  var mousePos = {\n\t    x: null,\n\t    y: null\n\n\t    // map of IE 10 pointer events\n\t  };var pointerMap = {\n\t    2: 'touch',\n\t    3: 'touch', // treat pen like touch\n\t    4: 'mouse'\n\n\t    // check support for passive event listeners\n\t  };var supportsPassive = false;\n\n\t  try {\n\t    var opts = Object.defineProperty({}, 'passive', {\n\t      get: function get() {\n\t        supportsPassive = true;\n\t      }\n\t    });\n\n\t    window.addEventListener('test', null, opts);\n\t  } catch (e) {}\n\t  // fail silently\n\n\n\t  /*\n\t   * set up\n\t   */\n\n\t  var setUp = function setUp() {\n\t    // add correct mouse wheel event mapping to `inputMap`\n\t    inputMap[detectWheel()] = 'mouse';\n\n\t    addListeners();\n\t  };\n\n\t  /*\n\t   * events\n\t   */\n\n\t  var addListeners = function addListeners() {\n\t    // `pointermove`, `MSPointerMove`, `mousemove` and mouse wheel event binding\n\t    // can only demonstrate potential, but not actual, interaction\n\t    // and are treated separately\n\t    var options = supportsPassive ? { passive: true, capture: true } : true;\n\n\t    document.addEventListener('DOMContentLoaded', setPersist, true);\n\n\t    // pointer events (mouse, pen, touch)\n\t    if (window.PointerEvent) {\n\t      window.addEventListener('pointerdown', setInput, true);\n\t      window.addEventListener('pointermove', setIntent, true);\n\t    } else if (window.MSPointerEvent) {\n\t      window.addEventListener('MSPointerDown', setInput, true);\n\t      window.addEventListener('MSPointerMove', setIntent, true);\n\t    } else {\n\t      // mouse events\n\t      window.addEventListener('mousedown', setInput, true);\n\t      window.addEventListener('mousemove', setIntent, true);\n\n\t      // touch events\n\t      if ('ontouchstart' in window) {\n\t        window.addEventListener('touchstart', setInput, options);\n\t        window.addEventListener('touchend', setInput, true);\n\t      }\n\t    }\n\n\t    // mouse wheel\n\t    window.addEventListener(detectWheel(), setIntent, options);\n\n\t    // keyboard events\n\t    window.addEventListener('keydown', setInput, true);\n\t    window.addEventListener('keyup', setInput, true);\n\n\t    // focus events\n\t    window.addEventListener('focusin', setElement, true);\n\t    window.addEventListener('focusout', clearElement, true);\n\t  };\n\n\t  // checks if input persistence should happen and\n\t  // get saved state from session storage if true (defaults to `false`)\n\t  var setPersist = function setPersist() {\n\t    shouldPersist = !(docElem.getAttribute('data-whatpersist') === 'false' || document.body.getAttribute('data-whatpersist') === 'false');\n\n\t    if (shouldPersist) {\n\t      // check for session variables and use if available\n\t      try {\n\t        if (window.sessionStorage.getItem('what-input')) {\n\t          currentInput = window.sessionStorage.getItem('what-input');\n\t        }\n\n\t        if (window.sessionStorage.getItem('what-intent')) {\n\t          currentIntent = window.sessionStorage.getItem('what-intent');\n\t        }\n\t      } catch (e) {\n\t        // fail silently\n\t      }\n\t    }\n\n\t    // always run these so at least `initial` state is set\n\t    doUpdate('input');\n\t    doUpdate('intent');\n\t  };\n\n\t  // checks conditions before updating new input\n\t  var setInput = function setInput(event) {\n\t    var eventKey = event.which;\n\t    var value = inputMap[event.type];\n\n\t    if (value === 'pointer') {\n\t      value = pointerType(event);\n\t    }\n\n\t    var ignoreMatch = !specificMap.length && ignoreMap.indexOf(eventKey) === -1;\n\n\t    var specificMatch = specificMap.length && specificMap.indexOf(eventKey) !== -1;\n\n\t    var shouldUpdate = value === 'keyboard' && eventKey && (ignoreMatch || specificMatch) || value === 'mouse' || value === 'touch';\n\n\t    // prevent touch detection from being overridden by event execution order\n\t    if (validateTouch(value)) {\n\t      shouldUpdate = false;\n\t    }\n\n\t    if (shouldUpdate && currentInput !== value) {\n\t      currentInput = value;\n\n\t      persistInput('input', currentInput);\n\t      doUpdate('input');\n\t    }\n\n\t    if (shouldUpdate && currentIntent !== value) {\n\t      // preserve intent for keyboard interaction with form fields\n\t      var activeElem = document.activeElement;\n\t      var notFormInput = activeElem && activeElem.nodeName && (formInputs.indexOf(activeElem.nodeName.toLowerCase()) === -1 || activeElem.nodeName.toLowerCase() === 'button' && !checkClosest(activeElem, 'form'));\n\n\t      if (notFormInput) {\n\t        currentIntent = value;\n\n\t        persistInput('intent', currentIntent);\n\t        doUpdate('intent');\n\t      }\n\t    }\n\t  };\n\n\t  // updates the doc and `inputTypes` array with new input\n\t  var doUpdate = function doUpdate(which) {\n\t    docElem.setAttribute('data-what' + which, which === 'input' ? currentInput : currentIntent);\n\n\t    fireFunctions(which);\n\t  };\n\n\t  // updates input intent for `mousemove` and `pointermove`\n\t  var setIntent = function setIntent(event) {\n\t    var value = inputMap[event.type];\n\n\t    if (value === 'pointer') {\n\t      value = pointerType(event);\n\t    }\n\n\t    // test to see if `mousemove` happened relative to the screen to detect scrolling versus mousemove\n\t    detectScrolling(event);\n\n\t    // only execute if scrolling isn't happening\n\t    if ((!isScrolling && !validateTouch(value) || isScrolling && event.type === 'wheel' || event.type === 'mousewheel' || event.type === 'DOMMouseScroll') && currentIntent !== value) {\n\t      currentIntent = value;\n\n\t      persistInput('intent', currentIntent);\n\t      doUpdate('intent');\n\t    }\n\t  };\n\n\t  var setElement = function setElement(event) {\n\t    if (!event.target.nodeName) {\n\t      // If nodeName is undefined, clear the element\n\t      // This can happen if click inside an <svg> element.\n\t      clearElement();\n\t      return;\n\t    }\n\n\t    currentElement = event.target.nodeName.toLowerCase();\n\t    docElem.setAttribute('data-whatelement', currentElement);\n\n\t    if (event.target.classList && event.target.classList.length) {\n\t      docElem.setAttribute('data-whatclasses', event.target.classList.toString().replace(' ', ','));\n\t    }\n\t  };\n\n\t  var clearElement = function clearElement() {\n\t    currentElement = null;\n\n\t    docElem.removeAttribute('data-whatelement');\n\t    docElem.removeAttribute('data-whatclasses');\n\t  };\n\n\t  var persistInput = function persistInput(which, value) {\n\t    if (shouldPersist) {\n\t      try {\n\t        window.sessionStorage.setItem('what-' + which, value);\n\t      } catch (e) {\n\t        // fail silently\n\t      }\n\t    }\n\t  };\n\n\t  /*\n\t   * utilities\n\t   */\n\n\t  var pointerType = function pointerType(event) {\n\t    if (typeof event.pointerType === 'number') {\n\t      return pointerMap[event.pointerType];\n\t    } else {\n\t      // treat pen like touch\n\t      return event.pointerType === 'pen' ? 'touch' : event.pointerType;\n\t    }\n\t  };\n\n\t  // prevent touch detection from being overridden by event execution order\n\t  var validateTouch = function validateTouch(value) {\n\t    var timestamp = Date.now();\n\n\t    var touchIsValid = value === 'mouse' && currentInput === 'touch' && timestamp - currentTimestamp < 200;\n\n\t    currentTimestamp = timestamp;\n\n\t    return touchIsValid;\n\t  };\n\n\t  // detect version of mouse wheel event to use\n\t  // via https://developer.mozilla.org/en-US/docs/Web/API/Element/wheel_event\n\t  var detectWheel = function detectWheel() {\n\t    var wheelType = null;\n\n\t    // Modern browsers support \"wheel\"\n\t    if ('onwheel' in document.createElement('div')) {\n\t      wheelType = 'wheel';\n\t    } else {\n\t      // Webkit and IE support at least \"mousewheel\"\n\t      // or assume that remaining browsers are older Firefox\n\t      wheelType = document.onmousewheel !== undefined ? 'mousewheel' : 'DOMMouseScroll';\n\t    }\n\n\t    return wheelType;\n\t  };\n\n\t  // runs callback functions\n\t  var fireFunctions = function fireFunctions(type) {\n\t    for (var i = 0, len = functionList.length; i < len; i++) {\n\t      if (functionList[i].type === type) {\n\t        functionList[i].fn.call(undefined, type === 'input' ? currentInput : currentIntent);\n\t      }\n\t    }\n\t  };\n\n\t  // finds matching element in an object\n\t  var objPos = function objPos(match) {\n\t    for (var i = 0, len = functionList.length; i < len; i++) {\n\t      if (functionList[i].fn === match) {\n\t        return i;\n\t      }\n\t    }\n\t  };\n\n\t  var detectScrolling = function detectScrolling(event) {\n\t    if (mousePos.x !== event.screenX || mousePos.y !== event.screenY) {\n\t      isScrolling = false;\n\n\t      mousePos.x = event.screenX;\n\t      mousePos.y = event.screenY;\n\t    } else {\n\t      isScrolling = true;\n\t    }\n\t  };\n\n\t  // manual version of `closest()`\n\t  var checkClosest = function checkClosest(elem, tag) {\n\t    var ElementPrototype = window.Element.prototype;\n\n\t    if (!ElementPrototype.matches) {\n\t      ElementPrototype.matches = ElementPrototype.msMatchesSelector || ElementPrototype.webkitMatchesSelector;\n\t    }\n\n\t    if (!ElementPrototype.closest) {\n\t      do {\n\t        if (elem.matches(tag)) {\n\t          return elem;\n\t        }\n\n\t        elem = elem.parentElement || elem.parentNode;\n\t      } while (elem !== null && elem.nodeType === 1);\n\n\t      return null;\n\t    } else {\n\t      return elem.closest(tag);\n\t    }\n\t  };\n\n\t  /*\n\t   * init\n\t   */\n\n\t  // don't start script unless browser cuts the mustard\n\t  // (also passes if polyfills are used)\n\t  if ('addEventListener' in window && Array.prototype.indexOf) {\n\t    setUp();\n\t  }\n\n\t  /*\n\t   * api\n\t   */\n\n\t  return {\n\t    // returns string: the current input type\n\t    // opt: 'intent'|'input'\n\t    // 'input' (default): returns the same value as the `data-whatinput` attribute\n\t    // 'intent': includes `data-whatintent` value if it's different than `data-whatinput`\n\t    ask: function ask(opt) {\n\t      return opt === 'intent' ? currentIntent : currentInput;\n\t    },\n\n\t    // returns string: the currently focused element or null\n\t    element: function element() {\n\t      return currentElement;\n\t    },\n\n\t    // overwrites ignored keys with provided array\n\t    ignoreKeys: function ignoreKeys(arr) {\n\t      ignoreMap = arr;\n\t    },\n\n\t    // overwrites specific char keys to update on\n\t    specificKeys: function specificKeys(arr) {\n\t      specificMap = arr;\n\t    },\n\n\t    // attach functions to input and intent \"events\"\n\t    // funct: function to fire on change\n\t    // eventType: 'input'|'intent'\n\t    registerOnChange: function registerOnChange(fn, eventType) {\n\t      functionList.push({\n\t        fn: fn,\n\t        type: eventType || 'input'\n\t      });\n\t    },\n\n\t    unRegisterOnChange: function unRegisterOnChange(fn) {\n\t      var position = objPos(fn);\n\n\t      if (position || position === 0) {\n\t        functionList.splice(position, 1);\n\t      }\n\t    },\n\n\t    clearStorage: function clearStorage() {\n\t      window.sessionStorage.clear();\n\t    }\n\t  };\n\t}();\n\n/***/ })\n/******/ ])\n});\n;","export function displayPrice(price: number|string, zeroValue: any = null): string|any {\n    price = Number(price)\n    if (price === 0 && zeroValue !== null){\n        // To be able to return a translation if the price is 0.\n        return zeroValue\n    }\n\n    return (price / 100).toLocaleString('nl-NL', { style: 'currency', currency: 'EUR' })\n}\n\nexport function discountPercentage(productPrice: number|string, productOriginalPrice: number|string): number {\n    var price = 0\n    var originalPrice = 0\n\n    if (typeof productPrice === 'string'){\n      price = parseInt(productPrice, 10)\n    } else {\n      price = productPrice\n    }\n\n    if (typeof productOriginalPrice === 'string'){\n      originalPrice = parseInt(productOriginalPrice, 10)\n    } else {\n      originalPrice = productOriginalPrice\n    }\n\n    if (price === originalPrice) {\n      return 0\n    }\n\n    return Math.round(((originalPrice - price) / originalPrice) * 100)\n  }\n","export function translate(k: string, replacements = {}) {\n    return (window as any).translate(k, replacements)\n}\n\nexport function generateRoute(name: string) {\n    return (window as any).generateRoute(name)\n}\n","export declare interface EventBus {\n\n    constructor(description: string): EventBus\n\n    on(type: string, listener: (event: Event) => void, replay: boolean): void\n    on(type: string, listener: (event: Event) => void): void\n\n    once(type: string, listener: (event: Event) => void): void\n\n    off(type: string, listener: (event: Event) => void): void\n\n    emit(type: string, data: any): boolean\n\n}\n\nconst eventbus: EventBus = (window as any).eventbus as EventBus\n\nexport default eventbus","import eventBus from '../eventbus'\n\nexport function emitEvent<T>(eventName: TrackingEvent, data: T) {\n    if (!eventBus) {\n        console.error('EventBus not found.')\n        return\n    }\n\n    if ((import.meta.env.MODE ?? '') === 'development') {\n        // Prevent emitting events in development mode but debug them instead.\n        printEvent(eventName, data)\n        return\n    }\n\n    eventBus.emit(eventName, data)\n}\n\nexport function printEvent<T>(eventName: TrackingEvent, data: T) {\n    try {\n        console.debug(\n            \"-------------------------\\n\",\n            \"Event name: \" + eventName + \"\\n\",\n            \"Event Data:\\n\", data ?? 'No data found in event', \"\\n\",\n            \"-------------------------\\n\",\n        )\n    } catch (e) {\n        console.error(`Failed to debug event '${eventName}': ${e}`)\n    }\n}\n\nexport const EventCheckoutStep: TrackingEvent = 'v1.checkout.step'\nexport const EventCartAdd: TrackingEvent = 'v1.cart.add'\nexport const EventCartRemove: TrackingEvent = 'v1.cart.remove'\nexport const EventCheckoutConfirmation: TrackingEvent = 'v1.checkout.confirmation'\nexport const EventProductClick: TrackingEvent = 'v1.product.click'\nexport const EventCollectionImpression: TrackingEvent = 'v1.collection.impression'\nexport const EventProductView: TrackingEvent = 'v1.product.view'\n\ntype TrackingEvent =\n    'v1.checkout.step' |\n    'v1.cart.add' |\n    'v1.cart.remove' |\n    'v1.checkout.confirmation' |\n    'v1.product.click' |\n    'v1.collection.impression' |\n    'v1.product.view'\n\nexport const CheckoutStepCart: CheckoutStep = 'cart'\nexport const CheckoutStepCredentials: CheckoutStep = 'credentials'\nexport const CheckoutStepPaymentSelection: CheckoutStep = 'payment-selection'\nexport const CheckoutStepCreateOrder: CheckoutStep = 'create-order'\nexport const CheckoutStepUpdateOrder: CheckoutStep = 'update-order'\n\ntype CheckoutStep = 'cart' | 'credentials' | 'payment-selection' | 'create-order' | 'update-order'\n\n\nexport interface EventProduct {\n    ID: string,\n    name: string,\n    variants: EventProductVariant[]\n    price: number,\n    attributes: { [key: string]: string },\n}\n\ninterface EventProductVariant {\n    ID: string\n    name: string,\n    price: number,\n    attributes: { [key: string]: string },\n}\n","const runningOnBrowser = typeof window !== \"undefined\";\n\nconst isBot =\n    (runningOnBrowser && !(\"onscroll\" in window)) ||\n    (typeof navigator !== \"undefined\" && /(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent));\n\nconst supportsIntersectionObserver = runningOnBrowser && \"IntersectionObserver\" in window;\n\nconst supportsClassList = runningOnBrowser && \"classList\" in document.createElement(\"p\");\n\nconst isHiDpi = runningOnBrowser && window.devicePixelRatio > 1;\n\nconst defaultSettings = {\n    elements_selector: \".lazy\",\n    container: isBot || runningOnBrowser ? document : null,\n    threshold: 300,\n    thresholds: null,\n    data_src: \"src\",\n    data_srcset: \"srcset\",\n    data_sizes: \"sizes\",\n    data_bg: \"bg\",\n    data_bg_hidpi: \"bg-hidpi\",\n    data_bg_multi: \"bg-multi\",\n    data_bg_multi_hidpi: \"bg-multi-hidpi\",\n    data_bg_set: \"bg-set\",\n    data_poster: \"poster\",\n    class_applied: \"applied\",\n    class_loading: \"loading\",\n    class_loaded: \"loaded\",\n    class_error: \"error\",\n    class_entered: \"entered\",\n    class_exited: \"exited\",\n    unobserve_completed: true,\n    unobserve_entered: false,\n    cancel_on_exit: true,\n    callback_enter: null,\n    callback_exit: null,\n    callback_applied: null,\n    callback_loading: null,\n    callback_loaded: null,\n    callback_error: null,\n    callback_finish: null,\n    callback_cancel: null,\n    use_native: false,\n    restore_on_error: false,\n};\n\nconst getExtendedSettings = (customSettings) => {\n    return Object.assign({}, defaultSettings, customSettings);\n};\n\n/* Creates instance and notifies it through the window element */\nconst createInstance = function(classObj, options) {\n    let event;\n    const eventString = \"LazyLoad::Initialized\";\n    const instance = new classObj(options);\n    try {\n        // Works in modern browsers\n        event = new CustomEvent(eventString, { detail: { instance } });\n    } catch (err) {\n        // Works in Internet Explorer (all versions)\n        event = document.createEvent(\"CustomEvent\");\n        event.initCustomEvent(eventString, false, false, { instance });\n    }\n    window.dispatchEvent(event);\n};\n\n/* Auto initialization of one or more instances of lazyload, depending on the \n    options passed in (plain object or an array) */\nconst autoInitialize = (classObj, options) => {\n    if (!options) {\n        return;\n    }\n    if (!options.length) {\n        // Plain object\n        createInstance(classObj, options);\n    } else {\n        // Array of objects\n        for (let i = 0, optionsItem; (optionsItem = options[i]); i += 1) {\n            createInstance(classObj, optionsItem);\n        }\n    }\n};\n\nconst SRC = \"src\";\nconst SRCSET = \"srcset\";\nconst SIZES = \"sizes\";\nconst POSTER = \"poster\";\nconst ORIGINALS = \"llOriginalAttrs\";\nconst DATA = \"data\";\n\nconst statusLoading = \"loading\";\nconst statusLoaded = \"loaded\";\nconst statusApplied = \"applied\";\nconst statusEntered = \"entered\";\nconst statusError = \"error\";\nconst statusNative = \"native\";\n\nconst dataPrefix = \"data-\";\nconst statusDataName = \"ll-status\";\n\nconst getData = (element, attribute) => {\n    return element.getAttribute(dataPrefix + attribute);\n};\n\nconst setData = (element, attribute, value) => {\n    var attrName = dataPrefix + attribute;\n    if (value === null) {\n        element.removeAttribute(attrName);\n        return;\n    }\n    element.setAttribute(attrName, value);\n};\n\nconst getStatus = (element) => getData(element, statusDataName);\nconst setStatus = (element, status) => setData(element, statusDataName, status);\nconst resetStatus = (element) => setStatus(element, null);\n\nconst hasEmptyStatus = (element) => getStatus(element) === null;\nconst hasStatusLoading = (element) => getStatus(element) === statusLoading;\nconst hasStatusError = (element) => getStatus(element) === statusError;\nconst hasStatusNative = (element) => getStatus(element) === statusNative;\n\nconst statusesAfterLoading = [statusLoading, statusLoaded, statusApplied, statusError];\nconst hadStartedLoading = (element) => statusesAfterLoading.indexOf(getStatus(element)) >= 0;\n\nconst safeCallback = (callback, arg1, arg2, arg3) => {\n\tif (!callback) {\n\t\treturn;\n\t}\n\n\tif (arg3 !== undefined) {\n\t\tcallback(arg1, arg2, arg3);\n\t\treturn;\n\t}\n\tif (arg2 !== undefined) {\n\t\tcallback(arg1, arg2);\n\t\treturn;\n\t}\n\tcallback(arg1);\n};\n\nconst addClass = (element, className) => {\n\tif (supportsClassList) {\n\t\telement.classList.add(className);\n\t\treturn;\n\t}\n\telement.className += (element.className ? \" \" : \"\") + className;\n};\n\nconst removeClass = (element, className) => {\n\tif (supportsClassList) {\n\t\telement.classList.remove(className);\n\t\treturn;\n\t}\n\telement.className = element.className.\n\t\treplace(new RegExp(\"(^|\\\\s+)\" + className + \"(\\\\s+|$)\"), \" \").\n\t\treplace(/^\\s+/, \"\").\n\t\treplace(/\\s+$/, \"\");\n};\n\nconst addTempImage = (element) => {\n    element.llTempImage = document.createElement(\"IMG\");\n};\n\nconst deleteTempImage = (element) => {\n    delete element.llTempImage;\n};\n\nconst getTempImage = (element) => element.llTempImage;\n\nconst unobserve = (element, instance) => {\n    if (!instance) return;\n    const observer = instance._observer;\n    if (!observer) return;\n    observer.unobserve(element);\n};\n\nconst resetObserver = (observer) => {\n    observer.disconnect();\n};\n\nconst unobserveEntered = (element, settings, instance) => {\n    if (settings.unobserve_entered) unobserve(element, instance);\n};\n\nconst updateLoadingCount = (instance, delta) => {\n    if (!instance) return;\n    instance.loadingCount += delta;\n};\n\nconst decreaseToLoadCount = (instance) => {\n    if (!instance) return;\n    instance.toLoadCount -= 1;\n};\n\nconst setToLoadCount = (instance, value) => {\n    if (!instance) return;\n    instance.toLoadCount = value;\n};\n\nconst isSomethingLoading = (instance) => instance.loadingCount > 0;\n\nconst haveElementsToLoad = (instance) => instance.toLoadCount > 0;\n\nconst getSourceTags = (parentTag) => {\n  let sourceTags = [];\n  for (let i = 0, childTag; (childTag = parentTag.children[i]); i += 1) {\n      if (childTag.tagName === \"SOURCE\") {\n          sourceTags.push(childTag);\n      }\n  }\n  return sourceTags;\n};\n\nconst forEachPictureSource = (element, fn) => {\n  const parent = element.parentNode;\n  if (!parent || parent.tagName !== \"PICTURE\") {\n      return;\n  }\n  let sourceTags = getSourceTags(parent);\n  sourceTags.forEach(fn);\n};\n\nconst forEachVideoSource = (element, fn) => {\n  let sourceTags = getSourceTags(element);\n  sourceTags.forEach(fn);\n};\n\nconst attrsSrc = [SRC];\nconst attrsSrcPoster = [SRC, POSTER];\nconst attrsSrcSrcsetSizes = [SRC, SRCSET, SIZES];\nconst attrsData = [DATA];\n\nconst hasOriginalAttrs = (element) => !!element[ORIGINALS];\nconst getOriginalAttrs = (element) => element[ORIGINALS];\nconst deleteOriginalAttrs = (element) => delete element[ORIGINALS];\n\n// ## SAVE ##\n\nconst setOriginalsObject = (element, attributes) => {\n    if (hasOriginalAttrs(element)) {\n        return;\n    }\n    const originals = {};\n    attributes.forEach((attribute) => {\n        originals[attribute] = element.getAttribute(attribute);\n    });\n    element[ORIGINALS] = originals;\n};\n\nconst saveOriginalBackgroundStyle = (element) => {\n    if (hasOriginalAttrs(element)) {\n        return;\n    }\n    element[ORIGINALS] = { backgroundImage: element.style.backgroundImage };\n};\n\n// ## RESTORE ##\n\nconst setOrResetAttribute = (element, attrName, value) => {\n    if (!value) {\n        element.removeAttribute(attrName);\n        return;\n    }\n    element.setAttribute(attrName, value);\n};\n\nconst restoreOriginalAttrs = (element, attributes) => {\n    if (!hasOriginalAttrs(element)) {\n        return;\n    }\n    const originals = getOriginalAttrs(element);\n    attributes.forEach((attribute) => {\n        setOrResetAttribute(element, attribute, originals[attribute]);\n    });\n};\n\nconst restoreOriginalBgImage = (element) => {\n    if (!hasOriginalAttrs(element)) {\n        return;\n    }\n    const originals = getOriginalAttrs(element);\n    element.style.backgroundImage = originals.backgroundImage;\n};\n\nconst manageApplied = (element, settings, instance) => {\n    addClass(element, settings.class_applied);\n    setStatus(element, statusApplied);\n    // Instance is not provided when loading is called from static class\n    if (!instance) return;\n    if (settings.unobserve_completed) {\n        // Unobserve now because we can't do it on load\n        unobserve(element, settings);\n    }\n    safeCallback(settings.callback_applied, element, instance);\n};\n\nconst manageLoading = (element, settings, instance) => {\n    addClass(element, settings.class_loading);\n    setStatus(element, statusLoading);\n    // Instance is not provided when loading is called from static class\n    if (!instance) return;\n    updateLoadingCount(instance, +1);\n    safeCallback(settings.callback_loading, element, instance);\n};\n\nconst setAttributeIfValue = (element, attrName, value) => {\n    if (!value) {\n        return;\n    }\n    element.setAttribute(attrName, value);\n};\n\nconst setImageAttributes = (element, settings) => {\n    setAttributeIfValue(element, SIZES, getData(element, settings.data_sizes));\n    setAttributeIfValue(element, SRCSET, getData(element, settings.data_srcset));\n    setAttributeIfValue(element, SRC, getData(element, settings.data_src));\n};\n\nconst setSourcesImg = (imgEl, settings) => {\n    forEachPictureSource(imgEl, (sourceTag) => {\n        setOriginalsObject(sourceTag, attrsSrcSrcsetSizes);\n        setImageAttributes(sourceTag, settings);\n    });\n    setOriginalsObject(imgEl, attrsSrcSrcsetSizes);\n    setImageAttributes(imgEl, settings);\n};\n\nconst setSourcesIframe = (iframe, settings) => {\n    setOriginalsObject(iframe, attrsSrc);\n    setAttributeIfValue(iframe, SRC, getData(iframe, settings.data_src));\n};\n\nconst setSourcesVideo = (videoEl, settings) => {\n    forEachVideoSource(videoEl, (sourceEl) => {\n        setOriginalsObject(sourceEl, attrsSrc);\n        setAttributeIfValue(sourceEl, SRC, getData(sourceEl, settings.data_src));\n    });\n    setOriginalsObject(videoEl, attrsSrcPoster);\n\n    setAttributeIfValue(videoEl, POSTER, getData(videoEl, settings.data_poster));\n    setAttributeIfValue(videoEl, SRC, getData(videoEl, settings.data_src));\n    videoEl.load();\n};\n\nconst setSourcesObject = (object, settings) => {\n    setOriginalsObject(object, attrsData);\n    setAttributeIfValue(object, DATA, getData(object, settings.data_src));\n};\n\nconst setBackground = (element, settings, instance) => {\n    const bg1xValue = getData(element, settings.data_bg);\n    const bgHiDpiValue = getData(element, settings.data_bg_hidpi);\n    const bgDataValue = isHiDpi && bgHiDpiValue ? bgHiDpiValue : bg1xValue;\n    if (!bgDataValue) return;\n    element.style.backgroundImage = `url(\"${bgDataValue}\")`;\n    getTempImage(element).setAttribute(SRC, bgDataValue);\n    manageLoading(element, settings, instance);\n};\n\n// NOTE: THE TEMP IMAGE TRICK CANNOT BE DONE WITH data-multi-bg\n// BECAUSE INSIDE ITS VALUES MUST BE WRAPPED WITH URL() AND ONE OF THEM\n// COULD BE A GRADIENT BACKGROUND IMAGE\nconst setMultiBackground = (element, settings, instance) => {\n    const bg1xValue = getData(element, settings.data_bg_multi);\n    const bgHiDpiValue = getData(element, settings.data_bg_multi_hidpi);\n    const bgDataValue = isHiDpi && bgHiDpiValue ? bgHiDpiValue : bg1xValue;\n    if (!bgDataValue) {\n        return;\n    }\n    element.style.backgroundImage = bgDataValue;\n    manageApplied(element, settings, instance);\n};\n\nconst setImgsetBackground = (element, settings, instance) => {\n    const bgImgSetDataValue = getData(element, settings.data_bg_set);\n    if (!bgImgSetDataValue) {\n        return;\n    }\n    const imgSetValues = bgImgSetDataValue.split(\"|\");\n    let bgImageValues = imgSetValues.map((value) => `image-set(${value})`);\n    element.style.backgroundImage = bgImageValues.join();\n    // Temporary fix for Chromeium with the -webkit- prefix\n    if (element.style.backgroundImage === '') {\n        bgImageValues = imgSetValues.map((value) => `-webkit-image-set(${value})`);\n        element.style.backgroundImage = bgImageValues.join();\n    }\n    manageApplied(element, settings, instance);\n};\n\nconst setSourcesFunctions = {\n    IMG: setSourcesImg,\n    IFRAME: setSourcesIframe,\n    VIDEO: setSourcesVideo,\n    OBJECT: setSourcesObject\n};\n\nconst setSourcesNative = (element, settings) => {\n    const setSourcesFunction = setSourcesFunctions[element.tagName];\n    if (!setSourcesFunction) {\n        return;\n    }\n    setSourcesFunction(element, settings);\n};\n\nconst setSources = (element, settings, instance) => {\n    const setSourcesFunction = setSourcesFunctions[element.tagName];\n    if (!setSourcesFunction) {\n        return;\n    }\n    setSourcesFunction(element, settings);\n    manageLoading(element, settings, instance);\n};\n\nconst elementsWithLoadEvent = [\"IMG\", \"IFRAME\", \"VIDEO\", \"OBJECT\"];\nconst hasLoadEvent = (element) => elementsWithLoadEvent.indexOf(element.tagName) > -1;\n\nconst checkFinish = (settings, instance) => {\n    if (instance && !isSomethingLoading(instance) && !haveElementsToLoad(instance)) {\n        safeCallback(settings.callback_finish, instance);\n    }\n};\n\nconst addEventListener = (element, eventName, handler) => {\n    element.addEventListener(eventName, handler);\n    element.llEvLisnrs[eventName] = handler;\n};\n\nconst removeEventListener = (element, eventName, handler) => {\n    element.removeEventListener(eventName, handler);\n};\n\nconst hasEventListeners = (element) => {\n    return !!element.llEvLisnrs;\n};\n\nconst addEventListeners = (element, loadHandler, errorHandler) => {\n    if (!hasEventListeners(element)) element.llEvLisnrs = {};\n    const loadEventName = element.tagName === \"VIDEO\" ? \"loadeddata\" : \"load\";\n    addEventListener(element, loadEventName, loadHandler);\n    addEventListener(element, \"error\", errorHandler);\n};\n\nconst removeEventListeners = (element) => {\n    if (!hasEventListeners(element)) {\n        return;\n    }\n    const eventListeners = element.llEvLisnrs;\n    for (let eventName in eventListeners) {\n        const handler = eventListeners[eventName];\n        removeEventListener(element, eventName, handler);\n    }\n    delete element.llEvLisnrs;\n};\n\nconst doneHandler = (element, settings, instance) => {\n    deleteTempImage(element);\n    updateLoadingCount(instance, -1);\n    decreaseToLoadCount(instance);\n    removeClass(element, settings.class_loading);\n    if (settings.unobserve_completed) {\n        unobserve(element, instance);\n    }\n};\n\nconst loadHandler = (event, element, settings, instance) => {\n    const goingNative = hasStatusNative(element);\n    doneHandler(element, settings, instance);\n    addClass(element, settings.class_loaded);\n    setStatus(element, statusLoaded);\n    safeCallback(settings.callback_loaded, element, instance);\n    if (!goingNative) checkFinish(settings, instance);\n};\n\nconst errorHandler = (event, element, settings, instance) => {\n    const goingNative = hasStatusNative(element);\n    doneHandler(element, settings, instance);\n    addClass(element, settings.class_error);\n    setStatus(element, statusError);\n    safeCallback(settings.callback_error, element, instance);\n    if (settings.restore_on_error) restoreOriginalAttrs(element, attrsSrcSrcsetSizes);\n    if (!goingNative) checkFinish(settings, instance);\n};\n\nconst addOneShotEventListeners = (element, settings, instance) => {\n    const elementToListenTo = getTempImage(element) || element;\n    if (hasEventListeners(elementToListenTo)) {\n        // This happens when loading is retried twice\n        return;\n    }\n    const _loadHandler = (event) => {\n        loadHandler(event, element, settings, instance);\n        removeEventListeners(elementToListenTo);\n    };\n    const _errorHandler = (event) => {\n        errorHandler(event, element, settings, instance);\n        removeEventListeners(elementToListenTo);\n    };\n    addEventListeners(elementToListenTo, _loadHandler, _errorHandler);\n};\n\nconst loadBackground = (element, settings, instance) => {\n    addTempImage(element);\n    addOneShotEventListeners(element, settings, instance);\n    saveOriginalBackgroundStyle(element);\n    setBackground(element, settings, instance);\n    setMultiBackground(element, settings, instance);\n    setImgsetBackground(element, settings, instance);\n};\n\nconst loadRegular = (element, settings, instance) => {\n    addOneShotEventListeners(element, settings, instance);\n    setSources(element, settings, instance);\n};\n\nconst load = (element, settings, instance) => {\n    if (hasLoadEvent(element)) {\n        loadRegular(element, settings, instance);\n    } else {\n        loadBackground(element, settings, instance);\n    }\n};\n\nconst loadNative = (element, settings, instance) => {\n    element.setAttribute(\"loading\", \"lazy\");\n    addOneShotEventListeners(element, settings, instance);\n    setSourcesNative(element, settings);\n    setStatus(element, statusNative);\n};\n\nconst removeImageAttributes = (element) => {\n    element.removeAttribute(SRC);\n    element.removeAttribute(SRCSET);\n    element.removeAttribute(SIZES);\n};\n\nconst resetSourcesImg = (element) => {\n    forEachPictureSource(element, (sourceTag) => {\n        removeImageAttributes(sourceTag);\n    });\n    removeImageAttributes(element);\n};\n\nconst restoreImg = (imgEl) => {\n    forEachPictureSource(imgEl, (sourceEl) => {\n        restoreOriginalAttrs(sourceEl, attrsSrcSrcsetSizes);\n    });\n    restoreOriginalAttrs(imgEl, attrsSrcSrcsetSizes);\n};\n\nconst restoreVideo = (videoEl) => {\n    forEachVideoSource(videoEl, (sourceEl) => {\n        restoreOriginalAttrs(sourceEl, attrsSrc);\n    });\n    restoreOriginalAttrs(videoEl, attrsSrcPoster);\n    videoEl.load();\n};\n\nconst restoreIframe = (iframeEl) => {\n    restoreOriginalAttrs(iframeEl, attrsSrc);\n};\n\nconst restoreObject = (objectEl) => {\n    restoreOriginalAttrs(objectEl, attrsData);\n};\n\nconst restoreFunctions = {\n    IMG: restoreImg,\n    IFRAME: restoreIframe,\n    VIDEO: restoreVideo,\n    OBJECT: restoreObject\n};\n\nconst restoreAttributes = (element) => {\n    const restoreFunction = restoreFunctions[element.tagName];\n    if (!restoreFunction) {\n        restoreOriginalBgImage(element);\n        return;\n    }\n    restoreFunction(element);\n};\n\nconst resetClasses = (element, settings) => {\n    if (hasEmptyStatus(element) || hasStatusNative(element)) {\n        return;\n    }\n    removeClass(element, settings.class_entered);\n    removeClass(element, settings.class_exited);\n    removeClass(element, settings.class_applied);\n    removeClass(element, settings.class_loading);\n    removeClass(element, settings.class_loaded);\n    removeClass(element, settings.class_error);\n};\n\nconst restore = (element, settings) => {\n    restoreAttributes(element);\n    resetClasses(element, settings);\n    resetStatus(element);\n    deleteOriginalAttrs(element);\n};\n\nconst cancelLoading = (element, entry, settings, instance) => {\n    if (!settings.cancel_on_exit) return;\n    if (!hasStatusLoading(element)) return;\n    if (element.tagName !== \"IMG\") return; //Works only on images\n    removeEventListeners(element);\n    resetSourcesImg(element);\n    restoreImg(element);\n    removeClass(element, settings.class_loading);\n    updateLoadingCount(instance, -1);\n    resetStatus(element);\n    safeCallback(settings.callback_cancel, element, entry, instance);\n};\n\nconst onEnter = (element, entry, settings, instance) => {\n    const dontLoad = hadStartedLoading(element); /* Save status \n        before setting it, to prevent loading it again. Fixes #526. */\n    setStatus(element, statusEntered);\n    addClass(element, settings.class_entered);\n    removeClass(element, settings.class_exited);\n    unobserveEntered(element, settings, instance);\n    safeCallback(settings.callback_enter, element, entry, instance);\n    if (dontLoad) return;\n    load(element, settings, instance);\n};\n\nconst onExit = (element, entry, settings, instance) => {\n    if (hasEmptyStatus(element)) return; //Ignore the first pass, at landing\n    addClass(element, settings.class_exited);\n    cancelLoading(element, entry, settings, instance);\n    safeCallback(settings.callback_exit, element, entry, instance);\n};\n\nconst tagsWithNativeLazy = [\"IMG\", \"IFRAME\", \"VIDEO\"];\n\nconst shouldUseNative = (settings) =>\n    settings.use_native && \"loading\" in HTMLImageElement.prototype;\n\nconst loadAllNative = (elements, settings, instance) => {\n    elements.forEach((element) => {\n        if (tagsWithNativeLazy.indexOf(element.tagName) === -1) {\n            return;\n        }\n        loadNative(element, settings, instance);\n    });\n    setToLoadCount(instance, 0);\n};\n\nconst isIntersecting = (entry) => entry.isIntersecting || entry.intersectionRatio > 0;\n\nconst getObserverSettings = (settings) => ({\n    root: settings.container === document ? null : settings.container,\n    rootMargin: settings.thresholds || settings.threshold + \"px\"\n});\n\nconst intersectionHandler = (entries, settings, instance) => {\n    entries.forEach((entry) =>\n        isIntersecting(entry)\n            ? onEnter(entry.target, entry, settings, instance)\n            : onExit(entry.target, entry, settings, instance)\n    );\n};\n\nconst observeElements = (observer, elements) => {\n    elements.forEach((element) => {\n        observer.observe(element);\n    });\n};\n\nconst updateObserver = (observer, elementsToObserve) => {\n    resetObserver(observer);\n    observeElements(observer, elementsToObserve);\n};\n\nconst setObserver = (settings, instance) => {\n    if (!supportsIntersectionObserver || shouldUseNative(settings)) {\n        return;\n    }\n    instance._observer = new IntersectionObserver((entries) => {\n        intersectionHandler(entries, settings, instance);\n    }, getObserverSettings(settings));\n};\n\nconst toArray = (nodeSet) => Array.prototype.slice.call(nodeSet);\n\nconst queryElements = (settings) =>\n    settings.container.querySelectorAll(settings.elements_selector);\n\nconst excludeManagedElements = (elements) => toArray(elements).filter(hasEmptyStatus);\n\nconst hasError = (element) => hasStatusError(element);\nconst filterErrorElements = (elements) => toArray(elements).filter(hasError);\n\nconst getElementsToLoad = (elements, settings) =>\n    excludeManagedElements(elements || queryElements(settings));\n\nconst retryLazyLoad = (settings, instance) => {\n    const errorElements = filterErrorElements(queryElements(settings));\n    errorElements.forEach((element) => {\n        removeClass(element, settings.class_error);\n        resetStatus(element);\n    });\n    instance.update();\n};\n\nconst setOnlineCheck = (settings, instance) => {\n    if (!runningOnBrowser) {\n        return;\n    }\n    instance._onlineHandler = () => {\n        retryLazyLoad(settings, instance);\n    };\n    window.addEventListener(\"online\", instance._onlineHandler);\n};\n\nconst resetOnlineCheck = (instance) => {\n    if (!runningOnBrowser) {\n        return;\n    }\n    window.removeEventListener(\"online\", instance._onlineHandler);\n};\n\nconst LazyLoad = function (customSettings, elements) {\n    const settings = getExtendedSettings(customSettings);\n    this._settings = settings;\n    this.loadingCount = 0;\n    setObserver(settings, this);\n    setOnlineCheck(settings, this);\n    this.update(elements);\n};\n\nLazyLoad.prototype = {\n    update: function (givenNodeset) {\n        const settings = this._settings;\n        const elementsToLoad = getElementsToLoad(givenNodeset, settings);\n        setToLoadCount(this, elementsToLoad.length);\n\n        if (isBot || !supportsIntersectionObserver) {\n            this.loadAll(elementsToLoad);\n            return;\n        }\n        if (shouldUseNative(settings)) {\n            loadAllNative(elementsToLoad, settings, this);\n            return;\n        }\n\n        updateObserver(this._observer, elementsToLoad);\n    },\n\n    destroy: function () {\n        // Observer\n        if (this._observer) {\n            this._observer.disconnect();\n        }\n        // Clean handlers\n        resetOnlineCheck(this);\n        // Clean custom attributes on elements\n        queryElements(this._settings).forEach((element) => {\n            deleteOriginalAttrs(element);\n        });\n        // Delete all internal props\n        delete this._observer;\n        delete this._settings;\n        delete this._onlineHandler;\n        delete this.loadingCount;\n        delete this.toLoadCount;\n    },\n\n    loadAll: function (elements) {\n        const settings = this._settings;\n        const elementsToLoad = getElementsToLoad(elements, settings);\n        elementsToLoad.forEach((element) => {\n            unobserve(element, this);\n            load(element, settings, this);\n        });\n    },\n\n    restoreAll: function() {\n        const settings = this._settings;\n        queryElements(settings).forEach((element) => {\n            restore(element, settings);\n        });\n    }\n};\n\nLazyLoad.load = (element, customSettings) => {\n    const settings = getExtendedSettings(customSettings);\n    load(element, settings);\n};\n\nLazyLoad.resetStatus = (element) => {\n    resetStatus(element);\n};\n\n// Automatic instances creation if required (useful for async script loading)\nif (runningOnBrowser) {\n    autoInitialize(LazyLoad, window.lazyLoadOptions);\n}\n\nexport { LazyLoad as default };\n","import LazyLoad, { ILazyLoadInstance } from \"vanilla-lazyload\";\n\nlet instance: ILazyLoadInstance | null = null;\n\nexport function lazyLoadUpdate(): void {\n    if (instance !== null){\n        instance.update();\n        return;\n    }\n\n    instance  = new LazyLoad({\n        elements_selector: '[loading=lazy]',\n        use_native: true,\n    })\n\n    instance.update();\n}\n","// Unique ID creation requires a high quality random # generator. In the browser we therefore\n// require the crypto API and do not support built-in fallback to lower quality random number\n// generators (like Math.random()).\nvar getRandomValues;\nvar rnds8 = new Uint8Array(16);\nexport default function rng() {\n  // lazy load so that environments that need to polyfill have a chance to do so\n  if (!getRandomValues) {\n    // getRandomValues needs to be invoked in a context where \"this\" is a Crypto implementation. Also,\n    // find the complete implementation of crypto (msCrypto) on IE11.\n    getRandomValues = typeof crypto !== 'undefined' && crypto.getRandomValues && crypto.getRandomValues.bind(crypto) || typeof msCrypto !== 'undefined' && typeof msCrypto.getRandomValues === 'function' && msCrypto.getRandomValues.bind(msCrypto);\n\n    if (!getRandomValues) {\n      throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');\n    }\n  }\n\n  return getRandomValues(rnds8);\n}","export default /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;","import REGEX from './regex.js';\n\nfunction validate(uuid) {\n  return typeof uuid === 'string' && REGEX.test(uuid);\n}\n\nexport default validate;","import validate from './validate.js';\n/**\n * Convert array of 16 byte values to UUID string format of the form:\n * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX\n */\n\nvar byteToHex = [];\n\nfor (var i = 0; i < 256; ++i) {\n  byteToHex.push((i + 0x100).toString(16).substr(1));\n}\n\nfunction stringify(arr) {\n  var offset = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;\n  // Note: Be careful editing this code!  It's been tuned for performance\n  // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434\n  var uuid = (byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]]).toLowerCase(); // Consistency check for valid UUID.  If this throws, it's likely due to one\n  // of the following:\n  // - One or more input array values don't map to a hex octet (leading to\n  // \"undefined\" in the uuid)\n  // - Invalid input values for the RFC `version` or `variant` fields\n\n  if (!validate(uuid)) {\n    throw TypeError('Stringified UUID is invalid');\n  }\n\n  return uuid;\n}\n\nexport default stringify;","import rng from './rng.js';\nimport stringify from './stringify.js';\n\nfunction v4(options, buf, offset) {\n  options = options || {};\n  var rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`\n\n  rnds[6] = rnds[6] & 0x0f | 0x40;\n  rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided\n\n  if (buf) {\n    offset = offset || 0;\n\n    for (var i = 0; i < 16; ++i) {\n      buf[offset + i] = rnds[i];\n    }\n\n    return buf;\n  }\n\n  return stringify(rnds);\n}\n\nexport default v4;","import { shallowRef, watchEffect, readonly, ref, watch, customRef, getCurrentScope, onScopeDispose, effectScope, provide, inject, isVue3, version, isRef, unref, computed, reactive, toRefs as toRefs$1, toRef as toRef$1, isVue2, set as set$1, getCurrentInstance, onBeforeMount, nextTick, onBeforeUnmount, onMounted, onUnmounted, isReactive } from 'vue-demi';\n\nvar __defProp$b = Object.defineProperty;\nvar __defProps$8 = Object.defineProperties;\nvar __getOwnPropDescs$8 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$d = Object.getOwnPropertySymbols;\nvar __hasOwnProp$d = Object.prototype.hasOwnProperty;\nvar __propIsEnum$d = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$b(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$b = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$d.call(b, prop))\n      __defNormalProp$b(a, prop, b[prop]);\n  if (__getOwnPropSymbols$d)\n    for (var prop of __getOwnPropSymbols$d(b)) {\n      if (__propIsEnum$d.call(b, prop))\n        __defNormalProp$b(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$8 = (a, b) => __defProps$8(a, __getOwnPropDescs$8(b));\nfunction computedEager(fn, options) {\n  var _a;\n  const result = shallowRef();\n  watchEffect(() => {\n    result.value = fn();\n  }, __spreadProps$8(__spreadValues$b({}, options), {\n    flush: (_a = options == null ? void 0 : options.flush) != null ? _a : \"sync\"\n  }));\n  return readonly(result);\n}\n\nfunction computedWithControl(source, fn) {\n  let v = void 0;\n  let track;\n  let trigger;\n  const dirty = ref(true);\n  const update = () => {\n    dirty.value = true;\n    trigger();\n  };\n  watch(source, update, { flush: \"sync\" });\n  const get = typeof fn === \"function\" ? fn : fn.get;\n  const set = typeof fn === \"function\" ? void 0 : fn.set;\n  const result = customRef((_track, _trigger) => {\n    track = _track;\n    trigger = _trigger;\n    return {\n      get() {\n        if (dirty.value) {\n          v = get();\n          dirty.value = false;\n        }\n        track();\n        return v;\n      },\n      set(v2) {\n        set == null ? void 0 : set(v2);\n      }\n    };\n  });\n  if (Object.isExtensible(result))\n    result.trigger = update;\n  return result;\n}\n\nfunction tryOnScopeDispose(fn) {\n  if (getCurrentScope()) {\n    onScopeDispose(fn);\n    return true;\n  }\n  return false;\n}\n\nfunction createEventHook() {\n  const fns = /* @__PURE__ */ new Set();\n  const off = (fn) => {\n    fns.delete(fn);\n  };\n  const on = (fn) => {\n    fns.add(fn);\n    const offFn = () => off(fn);\n    tryOnScopeDispose(offFn);\n    return {\n      off: offFn\n    };\n  };\n  const trigger = (param) => {\n    return Promise.all(Array.from(fns).map((fn) => fn(param)));\n  };\n  return {\n    on,\n    off,\n    trigger\n  };\n}\n\nfunction createGlobalState(stateFactory) {\n  let initialized = false;\n  let state;\n  const scope = effectScope(true);\n  return (...args) => {\n    if (!initialized) {\n      state = scope.run(() => stateFactory(...args));\n      initialized = true;\n    }\n    return state;\n  };\n}\n\nfunction createInjectionState(composable) {\n  const key = Symbol(\"InjectionState\");\n  const useProvidingState = (...args) => {\n    const state = composable(...args);\n    provide(key, state);\n    return state;\n  };\n  const useInjectedState = () => inject(key);\n  return [useProvidingState, useInjectedState];\n}\n\nfunction createSharedComposable(composable) {\n  let subscribers = 0;\n  let state;\n  let scope;\n  const dispose = () => {\n    subscribers -= 1;\n    if (scope && subscribers <= 0) {\n      scope.stop();\n      state = void 0;\n      scope = void 0;\n    }\n  };\n  return (...args) => {\n    subscribers += 1;\n    if (!state) {\n      scope = effectScope(true);\n      state = scope.run(() => composable(...args));\n    }\n    tryOnScopeDispose(dispose);\n    return state;\n  };\n}\n\nfunction extendRef(ref, extend, { enumerable = false, unwrap = true } = {}) {\n  if (!isVue3 && !version.startsWith(\"2.7.\")) {\n    if (process.env.NODE_ENV !== \"production\")\n      throw new Error(\"[VueUse] extendRef only works in Vue 2.7 or above.\");\n    return;\n  }\n  for (const [key, value] of Object.entries(extend)) {\n    if (key === \"value\")\n      continue;\n    if (isRef(value) && unwrap) {\n      Object.defineProperty(ref, key, {\n        get() {\n          return value.value;\n        },\n        set(v) {\n          value.value = v;\n        },\n        enumerable\n      });\n    } else {\n      Object.defineProperty(ref, key, { value, enumerable });\n    }\n  }\n  return ref;\n}\n\nfunction get(obj, key) {\n  if (key == null)\n    return unref(obj);\n  return unref(obj)[key];\n}\n\nfunction isDefined(v) {\n  return unref(v) != null;\n}\n\nvar __defProp$a = Object.defineProperty;\nvar __getOwnPropSymbols$c = Object.getOwnPropertySymbols;\nvar __hasOwnProp$c = Object.prototype.hasOwnProperty;\nvar __propIsEnum$c = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$a = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$c.call(b, prop))\n      __defNormalProp$a(a, prop, b[prop]);\n  if (__getOwnPropSymbols$c)\n    for (var prop of __getOwnPropSymbols$c(b)) {\n      if (__propIsEnum$c.call(b, prop))\n        __defNormalProp$a(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction makeDestructurable(obj, arr) {\n  if (typeof Symbol !== \"undefined\") {\n    const clone = __spreadValues$a({}, obj);\n    Object.defineProperty(clone, Symbol.iterator, {\n      enumerable: false,\n      value() {\n        let index = 0;\n        return {\n          next: () => ({\n            value: arr[index++],\n            done: index > arr.length\n          })\n        };\n      }\n    });\n    return clone;\n  } else {\n    return Object.assign([...arr], obj);\n  }\n}\n\nfunction toValue(r) {\n  return typeof r === \"function\" ? r() : unref(r);\n}\nconst resolveUnref = toValue;\n\nfunction reactify(fn, options) {\n  const unrefFn = (options == null ? void 0 : options.computedGetter) === false ? unref : toValue;\n  return function(...args) {\n    return computed(() => fn.apply(this, args.map((i) => unrefFn(i))));\n  };\n}\n\nfunction reactifyObject(obj, optionsOrKeys = {}) {\n  let keys = [];\n  let options;\n  if (Array.isArray(optionsOrKeys)) {\n    keys = optionsOrKeys;\n  } else {\n    options = optionsOrKeys;\n    const { includeOwnProperties = true } = optionsOrKeys;\n    keys.push(...Object.keys(obj));\n    if (includeOwnProperties)\n      keys.push(...Object.getOwnPropertyNames(obj));\n  }\n  return Object.fromEntries(\n    keys.map((key) => {\n      const value = obj[key];\n      return [\n        key,\n        typeof value === \"function\" ? reactify(value.bind(obj), options) : value\n      ];\n    })\n  );\n}\n\nfunction toReactive(objectRef) {\n  if (!isRef(objectRef))\n    return reactive(objectRef);\n  const proxy = new Proxy({}, {\n    get(_, p, receiver) {\n      return unref(Reflect.get(objectRef.value, p, receiver));\n    },\n    set(_, p, value) {\n      if (isRef(objectRef.value[p]) && !isRef(value))\n        objectRef.value[p].value = value;\n      else\n        objectRef.value[p] = value;\n      return true;\n    },\n    deleteProperty(_, p) {\n      return Reflect.deleteProperty(objectRef.value, p);\n    },\n    has(_, p) {\n      return Reflect.has(objectRef.value, p);\n    },\n    ownKeys() {\n      return Object.keys(objectRef.value);\n    },\n    getOwnPropertyDescriptor() {\n      return {\n        enumerable: true,\n        configurable: true\n      };\n    }\n  });\n  return reactive(proxy);\n}\n\nfunction reactiveComputed(fn) {\n  return toReactive(computed(fn));\n}\n\nfunction reactiveOmit(obj, ...keys) {\n  const flatKeys = keys.flat();\n  const predicate = flatKeys[0];\n  return reactiveComputed(\n    () => typeof predicate === \"function\" ? Object.fromEntries(Object.entries(toRefs$1(obj)).filter(([k, v]) => !predicate(toValue(v), k))) : Object.fromEntries(Object.entries(toRefs$1(obj)).filter((e) => !flatKeys.includes(e[0])))\n  );\n}\n\nconst isClient = typeof window !== \"undefined\";\nconst isDef = (val) => typeof val !== \"undefined\";\nconst notNullish = (val) => val != null;\nconst assert = (condition, ...infos) => {\n  if (!condition)\n    console.warn(...infos);\n};\nconst toString = Object.prototype.toString;\nconst isObject = (val) => toString.call(val) === \"[object Object]\";\nconst now = () => Date.now();\nconst timestamp = () => +Date.now();\nconst clamp = (n, min, max) => Math.min(max, Math.max(min, n));\nconst noop = () => {\n};\nconst rand = (min, max) => {\n  min = Math.ceil(min);\n  max = Math.floor(max);\n  return Math.floor(Math.random() * (max - min + 1)) + min;\n};\nconst hasOwn = (val, key) => Object.prototype.hasOwnProperty.call(val, key);\nconst isIOS = /* @__PURE__ */ getIsIOS();\nfunction getIsIOS() {\n  var _a;\n  return isClient && ((_a = window == null ? void 0 : window.navigator) == null ? void 0 : _a.userAgent) && /* @__PURE__ */ /iP(ad|hone|od)/.test(window.navigator.userAgent);\n}\n\nfunction createFilterWrapper(filter, fn) {\n  function wrapper(...args) {\n    return new Promise((resolve, reject) => {\n      Promise.resolve(filter(() => fn.apply(this, args), { fn, thisArg: this, args })).then(resolve).catch(reject);\n    });\n  }\n  return wrapper;\n}\nconst bypassFilter = (invoke) => {\n  return invoke();\n};\nfunction debounceFilter(ms, options = {}) {\n  let timer;\n  let maxTimer;\n  let lastRejector = noop;\n  const _clearTimeout = (timer2) => {\n    clearTimeout(timer2);\n    lastRejector();\n    lastRejector = noop;\n  };\n  const filter = (invoke) => {\n    const duration = toValue(ms);\n    const maxDuration = toValue(options.maxWait);\n    if (timer)\n      _clearTimeout(timer);\n    if (duration <= 0 || maxDuration !== void 0 && maxDuration <= 0) {\n      if (maxTimer) {\n        _clearTimeout(maxTimer);\n        maxTimer = null;\n      }\n      return Promise.resolve(invoke());\n    }\n    return new Promise((resolve, reject) => {\n      lastRejector = options.rejectOnCancel ? reject : resolve;\n      if (maxDuration && !maxTimer) {\n        maxTimer = setTimeout(() => {\n          if (timer)\n            _clearTimeout(timer);\n          maxTimer = null;\n          resolve(invoke());\n        }, maxDuration);\n      }\n      timer = setTimeout(() => {\n        if (maxTimer)\n          _clearTimeout(maxTimer);\n        maxTimer = null;\n        resolve(invoke());\n      }, duration);\n    });\n  };\n  return filter;\n}\nfunction throttleFilter(ms, trailing = true, leading = true, rejectOnCancel = false) {\n  let lastExec = 0;\n  let timer;\n  let isLeading = true;\n  let lastRejector = noop;\n  let lastValue;\n  const clear = () => {\n    if (timer) {\n      clearTimeout(timer);\n      timer = void 0;\n      lastRejector();\n      lastRejector = noop;\n    }\n  };\n  const filter = (_invoke) => {\n    const duration = toValue(ms);\n    const elapsed = Date.now() - lastExec;\n    const invoke = () => {\n      return lastValue = _invoke();\n    };\n    clear();\n    if (duration <= 0) {\n      lastExec = Date.now();\n      return invoke();\n    }\n    if (elapsed > duration && (leading || !isLeading)) {\n      lastExec = Date.now();\n      invoke();\n    } else if (trailing) {\n      lastValue = new Promise((resolve, reject) => {\n        lastRejector = rejectOnCancel ? reject : resolve;\n        timer = setTimeout(() => {\n          lastExec = Date.now();\n          isLeading = true;\n          resolve(invoke());\n          clear();\n        }, Math.max(0, duration - elapsed));\n      });\n    }\n    if (!leading && !timer)\n      timer = setTimeout(() => isLeading = true, duration);\n    isLeading = false;\n    return lastValue;\n  };\n  return filter;\n}\nfunction pausableFilter(extendFilter = bypassFilter) {\n  const isActive = ref(true);\n  function pause() {\n    isActive.value = false;\n  }\n  function resume() {\n    isActive.value = true;\n  }\n  const eventFilter = (...args) => {\n    if (isActive.value)\n      extendFilter(...args);\n  };\n  return { isActive: readonly(isActive), pause, resume, eventFilter };\n}\n\nconst directiveHooks = {\n  mounted: isVue3 ? \"mounted\" : \"inserted\",\n  updated: isVue3 ? \"updated\" : \"componentUpdated\",\n  unmounted: isVue3 ? \"unmounted\" : \"unbind\"\n};\n\nfunction promiseTimeout(ms, throwOnTimeout = false, reason = \"Timeout\") {\n  return new Promise((resolve, reject) => {\n    if (throwOnTimeout)\n      setTimeout(() => reject(reason), ms);\n    else\n      setTimeout(resolve, ms);\n  });\n}\nfunction identity(arg) {\n  return arg;\n}\nfunction createSingletonPromise(fn) {\n  let _promise;\n  function wrapper() {\n    if (!_promise)\n      _promise = fn();\n    return _promise;\n  }\n  wrapper.reset = async () => {\n    const _prev = _promise;\n    _promise = void 0;\n    if (_prev)\n      await _prev;\n  };\n  return wrapper;\n}\nfunction invoke(fn) {\n  return fn();\n}\nfunction containsProp(obj, ...props) {\n  return props.some((k) => k in obj);\n}\nfunction increaseWithUnit(target, delta) {\n  var _a;\n  if (typeof target === \"number\")\n    return target + delta;\n  const value = ((_a = target.match(/^-?[0-9]+\\.?[0-9]*/)) == null ? void 0 : _a[0]) || \"\";\n  const unit = target.slice(value.length);\n  const result = parseFloat(value) + delta;\n  if (Number.isNaN(result))\n    return target;\n  return result + unit;\n}\nfunction objectPick(obj, keys, omitUndefined = false) {\n  return keys.reduce((n, k) => {\n    if (k in obj) {\n      if (!omitUndefined || obj[k] !== void 0)\n        n[k] = obj[k];\n    }\n    return n;\n  }, {});\n}\nfunction objectOmit(obj, keys, omitUndefined = false) {\n  return Object.fromEntries(Object.entries(obj).filter(([key, value]) => {\n    return (!omitUndefined || value !== void 0) && !keys.includes(key);\n  }));\n}\nfunction objectEntries(obj) {\n  return Object.entries(obj);\n}\n\nfunction toRef(...args) {\n  if (args.length !== 1)\n    return toRef$1(...args);\n  const r = args[0];\n  return typeof r === \"function\" ? readonly(customRef(() => ({ get: r, set: noop }))) : ref(r);\n}\nconst resolveRef = toRef;\n\nfunction reactivePick(obj, ...keys) {\n  const flatKeys = keys.flat();\n  const predicate = flatKeys[0];\n  return reactiveComputed(() => typeof predicate === \"function\" ? Object.fromEntries(Object.entries(toRefs$1(obj)).filter(([k, v]) => predicate(toValue(v), k))) : Object.fromEntries(flatKeys.map((k) => [k, toRef(obj, k)])));\n}\n\nfunction refAutoReset(defaultValue, afterMs = 1e4) {\n  return customRef((track, trigger) => {\n    let value = defaultValue;\n    let timer;\n    const resetAfter = () => setTimeout(() => {\n      value = defaultValue;\n      trigger();\n    }, toValue(afterMs));\n    tryOnScopeDispose(() => {\n      clearTimeout(timer);\n    });\n    return {\n      get() {\n        track();\n        return value;\n      },\n      set(newValue) {\n        value = newValue;\n        trigger();\n        clearTimeout(timer);\n        timer = resetAfter();\n      }\n    };\n  });\n}\n\nfunction useDebounceFn(fn, ms = 200, options = {}) {\n  return createFilterWrapper(\n    debounceFilter(ms, options),\n    fn\n  );\n}\n\nfunction refDebounced(value, ms = 200, options = {}) {\n  const debounced = ref(value.value);\n  const updater = useDebounceFn(() => {\n    debounced.value = value.value;\n  }, ms, options);\n  watch(value, () => updater());\n  return debounced;\n}\n\nfunction refDefault(source, defaultValue) {\n  return computed({\n    get() {\n      var _a;\n      return (_a = source.value) != null ? _a : defaultValue;\n    },\n    set(value) {\n      source.value = value;\n    }\n  });\n}\n\nfunction useThrottleFn(fn, ms = 200, trailing = false, leading = true, rejectOnCancel = false) {\n  return createFilterWrapper(\n    throttleFilter(ms, trailing, leading, rejectOnCancel),\n    fn\n  );\n}\n\nfunction refThrottled(value, delay = 200, trailing = true, leading = true) {\n  if (delay <= 0)\n    return value;\n  const throttled = ref(value.value);\n  const updater = useThrottleFn(() => {\n    throttled.value = value.value;\n  }, delay, trailing, leading);\n  watch(value, () => updater());\n  return throttled;\n}\n\nfunction refWithControl(initial, options = {}) {\n  let source = initial;\n  let track;\n  let trigger;\n  const ref = customRef((_track, _trigger) => {\n    track = _track;\n    trigger = _trigger;\n    return {\n      get() {\n        return get();\n      },\n      set(v) {\n        set(v);\n      }\n    };\n  });\n  function get(tracking = true) {\n    if (tracking)\n      track();\n    return source;\n  }\n  function set(value, triggering = true) {\n    var _a, _b;\n    if (value === source)\n      return;\n    const old = source;\n    if (((_a = options.onBeforeChange) == null ? void 0 : _a.call(options, value, old)) === false)\n      return;\n    source = value;\n    (_b = options.onChanged) == null ? void 0 : _b.call(options, value, old);\n    if (triggering)\n      trigger();\n  }\n  const untrackedGet = () => get(false);\n  const silentSet = (v) => set(v, false);\n  const peek = () => get(false);\n  const lay = (v) => set(v, false);\n  return extendRef(\n    ref,\n    {\n      get,\n      set,\n      untrackedGet,\n      silentSet,\n      peek,\n      lay\n    },\n    { enumerable: true }\n  );\n}\nconst controlledRef = refWithControl;\n\nfunction set(...args) {\n  if (args.length === 2) {\n    const [ref, value] = args;\n    ref.value = value;\n  }\n  if (args.length === 3) {\n    if (isVue2) {\n      set$1(...args);\n    } else {\n      const [target, key, value] = args;\n      target[key] = value;\n    }\n  }\n}\n\nfunction syncRef(left, right, options = {}) {\n  var _a, _b;\n  const {\n    flush = \"sync\",\n    deep = false,\n    immediate = true,\n    direction = \"both\",\n    transform = {}\n  } = options;\n  let watchLeft;\n  let watchRight;\n  const transformLTR = (_a = transform.ltr) != null ? _a : (v) => v;\n  const transformRTL = (_b = transform.rtl) != null ? _b : (v) => v;\n  if (direction === \"both\" || direction === \"ltr\") {\n    watchLeft = watch(\n      left,\n      (newValue) => right.value = transformLTR(newValue),\n      { flush, deep, immediate }\n    );\n  }\n  if (direction === \"both\" || direction === \"rtl\") {\n    watchRight = watch(\n      right,\n      (newValue) => left.value = transformRTL(newValue),\n      { flush, deep, immediate }\n    );\n  }\n  return () => {\n    watchLeft == null ? void 0 : watchLeft();\n    watchRight == null ? void 0 : watchRight();\n  };\n}\n\nfunction syncRefs(source, targets, options = {}) {\n  const {\n    flush = \"sync\",\n    deep = false,\n    immediate = true\n  } = options;\n  if (!Array.isArray(targets))\n    targets = [targets];\n  return watch(\n    source,\n    (newValue) => targets.forEach((target) => target.value = newValue),\n    { flush, deep, immediate }\n  );\n}\n\nvar __defProp$9 = Object.defineProperty;\nvar __defProps$7 = Object.defineProperties;\nvar __getOwnPropDescs$7 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$b = Object.getOwnPropertySymbols;\nvar __hasOwnProp$b = Object.prototype.hasOwnProperty;\nvar __propIsEnum$b = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$9 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$b.call(b, prop))\n      __defNormalProp$9(a, prop, b[prop]);\n  if (__getOwnPropSymbols$b)\n    for (var prop of __getOwnPropSymbols$b(b)) {\n      if (__propIsEnum$b.call(b, prop))\n        __defNormalProp$9(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$7 = (a, b) => __defProps$7(a, __getOwnPropDescs$7(b));\nfunction toRefs(objectRef) {\n  if (!isRef(objectRef))\n    return toRefs$1(objectRef);\n  const result = Array.isArray(objectRef.value) ? new Array(objectRef.value.length) : {};\n  for (const key in objectRef.value) {\n    result[key] = customRef(() => ({\n      get() {\n        return objectRef.value[key];\n      },\n      set(v) {\n        if (Array.isArray(objectRef.value)) {\n          const copy = [...objectRef.value];\n          copy[key] = v;\n          objectRef.value = copy;\n        } else {\n          const newObject = __spreadProps$7(__spreadValues$9({}, objectRef.value), { [key]: v });\n          Object.setPrototypeOf(newObject, objectRef.value);\n          objectRef.value = newObject;\n        }\n      }\n    }));\n  }\n  return result;\n}\n\nfunction tryOnBeforeMount(fn, sync = true) {\n  if (getCurrentInstance())\n    onBeforeMount(fn);\n  else if (sync)\n    fn();\n  else\n    nextTick(fn);\n}\n\nfunction tryOnBeforeUnmount(fn) {\n  if (getCurrentInstance())\n    onBeforeUnmount(fn);\n}\n\nfunction tryOnMounted(fn, sync = true) {\n  if (getCurrentInstance())\n    onMounted(fn);\n  else if (sync)\n    fn();\n  else\n    nextTick(fn);\n}\n\nfunction tryOnUnmounted(fn) {\n  if (getCurrentInstance())\n    onUnmounted(fn);\n}\n\nfunction createUntil(r, isNot = false) {\n  function toMatch(condition, { flush = \"sync\", deep = false, timeout, throwOnTimeout } = {}) {\n    let stop = null;\n    const watcher = new Promise((resolve) => {\n      stop = watch(\n        r,\n        (v) => {\n          if (condition(v) !== isNot) {\n            stop == null ? void 0 : stop();\n            resolve(v);\n          }\n        },\n        {\n          flush,\n          deep,\n          immediate: true\n        }\n      );\n    });\n    const promises = [watcher];\n    if (timeout != null) {\n      promises.push(\n        promiseTimeout(timeout, throwOnTimeout).then(() => toValue(r)).finally(() => stop == null ? void 0 : stop())\n      );\n    }\n    return Promise.race(promises);\n  }\n  function toBe(value, options) {\n    if (!isRef(value))\n      return toMatch((v) => v === value, options);\n    const { flush = \"sync\", deep = false, timeout, throwOnTimeout } = options != null ? options : {};\n    let stop = null;\n    const watcher = new Promise((resolve) => {\n      stop = watch(\n        [r, value],\n        ([v1, v2]) => {\n          if (isNot !== (v1 === v2)) {\n            stop == null ? void 0 : stop();\n            resolve(v1);\n          }\n        },\n        {\n          flush,\n          deep,\n          immediate: true\n        }\n      );\n    });\n    const promises = [watcher];\n    if (timeout != null) {\n      promises.push(\n        promiseTimeout(timeout, throwOnTimeout).then(() => toValue(r)).finally(() => {\n          stop == null ? void 0 : stop();\n          return toValue(r);\n        })\n      );\n    }\n    return Promise.race(promises);\n  }\n  function toBeTruthy(options) {\n    return toMatch((v) => Boolean(v), options);\n  }\n  function toBeNull(options) {\n    return toBe(null, options);\n  }\n  function toBeUndefined(options) {\n    return toBe(void 0, options);\n  }\n  function toBeNaN(options) {\n    return toMatch(Number.isNaN, options);\n  }\n  function toContains(value, options) {\n    return toMatch((v) => {\n      const array = Array.from(v);\n      return array.includes(value) || array.includes(toValue(value));\n    }, options);\n  }\n  function changed(options) {\n    return changedTimes(1, options);\n  }\n  function changedTimes(n = 1, options) {\n    let count = -1;\n    return toMatch(() => {\n      count += 1;\n      return count >= n;\n    }, options);\n  }\n  if (Array.isArray(toValue(r))) {\n    const instance = {\n      toMatch,\n      toContains,\n      changed,\n      changedTimes,\n      get not() {\n        return createUntil(r, !isNot);\n      }\n    };\n    return instance;\n  } else {\n    const instance = {\n      toMatch,\n      toBe,\n      toBeTruthy,\n      toBeNull,\n      toBeNaN,\n      toBeUndefined,\n      changed,\n      changedTimes,\n      get not() {\n        return createUntil(r, !isNot);\n      }\n    };\n    return instance;\n  }\n}\nfunction until(r) {\n  return createUntil(r);\n}\n\nfunction defaultComparator(value, othVal) {\n  return value === othVal;\n}\nfunction useArrayDifference(...args) {\n  var _a;\n  const list = args[0];\n  const values = args[1];\n  let compareFn = (_a = args[2]) != null ? _a : defaultComparator;\n  if (typeof compareFn === \"string\") {\n    const key = compareFn;\n    compareFn = (value, othVal) => value[key] === othVal[key];\n  }\n  return computed(() => toValue(list).filter((x) => toValue(values).findIndex((y) => compareFn(x, y)) === -1));\n}\n\nfunction useArrayEvery(list, fn) {\n  return computed(() => toValue(list).every((element, index, array) => fn(toValue(element), index, array)));\n}\n\nfunction useArrayFilter(list, fn) {\n  return computed(() => toValue(list).map((i) => toValue(i)).filter(fn));\n}\n\nfunction useArrayFind(list, fn) {\n  return computed(\n    () => toValue(\n      toValue(list).find((element, index, array) => fn(toValue(element), index, array))\n    )\n  );\n}\n\nfunction useArrayFindIndex(list, fn) {\n  return computed(() => toValue(list).findIndex((element, index, array) => fn(toValue(element), index, array)));\n}\n\nfunction findLast(arr, cb) {\n  let index = arr.length;\n  while (index-- > 0) {\n    if (cb(arr[index], index, arr))\n      return arr[index];\n  }\n  return void 0;\n}\nfunction useArrayFindLast(list, fn) {\n  return computed(\n    () => toValue(\n      !Array.prototype.findLast ? findLast(toValue(list), (element, index, array) => fn(toValue(element), index, array)) : toValue(list).findLast((element, index, array) => fn(toValue(element), index, array))\n    )\n  );\n}\n\nfunction isArrayIncludesOptions(obj) {\n  return isObject(obj) && containsProp(obj, \"formIndex\", \"comparator\");\n}\nfunction useArrayIncludes(...args) {\n  var _a;\n  const list = args[0];\n  const value = args[1];\n  let comparator = args[2];\n  let formIndex = 0;\n  if (isArrayIncludesOptions(comparator)) {\n    formIndex = (_a = comparator.fromIndex) != null ? _a : 0;\n    comparator = comparator.comparator;\n  }\n  if (typeof comparator === \"string\") {\n    const key = comparator;\n    comparator = (element, value2) => element[key] === toValue(value2);\n  }\n  comparator = comparator != null ? comparator : (element, value2) => element === toValue(value2);\n  return computed(\n    () => toValue(list).slice(formIndex).some(\n      (element, index, array) => comparator(toValue(element), toValue(value), index, toValue(array))\n    )\n  );\n}\n\nfunction useArrayJoin(list, separator) {\n  return computed(() => toValue(list).map((i) => toValue(i)).join(toValue(separator)));\n}\n\nfunction useArrayMap(list, fn) {\n  return computed(() => toValue(list).map((i) => toValue(i)).map(fn));\n}\n\nfunction useArrayReduce(list, reducer, ...args) {\n  const reduceCallback = (sum, value, index) => reducer(toValue(sum), toValue(value), index);\n  return computed(() => {\n    const resolved = toValue(list);\n    return args.length ? resolved.reduce(reduceCallback, toValue(args[0])) : resolved.reduce(reduceCallback);\n  });\n}\n\nfunction useArraySome(list, fn) {\n  return computed(() => toValue(list).some((element, index, array) => fn(toValue(element), index, array)));\n}\n\nfunction uniq(array) {\n  return Array.from(new Set(array));\n}\nfunction uniqueElementsBy(array, fn) {\n  return array.reduce((acc, v) => {\n    if (!acc.some((x) => fn(v, x, array)))\n      acc.push(v);\n    return acc;\n  }, []);\n}\nfunction useArrayUnique(list, compareFn) {\n  return computed(() => {\n    const resolvedList = toValue(list).map((element) => toValue(element));\n    return compareFn ? uniqueElementsBy(resolvedList, compareFn) : uniq(resolvedList);\n  });\n}\n\nfunction useCounter(initialValue = 0, options = {}) {\n  const count = ref(initialValue);\n  const {\n    max = Infinity,\n    min = -Infinity\n  } = options;\n  const inc = (delta = 1) => count.value = Math.min(max, count.value + delta);\n  const dec = (delta = 1) => count.value = Math.max(min, count.value - delta);\n  const get = () => count.value;\n  const set = (val) => count.value = Math.max(min, Math.min(max, val));\n  const reset = (val = initialValue) => {\n    initialValue = val;\n    return set(val);\n  };\n  return { count, inc, dec, get, set, reset };\n}\n\nconst REGEX_PARSE = /^(\\d{4})[-/]?(\\d{1,2})?[-/]?(\\d{0,2})[Tt\\s]*(\\d{1,2})?:?(\\d{1,2})?:?(\\d{1,2})?[.:]?(\\d+)?$/;\nconst REGEX_FORMAT = /\\[([^\\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a{1,2}|A{1,2}|m{1,2}|s{1,2}|Z{1,2}|SSS/g;\nfunction defaultMeridiem(hours, minutes, isLowercase, hasPeriod) {\n  let m = hours < 12 ? \"AM\" : \"PM\";\n  if (hasPeriod)\n    m = m.split(\"\").reduce((acc, curr) => acc += `${curr}.`, \"\");\n  return isLowercase ? m.toLowerCase() : m;\n}\nfunction formatDate(date, formatStr, options = {}) {\n  var _a;\n  const years = date.getFullYear();\n  const month = date.getMonth();\n  const days = date.getDate();\n  const hours = date.getHours();\n  const minutes = date.getMinutes();\n  const seconds = date.getSeconds();\n  const milliseconds = date.getMilliseconds();\n  const day = date.getDay();\n  const meridiem = (_a = options.customMeridiem) != null ? _a : defaultMeridiem;\n  const matches = {\n    YY: () => String(years).slice(-2),\n    YYYY: () => years,\n    M: () => month + 1,\n    MM: () => `${month + 1}`.padStart(2, \"0\"),\n    MMM: () => date.toLocaleDateString(options.locales, { month: \"short\" }),\n    MMMM: () => date.toLocaleDateString(options.locales, { month: \"long\" }),\n    D: () => String(days),\n    DD: () => `${days}`.padStart(2, \"0\"),\n    H: () => String(hours),\n    HH: () => `${hours}`.padStart(2, \"0\"),\n    h: () => `${hours % 12 || 12}`.padStart(1, \"0\"),\n    hh: () => `${hours % 12 || 12}`.padStart(2, \"0\"),\n    m: () => String(minutes),\n    mm: () => `${minutes}`.padStart(2, \"0\"),\n    s: () => String(seconds),\n    ss: () => `${seconds}`.padStart(2, \"0\"),\n    SSS: () => `${milliseconds}`.padStart(3, \"0\"),\n    d: () => day,\n    dd: () => date.toLocaleDateString(options.locales, { weekday: \"narrow\" }),\n    ddd: () => date.toLocaleDateString(options.locales, { weekday: \"short\" }),\n    dddd: () => date.toLocaleDateString(options.locales, { weekday: \"long\" }),\n    A: () => meridiem(hours, minutes),\n    AA: () => meridiem(hours, minutes, false, true),\n    a: () => meridiem(hours, minutes, true),\n    aa: () => meridiem(hours, minutes, true, true)\n  };\n  return formatStr.replace(REGEX_FORMAT, (match, $1) => $1 || matches[match]());\n}\nfunction normalizeDate(date) {\n  if (date === null)\n    return /* @__PURE__ */ new Date(NaN);\n  if (date === void 0)\n    return /* @__PURE__ */ new Date();\n  if (date instanceof Date)\n    return new Date(date);\n  if (typeof date === \"string\" && !/Z$/i.test(date)) {\n    const d = date.match(REGEX_PARSE);\n    if (d) {\n      const m = d[2] - 1 || 0;\n      const ms = (d[7] || \"0\").substring(0, 3);\n      return new Date(d[1], m, d[3] || 1, d[4] || 0, d[5] || 0, d[6] || 0, ms);\n    }\n  }\n  return new Date(date);\n}\nfunction useDateFormat(date, formatStr = \"HH:mm:ss\", options = {}) {\n  return computed(() => formatDate(normalizeDate(toValue(date)), toValue(formatStr), options));\n}\n\nfunction useIntervalFn(cb, interval = 1e3, options = {}) {\n  const {\n    immediate = true,\n    immediateCallback = false\n  } = options;\n  let timer = null;\n  const isActive = ref(false);\n  function clean() {\n    if (timer) {\n      clearInterval(timer);\n      timer = null;\n    }\n  }\n  function pause() {\n    isActive.value = false;\n    clean();\n  }\n  function resume() {\n    const intervalValue = toValue(interval);\n    if (intervalValue <= 0)\n      return;\n    isActive.value = true;\n    if (immediateCallback)\n      cb();\n    clean();\n    timer = setInterval(cb, intervalValue);\n  }\n  if (immediate && isClient)\n    resume();\n  if (isRef(interval) || typeof interval === \"function\") {\n    const stopWatch = watch(interval, () => {\n      if (isActive.value && isClient)\n        resume();\n    });\n    tryOnScopeDispose(stopWatch);\n  }\n  tryOnScopeDispose(pause);\n  return {\n    isActive,\n    pause,\n    resume\n  };\n}\n\nvar __defProp$8 = Object.defineProperty;\nvar __getOwnPropSymbols$a = Object.getOwnPropertySymbols;\nvar __hasOwnProp$a = Object.prototype.hasOwnProperty;\nvar __propIsEnum$a = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$8 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$a.call(b, prop))\n      __defNormalProp$8(a, prop, b[prop]);\n  if (__getOwnPropSymbols$a)\n    for (var prop of __getOwnPropSymbols$a(b)) {\n      if (__propIsEnum$a.call(b, prop))\n        __defNormalProp$8(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useInterval(interval = 1e3, options = {}) {\n  const {\n    controls: exposeControls = false,\n    immediate = true,\n    callback\n  } = options;\n  const counter = ref(0);\n  const update = () => counter.value += 1;\n  const reset = () => {\n    counter.value = 0;\n  };\n  const controls = useIntervalFn(\n    callback ? () => {\n      update();\n      callback(counter.value);\n    } : update,\n    interval,\n    { immediate }\n  );\n  if (exposeControls) {\n    return __spreadValues$8({\n      counter,\n      reset\n    }, controls);\n  } else {\n    return counter;\n  }\n}\n\nfunction useLastChanged(source, options = {}) {\n  var _a;\n  const ms = ref((_a = options.initialValue) != null ? _a : null);\n  watch(\n    source,\n    () => ms.value = timestamp(),\n    options\n  );\n  return ms;\n}\n\nfunction useTimeoutFn(cb, interval, options = {}) {\n  const {\n    immediate = true\n  } = options;\n  const isPending = ref(false);\n  let timer = null;\n  function clear() {\n    if (timer) {\n      clearTimeout(timer);\n      timer = null;\n    }\n  }\n  function stop() {\n    isPending.value = false;\n    clear();\n  }\n  function start(...args) {\n    clear();\n    isPending.value = true;\n    timer = setTimeout(() => {\n      isPending.value = false;\n      timer = null;\n      cb(...args);\n    }, toValue(interval));\n  }\n  if (immediate) {\n    isPending.value = true;\n    if (isClient)\n      start();\n  }\n  tryOnScopeDispose(stop);\n  return {\n    isPending: readonly(isPending),\n    start,\n    stop\n  };\n}\n\nvar __defProp$7 = Object.defineProperty;\nvar __getOwnPropSymbols$9 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$9 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$9 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$7 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$9.call(b, prop))\n      __defNormalProp$7(a, prop, b[prop]);\n  if (__getOwnPropSymbols$9)\n    for (var prop of __getOwnPropSymbols$9(b)) {\n      if (__propIsEnum$9.call(b, prop))\n        __defNormalProp$7(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useTimeout(interval = 1e3, options = {}) {\n  const {\n    controls: exposeControls = false,\n    callback\n  } = options;\n  const controls = useTimeoutFn(\n    callback != null ? callback : noop,\n    interval,\n    options\n  );\n  const ready = computed(() => !controls.isPending.value);\n  if (exposeControls) {\n    return __spreadValues$7({\n      ready\n    }, controls);\n  } else {\n    return ready;\n  }\n}\n\nfunction useToNumber(value, options = {}) {\n  const {\n    method = \"parseFloat\",\n    radix,\n    nanToZero\n  } = options;\n  return computed(() => {\n    let resolved = toValue(value);\n    if (typeof resolved === \"string\")\n      resolved = Number[method](resolved, radix);\n    if (nanToZero && isNaN(resolved))\n      resolved = 0;\n    return resolved;\n  });\n}\n\nfunction useToString(value) {\n  return computed(() => `${toValue(value)}`);\n}\n\nfunction useToggle(initialValue = false, options = {}) {\n  const {\n    truthyValue = true,\n    falsyValue = false\n  } = options;\n  const valueIsRef = isRef(initialValue);\n  const _value = ref(initialValue);\n  function toggle(value) {\n    if (arguments.length) {\n      _value.value = value;\n      return _value.value;\n    } else {\n      const truthy = toValue(truthyValue);\n      _value.value = _value.value === truthy ? toValue(falsyValue) : truthy;\n      return _value.value;\n    }\n  }\n  if (valueIsRef)\n    return toggle;\n  else\n    return [_value, toggle];\n}\n\nfunction watchArray(source, cb, options) {\n  let oldList = (options == null ? void 0 : options.immediate) ? [] : [\n    ...source instanceof Function ? source() : Array.isArray(source) ? source : toValue(source)\n  ];\n  return watch(source, (newList, _, onCleanup) => {\n    const oldListRemains = new Array(oldList.length);\n    const added = [];\n    for (const obj of newList) {\n      let found = false;\n      for (let i = 0; i < oldList.length; i++) {\n        if (!oldListRemains[i] && obj === oldList[i]) {\n          oldListRemains[i] = true;\n          found = true;\n          break;\n        }\n      }\n      if (!found)\n        added.push(obj);\n    }\n    const removed = oldList.filter((_2, i) => !oldListRemains[i]);\n    cb(newList, oldList, added, removed, onCleanup);\n    oldList = [...newList];\n  }, options);\n}\n\nvar __getOwnPropSymbols$8 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$8 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$8 = Object.prototype.propertyIsEnumerable;\nvar __objRest$5 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$8.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$8)\n    for (var prop of __getOwnPropSymbols$8(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$8.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction watchWithFilter(source, cb, options = {}) {\n  const _a = options, {\n    eventFilter = bypassFilter\n  } = _a, watchOptions = __objRest$5(_a, [\n    \"eventFilter\"\n  ]);\n  return watch(\n    source,\n    createFilterWrapper(\n      eventFilter,\n      cb\n    ),\n    watchOptions\n  );\n}\n\nvar __getOwnPropSymbols$7 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$7 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$7 = Object.prototype.propertyIsEnumerable;\nvar __objRest$4 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$7.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$7)\n    for (var prop of __getOwnPropSymbols$7(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$7.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction watchAtMost(source, cb, options) {\n  const _a = options, {\n    count\n  } = _a, watchOptions = __objRest$4(_a, [\n    \"count\"\n  ]);\n  const current = ref(0);\n  const stop = watchWithFilter(\n    source,\n    (...args) => {\n      current.value += 1;\n      if (current.value >= toValue(count))\n        nextTick(() => stop());\n      cb(...args);\n    },\n    watchOptions\n  );\n  return { count: current, stop };\n}\n\nvar __defProp$6 = Object.defineProperty;\nvar __defProps$6 = Object.defineProperties;\nvar __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$6 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$6 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$6 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$6 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$6.call(b, prop))\n      __defNormalProp$6(a, prop, b[prop]);\n  if (__getOwnPropSymbols$6)\n    for (var prop of __getOwnPropSymbols$6(b)) {\n      if (__propIsEnum$6.call(b, prop))\n        __defNormalProp$6(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$6 = (a, b) => __defProps$6(a, __getOwnPropDescs$6(b));\nvar __objRest$3 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$6.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$6)\n    for (var prop of __getOwnPropSymbols$6(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$6.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction watchDebounced(source, cb, options = {}) {\n  const _a = options, {\n    debounce = 0,\n    maxWait = void 0\n  } = _a, watchOptions = __objRest$3(_a, [\n    \"debounce\",\n    \"maxWait\"\n  ]);\n  return watchWithFilter(\n    source,\n    cb,\n    __spreadProps$6(__spreadValues$6({}, watchOptions), {\n      eventFilter: debounceFilter(debounce, { maxWait })\n    })\n  );\n}\n\nvar __defProp$5 = Object.defineProperty;\nvar __defProps$5 = Object.defineProperties;\nvar __getOwnPropDescs$5 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$5 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$5 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$5 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$5 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$5.call(b, prop))\n      __defNormalProp$5(a, prop, b[prop]);\n  if (__getOwnPropSymbols$5)\n    for (var prop of __getOwnPropSymbols$5(b)) {\n      if (__propIsEnum$5.call(b, prop))\n        __defNormalProp$5(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$5 = (a, b) => __defProps$5(a, __getOwnPropDescs$5(b));\nfunction watchDeep(source, cb, options) {\n  return watch(\n    source,\n    cb,\n    __spreadProps$5(__spreadValues$5({}, options), {\n      deep: true\n    })\n  );\n}\n\nvar __defProp$4 = Object.defineProperty;\nvar __defProps$4 = Object.defineProperties;\nvar __getOwnPropDescs$4 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$4 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$4 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$4 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$4 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$4.call(b, prop))\n      __defNormalProp$4(a, prop, b[prop]);\n  if (__getOwnPropSymbols$4)\n    for (var prop of __getOwnPropSymbols$4(b)) {\n      if (__propIsEnum$4.call(b, prop))\n        __defNormalProp$4(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$4 = (a, b) => __defProps$4(a, __getOwnPropDescs$4(b));\nvar __objRest$2 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$4.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$4)\n    for (var prop of __getOwnPropSymbols$4(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$4.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction watchIgnorable(source, cb, options = {}) {\n  const _a = options, {\n    eventFilter = bypassFilter\n  } = _a, watchOptions = __objRest$2(_a, [\n    \"eventFilter\"\n  ]);\n  const filteredCb = createFilterWrapper(\n    eventFilter,\n    cb\n  );\n  let ignoreUpdates;\n  let ignorePrevAsyncUpdates;\n  let stop;\n  if (watchOptions.flush === \"sync\") {\n    const ignore = ref(false);\n    ignorePrevAsyncUpdates = () => {\n    };\n    ignoreUpdates = (updater) => {\n      ignore.value = true;\n      updater();\n      ignore.value = false;\n    };\n    stop = watch(\n      source,\n      (...args) => {\n        if (!ignore.value)\n          filteredCb(...args);\n      },\n      watchOptions\n    );\n  } else {\n    const disposables = [];\n    const ignoreCounter = ref(0);\n    const syncCounter = ref(0);\n    ignorePrevAsyncUpdates = () => {\n      ignoreCounter.value = syncCounter.value;\n    };\n    disposables.push(\n      watch(\n        source,\n        () => {\n          syncCounter.value++;\n        },\n        __spreadProps$4(__spreadValues$4({}, watchOptions), { flush: \"sync\" })\n      )\n    );\n    ignoreUpdates = (updater) => {\n      const syncCounterPrev = syncCounter.value;\n      updater();\n      ignoreCounter.value += syncCounter.value - syncCounterPrev;\n    };\n    disposables.push(\n      watch(\n        source,\n        (...args) => {\n          const ignore = ignoreCounter.value > 0 && ignoreCounter.value === syncCounter.value;\n          ignoreCounter.value = 0;\n          syncCounter.value = 0;\n          if (ignore)\n            return;\n          filteredCb(...args);\n        },\n        watchOptions\n      )\n    );\n    stop = () => {\n      disposables.forEach((fn) => fn());\n    };\n  }\n  return { stop, ignoreUpdates, ignorePrevAsyncUpdates };\n}\n\nvar __defProp$3 = Object.defineProperty;\nvar __defProps$3 = Object.defineProperties;\nvar __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$3 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$3 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$3 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$3 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$3.call(b, prop))\n      __defNormalProp$3(a, prop, b[prop]);\n  if (__getOwnPropSymbols$3)\n    for (var prop of __getOwnPropSymbols$3(b)) {\n      if (__propIsEnum$3.call(b, prop))\n        __defNormalProp$3(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$3 = (a, b) => __defProps$3(a, __getOwnPropDescs$3(b));\nfunction watchImmediate(source, cb, options) {\n  return watch(\n    source,\n    cb,\n    __spreadProps$3(__spreadValues$3({}, options), {\n      immediate: true\n    })\n  );\n}\n\nfunction watchOnce(source, cb, options) {\n  const stop = watch(source, (...args) => {\n    nextTick(() => stop());\n    return cb(...args);\n  }, options);\n}\n\nvar __defProp$2 = Object.defineProperty;\nvar __defProps$2 = Object.defineProperties;\nvar __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$2 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$2 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$2 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$2 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$2.call(b, prop))\n      __defNormalProp$2(a, prop, b[prop]);\n  if (__getOwnPropSymbols$2)\n    for (var prop of __getOwnPropSymbols$2(b)) {\n      if (__propIsEnum$2.call(b, prop))\n        __defNormalProp$2(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$2 = (a, b) => __defProps$2(a, __getOwnPropDescs$2(b));\nvar __objRest$1 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$2.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$2)\n    for (var prop of __getOwnPropSymbols$2(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$2.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction watchPausable(source, cb, options = {}) {\n  const _a = options, {\n    eventFilter: filter\n  } = _a, watchOptions = __objRest$1(_a, [\n    \"eventFilter\"\n  ]);\n  const { eventFilter, pause, resume, isActive } = pausableFilter(filter);\n  const stop = watchWithFilter(\n    source,\n    cb,\n    __spreadProps$2(__spreadValues$2({}, watchOptions), {\n      eventFilter\n    })\n  );\n  return { stop, pause, resume, isActive };\n}\n\nvar __defProp$1 = Object.defineProperty;\nvar __defProps$1 = Object.defineProperties;\nvar __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$1 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$1 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$1 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$1.call(b, prop))\n      __defNormalProp$1(a, prop, b[prop]);\n  if (__getOwnPropSymbols$1)\n    for (var prop of __getOwnPropSymbols$1(b)) {\n      if (__propIsEnum$1.call(b, prop))\n        __defNormalProp$1(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$1 = (a, b) => __defProps$1(a, __getOwnPropDescs$1(b));\nvar __objRest = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$1.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$1)\n    for (var prop of __getOwnPropSymbols$1(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$1.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction watchThrottled(source, cb, options = {}) {\n  const _a = options, {\n    throttle = 0,\n    trailing = true,\n    leading = true\n  } = _a, watchOptions = __objRest(_a, [\n    \"throttle\",\n    \"trailing\",\n    \"leading\"\n  ]);\n  return watchWithFilter(\n    source,\n    cb,\n    __spreadProps$1(__spreadValues$1({}, watchOptions), {\n      eventFilter: throttleFilter(throttle, trailing, leading)\n    })\n  );\n}\n\nvar __defProp = Object.defineProperty;\nvar __defProps = Object.defineProperties;\nvar __getOwnPropDescs = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols = Object.getOwnPropertySymbols;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __propIsEnum = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp.call(b, prop))\n      __defNormalProp(a, prop, b[prop]);\n  if (__getOwnPropSymbols)\n    for (var prop of __getOwnPropSymbols(b)) {\n      if (__propIsEnum.call(b, prop))\n        __defNormalProp(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));\nfunction watchTriggerable(source, cb, options = {}) {\n  let cleanupFn;\n  function onEffect() {\n    if (!cleanupFn)\n      return;\n    const fn = cleanupFn;\n    cleanupFn = void 0;\n    fn();\n  }\n  function onCleanup(callback) {\n    cleanupFn = callback;\n  }\n  const _cb = (value, oldValue) => {\n    onEffect();\n    return cb(value, oldValue, onCleanup);\n  };\n  const res = watchIgnorable(source, _cb, options);\n  const { ignoreUpdates } = res;\n  const trigger = () => {\n    let res2;\n    ignoreUpdates(() => {\n      res2 = _cb(getWatchSources(source), getOldValue(source));\n    });\n    return res2;\n  };\n  return __spreadProps(__spreadValues({}, res), {\n    trigger\n  });\n}\nfunction getWatchSources(sources) {\n  if (isReactive(sources))\n    return sources;\n  if (Array.isArray(sources))\n    return sources.map((item) => toValue(item));\n  return toValue(sources);\n}\nfunction getOldValue(source) {\n  return Array.isArray(source) ? source.map(() => void 0) : void 0;\n}\n\nfunction whenever(source, cb, options) {\n  return watch(\n    source,\n    (v, ov, onInvalidate) => {\n      if (v)\n        cb(v, ov, onInvalidate);\n    },\n    options\n  );\n}\n\nexport { assert, refAutoReset as autoResetRef, bypassFilter, clamp, computedEager, computedWithControl, containsProp, computedWithControl as controlledComputed, controlledRef, createEventHook, createFilterWrapper, createGlobalState, createInjectionState, reactify as createReactiveFn, createSharedComposable, createSingletonPromise, debounceFilter, refDebounced as debouncedRef, watchDebounced as debouncedWatch, directiveHooks, computedEager as eagerComputed, extendRef, formatDate, get, hasOwn, identity, watchIgnorable as ignorableWatch, increaseWithUnit, invoke, isClient, isDef, isDefined, isIOS, isObject, makeDestructurable, noop, normalizeDate, notNullish, now, objectEntries, objectOmit, objectPick, pausableFilter, watchPausable as pausableWatch, promiseTimeout, rand, reactify, reactifyObject, reactiveComputed, reactiveOmit, reactivePick, refAutoReset, refDebounced, refDefault, refThrottled, refWithControl, resolveRef, resolveUnref, set, syncRef, syncRefs, throttleFilter, refThrottled as throttledRef, watchThrottled as throttledWatch, timestamp, toReactive, toRef, toRefs, toValue, tryOnBeforeMount, tryOnBeforeUnmount, tryOnMounted, tryOnScopeDispose, tryOnUnmounted, until, useArrayDifference, useArrayEvery, useArrayFilter, useArrayFind, useArrayFindIndex, useArrayFindLast, useArrayIncludes, useArrayJoin, useArrayMap, useArrayReduce, useArraySome, useArrayUnique, useCounter, useDateFormat, refDebounced as useDebounce, useDebounceFn, useInterval, useIntervalFn, useLastChanged, refThrottled as useThrottle, useThrottleFn, useTimeout, useTimeoutFn, useToNumber, useToString, useToggle, watchArray, watchAtMost, watchDebounced, watchDeep, watchIgnorable, watchImmediate, watchOnce, watchPausable, watchThrottled, watchTriggerable, watchWithFilter, whenever };\n","import { noop, makeDestructurable, toValue, isClient, tryOnScopeDispose, isIOS, tryOnMounted, computedWithControl, isObject, objectOmit, promiseTimeout, toRef, increaseWithUnit, objectEntries, useTimeoutFn, pausableWatch, createEventHook, timestamp, pausableFilter, watchIgnorable, debounceFilter, createFilterWrapper, bypassFilter, createSingletonPromise, toRefs, notNullish, containsProp, until, hasOwn, throttleFilter, useDebounceFn, useThrottleFn, useIntervalFn, clamp, syncRef, objectPick, tryOnUnmounted, watchWithFilter, identity, isDef } from '@vueuse/shared';\nexport * from '@vueuse/shared';\nimport { isRef, ref, shallowRef, watchEffect, computed, inject, isVue3, version, defineComponent, h, TransitionGroup, shallowReactive, Fragment, watch, getCurrentInstance, customRef, onUpdated, onMounted, readonly, nextTick, reactive, markRaw, getCurrentScope, isVue2, set, del, isReadonly, onBeforeUpdate } from 'vue-demi';\nimport { useMutationObserver as useMutationObserver$1 } from '@vueuse/core';\nimport { computed as computed$1 } from '@vue/reactivity';\n\nfunction computedAsync(evaluationCallback, initialState, optionsOrRef) {\n  let options;\n  if (isRef(optionsOrRef)) {\n    options = {\n      evaluating: optionsOrRef\n    };\n  } else {\n    options = optionsOrRef || {};\n  }\n  const {\n    lazy = false,\n    evaluating = void 0,\n    shallow = true,\n    onError = noop\n  } = options;\n  const started = ref(!lazy);\n  const current = shallow ? shallowRef(initialState) : ref(initialState);\n  let counter = 0;\n  watchEffect(async (onInvalidate) => {\n    if (!started.value)\n      return;\n    counter++;\n    const counterAtBeginning = counter;\n    let hasFinished = false;\n    if (evaluating) {\n      Promise.resolve().then(() => {\n        evaluating.value = true;\n      });\n    }\n    try {\n      const result = await evaluationCallback((cancelCallback) => {\n        onInvalidate(() => {\n          if (evaluating)\n            evaluating.value = false;\n          if (!hasFinished)\n            cancelCallback();\n        });\n      });\n      if (counterAtBeginning === counter)\n        current.value = result;\n    } catch (e) {\n      onError(e);\n    } finally {\n      if (evaluating && counterAtBeginning === counter)\n        evaluating.value = false;\n      hasFinished = true;\n    }\n  });\n  if (lazy) {\n    return computed(() => {\n      started.value = true;\n      return current.value;\n    });\n  } else {\n    return current;\n  }\n}\n\nfunction computedInject(key, options, defaultSource, treatDefaultAsFactory) {\n  let source = inject(key);\n  if (defaultSource)\n    source = inject(key, defaultSource);\n  if (treatDefaultAsFactory)\n    source = inject(key, defaultSource, treatDefaultAsFactory);\n  if (typeof options === \"function\") {\n    return computed((ctx) => options(source, ctx));\n  } else {\n    return computed({\n      get: (ctx) => options.get(source, ctx),\n      set: options.set\n    });\n  }\n}\n\nvar __defProp$o = Object.defineProperty;\nvar __defProps$b = Object.defineProperties;\nvar __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$r = Object.getOwnPropertySymbols;\nvar __hasOwnProp$r = Object.prototype.hasOwnProperty;\nvar __propIsEnum$r = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$o = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$r.call(b, prop))\n      __defNormalProp$o(a, prop, b[prop]);\n  if (__getOwnPropSymbols$r)\n    for (var prop of __getOwnPropSymbols$r(b)) {\n      if (__propIsEnum$r.call(b, prop))\n        __defNormalProp$o(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));\nfunction createReusableTemplate() {\n  if (!isVue3 && !version.startsWith(\"2.7.\")) {\n    if (process.env.NODE_ENV !== \"production\")\n      throw new Error(\"[VueUse] createReusableTemplate only works in Vue 2.7 or above.\");\n    return;\n  }\n  let render;\n  const define = /* #__PURE__ */ defineComponent({\n    setup(_, { slots }) {\n      return () => {\n        render = slots.default;\n      };\n    }\n  });\n  const reuse = /* #__PURE__ */ defineComponent({\n    inheritAttrs: false,\n    setup(_, { attrs, slots }) {\n      return () => {\n        if (!render && process.env.NODE_ENV !== \"production\")\n          throw new Error(\"[VueUse] Failed to find the definition of reusable template\");\n        return render == null ? void 0 : render(__spreadProps$b(__spreadValues$o({}, attrs), { $slots: slots }));\n      };\n    }\n  });\n  return makeDestructurable(\n    { define, reuse },\n    [define, reuse]\n  );\n}\n\nfunction createTemplatePromise(options = {}) {\n  if (!isVue3) {\n    if (process.env.NODE_ENV !== \"production\")\n      throw new Error(\"[VueUse] createTemplatePromise only works in Vue 3 or above.\");\n    return;\n  }\n  let index = 0;\n  const instances = ref([]);\n  function create(...args) {\n    const props = shallowReactive({\n      key: index++,\n      args,\n      promise: void 0,\n      resolve: () => {\n      },\n      reject: () => {\n      },\n      isResolving: false,\n      options\n    });\n    instances.value.push(props);\n    props.promise = new Promise((_resolve, _reject) => {\n      props.resolve = (v) => {\n        props.isResolving = true;\n        return _resolve(v);\n      };\n      props.reject = _reject;\n    }).finally(() => {\n      props.promise = void 0;\n      const index2 = instances.value.indexOf(props);\n      if (index2 !== -1)\n        instances.value.splice(index2, 1);\n    });\n    return props.promise;\n  }\n  function start(...args) {\n    if (options.singleton && instances.value.length > 0)\n      return instances.value[0].promise;\n    return create(...args);\n  }\n  const component = /* #__PURE__ */ defineComponent((_, { slots }) => {\n    const renderList = () => instances.value.map((props) => {\n      var _a;\n      return h(Fragment, { key: props.key }, (_a = slots.default) == null ? void 0 : _a.call(slots, props));\n    });\n    if (options.transition)\n      return () => h(TransitionGroup, options.transition, renderList);\n    return renderList;\n  });\n  component.start = start;\n  return component;\n}\n\nfunction createUnrefFn(fn) {\n  return function(...args) {\n    return fn.apply(this, args.map((i) => toValue(i)));\n  };\n}\n\nfunction unrefElement(elRef) {\n  var _a;\n  const plain = toValue(elRef);\n  return (_a = plain == null ? void 0 : plain.$el) != null ? _a : plain;\n}\n\nconst defaultWindow = isClient ? window : void 0;\nconst defaultDocument = isClient ? window.document : void 0;\nconst defaultNavigator = isClient ? window.navigator : void 0;\nconst defaultLocation = isClient ? window.location : void 0;\n\nfunction useEventListener(...args) {\n  let target;\n  let events;\n  let listeners;\n  let options;\n  if (typeof args[0] === \"string\" || Array.isArray(args[0])) {\n    [events, listeners, options] = args;\n    target = defaultWindow;\n  } else {\n    [target, events, listeners, options] = args;\n  }\n  if (!target)\n    return noop;\n  if (!Array.isArray(events))\n    events = [events];\n  if (!Array.isArray(listeners))\n    listeners = [listeners];\n  const cleanups = [];\n  const cleanup = () => {\n    cleanups.forEach((fn) => fn());\n    cleanups.length = 0;\n  };\n  const register = (el, event, listener, options2) => {\n    el.addEventListener(event, listener, options2);\n    return () => el.removeEventListener(event, listener, options2);\n  };\n  const stopWatch = watch(\n    () => [unrefElement(target), toValue(options)],\n    ([el, options2]) => {\n      cleanup();\n      if (!el)\n        return;\n      cleanups.push(\n        ...events.flatMap((event) => {\n          return listeners.map((listener) => register(el, event, listener, options2));\n        })\n      );\n    },\n    { immediate: true, flush: \"post\" }\n  );\n  const stop = () => {\n    stopWatch();\n    cleanup();\n  };\n  tryOnScopeDispose(stop);\n  return stop;\n}\n\nlet _iOSWorkaround = false;\nfunction onClickOutside(target, handler, options = {}) {\n  const { window = defaultWindow, ignore = [], capture = true, detectIframe = false } = options;\n  if (!window)\n    return;\n  if (isIOS && !_iOSWorkaround) {\n    _iOSWorkaround = true;\n    Array.from(window.document.body.children).forEach((el) => el.addEventListener(\"click\", noop));\n  }\n  let shouldListen = true;\n  const shouldIgnore = (event) => {\n    return ignore.some((target2) => {\n      if (typeof target2 === \"string\") {\n        return Array.from(window.document.querySelectorAll(target2)).some((el) => el === event.target || event.composedPath().includes(el));\n      } else {\n        const el = unrefElement(target2);\n        return el && (event.target === el || event.composedPath().includes(el));\n      }\n    });\n  };\n  const listener = (event) => {\n    const el = unrefElement(target);\n    if (!el || el === event.target || event.composedPath().includes(el))\n      return;\n    if (event.detail === 0)\n      shouldListen = !shouldIgnore(event);\n    if (!shouldListen) {\n      shouldListen = true;\n      return;\n    }\n    handler(event);\n  };\n  const cleanup = [\n    useEventListener(window, \"click\", listener, { passive: true, capture }),\n    useEventListener(window, \"pointerdown\", (e) => {\n      const el = unrefElement(target);\n      if (el)\n        shouldListen = !e.composedPath().includes(el) && !shouldIgnore(e);\n    }, { passive: true }),\n    detectIframe && useEventListener(window, \"blur\", (event) => {\n      var _a;\n      const el = unrefElement(target);\n      if (((_a = window.document.activeElement) == null ? void 0 : _a.tagName) === \"IFRAME\" && !(el == null ? void 0 : el.contains(window.document.activeElement)))\n        handler(event);\n    })\n  ].filter(Boolean);\n  const stop = () => cleanup.forEach((fn) => fn());\n  return stop;\n}\n\nvar __defProp$n = Object.defineProperty;\nvar __defProps$a = Object.defineProperties;\nvar __getOwnPropDescs$a = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$q = Object.getOwnPropertySymbols;\nvar __hasOwnProp$q = Object.prototype.hasOwnProperty;\nvar __propIsEnum$q = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$n = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$q.call(b, prop))\n      __defNormalProp$n(a, prop, b[prop]);\n  if (__getOwnPropSymbols$q)\n    for (var prop of __getOwnPropSymbols$q(b)) {\n      if (__propIsEnum$q.call(b, prop))\n        __defNormalProp$n(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$a = (a, b) => __defProps$a(a, __getOwnPropDescs$a(b));\nfunction createKeyPredicate(keyFilter) {\n  if (typeof keyFilter === \"function\")\n    return keyFilter;\n  else if (typeof keyFilter === \"string\")\n    return (event) => event.key === keyFilter;\n  else if (Array.isArray(keyFilter))\n    return (event) => keyFilter.includes(event.key);\n  return () => true;\n}\nfunction onKeyStroke(...args) {\n  let key;\n  let handler;\n  let options = {};\n  if (args.length === 3) {\n    key = args[0];\n    handler = args[1];\n    options = args[2];\n  } else if (args.length === 2) {\n    if (typeof args[1] === \"object\") {\n      key = true;\n      handler = args[0];\n      options = args[1];\n    } else {\n      key = args[0];\n      handler = args[1];\n    }\n  } else {\n    key = true;\n    handler = args[0];\n  }\n  const {\n    target = defaultWindow,\n    eventName = \"keydown\",\n    passive = false,\n    dedupe = false\n  } = options;\n  const predicate = createKeyPredicate(key);\n  const listener = (e) => {\n    if (e.repeat && toValue(dedupe))\n      return;\n    if (predicate(e))\n      handler(e);\n  };\n  return useEventListener(target, eventName, listener, passive);\n}\nfunction onKeyDown(key, handler, options = {}) {\n  return onKeyStroke(key, handler, __spreadProps$a(__spreadValues$n({}, options), { eventName: \"keydown\" }));\n}\nfunction onKeyPressed(key, handler, options = {}) {\n  return onKeyStroke(key, handler, __spreadProps$a(__spreadValues$n({}, options), { eventName: \"keypress\" }));\n}\nfunction onKeyUp(key, handler, options = {}) {\n  return onKeyStroke(key, handler, __spreadProps$a(__spreadValues$n({}, options), { eventName: \"keyup\" }));\n}\n\nconst DEFAULT_DELAY = 500;\nfunction onLongPress(target, handler, options) {\n  var _a, _b;\n  const elementRef = computed(() => unrefElement(target));\n  let timeout;\n  function clear() {\n    if (timeout) {\n      clearTimeout(timeout);\n      timeout = void 0;\n    }\n  }\n  function onDown(ev) {\n    var _a2, _b2, _c, _d;\n    if (((_a2 = options == null ? void 0 : options.modifiers) == null ? void 0 : _a2.self) && ev.target !== elementRef.value)\n      return;\n    clear();\n    if ((_b2 = options == null ? void 0 : options.modifiers) == null ? void 0 : _b2.prevent)\n      ev.preventDefault();\n    if ((_c = options == null ? void 0 : options.modifiers) == null ? void 0 : _c.stop)\n      ev.stopPropagation();\n    timeout = setTimeout(\n      () => handler(ev),\n      (_d = options == null ? void 0 : options.delay) != null ? _d : DEFAULT_DELAY\n    );\n  }\n  const listenerOptions = {\n    capture: (_a = options == null ? void 0 : options.modifiers) == null ? void 0 : _a.capture,\n    once: (_b = options == null ? void 0 : options.modifiers) == null ? void 0 : _b.once\n  };\n  useEventListener(elementRef, \"pointerdown\", onDown, listenerOptions);\n  useEventListener(elementRef, \"pointerup\", clear, listenerOptions);\n  useEventListener(elementRef, \"pointerleave\", clear, listenerOptions);\n}\n\nfunction isFocusedElementEditable() {\n  const { activeElement, body } = document;\n  if (!activeElement)\n    return false;\n  if (activeElement === body)\n    return false;\n  switch (activeElement.tagName) {\n    case \"INPUT\":\n    case \"TEXTAREA\":\n      return true;\n  }\n  return activeElement.hasAttribute(\"contenteditable\");\n}\nfunction isTypedCharValid({\n  keyCode,\n  metaKey,\n  ctrlKey,\n  altKey\n}) {\n  if (metaKey || ctrlKey || altKey)\n    return false;\n  if (keyCode >= 48 && keyCode <= 57)\n    return true;\n  if (keyCode >= 65 && keyCode <= 90)\n    return true;\n  if (keyCode >= 97 && keyCode <= 122)\n    return true;\n  return false;\n}\nfunction onStartTyping(callback, options = {}) {\n  const { document: document2 = defaultDocument } = options;\n  const keydown = (event) => {\n    !isFocusedElementEditable() && isTypedCharValid(event) && callback(event);\n  };\n  if (document2)\n    useEventListener(document2, \"keydown\", keydown, { passive: true });\n}\n\nfunction templateRef(key, initialValue = null) {\n  const instance = getCurrentInstance();\n  let _trigger = () => {\n  };\n  const element = customRef((track, trigger) => {\n    _trigger = trigger;\n    return {\n      get() {\n        var _a, _b;\n        track();\n        return (_b = (_a = instance == null ? void 0 : instance.proxy) == null ? void 0 : _a.$refs[key]) != null ? _b : initialValue;\n      },\n      set() {\n      }\n    };\n  });\n  tryOnMounted(_trigger);\n  onUpdated(_trigger);\n  return element;\n}\n\nfunction useActiveElement(options = {}) {\n  var _a;\n  const { window = defaultWindow } = options;\n  const document = (_a = options.document) != null ? _a : window == null ? void 0 : window.document;\n  const activeElement = computedWithControl(\n    () => null,\n    () => document == null ? void 0 : document.activeElement\n  );\n  if (window) {\n    useEventListener(window, \"blur\", (event) => {\n      if (event.relatedTarget !== null)\n        return;\n      activeElement.trigger();\n    }, true);\n    useEventListener(window, \"focus\", activeElement.trigger, true);\n  }\n  return activeElement;\n}\n\nfunction useMounted() {\n  const isMounted = ref(false);\n  if (getCurrentInstance()) {\n    onMounted(() => {\n      isMounted.value = true;\n    });\n  }\n  return isMounted;\n}\n\nfunction useSupported(callback) {\n  const isMounted = useMounted();\n  return computed(() => {\n    isMounted.value;\n    return Boolean(callback());\n  });\n}\n\nfunction useRafFn(fn, options = {}) {\n  const {\n    immediate = true,\n    window = defaultWindow\n  } = options;\n  const isActive = ref(false);\n  let previousFrameTimestamp = 0;\n  let rafId = null;\n  function loop(timestamp) {\n    if (!isActive.value || !window)\n      return;\n    const delta = timestamp - previousFrameTimestamp;\n    fn({ delta, timestamp });\n    previousFrameTimestamp = timestamp;\n    rafId = window.requestAnimationFrame(loop);\n  }\n  function resume() {\n    if (!isActive.value && window) {\n      isActive.value = true;\n      rafId = window.requestAnimationFrame(loop);\n    }\n  }\n  function pause() {\n    isActive.value = false;\n    if (rafId != null && window) {\n      window.cancelAnimationFrame(rafId);\n      rafId = null;\n    }\n  }\n  if (immediate)\n    resume();\n  tryOnScopeDispose(pause);\n  return {\n    isActive: readonly(isActive),\n    pause,\n    resume\n  };\n}\n\nfunction useAnimate(target, keyframes, options) {\n  let config;\n  let animateOptions;\n  if (isObject(options)) {\n    config = options;\n    animateOptions = objectOmit(options, [\"window\", \"immediate\", \"commitStyles\", \"persist\", \"onReady\", \"onError\"]);\n  } else {\n    config = { duration: options };\n    animateOptions = options;\n  }\n  const {\n    window = defaultWindow,\n    immediate = true,\n    commitStyles,\n    persist,\n    playbackRate: _playbackRate = 1,\n    onReady,\n    onError = (e) => {\n      console.error(e);\n    }\n  } = config;\n  const isSupported = useSupported(() => window && HTMLElement && \"animate\" in HTMLElement.prototype);\n  const animate = shallowRef(void 0);\n  const store = shallowReactive({\n    startTime: null,\n    currentTime: null,\n    timeline: null,\n    playbackRate: _playbackRate,\n    pending: false,\n    playState: immediate ? \"idle\" : \"paused\",\n    replaceState: \"active\"\n  });\n  const pending = computed(() => store.pending);\n  const playState = computed(() => store.playState);\n  const replaceState = computed(() => store.replaceState);\n  const startTime = computed({\n    get() {\n      return store.startTime;\n    },\n    set(value) {\n      store.startTime = value;\n      if (animate.value)\n        animate.value.startTime = value;\n    }\n  });\n  const currentTime = computed({\n    get() {\n      return store.currentTime;\n    },\n    set(value) {\n      store.currentTime = value;\n      if (animate.value) {\n        animate.value.currentTime = value;\n        syncResume();\n      }\n    }\n  });\n  const timeline = computed({\n    get() {\n      return store.timeline;\n    },\n    set(value) {\n      store.timeline = value;\n      if (animate.value)\n        animate.value.timeline = value;\n    }\n  });\n  const playbackRate = computed({\n    get() {\n      return store.playbackRate;\n    },\n    set(value) {\n      store.playbackRate = value;\n      if (animate.value)\n        animate.value.playbackRate = value;\n    }\n  });\n  const play = () => {\n    if (animate.value) {\n      try {\n        animate.value.play();\n        syncResume();\n      } catch (e) {\n        syncPause();\n        onError(e);\n      }\n    } else {\n      update();\n    }\n  };\n  const pause = () => {\n    var _a;\n    try {\n      (_a = animate.value) == null ? void 0 : _a.pause();\n      syncPause();\n    } catch (e) {\n      onError(e);\n    }\n  };\n  const reverse = () => {\n    var _a;\n    !animate.value && update();\n    try {\n      (_a = animate.value) == null ? void 0 : _a.reverse();\n      syncResume();\n    } catch (e) {\n      syncPause();\n      onError(e);\n    }\n  };\n  const finish = () => {\n    var _a;\n    try {\n      (_a = animate.value) == null ? void 0 : _a.finish();\n      syncPause();\n    } catch (e) {\n      onError(e);\n    }\n  };\n  const cancel = () => {\n    var _a;\n    try {\n      (_a = animate.value) == null ? void 0 : _a.cancel();\n      syncPause();\n    } catch (e) {\n      onError(e);\n    }\n  };\n  watch(() => unrefElement(target), (el) => {\n    el && update();\n  });\n  watch(() => keyframes, (value) => {\n    !animate.value && update();\n    if (!unrefElement(target) && animate.value) {\n      animate.value.effect = new KeyframeEffect(\n        unrefElement(target),\n        toValue(value),\n        animateOptions\n      );\n    }\n  }, { deep: true });\n  tryOnMounted(() => {\n    nextTick(() => update(true));\n  });\n  tryOnScopeDispose(cancel);\n  function update(init) {\n    const el = unrefElement(target);\n    if (!isSupported.value || !el)\n      return;\n    animate.value = el.animate(toValue(keyframes), animateOptions);\n    if (commitStyles)\n      animate.value.commitStyles();\n    if (persist)\n      animate.value.persist();\n    if (_playbackRate !== 1)\n      animate.value.playbackRate = _playbackRate;\n    if (init && !immediate)\n      animate.value.pause();\n    else\n      syncResume();\n    onReady == null ? void 0 : onReady(animate.value);\n  }\n  useEventListener(animate, \"cancel\", syncPause);\n  useEventListener(animate, \"finish\", syncPause);\n  useEventListener(animate, \"remove\", syncPause);\n  const { resume: resumeRef, pause: pauseRef } = useRafFn(() => {\n    if (!animate.value)\n      return;\n    store.pending = animate.value.pending;\n    store.playState = animate.value.playState;\n    store.replaceState = animate.value.replaceState;\n    store.startTime = animate.value.startTime;\n    store.currentTime = animate.value.currentTime;\n    store.timeline = animate.value.timeline;\n    store.playbackRate = animate.value.playbackRate;\n  }, { immediate: false });\n  function syncResume() {\n    if (isSupported.value)\n      resumeRef();\n  }\n  function syncPause() {\n    if (isSupported.value && window)\n      window.requestAnimationFrame(pauseRef);\n  }\n  return {\n    isSupported,\n    animate,\n    // actions\n    play,\n    pause,\n    reverse,\n    finish,\n    cancel,\n    // state\n    pending,\n    playState,\n    replaceState,\n    startTime,\n    currentTime,\n    timeline,\n    playbackRate\n  };\n}\n\nfunction useAsyncQueue(tasks, options = {}) {\n  const {\n    interrupt = true,\n    onError = noop,\n    onFinished = noop\n  } = options;\n  const promiseState = {\n    pending: \"pending\",\n    rejected: \"rejected\",\n    fulfilled: \"fulfilled\"\n  };\n  const initialResult = Array.from(new Array(tasks.length), () => ({ state: promiseState.pending, data: null }));\n  const result = reactive(initialResult);\n  const activeIndex = ref(-1);\n  if (!tasks || tasks.length === 0) {\n    onFinished();\n    return {\n      activeIndex,\n      result\n    };\n  }\n  function updateResult(state, res) {\n    activeIndex.value++;\n    result[activeIndex.value].data = res;\n    result[activeIndex.value].state = state;\n  }\n  tasks.reduce((prev, curr) => {\n    return prev.then((prevRes) => {\n      var _a;\n      if (((_a = result[activeIndex.value]) == null ? void 0 : _a.state) === promiseState.rejected && interrupt) {\n        onFinished();\n        return;\n      }\n      return curr(prevRes).then((currentRes) => {\n        updateResult(promiseState.fulfilled, currentRes);\n        activeIndex.value === tasks.length - 1 && onFinished();\n        return currentRes;\n      });\n    }).catch((e) => {\n      updateResult(promiseState.rejected, e);\n      onError();\n      return e;\n    });\n  }, Promise.resolve());\n  return {\n    activeIndex,\n    result\n  };\n}\n\nfunction useAsyncState(promise, initialState, options) {\n  const {\n    immediate = true,\n    delay = 0,\n    onError = noop,\n    onSuccess = noop,\n    resetOnExecute = true,\n    shallow = true,\n    throwError\n  } = options != null ? options : {};\n  const state = shallow ? shallowRef(initialState) : ref(initialState);\n  const isReady = ref(false);\n  const isLoading = ref(false);\n  const error = shallowRef(void 0);\n  async function execute(delay2 = 0, ...args) {\n    if (resetOnExecute)\n      state.value = initialState;\n    error.value = void 0;\n    isReady.value = false;\n    isLoading.value = true;\n    if (delay2 > 0)\n      await promiseTimeout(delay2);\n    const _promise = typeof promise === \"function\" ? promise(...args) : promise;\n    try {\n      const data = await _promise;\n      state.value = data;\n      isReady.value = true;\n      onSuccess(data);\n    } catch (e) {\n      error.value = e;\n      onError(e);\n      if (throwError)\n        throw e;\n    } finally {\n      isLoading.value = false;\n    }\n    return state.value;\n  }\n  if (immediate)\n    execute(delay);\n  return {\n    state,\n    isReady,\n    isLoading,\n    error,\n    execute\n  };\n}\n\nconst defaults = {\n  array: (v) => JSON.stringify(v),\n  object: (v) => JSON.stringify(v),\n  set: (v) => JSON.stringify(Array.from(v)),\n  map: (v) => JSON.stringify(Object.fromEntries(v)),\n  null: () => \"\"\n};\nfunction getDefaultSerialization(target) {\n  if (!target)\n    return defaults.null;\n  if (target instanceof Map)\n    return defaults.map;\n  else if (target instanceof Set)\n    return defaults.set;\n  else if (Array.isArray(target))\n    return defaults.array;\n  else\n    return defaults.object;\n}\n\nfunction useBase64(target, options) {\n  const base64 = ref(\"\");\n  const promise = ref();\n  function execute() {\n    if (!isClient)\n      return;\n    promise.value = new Promise((resolve, reject) => {\n      try {\n        const _target = toValue(target);\n        if (_target == null) {\n          resolve(\"\");\n        } else if (typeof _target === \"string\") {\n          resolve(blobToBase64(new Blob([_target], { type: \"text/plain\" })));\n        } else if (_target instanceof Blob) {\n          resolve(blobToBase64(_target));\n        } else if (_target instanceof ArrayBuffer) {\n          resolve(window.btoa(String.fromCharCode(...new Uint8Array(_target))));\n        } else if (_target instanceof HTMLCanvasElement) {\n          resolve(_target.toDataURL(options == null ? void 0 : options.type, options == null ? void 0 : options.quality));\n        } else if (_target instanceof HTMLImageElement) {\n          const img = _target.cloneNode(false);\n          img.crossOrigin = \"Anonymous\";\n          imgLoaded(img).then(() => {\n            const canvas = document.createElement(\"canvas\");\n            const ctx = canvas.getContext(\"2d\");\n            canvas.width = img.width;\n            canvas.height = img.height;\n            ctx.drawImage(img, 0, 0, canvas.width, canvas.height);\n            resolve(canvas.toDataURL(options == null ? void 0 : options.type, options == null ? void 0 : options.quality));\n          }).catch(reject);\n        } else if (typeof _target === \"object\") {\n          const _serializeFn = (options == null ? void 0 : options.serializer) || getDefaultSerialization(_target);\n          const serialized = _serializeFn(_target);\n          return resolve(blobToBase64(new Blob([serialized], { type: \"application/json\" })));\n        } else {\n          reject(new Error(\"target is unsupported types\"));\n        }\n      } catch (error) {\n        reject(error);\n      }\n    });\n    promise.value.then((res) => base64.value = res);\n    return promise.value;\n  }\n  if (isRef(target) || typeof target === \"function\")\n    watch(target, execute, { immediate: true });\n  else\n    execute();\n  return {\n    base64,\n    promise,\n    execute\n  };\n}\nfunction imgLoaded(img) {\n  return new Promise((resolve, reject) => {\n    if (!img.complete) {\n      img.onload = () => {\n        resolve();\n      };\n      img.onerror = reject;\n    } else {\n      resolve();\n    }\n  });\n}\nfunction blobToBase64(blob) {\n  return new Promise((resolve, reject) => {\n    const fr = new FileReader();\n    fr.onload = (e) => {\n      resolve(e.target.result);\n    };\n    fr.onerror = reject;\n    fr.readAsDataURL(blob);\n  });\n}\n\nfunction useBattery({ navigator = defaultNavigator } = {}) {\n  const events = [\"chargingchange\", \"chargingtimechange\", \"dischargingtimechange\", \"levelchange\"];\n  const isSupported = useSupported(() => navigator && \"getBattery\" in navigator);\n  const charging = ref(false);\n  const chargingTime = ref(0);\n  const dischargingTime = ref(0);\n  const level = ref(1);\n  let battery;\n  function updateBatteryInfo() {\n    charging.value = this.charging;\n    chargingTime.value = this.chargingTime || 0;\n    dischargingTime.value = this.dischargingTime || 0;\n    level.value = this.level;\n  }\n  if (isSupported.value) {\n    navigator.getBattery().then((_battery) => {\n      battery = _battery;\n      updateBatteryInfo.call(battery);\n      for (const event of events)\n        useEventListener(battery, event, updateBatteryInfo, { passive: true });\n    });\n  }\n  return {\n    isSupported,\n    charging,\n    chargingTime,\n    dischargingTime,\n    level\n  };\n}\n\nfunction useBluetooth(options) {\n  let {\n    acceptAllDevices = false\n  } = options || {};\n  const {\n    filters = void 0,\n    optionalServices = void 0,\n    navigator = defaultNavigator\n  } = options || {};\n  const isSupported = useSupported(() => navigator && \"bluetooth\" in navigator);\n  const device = shallowRef(void 0);\n  const error = shallowRef(null);\n  watch(device, () => {\n    connectToBluetoothGATTServer();\n  });\n  async function requestDevice() {\n    if (!isSupported.value)\n      return;\n    error.value = null;\n    if (filters && filters.length > 0)\n      acceptAllDevices = false;\n    try {\n      device.value = await (navigator == null ? void 0 : navigator.bluetooth.requestDevice({\n        acceptAllDevices,\n        filters,\n        optionalServices\n      }));\n    } catch (err) {\n      error.value = err;\n    }\n  }\n  const server = ref();\n  const isConnected = computed(() => {\n    var _a;\n    return ((_a = server.value) == null ? void 0 : _a.connected) || false;\n  });\n  async function connectToBluetoothGATTServer() {\n    error.value = null;\n    if (device.value && device.value.gatt) {\n      device.value.addEventListener(\"gattserverdisconnected\", () => {\n      });\n      try {\n        server.value = await device.value.gatt.connect();\n      } catch (err) {\n        error.value = err;\n      }\n    }\n  }\n  tryOnMounted(() => {\n    var _a;\n    if (device.value)\n      (_a = device.value.gatt) == null ? void 0 : _a.connect();\n  });\n  tryOnScopeDispose(() => {\n    var _a;\n    if (device.value)\n      (_a = device.value.gatt) == null ? void 0 : _a.disconnect();\n  });\n  return {\n    isSupported,\n    isConnected,\n    // Device:\n    device,\n    requestDevice,\n    // Server:\n    server,\n    // Errors:\n    error\n  };\n}\n\nfunction useMediaQuery(query, options = {}) {\n  const { window = defaultWindow } = options;\n  const isSupported = useSupported(() => window && \"matchMedia\" in window && typeof window.matchMedia === \"function\");\n  let mediaQuery;\n  const matches = ref(false);\n  const cleanup = () => {\n    if (!mediaQuery)\n      return;\n    if (\"removeEventListener\" in mediaQuery)\n      mediaQuery.removeEventListener(\"change\", update);\n    else\n      mediaQuery.removeListener(update);\n  };\n  const update = () => {\n    if (!isSupported.value)\n      return;\n    cleanup();\n    mediaQuery = window.matchMedia(toRef(query).value);\n    matches.value = !!(mediaQuery == null ? void 0 : mediaQuery.matches);\n    if (!mediaQuery)\n      return;\n    if (\"addEventListener\" in mediaQuery)\n      mediaQuery.addEventListener(\"change\", update);\n    else\n      mediaQuery.addListener(update);\n  };\n  watchEffect(update);\n  tryOnScopeDispose(() => cleanup());\n  return matches;\n}\n\nconst breakpointsTailwind = {\n  \"sm\": 640,\n  \"md\": 768,\n  \"lg\": 1024,\n  \"xl\": 1280,\n  \"2xl\": 1536\n};\nconst breakpointsBootstrapV5 = {\n  sm: 576,\n  md: 768,\n  lg: 992,\n  xl: 1200,\n  xxl: 1400\n};\nconst breakpointsVuetify = {\n  xs: 600,\n  sm: 960,\n  md: 1264,\n  lg: 1904\n};\nconst breakpointsAntDesign = {\n  xs: 480,\n  sm: 576,\n  md: 768,\n  lg: 992,\n  xl: 1200,\n  xxl: 1600\n};\nconst breakpointsQuasar = {\n  xs: 600,\n  sm: 1024,\n  md: 1440,\n  lg: 1920\n};\nconst breakpointsSematic = {\n  mobileS: 320,\n  mobileM: 375,\n  mobileL: 425,\n  tablet: 768,\n  laptop: 1024,\n  laptopL: 1440,\n  desktop4K: 2560\n};\nconst breakpointsMasterCss = {\n  \"3xs\": 360,\n  \"2xs\": 480,\n  \"xs\": 600,\n  \"sm\": 768,\n  \"md\": 1024,\n  \"lg\": 1280,\n  \"xl\": 1440,\n  \"2xl\": 1600,\n  \"3xl\": 1920,\n  \"4xl\": 2560\n};\n\nfunction useBreakpoints(breakpoints, options = {}) {\n  function getValue(k, delta) {\n    let v = breakpoints[k];\n    if (delta != null)\n      v = increaseWithUnit(v, delta);\n    if (typeof v === \"number\")\n      v = `${v}px`;\n    return v;\n  }\n  const { window = defaultWindow } = options;\n  function match(query) {\n    if (!window)\n      return false;\n    return window.matchMedia(query).matches;\n  }\n  const greaterOrEqual = (k) => {\n    return useMediaQuery(`(min-width: ${getValue(k)})`, options);\n  };\n  const shortcutMethods = Object.keys(breakpoints).reduce((shortcuts, k) => {\n    Object.defineProperty(shortcuts, k, {\n      get: () => greaterOrEqual(k),\n      enumerable: true,\n      configurable: true\n    });\n    return shortcuts;\n  }, {});\n  return Object.assign(shortcutMethods, {\n    greater(k) {\n      return useMediaQuery(`(min-width: ${getValue(k, 0.1)})`, options);\n    },\n    greaterOrEqual,\n    smaller(k) {\n      return useMediaQuery(`(max-width: ${getValue(k, -0.1)})`, options);\n    },\n    smallerOrEqual(k) {\n      return useMediaQuery(`(max-width: ${getValue(k)})`, options);\n    },\n    between(a, b) {\n      return useMediaQuery(`(min-width: ${getValue(a)}) and (max-width: ${getValue(b, -0.1)})`, options);\n    },\n    isGreater(k) {\n      return match(`(min-width: ${getValue(k, 0.1)})`);\n    },\n    isGreaterOrEqual(k) {\n      return match(`(min-width: ${getValue(k)})`);\n    },\n    isSmaller(k) {\n      return match(`(max-width: ${getValue(k, -0.1)})`);\n    },\n    isSmallerOrEqual(k) {\n      return match(`(max-width: ${getValue(k)})`);\n    },\n    isInBetween(a, b) {\n      return match(`(min-width: ${getValue(a)}) and (max-width: ${getValue(b, -0.1)})`);\n    },\n    current() {\n      const points = Object.keys(breakpoints).map((i) => [i, greaterOrEqual(i)]);\n      return computed(() => points.filter(([, v]) => v.value).map(([k]) => k));\n    }\n  });\n}\n\nfunction useBroadcastChannel(options) {\n  const {\n    name,\n    window = defaultWindow\n  } = options;\n  const isSupported = useSupported(() => window && \"BroadcastChannel\" in window);\n  const isClosed = ref(false);\n  const channel = ref();\n  const data = ref();\n  const error = shallowRef(null);\n  const post = (data2) => {\n    if (channel.value)\n      channel.value.postMessage(data2);\n  };\n  const close = () => {\n    if (channel.value)\n      channel.value.close();\n    isClosed.value = true;\n  };\n  if (isSupported.value) {\n    tryOnMounted(() => {\n      error.value = null;\n      channel.value = new BroadcastChannel(name);\n      channel.value.addEventListener(\"message\", (e) => {\n        data.value = e.data;\n      }, { passive: true });\n      channel.value.addEventListener(\"messageerror\", (e) => {\n        error.value = e;\n      }, { passive: true });\n      channel.value.addEventListener(\"close\", () => {\n        isClosed.value = true;\n      });\n    });\n  }\n  tryOnScopeDispose(() => {\n    close();\n  });\n  return {\n    isSupported,\n    channel,\n    data,\n    post,\n    close,\n    error,\n    isClosed\n  };\n}\n\nvar __defProp$m = Object.defineProperty;\nvar __getOwnPropSymbols$p = Object.getOwnPropertySymbols;\nvar __hasOwnProp$p = Object.prototype.hasOwnProperty;\nvar __propIsEnum$p = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$m = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$p.call(b, prop))\n      __defNormalProp$m(a, prop, b[prop]);\n  if (__getOwnPropSymbols$p)\n    for (var prop of __getOwnPropSymbols$p(b)) {\n      if (__propIsEnum$p.call(b, prop))\n        __defNormalProp$m(a, prop, b[prop]);\n    }\n  return a;\n};\nconst WRITABLE_PROPERTIES = [\n  \"hash\",\n  \"host\",\n  \"hostname\",\n  \"href\",\n  \"pathname\",\n  \"port\",\n  \"protocol\",\n  \"search\"\n];\nfunction useBrowserLocation({ window = defaultWindow } = {}) {\n  const refs = Object.fromEntries(\n    WRITABLE_PROPERTIES.map((key) => [key, ref()])\n  );\n  for (const [key, ref2] of objectEntries(refs)) {\n    watch(ref2, (value) => {\n      if (!(window == null ? void 0 : window.location) || window.location[key] === value)\n        return;\n      window.location[key] = value;\n    });\n  }\n  const buildState = (trigger) => {\n    var _a;\n    const { state: state2, length } = (window == null ? void 0 : window.history) || {};\n    const { origin } = (window == null ? void 0 : window.location) || {};\n    for (const key of WRITABLE_PROPERTIES)\n      refs[key].value = (_a = window == null ? void 0 : window.location) == null ? void 0 : _a[key];\n    return reactive(__spreadValues$m({\n      trigger,\n      state: state2,\n      length,\n      origin\n    }, refs));\n  };\n  const state = ref(buildState(\"load\"));\n  if (window) {\n    useEventListener(window, \"popstate\", () => state.value = buildState(\"popstate\"), { passive: true });\n    useEventListener(window, \"hashchange\", () => state.value = buildState(\"hashchange\"), { passive: true });\n  }\n  return state;\n}\n\nfunction useCached(refValue, comparator = (a, b) => a === b, watchOptions) {\n  const cachedValue = ref(refValue.value);\n  watch(() => refValue.value, (value) => {\n    if (!comparator(value, cachedValue.value))\n      cachedValue.value = value;\n  }, watchOptions);\n  return cachedValue;\n}\n\nfunction useClipboard(options = {}) {\n  const {\n    navigator = defaultNavigator,\n    read = false,\n    source,\n    copiedDuring = 1500,\n    legacy = false\n  } = options;\n  const events = [\"copy\", \"cut\"];\n  const isClipboardApiSupported = useSupported(() => navigator && \"clipboard\" in navigator);\n  const isSupported = computed(() => isClipboardApiSupported.value || legacy);\n  const text = ref(\"\");\n  const copied = ref(false);\n  const timeout = useTimeoutFn(() => copied.value = false, copiedDuring);\n  function updateText() {\n    if (isClipboardApiSupported.value) {\n      navigator.clipboard.readText().then((value) => {\n        text.value = value;\n      });\n    } else {\n      text.value = legacyRead();\n    }\n  }\n  if (isSupported.value && read) {\n    for (const event of events)\n      useEventListener(event, updateText);\n  }\n  async function copy(value = toValue(source)) {\n    if (isSupported.value && value != null) {\n      if (isClipboardApiSupported.value)\n        await navigator.clipboard.writeText(value);\n      else\n        legacyCopy(value);\n      text.value = value;\n      copied.value = true;\n      timeout.start();\n    }\n  }\n  function legacyCopy(value) {\n    const ta = document.createElement(\"textarea\");\n    ta.value = value != null ? value : \"\";\n    ta.style.position = \"absolute\";\n    ta.style.opacity = \"0\";\n    document.body.appendChild(ta);\n    ta.select();\n    document.execCommand(\"copy\");\n    ta.remove();\n  }\n  function legacyRead() {\n    var _a, _b, _c;\n    return (_c = (_b = (_a = document == null ? void 0 : document.getSelection) == null ? void 0 : _a.call(document)) == null ? void 0 : _b.toString()) != null ? _c : \"\";\n  }\n  return {\n    isSupported,\n    text,\n    copied,\n    copy\n  };\n}\n\nvar __defProp$l = Object.defineProperty;\nvar __defProps$9 = Object.defineProperties;\nvar __getOwnPropDescs$9 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$o = Object.getOwnPropertySymbols;\nvar __hasOwnProp$o = Object.prototype.hasOwnProperty;\nvar __propIsEnum$o = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$l = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$o.call(b, prop))\n      __defNormalProp$l(a, prop, b[prop]);\n  if (__getOwnPropSymbols$o)\n    for (var prop of __getOwnPropSymbols$o(b)) {\n      if (__propIsEnum$o.call(b, prop))\n        __defNormalProp$l(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$9 = (a, b) => __defProps$9(a, __getOwnPropDescs$9(b));\nfunction cloneFnJSON(source) {\n  return JSON.parse(JSON.stringify(source));\n}\nfunction useCloned(source, options = {}) {\n  const cloned = ref({});\n  const {\n    manual,\n    clone = cloneFnJSON,\n    // watch options\n    deep = true,\n    immediate = true\n  } = options;\n  function sync() {\n    cloned.value = clone(toValue(source));\n  }\n  if (!manual && isRef(source)) {\n    watch(source, sync, __spreadProps$9(__spreadValues$l({}, options), {\n      deep,\n      immediate\n    }));\n  } else {\n    sync();\n  }\n  return { cloned, sync };\n}\n\nconst _global = typeof globalThis !== \"undefined\" ? globalThis : typeof window !== \"undefined\" ? window : typeof global !== \"undefined\" ? global : typeof self !== \"undefined\" ? self : {};\nconst globalKey = \"__vueuse_ssr_handlers__\";\nconst handlers = /* @__PURE__ */ getHandlers();\nfunction getHandlers() {\n  if (!(globalKey in _global))\n    _global[globalKey] = _global[globalKey] || {};\n  return _global[globalKey];\n}\nfunction getSSRHandler(key, fallback) {\n  return handlers[key] || fallback;\n}\nfunction setSSRHandler(key, fn) {\n  handlers[key] = fn;\n}\n\nfunction guessSerializerType(rawInit) {\n  return rawInit == null ? \"any\" : rawInit instanceof Set ? \"set\" : rawInit instanceof Map ? \"map\" : rawInit instanceof Date ? \"date\" : typeof rawInit === \"boolean\" ? \"boolean\" : typeof rawInit === \"string\" ? \"string\" : typeof rawInit === \"object\" ? \"object\" : !Number.isNaN(rawInit) ? \"number\" : \"any\";\n}\n\nvar __defProp$k = Object.defineProperty;\nvar __getOwnPropSymbols$n = Object.getOwnPropertySymbols;\nvar __hasOwnProp$n = Object.prototype.hasOwnProperty;\nvar __propIsEnum$n = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$k = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$n.call(b, prop))\n      __defNormalProp$k(a, prop, b[prop]);\n  if (__getOwnPropSymbols$n)\n    for (var prop of __getOwnPropSymbols$n(b)) {\n      if (__propIsEnum$n.call(b, prop))\n        __defNormalProp$k(a, prop, b[prop]);\n    }\n  return a;\n};\nconst StorageSerializers = {\n  boolean: {\n    read: (v) => v === \"true\",\n    write: (v) => String(v)\n  },\n  object: {\n    read: (v) => JSON.parse(v),\n    write: (v) => JSON.stringify(v)\n  },\n  number: {\n    read: (v) => Number.parseFloat(v),\n    write: (v) => String(v)\n  },\n  any: {\n    read: (v) => v,\n    write: (v) => String(v)\n  },\n  string: {\n    read: (v) => v,\n    write: (v) => String(v)\n  },\n  map: {\n    read: (v) => new Map(JSON.parse(v)),\n    write: (v) => JSON.stringify(Array.from(v.entries()))\n  },\n  set: {\n    read: (v) => new Set(JSON.parse(v)),\n    write: (v) => JSON.stringify(Array.from(v))\n  },\n  date: {\n    read: (v) => new Date(v),\n    write: (v) => v.toISOString()\n  }\n};\nconst customStorageEventName = \"vueuse-storage\";\nfunction useStorage(key, defaults, storage, options = {}) {\n  var _a;\n  const {\n    flush = \"pre\",\n    deep = true,\n    listenToStorageChanges = true,\n    writeDefaults = true,\n    mergeDefaults = false,\n    shallow,\n    window = defaultWindow,\n    eventFilter,\n    onError = (e) => {\n      console.error(e);\n    }\n  } = options;\n  const data = (shallow ? shallowRef : ref)(defaults);\n  if (!storage) {\n    try {\n      storage = getSSRHandler(\"getDefaultStorage\", () => {\n        var _a2;\n        return (_a2 = defaultWindow) == null ? void 0 : _a2.localStorage;\n      })();\n    } catch (e) {\n      onError(e);\n    }\n  }\n  if (!storage)\n    return data;\n  const rawInit = toValue(defaults);\n  const type = guessSerializerType(rawInit);\n  const serializer = (_a = options.serializer) != null ? _a : StorageSerializers[type];\n  const { pause: pauseWatch, resume: resumeWatch } = pausableWatch(\n    data,\n    () => write(data.value),\n    { flush, deep, eventFilter }\n  );\n  if (window && listenToStorageChanges) {\n    useEventListener(window, \"storage\", update);\n    useEventListener(window, customStorageEventName, updateFromCustomEvent);\n  }\n  update();\n  return data;\n  function write(v) {\n    try {\n      if (v == null) {\n        storage.removeItem(key);\n      } else {\n        const serialized = serializer.write(v);\n        const oldValue = storage.getItem(key);\n        if (oldValue !== serialized) {\n          storage.setItem(key, serialized);\n          if (window) {\n            window.dispatchEvent(new CustomEvent(customStorageEventName, {\n              detail: {\n                key,\n                oldValue,\n                newValue: serialized,\n                storageArea: storage\n              }\n            }));\n          }\n        }\n      }\n    } catch (e) {\n      onError(e);\n    }\n  }\n  function read(event) {\n    const rawValue = event ? event.newValue : storage.getItem(key);\n    if (rawValue == null) {\n      if (writeDefaults && rawInit !== null)\n        storage.setItem(key, serializer.write(rawInit));\n      return rawInit;\n    } else if (!event && mergeDefaults) {\n      const value = serializer.read(rawValue);\n      if (typeof mergeDefaults === \"function\")\n        return mergeDefaults(value, rawInit);\n      else if (type === \"object\" && !Array.isArray(value))\n        return __spreadValues$k(__spreadValues$k({}, rawInit), value);\n      return value;\n    } else if (typeof rawValue !== \"string\") {\n      return rawValue;\n    } else {\n      return serializer.read(rawValue);\n    }\n  }\n  function updateFromCustomEvent(event) {\n    update(event.detail);\n  }\n  function update(event) {\n    if (event && event.storageArea !== storage)\n      return;\n    if (event && event.key == null) {\n      data.value = rawInit;\n      return;\n    }\n    if (event && event.key !== key)\n      return;\n    pauseWatch();\n    try {\n      data.value = read(event);\n    } catch (e) {\n      onError(e);\n    } finally {\n      if (event)\n        nextTick(resumeWatch);\n      else\n        resumeWatch();\n    }\n  }\n}\n\nfunction usePreferredDark(options) {\n  return useMediaQuery(\"(prefers-color-scheme: dark)\", options);\n}\n\nvar __defProp$j = Object.defineProperty;\nvar __getOwnPropSymbols$m = Object.getOwnPropertySymbols;\nvar __hasOwnProp$m = Object.prototype.hasOwnProperty;\nvar __propIsEnum$m = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$j = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$m.call(b, prop))\n      __defNormalProp$j(a, prop, b[prop]);\n  if (__getOwnPropSymbols$m)\n    for (var prop of __getOwnPropSymbols$m(b)) {\n      if (__propIsEnum$m.call(b, prop))\n        __defNormalProp$j(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useColorMode(options = {}) {\n  const {\n    selector = \"html\",\n    attribute = \"class\",\n    initialValue = \"auto\",\n    window = defaultWindow,\n    storage,\n    storageKey = \"vueuse-color-scheme\",\n    listenToStorageChanges = true,\n    storageRef,\n    emitAuto,\n    disableTransition = true\n  } = options;\n  const modes = __spreadValues$j({\n    auto: \"\",\n    light: \"light\",\n    dark: \"dark\"\n  }, options.modes || {});\n  const preferredDark = usePreferredDark({ window });\n  const system = computed(() => preferredDark.value ? \"dark\" : \"light\");\n  const store = storageRef || (storageKey == null ? ref(initialValue) : useStorage(storageKey, initialValue, storage, { window, listenToStorageChanges }));\n  const state = computed({\n    get() {\n      return store.value === \"auto\" && !emitAuto ? system.value : store.value;\n    },\n    set(v) {\n      store.value = v;\n    }\n  });\n  const updateHTMLAttrs = getSSRHandler(\n    \"updateHTMLAttrs\",\n    (selector2, attribute2, value) => {\n      const el = typeof selector2 === \"string\" ? window == null ? void 0 : window.document.querySelector(selector2) : toValue(selector2);\n      if (!el)\n        return;\n      let style;\n      if (disableTransition) {\n        style = window.document.createElement(\"style\");\n        style.appendChild(document.createTextNode(\"*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}\"));\n        window.document.head.appendChild(style);\n      }\n      if (attribute2 === \"class\") {\n        const current = value.split(/\\s/g);\n        Object.values(modes).flatMap((i) => (i || \"\").split(/\\s/g)).filter(Boolean).forEach((v) => {\n          if (current.includes(v))\n            el.classList.add(v);\n          else\n            el.classList.remove(v);\n        });\n      } else {\n        el.setAttribute(attribute2, value);\n      }\n      if (disableTransition) {\n        window.getComputedStyle(style).opacity;\n        document.head.removeChild(style);\n      }\n    }\n  );\n  function defaultOnChanged(mode) {\n    var _a;\n    const resolvedMode = mode === \"auto\" ? system.value : mode;\n    updateHTMLAttrs(selector, attribute, (_a = modes[resolvedMode]) != null ? _a : resolvedMode);\n  }\n  function onChanged(mode) {\n    if (options.onChanged)\n      options.onChanged(mode, defaultOnChanged);\n    else\n      defaultOnChanged(mode);\n  }\n  watch(state, onChanged, { flush: \"post\", immediate: true });\n  if (emitAuto)\n    watch(system, () => onChanged(state.value), { flush: \"post\" });\n  tryOnMounted(() => onChanged(state.value));\n  try {\n    return Object.assign(state, { store, system });\n  } catch (e) {\n    return state;\n  }\n}\n\nfunction useConfirmDialog(revealed = ref(false)) {\n  const confirmHook = createEventHook();\n  const cancelHook = createEventHook();\n  const revealHook = createEventHook();\n  let _resolve = noop;\n  const reveal = (data) => {\n    revealHook.trigger(data);\n    revealed.value = true;\n    return new Promise((resolve) => {\n      _resolve = resolve;\n    });\n  };\n  const confirm = (data) => {\n    revealed.value = false;\n    confirmHook.trigger(data);\n    _resolve({ data, isCanceled: false });\n  };\n  const cancel = (data) => {\n    revealed.value = false;\n    cancelHook.trigger(data);\n    _resolve({ data, isCanceled: true });\n  };\n  return {\n    isRevealed: computed(() => revealed.value),\n    reveal,\n    confirm,\n    cancel,\n    onReveal: revealHook.on,\n    onConfirm: confirmHook.on,\n    onCancel: cancelHook.on\n  };\n}\n\nfunction useCssVar(prop, target, options = {}) {\n  const { window = defaultWindow, initialValue = \"\", observe = false } = options;\n  const variable = ref(initialValue);\n  const elRef = computed(() => {\n    var _a;\n    return unrefElement(target) || ((_a = window == null ? void 0 : window.document) == null ? void 0 : _a.documentElement);\n  });\n  function updateCssVar() {\n    var _a;\n    const key = toValue(prop);\n    const el = toValue(elRef);\n    if (el && window) {\n      const value = (_a = window.getComputedStyle(el).getPropertyValue(key)) == null ? void 0 : _a.trim();\n      variable.value = value || initialValue;\n    }\n  }\n  if (observe) {\n    useMutationObserver$1(elRef, updateCssVar, {\n      attributes: true,\n      window\n    });\n  }\n  watch(\n    [elRef, () => toValue(prop)],\n    updateCssVar,\n    { immediate: true }\n  );\n  watch(\n    variable,\n    (val) => {\n      var _a;\n      if ((_a = elRef.value) == null ? void 0 : _a.style)\n        elRef.value.style.setProperty(toValue(prop), val);\n    }\n  );\n  return variable;\n}\n\nfunction useCurrentElement() {\n  const vm = getCurrentInstance();\n  const currentElement = computedWithControl(\n    () => null,\n    () => vm.proxy.$el\n  );\n  onUpdated(currentElement.trigger);\n  onMounted(currentElement.trigger);\n  return currentElement;\n}\n\nfunction useCycleList(list, options) {\n  const state = shallowRef(getInitialValue());\n  const listRef = toRef(list);\n  const index = computed({\n    get() {\n      var _a;\n      const targetList = toValue(list);\n      let index2 = (options == null ? void 0 : options.getIndexOf) ? options.getIndexOf(state.value, targetList) : targetList.indexOf(state.value);\n      if (index2 < 0)\n        index2 = (_a = options == null ? void 0 : options.fallbackIndex) != null ? _a : 0;\n      return index2;\n    },\n    set(v) {\n      set(v);\n    }\n  });\n  function set(i) {\n    const targetList = listRef.value;\n    const length = targetList.length;\n    const index2 = (i % length + length) % length;\n    const value = targetList[index2];\n    state.value = value;\n    return value;\n  }\n  function shift(delta = 1) {\n    return set(index.value + delta);\n  }\n  function next(n = 1) {\n    return shift(n);\n  }\n  function prev(n = 1) {\n    return shift(-n);\n  }\n  function getInitialValue() {\n    var _a, _b;\n    return (_b = toValue((_a = options == null ? void 0 : options.initialValue) != null ? _a : toValue(list)[0])) != null ? _b : void 0;\n  }\n  watch(listRef, () => set(index.value));\n  return {\n    state,\n    index,\n    next,\n    prev\n  };\n}\n\nvar __defProp$i = Object.defineProperty;\nvar __defProps$8 = Object.defineProperties;\nvar __getOwnPropDescs$8 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$l = Object.getOwnPropertySymbols;\nvar __hasOwnProp$l = Object.prototype.hasOwnProperty;\nvar __propIsEnum$l = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$i = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$l.call(b, prop))\n      __defNormalProp$i(a, prop, b[prop]);\n  if (__getOwnPropSymbols$l)\n    for (var prop of __getOwnPropSymbols$l(b)) {\n      if (__propIsEnum$l.call(b, prop))\n        __defNormalProp$i(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$8 = (a, b) => __defProps$8(a, __getOwnPropDescs$8(b));\nfunction useDark(options = {}) {\n  const {\n    valueDark = \"dark\",\n    valueLight = \"\",\n    window = defaultWindow\n  } = options;\n  const mode = useColorMode(__spreadProps$8(__spreadValues$i({}, options), {\n    onChanged: (mode2, defaultHandler) => {\n      var _a;\n      if (options.onChanged)\n        (_a = options.onChanged) == null ? void 0 : _a.call(options, mode2 === \"dark\", defaultHandler, mode2);\n      else\n        defaultHandler(mode2);\n    },\n    modes: {\n      dark: valueDark,\n      light: valueLight\n    }\n  }));\n  const preferredDark = usePreferredDark({ window });\n  const isDark = computed({\n    get() {\n      return mode.value === \"dark\";\n    },\n    set(v) {\n      if (v === preferredDark.value)\n        mode.value = \"auto\";\n      else\n        mode.value = v ? \"dark\" : \"light\";\n    }\n  });\n  return isDark;\n}\n\nfunction fnBypass(v) {\n  return v;\n}\nfunction fnSetSource(source, value) {\n  return source.value = value;\n}\nfunction defaultDump(clone) {\n  return clone ? typeof clone === \"function\" ? clone : cloneFnJSON : fnBypass;\n}\nfunction defaultParse(clone) {\n  return clone ? typeof clone === \"function\" ? clone : cloneFnJSON : fnBypass;\n}\nfunction useManualRefHistory(source, options = {}) {\n  const {\n    clone = false,\n    dump = defaultDump(clone),\n    parse = defaultParse(clone),\n    setSource = fnSetSource\n  } = options;\n  function _createHistoryRecord() {\n    return markRaw({\n      snapshot: dump(source.value),\n      timestamp: timestamp()\n    });\n  }\n  const last = ref(_createHistoryRecord());\n  const undoStack = ref([]);\n  const redoStack = ref([]);\n  const _setSource = (record) => {\n    setSource(source, parse(record.snapshot));\n    last.value = record;\n  };\n  const commit = () => {\n    undoStack.value.unshift(last.value);\n    last.value = _createHistoryRecord();\n    if (options.capacity && undoStack.value.length > options.capacity)\n      undoStack.value.splice(options.capacity, Infinity);\n    if (redoStack.value.length)\n      redoStack.value.splice(0, redoStack.value.length);\n  };\n  const clear = () => {\n    undoStack.value.splice(0, undoStack.value.length);\n    redoStack.value.splice(0, redoStack.value.length);\n  };\n  const undo = () => {\n    const state = undoStack.value.shift();\n    if (state) {\n      redoStack.value.unshift(last.value);\n      _setSource(state);\n    }\n  };\n  const redo = () => {\n    const state = redoStack.value.shift();\n    if (state) {\n      undoStack.value.unshift(last.value);\n      _setSource(state);\n    }\n  };\n  const reset = () => {\n    _setSource(last.value);\n  };\n  const history = computed(() => [last.value, ...undoStack.value]);\n  const canUndo = computed(() => undoStack.value.length > 0);\n  const canRedo = computed(() => redoStack.value.length > 0);\n  return {\n    source,\n    undoStack,\n    redoStack,\n    last,\n    history,\n    canUndo,\n    canRedo,\n    clear,\n    commit,\n    reset,\n    undo,\n    redo\n  };\n}\n\nvar __defProp$h = Object.defineProperty;\nvar __defProps$7 = Object.defineProperties;\nvar __getOwnPropDescs$7 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$k = Object.getOwnPropertySymbols;\nvar __hasOwnProp$k = Object.prototype.hasOwnProperty;\nvar __propIsEnum$k = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$h = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$k.call(b, prop))\n      __defNormalProp$h(a, prop, b[prop]);\n  if (__getOwnPropSymbols$k)\n    for (var prop of __getOwnPropSymbols$k(b)) {\n      if (__propIsEnum$k.call(b, prop))\n        __defNormalProp$h(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$7 = (a, b) => __defProps$7(a, __getOwnPropDescs$7(b));\nfunction useRefHistory(source, options = {}) {\n  const {\n    deep = false,\n    flush = \"pre\",\n    eventFilter\n  } = options;\n  const {\n    eventFilter: composedFilter,\n    pause,\n    resume: resumeTracking,\n    isActive: isTracking\n  } = pausableFilter(eventFilter);\n  const {\n    ignoreUpdates,\n    ignorePrevAsyncUpdates,\n    stop\n  } = watchIgnorable(\n    source,\n    commit,\n    { deep, flush, eventFilter: composedFilter }\n  );\n  function setSource(source2, value) {\n    ignorePrevAsyncUpdates();\n    ignoreUpdates(() => {\n      source2.value = value;\n    });\n  }\n  const manualHistory = useManualRefHistory(source, __spreadProps$7(__spreadValues$h({}, options), { clone: options.clone || deep, setSource }));\n  const { clear, commit: manualCommit } = manualHistory;\n  function commit() {\n    ignorePrevAsyncUpdates();\n    manualCommit();\n  }\n  function resume(commitNow) {\n    resumeTracking();\n    if (commitNow)\n      commit();\n  }\n  function batch(fn) {\n    let canceled = false;\n    const cancel = () => canceled = true;\n    ignoreUpdates(() => {\n      fn(cancel);\n    });\n    if (!canceled)\n      commit();\n  }\n  function dispose() {\n    stop();\n    clear();\n  }\n  return __spreadProps$7(__spreadValues$h({}, manualHistory), {\n    isTracking,\n    pause,\n    resume,\n    commit,\n    batch,\n    dispose\n  });\n}\n\nvar __defProp$g = Object.defineProperty;\nvar __defProps$6 = Object.defineProperties;\nvar __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$j = Object.getOwnPropertySymbols;\nvar __hasOwnProp$j = Object.prototype.hasOwnProperty;\nvar __propIsEnum$j = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$g = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$j.call(b, prop))\n      __defNormalProp$g(a, prop, b[prop]);\n  if (__getOwnPropSymbols$j)\n    for (var prop of __getOwnPropSymbols$j(b)) {\n      if (__propIsEnum$j.call(b, prop))\n        __defNormalProp$g(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$6 = (a, b) => __defProps$6(a, __getOwnPropDescs$6(b));\nfunction useDebouncedRefHistory(source, options = {}) {\n  const filter = options.debounce ? debounceFilter(options.debounce) : void 0;\n  const history = useRefHistory(source, __spreadProps$6(__spreadValues$g({}, options), { eventFilter: filter }));\n  return __spreadValues$g({}, history);\n}\n\nfunction useDeviceMotion(options = {}) {\n  const {\n    window = defaultWindow,\n    eventFilter = bypassFilter\n  } = options;\n  const acceleration = ref({ x: null, y: null, z: null });\n  const rotationRate = ref({ alpha: null, beta: null, gamma: null });\n  const interval = ref(0);\n  const accelerationIncludingGravity = ref({\n    x: null,\n    y: null,\n    z: null\n  });\n  if (window) {\n    const onDeviceMotion = createFilterWrapper(\n      eventFilter,\n      (event) => {\n        acceleration.value = event.acceleration;\n        accelerationIncludingGravity.value = event.accelerationIncludingGravity;\n        rotationRate.value = event.rotationRate;\n        interval.value = event.interval;\n      }\n    );\n    useEventListener(window, \"devicemotion\", onDeviceMotion);\n  }\n  return {\n    acceleration,\n    accelerationIncludingGravity,\n    rotationRate,\n    interval\n  };\n}\n\nfunction useDeviceOrientation(options = {}) {\n  const { window = defaultWindow } = options;\n  const isSupported = useSupported(() => window && \"DeviceOrientationEvent\" in window);\n  const isAbsolute = ref(false);\n  const alpha = ref(null);\n  const beta = ref(null);\n  const gamma = ref(null);\n  if (window && isSupported.value) {\n    useEventListener(window, \"deviceorientation\", (event) => {\n      isAbsolute.value = event.absolute;\n      alpha.value = event.alpha;\n      beta.value = event.beta;\n      gamma.value = event.gamma;\n    });\n  }\n  return {\n    isSupported,\n    isAbsolute,\n    alpha,\n    beta,\n    gamma\n  };\n}\n\nfunction useDevicePixelRatio({\n  window = defaultWindow\n} = {}) {\n  const pixelRatio = ref(1);\n  if (window) {\n    let observe = function() {\n      pixelRatio.value = window.devicePixelRatio;\n      cleanup();\n      media = window.matchMedia(`(resolution: ${pixelRatio.value}dppx)`);\n      media.addEventListener(\"change\", observe, { once: true });\n    }, cleanup = function() {\n      media == null ? void 0 : media.removeEventListener(\"change\", observe);\n    };\n    let media;\n    observe();\n    tryOnScopeDispose(cleanup);\n  }\n  return { pixelRatio };\n}\n\nfunction usePermission(permissionDesc, options = {}) {\n  const {\n    controls = false,\n    navigator = defaultNavigator\n  } = options;\n  const isSupported = useSupported(() => navigator && \"permissions\" in navigator);\n  let permissionStatus;\n  const desc = typeof permissionDesc === \"string\" ? { name: permissionDesc } : permissionDesc;\n  const state = ref();\n  const onChange = () => {\n    if (permissionStatus)\n      state.value = permissionStatus.state;\n  };\n  const query = createSingletonPromise(async () => {\n    if (!isSupported.value)\n      return;\n    if (!permissionStatus) {\n      try {\n        permissionStatus = await navigator.permissions.query(desc);\n        useEventListener(permissionStatus, \"change\", onChange);\n        onChange();\n      } catch (e) {\n        state.value = \"prompt\";\n      }\n    }\n    return permissionStatus;\n  });\n  query();\n  if (controls) {\n    return {\n      state,\n      isSupported,\n      query\n    };\n  } else {\n    return state;\n  }\n}\n\nfunction useDevicesList(options = {}) {\n  const {\n    navigator = defaultNavigator,\n    requestPermissions = false,\n    constraints = { audio: true, video: true },\n    onUpdated\n  } = options;\n  const devices = ref([]);\n  const videoInputs = computed(() => devices.value.filter((i) => i.kind === \"videoinput\"));\n  const audioInputs = computed(() => devices.value.filter((i) => i.kind === \"audioinput\"));\n  const audioOutputs = computed(() => devices.value.filter((i) => i.kind === \"audiooutput\"));\n  const isSupported = useSupported(() => navigator && navigator.mediaDevices && navigator.mediaDevices.enumerateDevices);\n  const permissionGranted = ref(false);\n  let stream;\n  async function update() {\n    if (!isSupported.value)\n      return;\n    devices.value = await navigator.mediaDevices.enumerateDevices();\n    onUpdated == null ? void 0 : onUpdated(devices.value);\n    if (stream) {\n      stream.getTracks().forEach((t) => t.stop());\n      stream = null;\n    }\n  }\n  async function ensurePermissions() {\n    if (!isSupported.value)\n      return false;\n    if (permissionGranted.value)\n      return true;\n    const { state, query } = usePermission(\"camera\", { controls: true });\n    await query();\n    if (state.value !== \"granted\") {\n      stream = await navigator.mediaDevices.getUserMedia(constraints);\n      update();\n      permissionGranted.value = true;\n    } else {\n      permissionGranted.value = true;\n    }\n    return permissionGranted.value;\n  }\n  if (isSupported.value) {\n    if (requestPermissions)\n      ensurePermissions();\n    useEventListener(navigator.mediaDevices, \"devicechange\", update);\n    update();\n  }\n  return {\n    devices,\n    ensurePermissions,\n    permissionGranted,\n    videoInputs,\n    audioInputs,\n    audioOutputs,\n    isSupported\n  };\n}\n\nfunction useDisplayMedia(options = {}) {\n  var _a;\n  const enabled = ref((_a = options.enabled) != null ? _a : false);\n  const video = options.video;\n  const audio = options.audio;\n  const { navigator = defaultNavigator } = options;\n  const isSupported = useSupported(() => {\n    var _a2;\n    return (_a2 = navigator == null ? void 0 : navigator.mediaDevices) == null ? void 0 : _a2.getDisplayMedia;\n  });\n  const constraint = { audio, video };\n  const stream = shallowRef();\n  async function _start() {\n    if (!isSupported.value || stream.value)\n      return;\n    stream.value = await navigator.mediaDevices.getDisplayMedia(constraint);\n    return stream.value;\n  }\n  async function _stop() {\n    var _a2;\n    (_a2 = stream.value) == null ? void 0 : _a2.getTracks().forEach((t) => t.stop());\n    stream.value = void 0;\n  }\n  function stop() {\n    _stop();\n    enabled.value = false;\n  }\n  async function start() {\n    await _start();\n    if (stream.value)\n      enabled.value = true;\n    return stream.value;\n  }\n  watch(\n    enabled,\n    (v) => {\n      if (v)\n        _start();\n      else\n        _stop();\n    },\n    { immediate: true }\n  );\n  return {\n    isSupported,\n    stream,\n    start,\n    stop,\n    enabled\n  };\n}\n\nfunction useDocumentVisibility({ document = defaultDocument } = {}) {\n  if (!document)\n    return ref(\"visible\");\n  const visibility = ref(document.visibilityState);\n  useEventListener(document, \"visibilitychange\", () => {\n    visibility.value = document.visibilityState;\n  });\n  return visibility;\n}\n\nvar __defProp$f = Object.defineProperty;\nvar __defProps$5 = Object.defineProperties;\nvar __getOwnPropDescs$5 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$i = Object.getOwnPropertySymbols;\nvar __hasOwnProp$i = Object.prototype.hasOwnProperty;\nvar __propIsEnum$i = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$f = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$i.call(b, prop))\n      __defNormalProp$f(a, prop, b[prop]);\n  if (__getOwnPropSymbols$i)\n    for (var prop of __getOwnPropSymbols$i(b)) {\n      if (__propIsEnum$i.call(b, prop))\n        __defNormalProp$f(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$5 = (a, b) => __defProps$5(a, __getOwnPropDescs$5(b));\nfunction useDraggable(target, options = {}) {\n  var _a, _b;\n  const {\n    pointerTypes,\n    preventDefault,\n    stopPropagation,\n    exact,\n    onMove,\n    onEnd,\n    onStart,\n    initialValue,\n    axis = \"both\",\n    draggingElement = defaultWindow,\n    handle: draggingHandle = target\n  } = options;\n  const position = ref(\n    (_a = toValue(initialValue)) != null ? _a : { x: 0, y: 0 }\n  );\n  const pressedDelta = ref();\n  const filterEvent = (e) => {\n    if (pointerTypes)\n      return pointerTypes.includes(e.pointerType);\n    return true;\n  };\n  const handleEvent = (e) => {\n    if (toValue(preventDefault))\n      e.preventDefault();\n    if (toValue(stopPropagation))\n      e.stopPropagation();\n  };\n  const start = (e) => {\n    if (!filterEvent(e))\n      return;\n    if (toValue(exact) && e.target !== toValue(target))\n      return;\n    const rect = toValue(target).getBoundingClientRect();\n    const pos = {\n      x: e.clientX - rect.left,\n      y: e.clientY - rect.top\n    };\n    if ((onStart == null ? void 0 : onStart(pos, e)) === false)\n      return;\n    pressedDelta.value = pos;\n    handleEvent(e);\n  };\n  const move = (e) => {\n    if (!filterEvent(e))\n      return;\n    if (!pressedDelta.value)\n      return;\n    let { x, y } = position.value;\n    if (axis === \"x\" || axis === \"both\")\n      x = e.clientX - pressedDelta.value.x;\n    if (axis === \"y\" || axis === \"both\")\n      y = e.clientY - pressedDelta.value.y;\n    position.value = {\n      x,\n      y\n    };\n    onMove == null ? void 0 : onMove(position.value, e);\n    handleEvent(e);\n  };\n  const end = (e) => {\n    if (!filterEvent(e))\n      return;\n    if (!pressedDelta.value)\n      return;\n    pressedDelta.value = void 0;\n    onEnd == null ? void 0 : onEnd(position.value, e);\n    handleEvent(e);\n  };\n  if (isClient) {\n    const config = { capture: (_b = options.capture) != null ? _b : true };\n    useEventListener(draggingHandle, \"pointerdown\", start, config);\n    useEventListener(draggingElement, \"pointermove\", move, config);\n    useEventListener(draggingElement, \"pointerup\", end, config);\n  }\n  return __spreadProps$5(__spreadValues$f({}, toRefs(position)), {\n    position,\n    isDragging: computed(() => !!pressedDelta.value),\n    style: computed(\n      () => `left:${position.value.x}px;top:${position.value.y}px;`\n    )\n  });\n}\n\nfunction useDropZone(target, onDrop) {\n  const isOverDropZone = ref(false);\n  let counter = 0;\n  if (isClient) {\n    useEventListener(target, \"dragenter\", (event) => {\n      event.preventDefault();\n      counter += 1;\n      isOverDropZone.value = true;\n    });\n    useEventListener(target, \"dragover\", (event) => {\n      event.preventDefault();\n    });\n    useEventListener(target, \"dragleave\", (event) => {\n      event.preventDefault();\n      counter -= 1;\n      if (counter === 0)\n        isOverDropZone.value = false;\n    });\n    useEventListener(target, \"drop\", (event) => {\n      var _a, _b;\n      event.preventDefault();\n      counter = 0;\n      isOverDropZone.value = false;\n      const files = Array.from((_b = (_a = event.dataTransfer) == null ? void 0 : _a.files) != null ? _b : []);\n      onDrop == null ? void 0 : onDrop(files.length === 0 ? null : files);\n    });\n  }\n  return {\n    isOverDropZone\n  };\n}\n\nvar __getOwnPropSymbols$h = Object.getOwnPropertySymbols;\nvar __hasOwnProp$h = Object.prototype.hasOwnProperty;\nvar __propIsEnum$h = Object.prototype.propertyIsEnumerable;\nvar __objRest$3 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$h.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$h)\n    for (var prop of __getOwnPropSymbols$h(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$h.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction useResizeObserver(target, callback, options = {}) {\n  const _a = options, { window = defaultWindow } = _a, observerOptions = __objRest$3(_a, [\"window\"]);\n  let observer;\n  const isSupported = useSupported(() => window && \"ResizeObserver\" in window);\n  const cleanup = () => {\n    if (observer) {\n      observer.disconnect();\n      observer = void 0;\n    }\n  };\n  const targets = computed(\n    () => Array.isArray(target) ? target.map((el) => unrefElement(el)) : [unrefElement(target)]\n  );\n  const stopWatch = watch(\n    targets,\n    (els) => {\n      cleanup();\n      if (isSupported.value && window) {\n        observer = new ResizeObserver(callback);\n        for (const _el of els)\n          _el && observer.observe(_el, observerOptions);\n      }\n    },\n    { immediate: true, flush: \"post\", deep: true }\n  );\n  const stop = () => {\n    cleanup();\n    stopWatch();\n  };\n  tryOnScopeDispose(stop);\n  return {\n    isSupported,\n    stop\n  };\n}\n\nfunction useElementBounding(target, options = {}) {\n  const {\n    reset = true,\n    windowResize = true,\n    windowScroll = true,\n    immediate = true\n  } = options;\n  const height = ref(0);\n  const bottom = ref(0);\n  const left = ref(0);\n  const right = ref(0);\n  const top = ref(0);\n  const width = ref(0);\n  const x = ref(0);\n  const y = ref(0);\n  function update() {\n    const el = unrefElement(target);\n    if (!el) {\n      if (reset) {\n        height.value = 0;\n        bottom.value = 0;\n        left.value = 0;\n        right.value = 0;\n        top.value = 0;\n        width.value = 0;\n        x.value = 0;\n        y.value = 0;\n      }\n      return;\n    }\n    const rect = el.getBoundingClientRect();\n    height.value = rect.height;\n    bottom.value = rect.bottom;\n    left.value = rect.left;\n    right.value = rect.right;\n    top.value = rect.top;\n    width.value = rect.width;\n    x.value = rect.x;\n    y.value = rect.y;\n  }\n  useResizeObserver(target, update);\n  watch(() => unrefElement(target), (ele) => !ele && update());\n  if (windowScroll)\n    useEventListener(\"scroll\", update, { capture: true, passive: true });\n  if (windowResize)\n    useEventListener(\"resize\", update, { passive: true });\n  tryOnMounted(() => {\n    if (immediate)\n      update();\n  });\n  return {\n    height,\n    bottom,\n    left,\n    right,\n    top,\n    width,\n    x,\n    y,\n    update\n  };\n}\n\nvar __defProp$e = Object.defineProperty;\nvar __getOwnPropSymbols$g = Object.getOwnPropertySymbols;\nvar __hasOwnProp$g = Object.prototype.hasOwnProperty;\nvar __propIsEnum$g = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$e = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$g.call(b, prop))\n      __defNormalProp$e(a, prop, b[prop]);\n  if (__getOwnPropSymbols$g)\n    for (var prop of __getOwnPropSymbols$g(b)) {\n      if (__propIsEnum$g.call(b, prop))\n        __defNormalProp$e(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useElementByPoint(options) {\n  const element = ref(null);\n  const { x, y, document = defaultDocument } = options;\n  const controls = useRafFn(() => {\n    element.value = (document == null ? void 0 : document.elementFromPoint(toValue(x), toValue(y))) || null;\n  });\n  return __spreadValues$e({\n    element\n  }, controls);\n}\n\nfunction useElementHover(el, options = {}) {\n  const {\n    delayEnter = 0,\n    delayLeave = 0,\n    window = defaultWindow\n  } = options;\n  const isHovered = ref(false);\n  let timer;\n  const toggle = (entering) => {\n    const delay = entering ? delayEnter : delayLeave;\n    if (timer) {\n      clearTimeout(timer);\n      timer = void 0;\n    }\n    if (delay)\n      timer = setTimeout(() => isHovered.value = entering, delay);\n    else\n      isHovered.value = entering;\n  };\n  if (!window)\n    return isHovered;\n  useEventListener(el, \"mouseenter\", () => toggle(true), { passive: true });\n  useEventListener(el, \"mouseleave\", () => toggle(false), { passive: true });\n  return isHovered;\n}\n\nfunction useElementSize(target, initialSize = { width: 0, height: 0 }, options = {}) {\n  const { window = defaultWindow, box = \"content-box\" } = options;\n  const isSVG = computed(() => {\n    var _a, _b;\n    return (_b = (_a = unrefElement(target)) == null ? void 0 : _a.namespaceURI) == null ? void 0 : _b.includes(\"svg\");\n  });\n  const width = ref(initialSize.width);\n  const height = ref(initialSize.height);\n  useResizeObserver(\n    target,\n    ([entry]) => {\n      const boxSize = box === \"border-box\" ? entry.borderBoxSize : box === \"content-box\" ? entry.contentBoxSize : entry.devicePixelContentBoxSize;\n      if (window && isSVG.value) {\n        const $elem = unrefElement(target);\n        if ($elem) {\n          const styles = window.getComputedStyle($elem);\n          width.value = parseFloat(styles.width);\n          height.value = parseFloat(styles.height);\n        }\n      } else {\n        if (boxSize) {\n          const formatBoxSize = Array.isArray(boxSize) ? boxSize : [boxSize];\n          width.value = formatBoxSize.reduce((acc, { inlineSize }) => acc + inlineSize, 0);\n          height.value = formatBoxSize.reduce((acc, { blockSize }) => acc + blockSize, 0);\n        } else {\n          width.value = entry.contentRect.width;\n          height.value = entry.contentRect.height;\n        }\n      }\n    },\n    options\n  );\n  watch(\n    () => unrefElement(target),\n    (ele) => {\n      width.value = ele ? initialSize.width : 0;\n      height.value = ele ? initialSize.height : 0;\n    }\n  );\n  return {\n    width,\n    height\n  };\n}\n\nfunction useIntersectionObserver(target, callback, options = {}) {\n  const {\n    root,\n    rootMargin = \"0px\",\n    threshold = 0.1,\n    window = defaultWindow,\n    immediate = true\n  } = options;\n  const isSupported = useSupported(() => window && \"IntersectionObserver\" in window);\n  const targets = computed$1(() => {\n    const _target = toValue(target);\n    return (Array.isArray(_target) ? _target : [_target]).map(unrefElement).filter(notNullish);\n  });\n  let cleanup = noop;\n  const isActive = ref(immediate);\n  const stopWatch = isSupported.value ? watch(\n    () => [targets.value, unrefElement(root), isActive.value],\n    ([targets2, root2]) => {\n      cleanup();\n      if (!isActive.value)\n        return;\n      if (targets2.length)\n        return;\n      const observer = new IntersectionObserver(\n        callback,\n        {\n          root: unrefElement(root2),\n          rootMargin,\n          threshold\n        }\n      );\n      targets2.forEach((el) => el && observer.observe(el));\n      cleanup = () => {\n        observer.disconnect();\n        cleanup = noop;\n      };\n    },\n    { immediate, flush: \"post\" }\n  ) : noop;\n  const stop = () => {\n    cleanup();\n    stopWatch();\n    isActive.value = false;\n  };\n  tryOnScopeDispose(stop);\n  return {\n    isSupported,\n    isActive,\n    pause() {\n      cleanup();\n      isActive.value = false;\n    },\n    resume() {\n      isActive.value = true;\n    },\n    stop\n  };\n}\n\nfunction useElementVisibility(element, { window = defaultWindow, scrollTarget } = {}) {\n  const elementIsVisible = ref(false);\n  useIntersectionObserver(\n    element,\n    ([{ isIntersecting }]) => {\n      elementIsVisible.value = isIntersecting;\n    },\n    {\n      root: scrollTarget,\n      window\n    }\n  );\n  return elementIsVisible;\n}\n\nconst events = /* @__PURE__ */ new Map();\n\nfunction useEventBus(key) {\n  const scope = getCurrentScope();\n  function on(listener) {\n    var _a;\n    const listeners = events.get(key) || /* @__PURE__ */ new Set();\n    listeners.add(listener);\n    events.set(key, listeners);\n    const _off = () => off(listener);\n    (_a = scope == null ? void 0 : scope.cleanups) == null ? void 0 : _a.push(_off);\n    return _off;\n  }\n  function once(listener) {\n    function _listener(...args) {\n      off(_listener);\n      listener(...args);\n    }\n    return on(_listener);\n  }\n  function off(listener) {\n    const listeners = events.get(key);\n    if (!listeners)\n      return;\n    listeners.delete(listener);\n    if (!listeners.size)\n      reset();\n  }\n  function reset() {\n    events.delete(key);\n  }\n  function emit(event, payload) {\n    var _a;\n    (_a = events.get(key)) == null ? void 0 : _a.forEach((v) => v(event, payload));\n  }\n  return { on, once, off, emit, reset };\n}\n\nfunction useEventSource(url, events = [], options = {}) {\n  const event = ref(null);\n  const data = ref(null);\n  const status = ref(\"CONNECTING\");\n  const eventSource = ref(null);\n  const error = shallowRef(null);\n  const {\n    withCredentials = false\n  } = options;\n  const close = () => {\n    if (eventSource.value) {\n      eventSource.value.close();\n      eventSource.value = null;\n      status.value = \"CLOSED\";\n    }\n  };\n  const es = new EventSource(url, { withCredentials });\n  eventSource.value = es;\n  es.onopen = () => {\n    status.value = \"OPEN\";\n    error.value = null;\n  };\n  es.onerror = (e) => {\n    status.value = \"CLOSED\";\n    error.value = e;\n  };\n  es.onmessage = (e) => {\n    event.value = null;\n    data.value = e.data;\n  };\n  for (const event_name of events) {\n    useEventListener(es, event_name, (e) => {\n      event.value = event_name;\n      data.value = e.data || null;\n    });\n  }\n  tryOnScopeDispose(() => {\n    close();\n  });\n  return {\n    eventSource,\n    event,\n    data,\n    status,\n    error,\n    close\n  };\n}\n\nfunction useEyeDropper(options = {}) {\n  const { initialValue = \"\" } = options;\n  const isSupported = useSupported(() => typeof window !== \"undefined\" && \"EyeDropper\" in window);\n  const sRGBHex = ref(initialValue);\n  async function open(openOptions) {\n    if (!isSupported.value)\n      return;\n    const eyeDropper = new window.EyeDropper();\n    const result = await eyeDropper.open(openOptions);\n    sRGBHex.value = result.sRGBHex;\n    return result;\n  }\n  return { isSupported, sRGBHex, open };\n}\n\nfunction useFavicon(newIcon = null, options = {}) {\n  const {\n    baseUrl = \"\",\n    rel = \"icon\",\n    document = defaultDocument\n  } = options;\n  const favicon = toRef(newIcon);\n  const applyIcon = (icon) => {\n    document == null ? void 0 : document.head.querySelectorAll(`link[rel*=\"${rel}\"]`).forEach((el) => el.href = `${baseUrl}${icon}`);\n  };\n  watch(\n    favicon,\n    (i, o) => {\n      if (typeof i === \"string\" && i !== o)\n        applyIcon(i);\n    },\n    { immediate: true }\n  );\n  return favicon;\n}\n\nvar __defProp$d = Object.defineProperty;\nvar __defProps$4 = Object.defineProperties;\nvar __getOwnPropDescs$4 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$f = Object.getOwnPropertySymbols;\nvar __hasOwnProp$f = Object.prototype.hasOwnProperty;\nvar __propIsEnum$f = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$d(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$d = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$f.call(b, prop))\n      __defNormalProp$d(a, prop, b[prop]);\n  if (__getOwnPropSymbols$f)\n    for (var prop of __getOwnPropSymbols$f(b)) {\n      if (__propIsEnum$f.call(b, prop))\n        __defNormalProp$d(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$4 = (a, b) => __defProps$4(a, __getOwnPropDescs$4(b));\nconst payloadMapping = {\n  json: \"application/json\",\n  text: \"text/plain\"\n};\nfunction isFetchOptions(obj) {\n  return obj && containsProp(obj, \"immediate\", \"refetch\", \"initialData\", \"timeout\", \"beforeFetch\", \"afterFetch\", \"onFetchError\", \"fetch\");\n}\nfunction isAbsoluteURL(url) {\n  return /^([a-z][a-z\\d+\\-.]*:)?\\/\\//i.test(url);\n}\nfunction headersToObject(headers) {\n  if (typeof Headers !== \"undefined\" && headers instanceof Headers)\n    return Object.fromEntries([...headers.entries()]);\n  return headers;\n}\nfunction combineCallbacks(combination, ...callbacks) {\n  if (combination === \"overwrite\") {\n    return async (ctx) => {\n      const callback = callbacks[callbacks.length - 1];\n      if (callback !== void 0)\n        await callback(ctx);\n      return ctx;\n    };\n  } else {\n    return async (ctx) => {\n      await callbacks.reduce((prevCallback, callback) => prevCallback.then(async () => {\n        if (callback)\n          ctx = __spreadValues$d(__spreadValues$d({}, ctx), await callback(ctx));\n      }), Promise.resolve());\n      return ctx;\n    };\n  }\n}\nfunction createFetch(config = {}) {\n  const _combination = config.combination || \"chain\";\n  const _options = config.options || {};\n  const _fetchOptions = config.fetchOptions || {};\n  function useFactoryFetch(url, ...args) {\n    const computedUrl = computed(() => {\n      const baseUrl = toValue(config.baseUrl);\n      const targetUrl = toValue(url);\n      return baseUrl && !isAbsoluteURL(targetUrl) ? joinPaths(baseUrl, targetUrl) : targetUrl;\n    });\n    let options = _options;\n    let fetchOptions = _fetchOptions;\n    if (args.length > 0) {\n      if (isFetchOptions(args[0])) {\n        options = __spreadProps$4(__spreadValues$d(__spreadValues$d({}, options), args[0]), {\n          beforeFetch: combineCallbacks(_combination, _options.beforeFetch, args[0].beforeFetch),\n          afterFetch: combineCallbacks(_combination, _options.afterFetch, args[0].afterFetch),\n          onFetchError: combineCallbacks(_combination, _options.onFetchError, args[0].onFetchError)\n        });\n      } else {\n        fetchOptions = __spreadProps$4(__spreadValues$d(__spreadValues$d({}, fetchOptions), args[0]), {\n          headers: __spreadValues$d(__spreadValues$d({}, headersToObject(fetchOptions.headers) || {}), headersToObject(args[0].headers) || {})\n        });\n      }\n    }\n    if (args.length > 1 && isFetchOptions(args[1])) {\n      options = __spreadProps$4(__spreadValues$d(__spreadValues$d({}, options), args[1]), {\n        beforeFetch: combineCallbacks(_combination, _options.beforeFetch, args[1].beforeFetch),\n        afterFetch: combineCallbacks(_combination, _options.afterFetch, args[1].afterFetch),\n        onFetchError: combineCallbacks(_combination, _options.onFetchError, args[1].onFetchError)\n      });\n    }\n    return useFetch(computedUrl, fetchOptions, options);\n  }\n  return useFactoryFetch;\n}\nfunction useFetch(url, ...args) {\n  var _a;\n  const supportsAbort = typeof AbortController === \"function\";\n  let fetchOptions = {};\n  let options = { immediate: true, refetch: false, timeout: 0 };\n  const config = {\n    method: \"GET\",\n    type: \"text\",\n    payload: void 0\n  };\n  if (args.length > 0) {\n    if (isFetchOptions(args[0]))\n      options = __spreadValues$d(__spreadValues$d({}, options), args[0]);\n    else\n      fetchOptions = args[0];\n  }\n  if (args.length > 1) {\n    if (isFetchOptions(args[1]))\n      options = __spreadValues$d(__spreadValues$d({}, options), args[1]);\n  }\n  const {\n    fetch = (_a = defaultWindow) == null ? void 0 : _a.fetch,\n    initialData,\n    timeout\n  } = options;\n  const responseEvent = createEventHook();\n  const errorEvent = createEventHook();\n  const finallyEvent = createEventHook();\n  const isFinished = ref(false);\n  const isFetching = ref(false);\n  const aborted = ref(false);\n  const statusCode = ref(null);\n  const response = shallowRef(null);\n  const error = shallowRef(null);\n  const data = shallowRef(initialData || null);\n  const canAbort = computed(() => supportsAbort && isFetching.value);\n  let controller;\n  let timer;\n  const abort = () => {\n    if (supportsAbort) {\n      controller == null ? void 0 : controller.abort();\n      controller = new AbortController();\n      controller.signal.onabort = () => aborted.value = true;\n      fetchOptions = __spreadProps$4(__spreadValues$d({}, fetchOptions), {\n        signal: controller.signal\n      });\n    }\n  };\n  const loading = (isLoading) => {\n    isFetching.value = isLoading;\n    isFinished.value = !isLoading;\n  };\n  if (timeout)\n    timer = useTimeoutFn(abort, timeout, { immediate: false });\n  const execute = async (throwOnFailed = false) => {\n    var _a2;\n    abort();\n    loading(true);\n    error.value = null;\n    statusCode.value = null;\n    aborted.value = false;\n    const defaultFetchOptions = {\n      method: config.method,\n      headers: {}\n    };\n    if (config.payload) {\n      const headers = headersToObject(defaultFetchOptions.headers);\n      if (config.payloadType)\n        headers[\"Content-Type\"] = (_a2 = payloadMapping[config.payloadType]) != null ? _a2 : config.payloadType;\n      const payload = toValue(config.payload);\n      defaultFetchOptions.body = config.payloadType === \"json\" ? JSON.stringify(payload) : payload;\n    }\n    let isCanceled = false;\n    const context = {\n      url: toValue(url),\n      options: __spreadValues$d(__spreadValues$d({}, defaultFetchOptions), fetchOptions),\n      cancel: () => {\n        isCanceled = true;\n      }\n    };\n    if (options.beforeFetch)\n      Object.assign(context, await options.beforeFetch(context));\n    if (isCanceled || !fetch) {\n      loading(false);\n      return Promise.resolve(null);\n    }\n    let responseData = null;\n    if (timer)\n      timer.start();\n    return new Promise((resolve, reject) => {\n      var _a3;\n      fetch(\n        context.url,\n        __spreadProps$4(__spreadValues$d(__spreadValues$d({}, defaultFetchOptions), context.options), {\n          headers: __spreadValues$d(__spreadValues$d({}, headersToObject(defaultFetchOptions.headers)), headersToObject((_a3 = context.options) == null ? void 0 : _a3.headers))\n        })\n      ).then(async (fetchResponse) => {\n        response.value = fetchResponse;\n        statusCode.value = fetchResponse.status;\n        responseData = await fetchResponse[config.type]();\n        if (!fetchResponse.ok) {\n          data.value = initialData || null;\n          throw new Error(fetchResponse.statusText);\n        }\n        if (options.afterFetch)\n          ({ data: responseData } = await options.afterFetch({ data: responseData, response: fetchResponse }));\n        data.value = responseData;\n        responseEvent.trigger(fetchResponse);\n        return resolve(fetchResponse);\n      }).catch(async (fetchError) => {\n        let errorData = fetchError.message || fetchError.name;\n        if (options.onFetchError)\n          ({ error: errorData } = await options.onFetchError({ data: responseData, error: fetchError, response: response.value }));\n        error.value = errorData;\n        errorEvent.trigger(fetchError);\n        if (throwOnFailed)\n          return reject(fetchError);\n        return resolve(null);\n      }).finally(() => {\n        loading(false);\n        if (timer)\n          timer.stop();\n        finallyEvent.trigger(null);\n      });\n    });\n  };\n  const refetch = toRef(options.refetch);\n  watch(\n    [\n      refetch,\n      toRef(url)\n    ],\n    ([refetch2]) => refetch2 && execute(),\n    { deep: true }\n  );\n  const shell = {\n    isFinished,\n    statusCode,\n    response,\n    error,\n    data,\n    isFetching,\n    canAbort,\n    aborted,\n    abort,\n    execute,\n    onFetchResponse: responseEvent.on,\n    onFetchError: errorEvent.on,\n    onFetchFinally: finallyEvent.on,\n    // method\n    get: setMethod(\"GET\"),\n    put: setMethod(\"PUT\"),\n    post: setMethod(\"POST\"),\n    delete: setMethod(\"DELETE\"),\n    patch: setMethod(\"PATCH\"),\n    head: setMethod(\"HEAD\"),\n    options: setMethod(\"OPTIONS\"),\n    // type\n    json: setType(\"json\"),\n    text: setType(\"text\"),\n    blob: setType(\"blob\"),\n    arrayBuffer: setType(\"arrayBuffer\"),\n    formData: setType(\"formData\")\n  };\n  function setMethod(method) {\n    return (payload, payloadType) => {\n      if (!isFetching.value) {\n        config.method = method;\n        config.payload = payload;\n        config.payloadType = payloadType;\n        if (isRef(config.payload)) {\n          watch(\n            [\n              refetch,\n              toRef(config.payload)\n            ],\n            ([refetch2]) => refetch2 && execute(),\n            { deep: true }\n          );\n        }\n        const rawPayload = toValue(config.payload);\n        if (!payloadType && rawPayload && Object.getPrototypeOf(rawPayload) === Object.prototype && !(rawPayload instanceof FormData))\n          config.payloadType = \"json\";\n        return __spreadProps$4(__spreadValues$d({}, shell), {\n          then(onFulfilled, onRejected) {\n            return waitUntilFinished().then(onFulfilled, onRejected);\n          }\n        });\n      }\n      return void 0;\n    };\n  }\n  function waitUntilFinished() {\n    return new Promise((resolve, reject) => {\n      until(isFinished).toBe(true).then(() => resolve(shell)).catch((error2) => reject(error2));\n    });\n  }\n  function setType(type) {\n    return () => {\n      if (!isFetching.value) {\n        config.type = type;\n        return __spreadProps$4(__spreadValues$d({}, shell), {\n          then(onFulfilled, onRejected) {\n            return waitUntilFinished().then(onFulfilled, onRejected);\n          }\n        });\n      }\n      return void 0;\n    };\n  }\n  if (options.immediate)\n    Promise.resolve().then(() => execute());\n  return __spreadProps$4(__spreadValues$d({}, shell), {\n    then(onFulfilled, onRejected) {\n      return waitUntilFinished().then(onFulfilled, onRejected);\n    }\n  });\n}\nfunction joinPaths(start, end) {\n  if (!start.endsWith(\"/\") && !end.startsWith(\"/\"))\n    return `${start}/${end}`;\n  return `${start}${end}`;\n}\n\nvar __defProp$c = Object.defineProperty;\nvar __getOwnPropSymbols$e = Object.getOwnPropertySymbols;\nvar __hasOwnProp$e = Object.prototype.hasOwnProperty;\nvar __propIsEnum$e = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$c(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$c = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$e.call(b, prop))\n      __defNormalProp$c(a, prop, b[prop]);\n  if (__getOwnPropSymbols$e)\n    for (var prop of __getOwnPropSymbols$e(b)) {\n      if (__propIsEnum$e.call(b, prop))\n        __defNormalProp$c(a, prop, b[prop]);\n    }\n  return a;\n};\nconst DEFAULT_OPTIONS = {\n  multiple: true,\n  accept: \"*\"\n};\nfunction useFileDialog(options = {}) {\n  const {\n    document = defaultDocument\n  } = options;\n  const files = ref(null);\n  const { on: onChange, trigger } = createEventHook();\n  let input;\n  if (document) {\n    input = document.createElement(\"input\");\n    input.type = \"file\";\n    input.onchange = (event) => {\n      const result = event.target;\n      files.value = result.files;\n      trigger(files.value);\n    };\n  }\n  const open = (localOptions) => {\n    if (!input)\n      return;\n    const _options = __spreadValues$c(__spreadValues$c(__spreadValues$c({}, DEFAULT_OPTIONS), options), localOptions);\n    input.multiple = _options.multiple;\n    input.accept = _options.accept;\n    if (hasOwn(_options, \"capture\"))\n      input.capture = _options.capture;\n    input.click();\n  };\n  const reset = () => {\n    files.value = null;\n    if (input)\n      input.value = \"\";\n  };\n  return {\n    files: readonly(files),\n    open,\n    reset,\n    onChange\n  };\n}\n\nvar __defProp$b = Object.defineProperty;\nvar __getOwnPropSymbols$d = Object.getOwnPropertySymbols;\nvar __hasOwnProp$d = Object.prototype.hasOwnProperty;\nvar __propIsEnum$d = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$b(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$b = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$d.call(b, prop))\n      __defNormalProp$b(a, prop, b[prop]);\n  if (__getOwnPropSymbols$d)\n    for (var prop of __getOwnPropSymbols$d(b)) {\n      if (__propIsEnum$d.call(b, prop))\n        __defNormalProp$b(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useFileSystemAccess(options = {}) {\n  const {\n    window: _window = defaultWindow,\n    dataType = \"Text\"\n  } = options;\n  const window = _window;\n  const isSupported = useSupported(() => window && \"showSaveFilePicker\" in window && \"showOpenFilePicker\" in window);\n  const fileHandle = ref();\n  const data = ref();\n  const file = ref();\n  const fileName = computed(() => {\n    var _a, _b;\n    return (_b = (_a = file.value) == null ? void 0 : _a.name) != null ? _b : \"\";\n  });\n  const fileMIME = computed(() => {\n    var _a, _b;\n    return (_b = (_a = file.value) == null ? void 0 : _a.type) != null ? _b : \"\";\n  });\n  const fileSize = computed(() => {\n    var _a, _b;\n    return (_b = (_a = file.value) == null ? void 0 : _a.size) != null ? _b : 0;\n  });\n  const fileLastModified = computed(() => {\n    var _a, _b;\n    return (_b = (_a = file.value) == null ? void 0 : _a.lastModified) != null ? _b : 0;\n  });\n  async function open(_options = {}) {\n    if (!isSupported.value)\n      return;\n    const [handle] = await window.showOpenFilePicker(__spreadValues$b(__spreadValues$b({}, toValue(options)), _options));\n    fileHandle.value = handle;\n    await updateFile();\n    await updateData();\n  }\n  async function create(_options = {}) {\n    if (!isSupported.value)\n      return;\n    fileHandle.value = await window.showSaveFilePicker(__spreadValues$b(__spreadValues$b({}, options), _options));\n    data.value = void 0;\n    await updateFile();\n    await updateData();\n  }\n  async function save(_options = {}) {\n    if (!isSupported.value)\n      return;\n    if (!fileHandle.value)\n      return saveAs(_options);\n    if (data.value) {\n      const writableStream = await fileHandle.value.createWritable();\n      await writableStream.write(data.value);\n      await writableStream.close();\n    }\n    await updateFile();\n  }\n  async function saveAs(_options = {}) {\n    if (!isSupported.value)\n      return;\n    fileHandle.value = await window.showSaveFilePicker(__spreadValues$b(__spreadValues$b({}, options), _options));\n    if (data.value) {\n      const writableStream = await fileHandle.value.createWritable();\n      await writableStream.write(data.value);\n      await writableStream.close();\n    }\n    await updateFile();\n  }\n  async function updateFile() {\n    var _a;\n    file.value = await ((_a = fileHandle.value) == null ? void 0 : _a.getFile());\n  }\n  async function updateData() {\n    var _a, _b;\n    const type = toValue(dataType);\n    if (type === \"Text\")\n      data.value = await ((_a = file.value) == null ? void 0 : _a.text());\n    else if (type === \"ArrayBuffer\")\n      data.value = await ((_b = file.value) == null ? void 0 : _b.arrayBuffer());\n    else if (type === \"Blob\")\n      data.value = file.value;\n  }\n  watch(() => toValue(dataType), updateData);\n  return {\n    isSupported,\n    data,\n    file,\n    fileName,\n    fileMIME,\n    fileSize,\n    fileLastModified,\n    open,\n    create,\n    save,\n    saveAs,\n    updateData\n  };\n}\n\nfunction useFocus(target, options = {}) {\n  const { initialValue = false } = options;\n  const innerFocused = ref(false);\n  const targetElement = computed(() => unrefElement(target));\n  useEventListener(targetElement, \"focus\", () => innerFocused.value = true);\n  useEventListener(targetElement, \"blur\", () => innerFocused.value = false);\n  const focused = computed({\n    get: () => innerFocused.value,\n    set(value) {\n      var _a, _b;\n      if (!value && innerFocused.value)\n        (_a = targetElement.value) == null ? void 0 : _a.blur();\n      else if (value && !innerFocused.value)\n        (_b = targetElement.value) == null ? void 0 : _b.focus();\n    }\n  });\n  watch(\n    targetElement,\n    () => {\n      focused.value = initialValue;\n    },\n    { immediate: true, flush: \"post\" }\n  );\n  return { focused };\n}\n\nfunction useFocusWithin(target, options = {}) {\n  const activeElement = useActiveElement(options);\n  const targetElement = computed(() => unrefElement(target));\n  const focused = computed(() => targetElement.value && activeElement.value ? targetElement.value.contains(activeElement.value) : false);\n  return { focused };\n}\n\nfunction useFps(options) {\n  var _a;\n  const fps = ref(0);\n  if (typeof performance === \"undefined\")\n    return fps;\n  const every = (_a = options == null ? void 0 : options.every) != null ? _a : 10;\n  let last = performance.now();\n  let ticks = 0;\n  useRafFn(() => {\n    ticks += 1;\n    if (ticks >= every) {\n      const now = performance.now();\n      const diff = now - last;\n      fps.value = Math.round(1e3 / (diff / ticks));\n      last = now;\n      ticks = 0;\n    }\n  });\n  return fps;\n}\n\nconst eventHandlers = [\n  \"fullscreenchange\",\n  \"webkitfullscreenchange\",\n  \"webkitendfullscreen\",\n  \"mozfullscreenchange\",\n  \"MSFullscreenChange\"\n];\nfunction useFullscreen(target, options = {}) {\n  const {\n    document = defaultDocument,\n    autoExit = false\n  } = options;\n  const targetRef = computed(() => {\n    var _a;\n    return (_a = unrefElement(target)) != null ? _a : document == null ? void 0 : document.querySelector(\"html\");\n  });\n  const isFullscreen = ref(false);\n  const requestMethod = computed(() => {\n    return [\n      \"requestFullscreen\",\n      \"webkitRequestFullscreen\",\n      \"webkitEnterFullscreen\",\n      \"webkitEnterFullScreen\",\n      \"webkitRequestFullScreen\",\n      \"mozRequestFullScreen\",\n      \"msRequestFullscreen\"\n    ].find((m) => document && m in document || targetRef.value && m in targetRef.value);\n  });\n  const exitMethod = computed(() => {\n    return [\n      \"exitFullscreen\",\n      \"webkitExitFullscreen\",\n      \"webkitExitFullScreen\",\n      \"webkitCancelFullScreen\",\n      \"mozCancelFullScreen\",\n      \"msExitFullscreen\"\n    ].find((m) => document && m in document || targetRef.value && m in targetRef.value);\n  });\n  const fullscreenEnabled = computed(() => {\n    return [\n      \"fullScreen\",\n      \"webkitIsFullScreen\",\n      \"webkitDisplayingFullscreen\",\n      \"mozFullScreen\",\n      \"msFullscreenElement\"\n    ].find((m) => document && m in document || targetRef.value && m in targetRef.value);\n  });\n  const isSupported = useSupported(\n    () => targetRef.value && document && requestMethod.value !== void 0 && exitMethod.value !== void 0 && fullscreenEnabled.value !== void 0\n  );\n  const isElementFullScreen = () => {\n    if (fullscreenEnabled.value) {\n      if (document && document[fullscreenEnabled.value] != null) {\n        return document[fullscreenEnabled.value];\n      } else {\n        const target2 = targetRef.value;\n        if ((target2 == null ? void 0 : target2[fullscreenEnabled.value]) != null) {\n          return Boolean(target2[fullscreenEnabled.value]);\n        }\n      }\n    }\n    return false;\n  };\n  async function exit() {\n    if (!isSupported.value)\n      return;\n    if (exitMethod.value) {\n      if ((document == null ? void 0 : document[exitMethod.value]) != null) {\n        await document[exitMethod.value]();\n      } else {\n        const target2 = targetRef.value;\n        if ((target2 == null ? void 0 : target2[exitMethod.value]) != null)\n          await target2[exitMethod.value]();\n      }\n    }\n    isFullscreen.value = false;\n  }\n  async function enter() {\n    if (!isSupported.value)\n      return;\n    if (isElementFullScreen())\n      await exit();\n    const target2 = targetRef.value;\n    if (requestMethod.value && (target2 == null ? void 0 : target2[requestMethod.value]) != null) {\n      await target2[requestMethod.value]();\n      isFullscreen.value = true;\n    }\n  }\n  async function toggle() {\n    await (isFullscreen.value ? exit() : enter());\n  }\n  const handlerCallback = () => {\n    isFullscreen.value = isElementFullScreen();\n  };\n  useEventListener(document, eventHandlers, handlerCallback, false);\n  useEventListener(() => unrefElement(targetRef), eventHandlers, handlerCallback, false);\n  if (autoExit)\n    tryOnScopeDispose(exit);\n  return {\n    isSupported,\n    isFullscreen,\n    enter,\n    exit,\n    toggle\n  };\n}\n\nfunction mapGamepadToXbox360Controller(gamepad) {\n  return computed(() => {\n    if (gamepad.value) {\n      return {\n        buttons: {\n          a: gamepad.value.buttons[0],\n          b: gamepad.value.buttons[1],\n          x: gamepad.value.buttons[2],\n          y: gamepad.value.buttons[3]\n        },\n        bumper: {\n          left: gamepad.value.buttons[4],\n          right: gamepad.value.buttons[5]\n        },\n        triggers: {\n          left: gamepad.value.buttons[6],\n          right: gamepad.value.buttons[7]\n        },\n        stick: {\n          left: {\n            horizontal: gamepad.value.axes[0],\n            vertical: gamepad.value.axes[1],\n            button: gamepad.value.buttons[10]\n          },\n          right: {\n            horizontal: gamepad.value.axes[2],\n            vertical: gamepad.value.axes[3],\n            button: gamepad.value.buttons[11]\n          }\n        },\n        dpad: {\n          up: gamepad.value.buttons[12],\n          down: gamepad.value.buttons[13],\n          left: gamepad.value.buttons[14],\n          right: gamepad.value.buttons[15]\n        },\n        back: gamepad.value.buttons[8],\n        start: gamepad.value.buttons[9]\n      };\n    }\n    return null;\n  });\n}\nfunction useGamepad(options = {}) {\n  const {\n    navigator = defaultNavigator\n  } = options;\n  const isSupported = useSupported(() => navigator && \"getGamepads\" in navigator);\n  const gamepads = ref([]);\n  const onConnectedHook = createEventHook();\n  const onDisconnectedHook = createEventHook();\n  const stateFromGamepad = (gamepad) => {\n    const hapticActuators = [];\n    const vibrationActuator = \"vibrationActuator\" in gamepad ? gamepad.vibrationActuator : null;\n    if (vibrationActuator)\n      hapticActuators.push(vibrationActuator);\n    if (gamepad.hapticActuators)\n      hapticActuators.push(...gamepad.hapticActuators);\n    return {\n      id: gamepad.id,\n      hapticActuators,\n      index: gamepad.index,\n      mapping: gamepad.mapping,\n      connected: gamepad.connected,\n      timestamp: gamepad.timestamp,\n      axes: gamepad.axes.map((axes) => axes),\n      buttons: gamepad.buttons.map((button) => ({ pressed: button.pressed, touched: button.touched, value: button.value }))\n    };\n  };\n  const updateGamepadState = () => {\n    const _gamepads = (navigator == null ? void 0 : navigator.getGamepads()) || [];\n    for (let i = 0; i < _gamepads.length; ++i) {\n      const gamepad = _gamepads[i];\n      if (gamepad) {\n        const index = gamepads.value.findIndex(({ index: index2 }) => index2 === gamepad.index);\n        if (index > -1)\n          gamepads.value[index] = stateFromGamepad(gamepad);\n      }\n    }\n  };\n  const { isActive, pause, resume } = useRafFn(updateGamepadState);\n  const onGamepadConnected = (gamepad) => {\n    if (!gamepads.value.some(({ index }) => index === gamepad.index)) {\n      gamepads.value.push(stateFromGamepad(gamepad));\n      onConnectedHook.trigger(gamepad.index);\n    }\n    resume();\n  };\n  const onGamepadDisconnected = (gamepad) => {\n    gamepads.value = gamepads.value.filter((x) => x.index !== gamepad.index);\n    onDisconnectedHook.trigger(gamepad.index);\n  };\n  useEventListener(\"gamepadconnected\", (e) => onGamepadConnected(e.gamepad));\n  useEventListener(\"gamepaddisconnected\", (e) => onGamepadDisconnected(e.gamepad));\n  tryOnMounted(() => {\n    const _gamepads = (navigator == null ? void 0 : navigator.getGamepads()) || [];\n    if (_gamepads) {\n      for (let i = 0; i < _gamepads.length; ++i) {\n        const gamepad = _gamepads[i];\n        if (gamepad)\n          onGamepadConnected(gamepad);\n      }\n    }\n  });\n  pause();\n  return {\n    isSupported,\n    onConnected: onConnectedHook.on,\n    onDisconnected: onDisconnectedHook.on,\n    gamepads,\n    pause,\n    resume,\n    isActive\n  };\n}\n\nfunction useGeolocation(options = {}) {\n  const {\n    enableHighAccuracy = true,\n    maximumAge = 3e4,\n    timeout = 27e3,\n    navigator = defaultNavigator,\n    immediate = true\n  } = options;\n  const isSupported = useSupported(() => navigator && \"geolocation\" in navigator);\n  const locatedAt = ref(null);\n  const error = shallowRef(null);\n  const coords = ref({\n    accuracy: 0,\n    latitude: Infinity,\n    longitude: Infinity,\n    altitude: null,\n    altitudeAccuracy: null,\n    heading: null,\n    speed: null\n  });\n  function updatePosition(position) {\n    locatedAt.value = position.timestamp;\n    coords.value = position.coords;\n    error.value = null;\n  }\n  let watcher;\n  function resume() {\n    if (isSupported.value) {\n      watcher = navigator.geolocation.watchPosition(\n        updatePosition,\n        (err) => error.value = err,\n        {\n          enableHighAccuracy,\n          maximumAge,\n          timeout\n        }\n      );\n    }\n  }\n  if (immediate)\n    resume();\n  function pause() {\n    if (watcher && navigator)\n      navigator.geolocation.clearWatch(watcher);\n  }\n  tryOnScopeDispose(() => {\n    pause();\n  });\n  return {\n    isSupported,\n    coords,\n    locatedAt,\n    error,\n    resume,\n    pause\n  };\n}\n\nconst defaultEvents$1 = [\"mousemove\", \"mousedown\", \"resize\", \"keydown\", \"touchstart\", \"wheel\"];\nconst oneMinute = 6e4;\nfunction useIdle(timeout = oneMinute, options = {}) {\n  const {\n    initialState = false,\n    listenForVisibilityChange = true,\n    events = defaultEvents$1,\n    window = defaultWindow,\n    eventFilter = throttleFilter(50)\n  } = options;\n  const idle = ref(initialState);\n  const lastActive = ref(timestamp());\n  let timer;\n  const reset = () => {\n    idle.value = false;\n    clearTimeout(timer);\n    timer = setTimeout(() => idle.value = true, timeout);\n  };\n  const onEvent = createFilterWrapper(\n    eventFilter,\n    () => {\n      lastActive.value = timestamp();\n      reset();\n    }\n  );\n  if (window) {\n    const document = window.document;\n    for (const event of events)\n      useEventListener(window, event, onEvent, { passive: true });\n    if (listenForVisibilityChange) {\n      useEventListener(document, \"visibilitychange\", () => {\n        if (!document.hidden)\n          onEvent();\n      });\n    }\n    reset();\n  }\n  return {\n    idle,\n    lastActive,\n    reset\n  };\n}\n\nvar __defProp$a = Object.defineProperty;\nvar __getOwnPropSymbols$c = Object.getOwnPropertySymbols;\nvar __hasOwnProp$c = Object.prototype.hasOwnProperty;\nvar __propIsEnum$c = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$a = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$c.call(b, prop))\n      __defNormalProp$a(a, prop, b[prop]);\n  if (__getOwnPropSymbols$c)\n    for (var prop of __getOwnPropSymbols$c(b)) {\n      if (__propIsEnum$c.call(b, prop))\n        __defNormalProp$a(a, prop, b[prop]);\n    }\n  return a;\n};\nasync function loadImage(options) {\n  return new Promise((resolve, reject) => {\n    const img = new Image();\n    const { src, srcset, sizes } = options;\n    img.src = src;\n    if (srcset)\n      img.srcset = srcset;\n    if (sizes)\n      img.sizes = sizes;\n    img.onload = () => resolve(img);\n    img.onerror = reject;\n  });\n}\nfunction useImage(options, asyncStateOptions = {}) {\n  const state = useAsyncState(\n    () => loadImage(toValue(options)),\n    void 0,\n    __spreadValues$a({\n      resetOnExecute: true\n    }, asyncStateOptions)\n  );\n  watch(\n    () => toValue(options),\n    () => state.execute(asyncStateOptions.delay),\n    { deep: true }\n  );\n  return state;\n}\n\nconst ARRIVED_STATE_THRESHOLD_PIXELS = 1;\nfunction useScroll(element, options = {}) {\n  const {\n    throttle = 0,\n    idle = 200,\n    onStop = noop,\n    onScroll = noop,\n    offset = {\n      left: 0,\n      right: 0,\n      top: 0,\n      bottom: 0\n    },\n    eventListenerOptions = {\n      capture: false,\n      passive: true\n    },\n    behavior = \"auto\"\n  } = options;\n  const internalX = ref(0);\n  const internalY = ref(0);\n  const x = computed({\n    get() {\n      return internalX.value;\n    },\n    set(x2) {\n      scrollTo(x2, void 0);\n    }\n  });\n  const y = computed({\n    get() {\n      return internalY.value;\n    },\n    set(y2) {\n      scrollTo(void 0, y2);\n    }\n  });\n  function scrollTo(_x, _y) {\n    var _a, _b, _c;\n    const _element = toValue(element);\n    if (!_element)\n      return;\n    (_c = _element instanceof Document ? document.body : _element) == null ? void 0 : _c.scrollTo({\n      top: (_a = toValue(_y)) != null ? _a : y.value,\n      left: (_b = toValue(_x)) != null ? _b : x.value,\n      behavior: toValue(behavior)\n    });\n  }\n  const isScrolling = ref(false);\n  const arrivedState = reactive({\n    left: true,\n    right: false,\n    top: true,\n    bottom: false\n  });\n  const directions = reactive({\n    left: false,\n    right: false,\n    top: false,\n    bottom: false\n  });\n  const onScrollEnd = (e) => {\n    if (!isScrolling.value)\n      return;\n    isScrolling.value = false;\n    directions.left = false;\n    directions.right = false;\n    directions.top = false;\n    directions.bottom = false;\n    onStop(e);\n  };\n  const onScrollEndDebounced = useDebounceFn(onScrollEnd, throttle + idle);\n  const onScrollHandler = (e) => {\n    const eventTarget = e.target === document ? e.target.documentElement : e.target;\n    const { display, flexDirection } = getComputedStyle(eventTarget);\n    const scrollLeft = eventTarget.scrollLeft;\n    directions.left = scrollLeft < internalX.value;\n    directions.right = scrollLeft > internalX.value;\n    const left = Math.abs(scrollLeft) <= 0 + (offset.left || 0);\n    const right = Math.abs(scrollLeft) + eventTarget.clientWidth >= eventTarget.scrollWidth - (offset.right || 0) - ARRIVED_STATE_THRESHOLD_PIXELS;\n    if (display === \"flex\" && flexDirection === \"row-reverse\") {\n      arrivedState.left = right;\n      arrivedState.right = left;\n    } else {\n      arrivedState.left = left;\n      arrivedState.right = right;\n    }\n    internalX.value = scrollLeft;\n    let scrollTop = eventTarget.scrollTop;\n    if (e.target === document && !scrollTop)\n      scrollTop = document.body.scrollTop;\n    directions.top = scrollTop < internalY.value;\n    directions.bottom = scrollTop > internalY.value;\n    const top = Math.abs(scrollTop) <= 0 + (offset.top || 0);\n    const bottom = Math.abs(scrollTop) + eventTarget.clientHeight >= eventTarget.scrollHeight - (offset.bottom || 0) - ARRIVED_STATE_THRESHOLD_PIXELS;\n    if (display === \"flex\" && flexDirection === \"column-reverse\") {\n      arrivedState.top = bottom;\n      arrivedState.bottom = top;\n    } else {\n      arrivedState.top = top;\n      arrivedState.bottom = bottom;\n    }\n    internalY.value = scrollTop;\n    isScrolling.value = true;\n    onScrollEndDebounced(e);\n    onScroll(e);\n  };\n  useEventListener(\n    element,\n    \"scroll\",\n    throttle ? useThrottleFn(onScrollHandler, throttle, true, false) : onScrollHandler,\n    eventListenerOptions\n  );\n  useEventListener(\n    element,\n    \"scrollend\",\n    onScrollEnd,\n    eventListenerOptions\n  );\n  return {\n    x,\n    y,\n    isScrolling,\n    arrivedState,\n    directions\n  };\n}\n\nvar __defProp$9 = Object.defineProperty;\nvar __defProps$3 = Object.defineProperties;\nvar __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$b = Object.getOwnPropertySymbols;\nvar __hasOwnProp$b = Object.prototype.hasOwnProperty;\nvar __propIsEnum$b = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$9 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$b.call(b, prop))\n      __defNormalProp$9(a, prop, b[prop]);\n  if (__getOwnPropSymbols$b)\n    for (var prop of __getOwnPropSymbols$b(b)) {\n      if (__propIsEnum$b.call(b, prop))\n        __defNormalProp$9(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$3 = (a, b) => __defProps$3(a, __getOwnPropDescs$3(b));\nfunction useInfiniteScroll(element, onLoadMore, options = {}) {\n  var _a;\n  const {\n    direction = \"bottom\",\n    interval = 100\n  } = options;\n  const state = reactive(useScroll(\n    element,\n    __spreadProps$3(__spreadValues$9({}, options), {\n      offset: __spreadValues$9({\n        [direction]: (_a = options.distance) != null ? _a : 0\n      }, options.offset)\n    })\n  ));\n  const promise = ref();\n  const isLoading = computed(() => !!promise.value);\n  function checkAndLoad() {\n    const el = toValue(element);\n    if (!el)\n      return;\n    const isNarrower = direction === \"bottom\" || direction === \"top\" ? el.scrollHeight <= el.clientHeight : el.scrollWidth <= el.clientWidth;\n    if (state.arrivedState[direction] || isNarrower) {\n      if (!promise.value) {\n        promise.value = Promise.all([\n          onLoadMore(state),\n          new Promise((resolve) => setTimeout(resolve, interval))\n        ]).finally(() => {\n          promise.value = null;\n          nextTick(() => checkAndLoad());\n        });\n      }\n    }\n  }\n  watch(\n    () => [state.arrivedState[direction], toValue(element)],\n    checkAndLoad,\n    { immediate: true }\n  );\n  return {\n    isLoading\n  };\n}\n\nconst defaultEvents = [\"mousedown\", \"mouseup\", \"keydown\", \"keyup\"];\nfunction useKeyModifier(modifier, options = {}) {\n  const {\n    events = defaultEvents,\n    document = defaultDocument,\n    initial = null\n  } = options;\n  const state = ref(initial);\n  if (document) {\n    events.forEach((listenerEvent) => {\n      useEventListener(document, listenerEvent, (evt) => {\n        if (typeof evt.getModifierState === \"function\")\n          state.value = evt.getModifierState(modifier);\n      });\n    });\n  }\n  return state;\n}\n\nfunction useLocalStorage(key, initialValue, options = {}) {\n  const { window = defaultWindow } = options;\n  return useStorage(key, initialValue, window == null ? void 0 : window.localStorage, options);\n}\n\nconst DefaultMagicKeysAliasMap = {\n  ctrl: \"control\",\n  command: \"meta\",\n  cmd: \"meta\",\n  option: \"alt\",\n  up: \"arrowup\",\n  down: \"arrowdown\",\n  left: \"arrowleft\",\n  right: \"arrowright\"\n};\n\nfunction useMagicKeys(options = {}) {\n  const {\n    reactive: useReactive = false,\n    target = defaultWindow,\n    aliasMap = DefaultMagicKeysAliasMap,\n    passive = true,\n    onEventFired = noop\n  } = options;\n  const current = reactive(/* @__PURE__ */ new Set());\n  const obj = {\n    toJSON() {\n      return {};\n    },\n    current\n  };\n  const refs = useReactive ? reactive(obj) : obj;\n  const metaDeps = /* @__PURE__ */ new Set();\n  const usedKeys = /* @__PURE__ */ new Set();\n  function setRefs(key, value) {\n    if (key in refs) {\n      if (useReactive)\n        refs[key] = value;\n      else\n        refs[key].value = value;\n    }\n  }\n  function reset() {\n    current.clear();\n    for (const key of usedKeys)\n      setRefs(key, false);\n  }\n  function updateRefs(e, value) {\n    var _a, _b;\n    const key = (_a = e.key) == null ? void 0 : _a.toLowerCase();\n    const code = (_b = e.code) == null ? void 0 : _b.toLowerCase();\n    const values = [code, key].filter(Boolean);\n    if (key) {\n      if (value)\n        current.add(key);\n      else\n        current.delete(key);\n    }\n    for (const key2 of values) {\n      usedKeys.add(key2);\n      setRefs(key2, value);\n    }\n    if (key === \"meta\" && !value) {\n      metaDeps.forEach((key2) => {\n        current.delete(key2);\n        setRefs(key2, false);\n      });\n      metaDeps.clear();\n    } else if (typeof e.getModifierState === \"function\" && e.getModifierState(\"Meta\") && value) {\n      [...current, ...values].forEach((key2) => metaDeps.add(key2));\n    }\n  }\n  useEventListener(target, \"keydown\", (e) => {\n    updateRefs(e, true);\n    return onEventFired(e);\n  }, { passive });\n  useEventListener(target, \"keyup\", (e) => {\n    updateRefs(e, false);\n    return onEventFired(e);\n  }, { passive });\n  useEventListener(\"blur\", reset, { passive: true });\n  useEventListener(\"focus\", reset, { passive: true });\n  const proxy = new Proxy(\n    refs,\n    {\n      get(target2, prop, rec) {\n        if (typeof prop !== \"string\")\n          return Reflect.get(target2, prop, rec);\n        prop = prop.toLowerCase();\n        if (prop in aliasMap)\n          prop = aliasMap[prop];\n        if (!(prop in refs)) {\n          if (/[+_-]/.test(prop)) {\n            const keys = prop.split(/[+_-]/g).map((i) => i.trim());\n            refs[prop] = computed(() => keys.every((key) => toValue(proxy[key])));\n          } else {\n            refs[prop] = ref(false);\n          }\n        }\n        const r = Reflect.get(target2, prop, rec);\n        return useReactive ? toValue(r) : r;\n      }\n    }\n  );\n  return proxy;\n}\n\nvar __defProp$8 = Object.defineProperty;\nvar __getOwnPropSymbols$a = Object.getOwnPropertySymbols;\nvar __hasOwnProp$a = Object.prototype.hasOwnProperty;\nvar __propIsEnum$a = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$8 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$a.call(b, prop))\n      __defNormalProp$8(a, prop, b[prop]);\n  if (__getOwnPropSymbols$a)\n    for (var prop of __getOwnPropSymbols$a(b)) {\n      if (__propIsEnum$a.call(b, prop))\n        __defNormalProp$8(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction usingElRef(source, cb) {\n  if (toValue(source))\n    cb(toValue(source));\n}\nfunction timeRangeToArray(timeRanges) {\n  let ranges = [];\n  for (let i = 0; i < timeRanges.length; ++i)\n    ranges = [...ranges, [timeRanges.start(i), timeRanges.end(i)]];\n  return ranges;\n}\nfunction tracksToArray(tracks) {\n  return Array.from(tracks).map(({ label, kind, language, mode, activeCues, cues, inBandMetadataTrackDispatchType }, id) => ({ id, label, kind, language, mode, activeCues, cues, inBandMetadataTrackDispatchType }));\n}\nconst defaultOptions = {\n  src: \"\",\n  tracks: []\n};\nfunction useMediaControls(target, options = {}) {\n  options = __spreadValues$8(__spreadValues$8({}, defaultOptions), options);\n  const {\n    document = defaultDocument\n  } = options;\n  const currentTime = ref(0);\n  const duration = ref(0);\n  const seeking = ref(false);\n  const volume = ref(1);\n  const waiting = ref(false);\n  const ended = ref(false);\n  const playing = ref(false);\n  const rate = ref(1);\n  const stalled = ref(false);\n  const buffered = ref([]);\n  const tracks = ref([]);\n  const selectedTrack = ref(-1);\n  const isPictureInPicture = ref(false);\n  const muted = ref(false);\n  const supportsPictureInPicture = document && \"pictureInPictureEnabled\" in document;\n  const sourceErrorEvent = createEventHook();\n  const disableTrack = (track) => {\n    usingElRef(target, (el) => {\n      if (track) {\n        const id = typeof track === \"number\" ? track : track.id;\n        el.textTracks[id].mode = \"disabled\";\n      } else {\n        for (let i = 0; i < el.textTracks.length; ++i)\n          el.textTracks[i].mode = \"disabled\";\n      }\n      selectedTrack.value = -1;\n    });\n  };\n  const enableTrack = (track, disableTracks = true) => {\n    usingElRef(target, (el) => {\n      const id = typeof track === \"number\" ? track : track.id;\n      if (disableTracks)\n        disableTrack();\n      el.textTracks[id].mode = \"showing\";\n      selectedTrack.value = id;\n    });\n  };\n  const togglePictureInPicture = () => {\n    return new Promise((resolve, reject) => {\n      usingElRef(target, async (el) => {\n        if (supportsPictureInPicture) {\n          if (!isPictureInPicture.value) {\n            el.requestPictureInPicture().then(resolve).catch(reject);\n          } else {\n            document.exitPictureInPicture().then(resolve).catch(reject);\n          }\n        }\n      });\n    });\n  };\n  watchEffect(() => {\n    if (!document)\n      return;\n    const el = toValue(target);\n    if (!el)\n      return;\n    const src = toValue(options.src);\n    let sources = [];\n    if (!src)\n      return;\n    if (typeof src === \"string\")\n      sources = [{ src }];\n    else if (Array.isArray(src))\n      sources = src;\n    else if (isObject(src))\n      sources = [src];\n    el.querySelectorAll(\"source\").forEach((e) => {\n      e.removeEventListener(\"error\", sourceErrorEvent.trigger);\n      e.remove();\n    });\n    sources.forEach(({ src: src2, type }) => {\n      const source = document.createElement(\"source\");\n      source.setAttribute(\"src\", src2);\n      source.setAttribute(\"type\", type || \"\");\n      source.addEventListener(\"error\", sourceErrorEvent.trigger);\n      el.appendChild(source);\n    });\n    el.load();\n  });\n  tryOnScopeDispose(() => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    el.querySelectorAll(\"source\").forEach((e) => e.removeEventListener(\"error\", sourceErrorEvent.trigger));\n  });\n  watch(volume, (vol) => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    el.volume = vol;\n  });\n  watch(muted, (mute) => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    el.muted = mute;\n  });\n  watch(rate, (rate2) => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    el.playbackRate = rate2;\n  });\n  watchEffect(() => {\n    if (!document)\n      return;\n    const textTracks = toValue(options.tracks);\n    const el = toValue(target);\n    if (!textTracks || !textTracks.length || !el)\n      return;\n    el.querySelectorAll(\"track\").forEach((e) => e.remove());\n    textTracks.forEach(({ default: isDefault, kind, label, src, srcLang }, i) => {\n      const track = document.createElement(\"track\");\n      track.default = isDefault || false;\n      track.kind = kind;\n      track.label = label;\n      track.src = src;\n      track.srclang = srcLang;\n      if (track.default)\n        selectedTrack.value = i;\n      el.appendChild(track);\n    });\n  });\n  const { ignoreUpdates: ignoreCurrentTimeUpdates } = watchIgnorable(currentTime, (time) => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    el.currentTime = time;\n  });\n  const { ignoreUpdates: ignorePlayingUpdates } = watchIgnorable(playing, (isPlaying) => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    isPlaying ? el.play() : el.pause();\n  });\n  useEventListener(target, \"timeupdate\", () => ignoreCurrentTimeUpdates(() => currentTime.value = toValue(target).currentTime));\n  useEventListener(target, \"durationchange\", () => duration.value = toValue(target).duration);\n  useEventListener(target, \"progress\", () => buffered.value = timeRangeToArray(toValue(target).buffered));\n  useEventListener(target, \"seeking\", () => seeking.value = true);\n  useEventListener(target, \"seeked\", () => seeking.value = false);\n  useEventListener(target, \"waiting\", () => waiting.value = true);\n  useEventListener(target, \"playing\", () => {\n    waiting.value = false;\n    ended.value = false;\n  });\n  useEventListener(target, \"ratechange\", () => rate.value = toValue(target).playbackRate);\n  useEventListener(target, \"stalled\", () => stalled.value = true);\n  useEventListener(target, \"ended\", () => ended.value = true);\n  useEventListener(target, \"pause\", () => ignorePlayingUpdates(() => playing.value = false));\n  useEventListener(target, \"play\", () => ignorePlayingUpdates(() => playing.value = true));\n  useEventListener(target, \"enterpictureinpicture\", () => isPictureInPicture.value = true);\n  useEventListener(target, \"leavepictureinpicture\", () => isPictureInPicture.value = false);\n  useEventListener(target, \"volumechange\", () => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    volume.value = el.volume;\n    muted.value = el.muted;\n  });\n  const listeners = [];\n  const stop = watch([target], () => {\n    const el = toValue(target);\n    if (!el)\n      return;\n    stop();\n    listeners[0] = useEventListener(el.textTracks, \"addtrack\", () => tracks.value = tracksToArray(el.textTracks));\n    listeners[1] = useEventListener(el.textTracks, \"removetrack\", () => tracks.value = tracksToArray(el.textTracks));\n    listeners[2] = useEventListener(el.textTracks, \"change\", () => tracks.value = tracksToArray(el.textTracks));\n  });\n  tryOnScopeDispose(() => listeners.forEach((listener) => listener()));\n  return {\n    currentTime,\n    duration,\n    waiting,\n    seeking,\n    ended,\n    stalled,\n    buffered,\n    playing,\n    rate,\n    // Volume\n    volume,\n    muted,\n    // Tracks\n    tracks,\n    selectedTrack,\n    enableTrack,\n    disableTrack,\n    // Picture in Picture\n    supportsPictureInPicture,\n    togglePictureInPicture,\n    isPictureInPicture,\n    // Events\n    onSourceError: sourceErrorEvent.on\n  };\n}\n\nfunction getMapVue2Compat() {\n  const data = reactive({});\n  return {\n    get: (key) => data[key],\n    set: (key, value) => set(data, key, value),\n    has: (key) => hasOwn(data, key),\n    delete: (key) => del(data, key),\n    clear: () => {\n      Object.keys(data).forEach((key) => {\n        del(data, key);\n      });\n    }\n  };\n}\nfunction useMemoize(resolver, options) {\n  const initCache = () => {\n    if (options == null ? void 0 : options.cache)\n      return reactive(options.cache);\n    if (isVue2)\n      return getMapVue2Compat();\n    return reactive(/* @__PURE__ */ new Map());\n  };\n  const cache = initCache();\n  const generateKey = (...args) => (options == null ? void 0 : options.getKey) ? options.getKey(...args) : JSON.stringify(args);\n  const _loadData = (key, ...args) => {\n    cache.set(key, resolver(...args));\n    return cache.get(key);\n  };\n  const loadData = (...args) => _loadData(generateKey(...args), ...args);\n  const deleteData = (...args) => {\n    cache.delete(generateKey(...args));\n  };\n  const clearData = () => {\n    cache.clear();\n  };\n  const memoized = (...args) => {\n    const key = generateKey(...args);\n    if (cache.has(key))\n      return cache.get(key);\n    return _loadData(key, ...args);\n  };\n  memoized.load = loadData;\n  memoized.delete = deleteData;\n  memoized.clear = clearData;\n  memoized.generateKey = generateKey;\n  memoized.cache = cache;\n  return memoized;\n}\n\nfunction useMemory(options = {}) {\n  const memory = ref();\n  const isSupported = useSupported(() => typeof performance !== \"undefined\" && \"memory\" in performance);\n  if (isSupported.value) {\n    const { interval = 1e3 } = options;\n    useIntervalFn(() => {\n      memory.value = performance.memory;\n    }, interval, { immediate: options.immediate, immediateCallback: options.immediateCallback });\n  }\n  return { isSupported, memory };\n}\n\nfunction useMouse(options = {}) {\n  const {\n    type = \"page\",\n    touch = true,\n    resetOnTouchEnds = false,\n    initialValue = { x: 0, y: 0 },\n    window = defaultWindow,\n    eventFilter\n  } = options;\n  const x = ref(initialValue.x);\n  const y = ref(initialValue.y);\n  const sourceType = ref(null);\n  const mouseHandler = (event) => {\n    if (type === \"page\") {\n      x.value = event.pageX;\n      y.value = event.pageY;\n    } else if (type === \"client\") {\n      x.value = event.clientX;\n      y.value = event.clientY;\n    } else if (type === \"screen\") {\n      x.value = event.screenX;\n      y.value = event.screenY;\n    } else if (type === \"movement\") {\n      x.value = event.movementX;\n      y.value = event.movementY;\n    }\n    sourceType.value = \"mouse\";\n  };\n  const reset = () => {\n    x.value = initialValue.x;\n    y.value = initialValue.y;\n  };\n  const touchHandler = (event) => {\n    if (event.touches.length > 0) {\n      const touch2 = event.touches[0];\n      if (type === \"page\") {\n        x.value = touch2.pageX;\n        y.value = touch2.pageY;\n      } else if (type === \"client\") {\n        x.value = touch2.clientX;\n        y.value = touch2.clientY;\n      } else if (type === \"screen\") {\n        x.value = touch2.screenX;\n        y.value = touch2.screenY;\n      }\n      sourceType.value = \"touch\";\n    }\n  };\n  const mouseHandlerWrapper = (event) => {\n    return eventFilter === void 0 ? mouseHandler(event) : eventFilter(() => mouseHandler(event), {});\n  };\n  const touchHandlerWrapper = (event) => {\n    return eventFilter === void 0 ? touchHandler(event) : eventFilter(() => touchHandler(event), {});\n  };\n  if (window) {\n    useEventListener(window, \"mousemove\", mouseHandlerWrapper, { passive: true });\n    useEventListener(window, \"dragover\", mouseHandlerWrapper, { passive: true });\n    if (touch && type !== \"movement\") {\n      useEventListener(window, \"touchstart\", touchHandlerWrapper, { passive: true });\n      useEventListener(window, \"touchmove\", touchHandlerWrapper, { passive: true });\n      if (resetOnTouchEnds)\n        useEventListener(window, \"touchend\", reset, { passive: true });\n    }\n  }\n  return {\n    x,\n    y,\n    sourceType\n  };\n}\n\nfunction useMouseInElement(target, options = {}) {\n  const {\n    handleOutside = true,\n    window = defaultWindow\n  } = options;\n  const { x, y, sourceType } = useMouse(options);\n  const targetRef = ref(target != null ? target : window == null ? void 0 : window.document.body);\n  const elementX = ref(0);\n  const elementY = ref(0);\n  const elementPositionX = ref(0);\n  const elementPositionY = ref(0);\n  const elementHeight = ref(0);\n  const elementWidth = ref(0);\n  const isOutside = ref(true);\n  let stop = () => {\n  };\n  if (window) {\n    stop = watch(\n      [targetRef, x, y],\n      () => {\n        const el = unrefElement(targetRef);\n        if (!el)\n          return;\n        const {\n          left,\n          top,\n          width,\n          height\n        } = el.getBoundingClientRect();\n        elementPositionX.value = left + window.pageXOffset;\n        elementPositionY.value = top + window.pageYOffset;\n        elementHeight.value = height;\n        elementWidth.value = width;\n        const elX = x.value - elementPositionX.value;\n        const elY = y.value - elementPositionY.value;\n        isOutside.value = width === 0 || height === 0 || elX < 0 || elY < 0 || elX > width || elY > height;\n        if (handleOutside || !isOutside.value) {\n          elementX.value = elX;\n          elementY.value = elY;\n        }\n      },\n      { immediate: true }\n    );\n    useEventListener(document, \"mouseleave\", () => {\n      isOutside.value = true;\n    });\n  }\n  return {\n    x,\n    y,\n    sourceType,\n    elementX,\n    elementY,\n    elementPositionX,\n    elementPositionY,\n    elementHeight,\n    elementWidth,\n    isOutside,\n    stop\n  };\n}\n\nfunction useMousePressed(options = {}) {\n  const {\n    touch = true,\n    drag = true,\n    initialValue = false,\n    window = defaultWindow\n  } = options;\n  const pressed = ref(initialValue);\n  const sourceType = ref(null);\n  if (!window) {\n    return {\n      pressed,\n      sourceType\n    };\n  }\n  const onPressed = (srcType) => () => {\n    pressed.value = true;\n    sourceType.value = srcType;\n  };\n  const onReleased = () => {\n    pressed.value = false;\n    sourceType.value = null;\n  };\n  const target = computed(() => unrefElement(options.target) || window);\n  useEventListener(target, \"mousedown\", onPressed(\"mouse\"), { passive: true });\n  useEventListener(window, \"mouseleave\", onReleased, { passive: true });\n  useEventListener(window, \"mouseup\", onReleased, { passive: true });\n  if (drag) {\n    useEventListener(target, \"dragstart\", onPressed(\"mouse\"), { passive: true });\n    useEventListener(window, \"drop\", onReleased, { passive: true });\n    useEventListener(window, \"dragend\", onReleased, { passive: true });\n  }\n  if (touch) {\n    useEventListener(target, \"touchstart\", onPressed(\"touch\"), { passive: true });\n    useEventListener(window, \"touchend\", onReleased, { passive: true });\n    useEventListener(window, \"touchcancel\", onReleased, { passive: true });\n  }\n  return {\n    pressed,\n    sourceType\n  };\n}\n\nvar __getOwnPropSymbols$9 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$9 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$9 = Object.prototype.propertyIsEnumerable;\nvar __objRest$2 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$9.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$9)\n    for (var prop of __getOwnPropSymbols$9(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$9.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction useMutationObserver(target, callback, options = {}) {\n  const _a = options, { window = defaultWindow } = _a, mutationOptions = __objRest$2(_a, [\"window\"]);\n  let observer;\n  const isSupported = useSupported(() => window && \"MutationObserver\" in window);\n  const cleanup = () => {\n    if (observer) {\n      observer.disconnect();\n      observer = void 0;\n    }\n  };\n  const stopWatch = watch(\n    () => unrefElement(target),\n    (el) => {\n      cleanup();\n      if (isSupported.value && window && el) {\n        observer = new MutationObserver(callback);\n        observer.observe(el, mutationOptions);\n      }\n    },\n    { immediate: true }\n  );\n  const stop = () => {\n    cleanup();\n    stopWatch();\n  };\n  tryOnScopeDispose(stop);\n  return {\n    isSupported,\n    stop\n  };\n}\n\nfunction useNavigatorLanguage(options = {}) {\n  const { window = defaultWindow } = options;\n  const navigator = window == null ? void 0 : window.navigator;\n  const isSupported = useSupported(() => navigator && \"language\" in navigator);\n  const language = ref(navigator == null ? void 0 : navigator.language);\n  useEventListener(window, \"languagechange\", () => {\n    if (navigator)\n      language.value = navigator.language;\n  });\n  return {\n    isSupported,\n    language\n  };\n}\n\nfunction useNetwork(options = {}) {\n  const { window = defaultWindow } = options;\n  const navigator = window == null ? void 0 : window.navigator;\n  const isSupported = useSupported(() => navigator && \"connection\" in navigator);\n  const isOnline = ref(true);\n  const saveData = ref(false);\n  const offlineAt = ref(void 0);\n  const onlineAt = ref(void 0);\n  const downlink = ref(void 0);\n  const downlinkMax = ref(void 0);\n  const rtt = ref(void 0);\n  const effectiveType = ref(void 0);\n  const type = ref(\"unknown\");\n  const connection = isSupported.value && navigator.connection;\n  function updateNetworkInformation() {\n    if (!navigator)\n      return;\n    isOnline.value = navigator.onLine;\n    offlineAt.value = isOnline.value ? void 0 : Date.now();\n    onlineAt.value = isOnline.value ? Date.now() : void 0;\n    if (connection) {\n      downlink.value = connection.downlink;\n      downlinkMax.value = connection.downlinkMax;\n      effectiveType.value = connection.effectiveType;\n      rtt.value = connection.rtt;\n      saveData.value = connection.saveData;\n      type.value = connection.type;\n    }\n  }\n  if (window) {\n    useEventListener(window, \"offline\", () => {\n      isOnline.value = false;\n      offlineAt.value = Date.now();\n    });\n    useEventListener(window, \"online\", () => {\n      isOnline.value = true;\n      onlineAt.value = Date.now();\n    });\n  }\n  if (connection)\n    useEventListener(connection, \"change\", updateNetworkInformation, false);\n  updateNetworkInformation();\n  return {\n    isSupported,\n    isOnline,\n    saveData,\n    offlineAt,\n    onlineAt,\n    downlink,\n    downlinkMax,\n    effectiveType,\n    rtt,\n    type\n  };\n}\n\nvar __defProp$7 = Object.defineProperty;\nvar __getOwnPropSymbols$8 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$8 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$8 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$7 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$8.call(b, prop))\n      __defNormalProp$7(a, prop, b[prop]);\n  if (__getOwnPropSymbols$8)\n    for (var prop of __getOwnPropSymbols$8(b)) {\n      if (__propIsEnum$8.call(b, prop))\n        __defNormalProp$7(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useNow(options = {}) {\n  const {\n    controls: exposeControls = false,\n    interval = \"requestAnimationFrame\"\n  } = options;\n  const now = ref(/* @__PURE__ */ new Date());\n  const update = () => now.value = /* @__PURE__ */ new Date();\n  const controls = interval === \"requestAnimationFrame\" ? useRafFn(update, { immediate: true }) : useIntervalFn(update, interval, { immediate: true });\n  if (exposeControls) {\n    return __spreadValues$7({\n      now\n    }, controls);\n  } else {\n    return now;\n  }\n}\n\nfunction useObjectUrl(object) {\n  const url = ref();\n  const release = () => {\n    if (url.value)\n      URL.revokeObjectURL(url.value);\n    url.value = void 0;\n  };\n  watch(\n    () => toValue(object),\n    (newObject) => {\n      release();\n      if (newObject)\n        url.value = URL.createObjectURL(newObject);\n    },\n    { immediate: true }\n  );\n  tryOnScopeDispose(release);\n  return readonly(url);\n}\n\nfunction useClamp(value, min, max) {\n  if (typeof value === \"function\" || isReadonly(value))\n    return computed(() => clamp(toValue(value), toValue(min), toValue(max)));\n  const _value = ref(value);\n  return computed({\n    get() {\n      return _value.value = clamp(_value.value, toValue(min), toValue(max));\n    },\n    set(value2) {\n      _value.value = clamp(value2, toValue(min), toValue(max));\n    }\n  });\n}\n\nfunction useOffsetPagination(options) {\n  const {\n    total = Infinity,\n    pageSize = 10,\n    page = 1,\n    onPageChange = noop,\n    onPageSizeChange = noop,\n    onPageCountChange = noop\n  } = options;\n  const currentPageSize = useClamp(pageSize, 1, Infinity);\n  const pageCount = computed(() => Math.max(\n    1,\n    Math.ceil(toValue(total) / toValue(currentPageSize))\n  ));\n  const currentPage = useClamp(page, 1, pageCount);\n  const isFirstPage = computed(() => currentPage.value === 1);\n  const isLastPage = computed(() => currentPage.value === pageCount.value);\n  if (isRef(page))\n    syncRef(page, currentPage);\n  if (isRef(pageSize))\n    syncRef(pageSize, currentPageSize);\n  function prev() {\n    currentPage.value--;\n  }\n  function next() {\n    currentPage.value++;\n  }\n  const returnValue = {\n    currentPage,\n    currentPageSize,\n    pageCount,\n    isFirstPage,\n    isLastPage,\n    prev,\n    next\n  };\n  watch(currentPage, () => {\n    onPageChange(reactive(returnValue));\n  });\n  watch(currentPageSize, () => {\n    onPageSizeChange(reactive(returnValue));\n  });\n  watch(pageCount, () => {\n    onPageCountChange(reactive(returnValue));\n  });\n  return returnValue;\n}\n\nfunction useOnline(options = {}) {\n  const { isOnline } = useNetwork(options);\n  return isOnline;\n}\n\nfunction usePageLeave(options = {}) {\n  const { window = defaultWindow } = options;\n  const isLeft = ref(false);\n  const handler = (event) => {\n    if (!window)\n      return;\n    event = event || window.event;\n    const from = event.relatedTarget || event.toElement;\n    isLeft.value = !from;\n  };\n  if (window) {\n    useEventListener(window, \"mouseout\", handler, { passive: true });\n    useEventListener(window.document, \"mouseleave\", handler, { passive: true });\n    useEventListener(window.document, \"mouseenter\", handler, { passive: true });\n  }\n  return isLeft;\n}\n\nfunction useParallax(target, options = {}) {\n  const {\n    deviceOrientationTiltAdjust = (i) => i,\n    deviceOrientationRollAdjust = (i) => i,\n    mouseTiltAdjust = (i) => i,\n    mouseRollAdjust = (i) => i,\n    window = defaultWindow\n  } = options;\n  const orientation = reactive(useDeviceOrientation({ window }));\n  const {\n    elementX: x,\n    elementY: y,\n    elementWidth: width,\n    elementHeight: height\n  } = useMouseInElement(target, { handleOutside: false, window });\n  const source = computed(() => {\n    if (orientation.isSupported && (orientation.alpha != null && orientation.alpha !== 0 || orientation.gamma != null && orientation.gamma !== 0))\n      return \"deviceOrientation\";\n    return \"mouse\";\n  });\n  const roll = computed(() => {\n    if (source.value === \"deviceOrientation\") {\n      const value = -orientation.beta / 90;\n      return deviceOrientationRollAdjust(value);\n    } else {\n      const value = -(y.value - height.value / 2) / height.value;\n      return mouseRollAdjust(value);\n    }\n  });\n  const tilt = computed(() => {\n    if (source.value === \"deviceOrientation\") {\n      const value = orientation.gamma / 90;\n      return deviceOrientationTiltAdjust(value);\n    } else {\n      const value = (x.value - width.value / 2) / width.value;\n      return mouseTiltAdjust(value);\n    }\n  });\n  return { roll, tilt, source };\n}\n\nfunction useParentElement(element = useCurrentElement()) {\n  const parentElement = shallowRef();\n  const update = () => {\n    const el = unrefElement(element);\n    if (el)\n      parentElement.value = el.parentElement;\n  };\n  tryOnMounted(update);\n  watch(() => toValue(element), update);\n  return parentElement;\n}\n\nvar __getOwnPropSymbols$7 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$7 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$7 = Object.prototype.propertyIsEnumerable;\nvar __objRest$1 = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$7.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$7)\n    for (var prop of __getOwnPropSymbols$7(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$7.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nfunction usePerformanceObserver(options, callback) {\n  const _a = options, {\n    window = defaultWindow,\n    immediate = true\n  } = _a, performanceOptions = __objRest$1(_a, [\n    \"window\",\n    \"immediate\"\n  ]);\n  const isSupported = useSupported(() => window && \"PerformanceObserver\" in window);\n  let observer;\n  const stop = () => {\n    observer == null ? void 0 : observer.disconnect();\n  };\n  const start = () => {\n    if (isSupported.value) {\n      stop();\n      observer = new PerformanceObserver(callback);\n      observer.observe(performanceOptions);\n    }\n  };\n  tryOnScopeDispose(stop);\n  if (immediate)\n    start();\n  return {\n    isSupported,\n    start,\n    stop\n  };\n}\n\nvar __defProp$6 = Object.defineProperty;\nvar __defProps$2 = Object.defineProperties;\nvar __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$6 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$6 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$6 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$6 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$6.call(b, prop))\n      __defNormalProp$6(a, prop, b[prop]);\n  if (__getOwnPropSymbols$6)\n    for (var prop of __getOwnPropSymbols$6(b)) {\n      if (__propIsEnum$6.call(b, prop))\n        __defNormalProp$6(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$2 = (a, b) => __defProps$2(a, __getOwnPropDescs$2(b));\nconst defaultState = {\n  x: 0,\n  y: 0,\n  pointerId: 0,\n  pressure: 0,\n  tiltX: 0,\n  tiltY: 0,\n  width: 0,\n  height: 0,\n  twist: 0,\n  pointerType: null\n};\nconst keys = /* @__PURE__ */ Object.keys(defaultState);\nfunction usePointer(options = {}) {\n  const {\n    target = defaultWindow\n  } = options;\n  const isInside = ref(false);\n  const state = ref(options.initialValue || {});\n  Object.assign(state.value, defaultState, state.value);\n  const handler = (event) => {\n    isInside.value = true;\n    if (options.pointerTypes && !options.pointerTypes.includes(event.pointerType))\n      return;\n    state.value = objectPick(event, keys, false);\n  };\n  if (target) {\n    useEventListener(target, \"pointerdown\", handler, { passive: true });\n    useEventListener(target, \"pointermove\", handler, { passive: true });\n    useEventListener(target, \"pointerleave\", () => isInside.value = false, { passive: true });\n  }\n  return __spreadProps$2(__spreadValues$6({}, toRefs(state)), {\n    isInside\n  });\n}\n\nfunction usePointerLock(target, options = {}) {\n  const { document = defaultDocument, pointerLockOptions } = options;\n  const isSupported = useSupported(() => document && \"pointerLockElement\" in document);\n  const element = ref();\n  const triggerElement = ref();\n  let targetElement;\n  if (isSupported.value) {\n    useEventListener(document, \"pointerlockchange\", () => {\n      var _a;\n      const currentElement = (_a = document.pointerLockElement) != null ? _a : element.value;\n      if (targetElement && currentElement === targetElement) {\n        element.value = document.pointerLockElement;\n        if (!element.value)\n          targetElement = triggerElement.value = null;\n      }\n    });\n    useEventListener(document, \"pointerlockerror\", () => {\n      var _a;\n      const currentElement = (_a = document.pointerLockElement) != null ? _a : element.value;\n      if (targetElement && currentElement === targetElement) {\n        const action = document.pointerLockElement ? \"release\" : \"acquire\";\n        throw new Error(`Failed to ${action} pointer lock.`);\n      }\n    });\n  }\n  async function lock(e, options2) {\n    var _a;\n    if (!isSupported.value)\n      throw new Error(\"Pointer Lock API is not supported by your browser.\");\n    triggerElement.value = e instanceof Event ? e.currentTarget : null;\n    targetElement = e instanceof Event ? (_a = unrefElement(target)) != null ? _a : triggerElement.value : unrefElement(e);\n    if (!targetElement)\n      throw new Error(\"Target element undefined.\");\n    targetElement.requestPointerLock(options2 != null ? options2 : pointerLockOptions);\n    return await until(element).toBe(targetElement);\n  }\n  async function unlock() {\n    if (!element.value)\n      return false;\n    document.exitPointerLock();\n    await until(element).toBeNull();\n    return true;\n  }\n  return {\n    isSupported,\n    element,\n    triggerElement,\n    lock,\n    unlock\n  };\n}\n\nfunction usePointerSwipe(target, options = {}) {\n  const targetRef = toRef(target);\n  const {\n    threshold = 50,\n    onSwipe,\n    onSwipeEnd,\n    onSwipeStart\n  } = options;\n  const posStart = reactive({ x: 0, y: 0 });\n  const updatePosStart = (x, y) => {\n    posStart.x = x;\n    posStart.y = y;\n  };\n  const posEnd = reactive({ x: 0, y: 0 });\n  const updatePosEnd = (x, y) => {\n    posEnd.x = x;\n    posEnd.y = y;\n  };\n  const distanceX = computed(() => posStart.x - posEnd.x);\n  const distanceY = computed(() => posStart.y - posEnd.y);\n  const { max, abs } = Math;\n  const isThresholdExceeded = computed(() => max(abs(distanceX.value), abs(distanceY.value)) >= threshold);\n  const isSwiping = ref(false);\n  const isPointerDown = ref(false);\n  const direction = computed(() => {\n    if (!isThresholdExceeded.value)\n      return \"none\";\n    if (abs(distanceX.value) > abs(distanceY.value)) {\n      return distanceX.value > 0 ? \"left\" : \"right\";\n    } else {\n      return distanceY.value > 0 ? \"up\" : \"down\";\n    }\n  });\n  const eventIsAllowed = (e) => {\n    var _a, _b, _c;\n    const isReleasingButton = e.buttons === 0;\n    const isPrimaryButton = e.buttons === 1;\n    return (_c = (_b = (_a = options.pointerTypes) == null ? void 0 : _a.includes(e.pointerType)) != null ? _b : isReleasingButton || isPrimaryButton) != null ? _c : true;\n  };\n  const stops = [\n    useEventListener(target, \"pointerdown\", (e) => {\n      var _a, _b;\n      if (!eventIsAllowed(e))\n        return;\n      isPointerDown.value = true;\n      (_b = (_a = targetRef.value) == null ? void 0 : _a.style) == null ? void 0 : _b.setProperty(\"touch-action\", \"none\");\n      const eventTarget = e.target;\n      eventTarget == null ? void 0 : eventTarget.setPointerCapture(e.pointerId);\n      const { clientX: x, clientY: y } = e;\n      updatePosStart(x, y);\n      updatePosEnd(x, y);\n      onSwipeStart == null ? void 0 : onSwipeStart(e);\n    }),\n    useEventListener(target, \"pointermove\", (e) => {\n      if (!eventIsAllowed(e))\n        return;\n      if (!isPointerDown.value)\n        return;\n      const { clientX: x, clientY: y } = e;\n      updatePosEnd(x, y);\n      if (!isSwiping.value && isThresholdExceeded.value)\n        isSwiping.value = true;\n      if (isSwiping.value)\n        onSwipe == null ? void 0 : onSwipe(e);\n    }),\n    useEventListener(target, \"pointerup\", (e) => {\n      var _a, _b;\n      if (!eventIsAllowed(e))\n        return;\n      if (isSwiping.value)\n        onSwipeEnd == null ? void 0 : onSwipeEnd(e, direction.value);\n      isPointerDown.value = false;\n      isSwiping.value = false;\n      (_b = (_a = targetRef.value) == null ? void 0 : _a.style) == null ? void 0 : _b.setProperty(\"touch-action\", \"initial\");\n    })\n  ];\n  const stop = () => stops.forEach((s) => s());\n  return {\n    isSwiping: readonly(isSwiping),\n    direction: readonly(direction),\n    posStart: readonly(posStart),\n    posEnd: readonly(posEnd),\n    distanceX,\n    distanceY,\n    stop\n  };\n}\n\nfunction usePreferredColorScheme(options) {\n  const isLight = useMediaQuery(\"(prefers-color-scheme: light)\", options);\n  const isDark = useMediaQuery(\"(prefers-color-scheme: dark)\", options);\n  return computed(() => {\n    if (isDark.value)\n      return \"dark\";\n    if (isLight.value)\n      return \"light\";\n    return \"no-preference\";\n  });\n}\n\nfunction usePreferredContrast(options) {\n  const isMore = useMediaQuery(\"(prefers-contrast: more)\", options);\n  const isLess = useMediaQuery(\"(prefers-contrast: less)\", options);\n  const isCustom = useMediaQuery(\"(prefers-contrast: custom)\", options);\n  return computed(() => {\n    if (isMore.value)\n      return \"more\";\n    if (isLess.value)\n      return \"less\";\n    if (isCustom.value)\n      return \"custom\";\n    return \"no-preference\";\n  });\n}\n\nfunction usePreferredLanguages(options = {}) {\n  const { window = defaultWindow } = options;\n  if (!window)\n    return ref([\"en\"]);\n  const navigator = window.navigator;\n  const value = ref(navigator.languages);\n  useEventListener(window, \"languagechange\", () => {\n    value.value = navigator.languages;\n  });\n  return value;\n}\n\nfunction usePreferredReducedMotion(options) {\n  const isReduced = useMediaQuery(\"(prefers-reduced-motion: reduce)\", options);\n  return computed(() => {\n    if (isReduced.value)\n      return \"reduce\";\n    return \"no-preference\";\n  });\n}\n\nfunction usePrevious(value, initialValue) {\n  const previous = shallowRef(initialValue);\n  watch(\n    toRef(value),\n    (_, oldValue) => {\n      previous.value = oldValue;\n    },\n    { flush: \"sync\" }\n  );\n  return readonly(previous);\n}\n\nfunction useScreenOrientation(options = {}) {\n  const {\n    window = defaultWindow\n  } = options;\n  const isSupported = useSupported(() => window && \"screen\" in window && \"orientation\" in window.screen);\n  const screenOrientation = isSupported.value ? window.screen.orientation : {};\n  const orientation = ref(screenOrientation.type);\n  const angle = ref(screenOrientation.angle || 0);\n  if (isSupported.value) {\n    useEventListener(window, \"orientationchange\", () => {\n      orientation.value = screenOrientation.type;\n      angle.value = screenOrientation.angle;\n    });\n  }\n  const lockOrientation = (type) => {\n    if (!isSupported.value)\n      return Promise.reject(new Error(\"Not supported\"));\n    return screenOrientation.lock(type);\n  };\n  const unlockOrientation = () => {\n    if (isSupported.value)\n      screenOrientation.unlock();\n  };\n  return {\n    isSupported,\n    orientation,\n    angle,\n    lockOrientation,\n    unlockOrientation\n  };\n}\n\nconst topVarName = \"--vueuse-safe-area-top\";\nconst rightVarName = \"--vueuse-safe-area-right\";\nconst bottomVarName = \"--vueuse-safe-area-bottom\";\nconst leftVarName = \"--vueuse-safe-area-left\";\nfunction useScreenSafeArea() {\n  const top = ref(\"\");\n  const right = ref(\"\");\n  const bottom = ref(\"\");\n  const left = ref(\"\");\n  if (isClient) {\n    const topCssVar = useCssVar(topVarName);\n    const rightCssVar = useCssVar(rightVarName);\n    const bottomCssVar = useCssVar(bottomVarName);\n    const leftCssVar = useCssVar(leftVarName);\n    topCssVar.value = \"env(safe-area-inset-top, 0px)\";\n    rightCssVar.value = \"env(safe-area-inset-right, 0px)\";\n    bottomCssVar.value = \"env(safe-area-inset-bottom, 0px)\";\n    leftCssVar.value = \"env(safe-area-inset-left, 0px)\";\n    update();\n    useEventListener(\"resize\", useDebounceFn(update));\n  }\n  function update() {\n    top.value = getValue(topVarName);\n    right.value = getValue(rightVarName);\n    bottom.value = getValue(bottomVarName);\n    left.value = getValue(leftVarName);\n  }\n  return {\n    top,\n    right,\n    bottom,\n    left,\n    update\n  };\n}\nfunction getValue(position) {\n  return getComputedStyle(document.documentElement).getPropertyValue(position);\n}\n\nfunction useScriptTag(src, onLoaded = noop, options = {}) {\n  const {\n    immediate = true,\n    manual = false,\n    type = \"text/javascript\",\n    async = true,\n    crossOrigin,\n    referrerPolicy,\n    noModule,\n    defer,\n    document = defaultDocument,\n    attrs = {}\n  } = options;\n  const scriptTag = ref(null);\n  let _promise = null;\n  const loadScript = (waitForScriptLoad) => new Promise((resolve, reject) => {\n    const resolveWithElement = (el2) => {\n      scriptTag.value = el2;\n      resolve(el2);\n      return el2;\n    };\n    if (!document) {\n      resolve(false);\n      return;\n    }\n    let shouldAppend = false;\n    let el = document.querySelector(`script[src=\"${toValue(src)}\"]`);\n    if (!el) {\n      el = document.createElement(\"script\");\n      el.type = type;\n      el.async = async;\n      el.src = toValue(src);\n      if (defer)\n        el.defer = defer;\n      if (crossOrigin)\n        el.crossOrigin = crossOrigin;\n      if (noModule)\n        el.noModule = noModule;\n      if (referrerPolicy)\n        el.referrerPolicy = referrerPolicy;\n      Object.entries(attrs).forEach(([name, value]) => el == null ? void 0 : el.setAttribute(name, value));\n      shouldAppend = true;\n    } else if (el.hasAttribute(\"data-loaded\")) {\n      resolveWithElement(el);\n    }\n    el.addEventListener(\"error\", (event) => reject(event));\n    el.addEventListener(\"abort\", (event) => reject(event));\n    el.addEventListener(\"load\", () => {\n      el.setAttribute(\"data-loaded\", \"true\");\n      onLoaded(el);\n      resolveWithElement(el);\n    });\n    if (shouldAppend)\n      el = document.head.appendChild(el);\n    if (!waitForScriptLoad)\n      resolveWithElement(el);\n  });\n  const load = (waitForScriptLoad = true) => {\n    if (!_promise)\n      _promise = loadScript(waitForScriptLoad);\n    return _promise;\n  };\n  const unload = () => {\n    if (!document)\n      return;\n    _promise = null;\n    if (scriptTag.value)\n      scriptTag.value = null;\n    const el = document.querySelector(`script[src=\"${toValue(src)}\"]`);\n    if (el)\n      document.head.removeChild(el);\n  };\n  if (immediate && !manual)\n    tryOnMounted(load);\n  if (!manual)\n    tryOnUnmounted(unload);\n  return { scriptTag, load, unload };\n}\n\nfunction checkOverflowScroll(ele) {\n  const style = window.getComputedStyle(ele);\n  if (style.overflowX === \"scroll\" || style.overflowY === \"scroll\" || style.overflowX === \"auto\" && ele.clientHeight < ele.scrollHeight || style.overflowY === \"auto\" && ele.clientWidth < ele.scrollWidth) {\n    return true;\n  } else {\n    const parent = ele.parentNode;\n    if (!parent || parent.tagName === \"BODY\")\n      return false;\n    return checkOverflowScroll(parent);\n  }\n}\nfunction preventDefault(rawEvent) {\n  const e = rawEvent || window.event;\n  const _target = e.target;\n  if (checkOverflowScroll(_target))\n    return false;\n  if (e.touches.length > 1)\n    return true;\n  if (e.preventDefault)\n    e.preventDefault();\n  return false;\n}\nfunction useScrollLock(element, initialState = false) {\n  const isLocked = ref(initialState);\n  let stopTouchMoveListener = null;\n  let initialOverflow;\n  watch(toRef(element), (el) => {\n    if (el) {\n      const ele = el;\n      initialOverflow = ele.style.overflow;\n      if (isLocked.value)\n        ele.style.overflow = \"hidden\";\n    }\n  }, {\n    immediate: true\n  });\n  const lock = () => {\n    const ele = toValue(element);\n    if (!ele || isLocked.value)\n      return;\n    if (isIOS) {\n      stopTouchMoveListener = useEventListener(\n        ele,\n        \"touchmove\",\n        (e) => {\n          preventDefault(e);\n        },\n        { passive: false }\n      );\n    }\n    ele.style.overflow = \"hidden\";\n    isLocked.value = true;\n  };\n  const unlock = () => {\n    const ele = toValue(element);\n    if (!ele || !isLocked.value)\n      return;\n    isIOS && (stopTouchMoveListener == null ? void 0 : stopTouchMoveListener());\n    ele.style.overflow = initialOverflow;\n    isLocked.value = false;\n  };\n  tryOnScopeDispose(unlock);\n  return computed({\n    get() {\n      return isLocked.value;\n    },\n    set(v) {\n      if (v)\n        lock();\n      else\n        unlock();\n    }\n  });\n}\n\nfunction useSessionStorage(key, initialValue, options = {}) {\n  const { window = defaultWindow } = options;\n  return useStorage(key, initialValue, window == null ? void 0 : window.sessionStorage, options);\n}\n\nvar __defProp$5 = Object.defineProperty;\nvar __getOwnPropSymbols$5 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$5 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$5 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$5 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$5.call(b, prop))\n      __defNormalProp$5(a, prop, b[prop]);\n  if (__getOwnPropSymbols$5)\n    for (var prop of __getOwnPropSymbols$5(b)) {\n      if (__propIsEnum$5.call(b, prop))\n        __defNormalProp$5(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useShare(shareOptions = {}, options = {}) {\n  const { navigator = defaultNavigator } = options;\n  const _navigator = navigator;\n  const isSupported = useSupported(() => _navigator && \"canShare\" in _navigator);\n  const share = async (overrideOptions = {}) => {\n    if (isSupported.value) {\n      const data = __spreadValues$5(__spreadValues$5({}, toValue(shareOptions)), toValue(overrideOptions));\n      let granted = true;\n      if (data.files && _navigator.canShare)\n        granted = _navigator.canShare({ files: data.files });\n      if (granted)\n        return _navigator.share(data);\n    }\n  };\n  return {\n    isSupported,\n    share\n  };\n}\n\nconst defaultSortFn = (source, compareFn) => source.sort(compareFn);\nconst defaultCompare = (a, b) => a - b;\nfunction useSorted(...args) {\n  var _a, _b, _c, _d;\n  const [source] = args;\n  let compareFn = defaultCompare;\n  let options = {};\n  if (args.length === 2) {\n    if (typeof args[1] === \"object\") {\n      options = args[1];\n      compareFn = (_a = options.compareFn) != null ? _a : defaultCompare;\n    } else {\n      compareFn = (_b = args[1]) != null ? _b : defaultCompare;\n    }\n  } else if (args.length > 2) {\n    compareFn = (_c = args[1]) != null ? _c : defaultCompare;\n    options = (_d = args[2]) != null ? _d : {};\n  }\n  const {\n    dirty = false,\n    sortFn = defaultSortFn\n  } = options;\n  if (!dirty)\n    return computed(() => sortFn([...toValue(source)], compareFn));\n  watchEffect(() => {\n    const result = sortFn(toValue(source), compareFn);\n    if (isRef(source))\n      source.value = result;\n    else\n      source.splice(0, source.length, ...result);\n  });\n  return source;\n}\n\nfunction useSpeechRecognition(options = {}) {\n  const {\n    interimResults = true,\n    continuous = true,\n    window = defaultWindow\n  } = options;\n  const lang = toRef(options.lang || \"en-US\");\n  const isListening = ref(false);\n  const isFinal = ref(false);\n  const result = ref(\"\");\n  const error = shallowRef(void 0);\n  const toggle = (value = !isListening.value) => {\n    isListening.value = value;\n  };\n  const start = () => {\n    isListening.value = true;\n  };\n  const stop = () => {\n    isListening.value = false;\n  };\n  const SpeechRecognition = window && (window.SpeechRecognition || window.webkitSpeechRecognition);\n  const isSupported = useSupported(() => SpeechRecognition);\n  let recognition;\n  if (isSupported.value) {\n    recognition = new SpeechRecognition();\n    recognition.continuous = continuous;\n    recognition.interimResults = interimResults;\n    recognition.lang = toValue(lang);\n    recognition.onstart = () => {\n      isFinal.value = false;\n    };\n    watch(lang, (lang2) => {\n      if (recognition && !isListening.value)\n        recognition.lang = lang2;\n    });\n    recognition.onresult = (event) => {\n      const transcript = Array.from(event.results).map((result2) => {\n        isFinal.value = result2.isFinal;\n        return result2[0];\n      }).map((result2) => result2.transcript).join(\"\");\n      result.value = transcript;\n      error.value = void 0;\n    };\n    recognition.onerror = (event) => {\n      error.value = event;\n    };\n    recognition.onend = () => {\n      isListening.value = false;\n      recognition.lang = toValue(lang);\n    };\n    watch(isListening, () => {\n      if (isListening.value)\n        recognition.start();\n      else\n        recognition.stop();\n    });\n  }\n  tryOnScopeDispose(() => {\n    isListening.value = false;\n  });\n  return {\n    isSupported,\n    isListening,\n    isFinal,\n    recognition,\n    result,\n    error,\n    toggle,\n    start,\n    stop\n  };\n}\n\nfunction useSpeechSynthesis(text, options = {}) {\n  const {\n    pitch = 1,\n    rate = 1,\n    volume = 1,\n    window = defaultWindow\n  } = options;\n  const synth = window && window.speechSynthesis;\n  const isSupported = useSupported(() => synth);\n  const isPlaying = ref(false);\n  const status = ref(\"init\");\n  const spokenText = toRef(text || \"\");\n  const lang = toRef(options.lang || \"en-US\");\n  const error = shallowRef(void 0);\n  const toggle = (value = !isPlaying.value) => {\n    isPlaying.value = value;\n  };\n  const bindEventsForUtterance = (utterance2) => {\n    utterance2.lang = toValue(lang);\n    utterance2.voice = toValue(options.voice) || null;\n    utterance2.pitch = pitch;\n    utterance2.rate = rate;\n    utterance2.volume = volume;\n    utterance2.onstart = () => {\n      isPlaying.value = true;\n      status.value = \"play\";\n    };\n    utterance2.onpause = () => {\n      isPlaying.value = false;\n      status.value = \"pause\";\n    };\n    utterance2.onresume = () => {\n      isPlaying.value = true;\n      status.value = \"play\";\n    };\n    utterance2.onend = () => {\n      isPlaying.value = false;\n      status.value = \"end\";\n    };\n    utterance2.onerror = (event) => {\n      error.value = event;\n    };\n  };\n  const utterance = computed(() => {\n    isPlaying.value = false;\n    status.value = \"init\";\n    const newUtterance = new SpeechSynthesisUtterance(spokenText.value);\n    bindEventsForUtterance(newUtterance);\n    return newUtterance;\n  });\n  const speak = () => {\n    synth.cancel();\n    utterance && synth.speak(utterance.value);\n  };\n  const stop = () => {\n    synth.cancel();\n    isPlaying.value = false;\n  };\n  if (isSupported.value) {\n    bindEventsForUtterance(utterance.value);\n    watch(lang, (lang2) => {\n      if (utterance.value && !isPlaying.value)\n        utterance.value.lang = lang2;\n    });\n    if (options.voice) {\n      watch(options.voice, () => {\n        synth.cancel();\n      });\n    }\n    watch(isPlaying, () => {\n      if (isPlaying.value)\n        synth.resume();\n      else\n        synth.pause();\n    });\n  }\n  tryOnScopeDispose(() => {\n    isPlaying.value = false;\n  });\n  return {\n    isSupported,\n    isPlaying,\n    status,\n    utterance,\n    error,\n    stop,\n    toggle,\n    speak\n  };\n}\n\nfunction useStepper(steps, initialStep) {\n  const stepsRef = ref(steps);\n  const stepNames = computed(() => Array.isArray(stepsRef.value) ? stepsRef.value : Object.keys(stepsRef.value));\n  const index = ref(stepNames.value.indexOf(initialStep != null ? initialStep : stepNames.value[0]));\n  const current = computed(() => at(index.value));\n  const isFirst = computed(() => index.value === 0);\n  const isLast = computed(() => index.value === stepNames.value.length - 1);\n  const next = computed(() => stepNames.value[index.value + 1]);\n  const previous = computed(() => stepNames.value[index.value - 1]);\n  function at(index2) {\n    if (Array.isArray(stepsRef.value))\n      return stepsRef.value[index2];\n    return stepsRef.value[stepNames.value[index2]];\n  }\n  function get(step) {\n    if (!stepNames.value.includes(step))\n      return;\n    return at(stepNames.value.indexOf(step));\n  }\n  function goTo(step) {\n    if (stepNames.value.includes(step))\n      index.value = stepNames.value.indexOf(step);\n  }\n  function goToNext() {\n    if (isLast.value)\n      return;\n    index.value++;\n  }\n  function goToPrevious() {\n    if (isFirst.value)\n      return;\n    index.value--;\n  }\n  function goBackTo(step) {\n    if (isAfter(step))\n      goTo(step);\n  }\n  function isNext(step) {\n    return stepNames.value.indexOf(step) === index.value + 1;\n  }\n  function isPrevious(step) {\n    return stepNames.value.indexOf(step) === index.value - 1;\n  }\n  function isCurrent(step) {\n    return stepNames.value.indexOf(step) === index.value;\n  }\n  function isBefore(step) {\n    return index.value < stepNames.value.indexOf(step);\n  }\n  function isAfter(step) {\n    return index.value > stepNames.value.indexOf(step);\n  }\n  return {\n    steps: stepsRef,\n    stepNames,\n    index,\n    current,\n    next,\n    previous,\n    isFirst,\n    isLast,\n    at,\n    get,\n    goTo,\n    goToNext,\n    goToPrevious,\n    goBackTo,\n    isNext,\n    isPrevious,\n    isCurrent,\n    isBefore,\n    isAfter\n  };\n}\n\nvar __defProp$4 = Object.defineProperty;\nvar __getOwnPropSymbols$4 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$4 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$4 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$4 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$4.call(b, prop))\n      __defNormalProp$4(a, prop, b[prop]);\n  if (__getOwnPropSymbols$4)\n    for (var prop of __getOwnPropSymbols$4(b)) {\n      if (__propIsEnum$4.call(b, prop))\n        __defNormalProp$4(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useStorageAsync(key, initialValue, storage, options = {}) {\n  var _a;\n  const {\n    flush = \"pre\",\n    deep = true,\n    listenToStorageChanges = true,\n    writeDefaults = true,\n    mergeDefaults = false,\n    shallow,\n    window = defaultWindow,\n    eventFilter,\n    onError = (e) => {\n      console.error(e);\n    }\n  } = options;\n  const rawInit = toValue(initialValue);\n  const type = guessSerializerType(rawInit);\n  const data = (shallow ? shallowRef : ref)(initialValue);\n  const serializer = (_a = options.serializer) != null ? _a : StorageSerializers[type];\n  if (!storage) {\n    try {\n      storage = getSSRHandler(\"getDefaultStorage\", () => {\n        var _a2;\n        return (_a2 = defaultWindow) == null ? void 0 : _a2.localStorage;\n      })();\n    } catch (e) {\n      onError(e);\n    }\n  }\n  async function read(event) {\n    if (!storage || event && event.key !== key)\n      return;\n    try {\n      const rawValue = event ? event.newValue : await storage.getItem(key);\n      if (rawValue == null) {\n        data.value = rawInit;\n        if (writeDefaults && rawInit !== null)\n          await storage.setItem(key, await serializer.write(rawInit));\n      } else if (mergeDefaults) {\n        const value = await serializer.read(rawValue);\n        if (typeof mergeDefaults === \"function\")\n          data.value = mergeDefaults(value, rawInit);\n        else if (type === \"object\" && !Array.isArray(value))\n          data.value = __spreadValues$4(__spreadValues$4({}, rawInit), value);\n        else\n          data.value = value;\n      } else {\n        data.value = await serializer.read(rawValue);\n      }\n    } catch (e) {\n      onError(e);\n    }\n  }\n  read();\n  if (window && listenToStorageChanges)\n    useEventListener(window, \"storage\", (e) => Promise.resolve().then(() => read(e)));\n  if (storage) {\n    watchWithFilter(\n      data,\n      async () => {\n        try {\n          if (data.value == null)\n            await storage.removeItem(key);\n          else\n            await storage.setItem(key, await serializer.write(data.value));\n        } catch (e) {\n          onError(e);\n        }\n      },\n      {\n        flush,\n        deep,\n        eventFilter\n      }\n    );\n  }\n  return data;\n}\n\nlet _id = 0;\nfunction useStyleTag(css, options = {}) {\n  const isLoaded = ref(false);\n  const {\n    document = defaultDocument,\n    immediate = true,\n    manual = false,\n    id = `vueuse_styletag_${++_id}`\n  } = options;\n  const cssRef = ref(css);\n  let stop = () => {\n  };\n  const load = () => {\n    if (!document)\n      return;\n    const el = document.getElementById(id) || document.createElement(\"style\");\n    if (!el.isConnected) {\n      el.type = \"text/css\";\n      el.id = id;\n      if (options.media)\n        el.media = options.media;\n      document.head.appendChild(el);\n    }\n    if (isLoaded.value)\n      return;\n    stop = watch(\n      cssRef,\n      (value) => {\n        el.textContent = value;\n      },\n      { immediate: true }\n    );\n    isLoaded.value = true;\n  };\n  const unload = () => {\n    if (!document || !isLoaded.value)\n      return;\n    stop();\n    document.head.removeChild(document.getElementById(id));\n    isLoaded.value = false;\n  };\n  if (immediate && !manual)\n    tryOnMounted(load);\n  if (!manual)\n    tryOnScopeDispose(unload);\n  return {\n    id,\n    css: cssRef,\n    unload,\n    load,\n    isLoaded: readonly(isLoaded)\n  };\n}\n\nfunction useSwipe(target, options = {}) {\n  const {\n    threshold = 50,\n    onSwipe,\n    onSwipeEnd,\n    onSwipeStart,\n    passive = true,\n    window = defaultWindow\n  } = options;\n  const coordsStart = reactive({ x: 0, y: 0 });\n  const coordsEnd = reactive({ x: 0, y: 0 });\n  const diffX = computed(() => coordsStart.x - coordsEnd.x);\n  const diffY = computed(() => coordsStart.y - coordsEnd.y);\n  const { max, abs } = Math;\n  const isThresholdExceeded = computed(() => max(abs(diffX.value), abs(diffY.value)) >= threshold);\n  const isSwiping = ref(false);\n  const direction = computed(() => {\n    if (!isThresholdExceeded.value)\n      return \"none\";\n    if (abs(diffX.value) > abs(diffY.value)) {\n      return diffX.value > 0 ? \"left\" : \"right\";\n    } else {\n      return diffY.value > 0 ? \"up\" : \"down\";\n    }\n  });\n  const getTouchEventCoords = (e) => [e.touches[0].clientX, e.touches[0].clientY];\n  const updateCoordsStart = (x, y) => {\n    coordsStart.x = x;\n    coordsStart.y = y;\n  };\n  const updateCoordsEnd = (x, y) => {\n    coordsEnd.x = x;\n    coordsEnd.y = y;\n  };\n  let listenerOptions;\n  const isPassiveEventSupported = checkPassiveEventSupport(window == null ? void 0 : window.document);\n  if (!passive)\n    listenerOptions = isPassiveEventSupported ? { passive: false, capture: true } : { capture: true };\n  else\n    listenerOptions = isPassiveEventSupported ? { passive: true } : { capture: false };\n  const onTouchEnd = (e) => {\n    if (isSwiping.value)\n      onSwipeEnd == null ? void 0 : onSwipeEnd(e, direction.value);\n    isSwiping.value = false;\n  };\n  const stops = [\n    useEventListener(target, \"touchstart\", (e) => {\n      if (listenerOptions.capture && !listenerOptions.passive)\n        e.preventDefault();\n      const [x, y] = getTouchEventCoords(e);\n      updateCoordsStart(x, y);\n      updateCoordsEnd(x, y);\n      onSwipeStart == null ? void 0 : onSwipeStart(e);\n    }, listenerOptions),\n    useEventListener(target, \"touchmove\", (e) => {\n      const [x, y] = getTouchEventCoords(e);\n      updateCoordsEnd(x, y);\n      if (!isSwiping.value && isThresholdExceeded.value)\n        isSwiping.value = true;\n      if (isSwiping.value)\n        onSwipe == null ? void 0 : onSwipe(e);\n    }, listenerOptions),\n    useEventListener(target, \"touchend\", onTouchEnd, listenerOptions),\n    useEventListener(target, \"touchcancel\", onTouchEnd, listenerOptions)\n  ];\n  const stop = () => stops.forEach((s) => s());\n  return {\n    isPassiveEventSupported,\n    isSwiping,\n    direction,\n    coordsStart,\n    coordsEnd,\n    lengthX: diffX,\n    lengthY: diffY,\n    stop\n  };\n}\nfunction checkPassiveEventSupport(document) {\n  if (!document)\n    return false;\n  let supportsPassive = false;\n  const optionsBlock = {\n    get passive() {\n      supportsPassive = true;\n      return false;\n    }\n  };\n  document.addEventListener(\"x\", noop, optionsBlock);\n  document.removeEventListener(\"x\", noop);\n  return supportsPassive;\n}\n\nfunction useTemplateRefsList() {\n  const refs = ref([]);\n  refs.value.set = (el) => {\n    if (el)\n      refs.value.push(el);\n  };\n  onBeforeUpdate(() => {\n    refs.value.length = 0;\n  });\n  return refs;\n}\n\nfunction useTextDirection(options = {}) {\n  const {\n    document = defaultDocument,\n    selector = \"html\",\n    observe = false,\n    initialValue = \"ltr\"\n  } = options;\n  function getValue() {\n    var _a, _b;\n    return (_b = (_a = document == null ? void 0 : document.querySelector(selector)) == null ? void 0 : _a.getAttribute(\"dir\")) != null ? _b : initialValue;\n  }\n  const dir = ref(getValue());\n  tryOnMounted(() => dir.value = getValue());\n  if (observe && document) {\n    useMutationObserver(\n      document.querySelector(selector),\n      () => dir.value = getValue(),\n      { attributes: true }\n    );\n  }\n  return computed({\n    get() {\n      return dir.value;\n    },\n    set(v) {\n      var _a, _b;\n      dir.value = v;\n      if (!document)\n        return;\n      if (dir.value)\n        (_a = document.querySelector(selector)) == null ? void 0 : _a.setAttribute(\"dir\", dir.value);\n      else\n        (_b = document.querySelector(selector)) == null ? void 0 : _b.removeAttribute(\"dir\");\n    }\n  });\n}\n\nfunction getRangesFromSelection(selection) {\n  var _a;\n  const rangeCount = (_a = selection.rangeCount) != null ? _a : 0;\n  const ranges = new Array(rangeCount);\n  for (let i = 0; i < rangeCount; i++) {\n    const range = selection.getRangeAt(i);\n    ranges[i] = range;\n  }\n  return ranges;\n}\nfunction useTextSelection(options = {}) {\n  const {\n    window = defaultWindow\n  } = options;\n  const selection = ref(null);\n  const text = computed(() => {\n    var _a, _b;\n    return (_b = (_a = selection.value) == null ? void 0 : _a.toString()) != null ? _b : \"\";\n  });\n  const ranges = computed(() => selection.value ? getRangesFromSelection(selection.value) : []);\n  const rects = computed(() => ranges.value.map((range) => range.getBoundingClientRect()));\n  function onSelectionChange() {\n    selection.value = null;\n    if (window)\n      selection.value = window.getSelection();\n  }\n  if (window)\n    useEventListener(window.document, \"selectionchange\", onSelectionChange);\n  return {\n    text,\n    rects,\n    ranges,\n    selection\n  };\n}\n\nfunction useTextareaAutosize(options) {\n  const textarea = ref(options == null ? void 0 : options.element);\n  const input = ref(options == null ? void 0 : options.input);\n  const textareaScrollHeight = ref(1);\n  function triggerResize() {\n    var _a, _b;\n    if (!textarea.value)\n      return;\n    let height = \"\";\n    textarea.value.style.height = \"1px\";\n    textareaScrollHeight.value = (_a = textarea.value) == null ? void 0 : _a.scrollHeight;\n    if (options == null ? void 0 : options.styleTarget)\n      toValue(options.styleTarget).style.height = `${textareaScrollHeight.value}px`;\n    else\n      height = `${textareaScrollHeight.value}px`;\n    textarea.value.style.height = height;\n    (_b = options == null ? void 0 : options.onResize) == null ? void 0 : _b.call(options);\n  }\n  watch([input, textarea], triggerResize, { immediate: true });\n  useResizeObserver(textarea, () => triggerResize());\n  if (options == null ? void 0 : options.watch)\n    watch(options.watch, triggerResize, { immediate: true, deep: true });\n  return {\n    textarea,\n    input,\n    triggerResize\n  };\n}\n\nvar __defProp$3 = Object.defineProperty;\nvar __defProps$1 = Object.defineProperties;\nvar __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols$3 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$3 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$3 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$3 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$3.call(b, prop))\n      __defNormalProp$3(a, prop, b[prop]);\n  if (__getOwnPropSymbols$3)\n    for (var prop of __getOwnPropSymbols$3(b)) {\n      if (__propIsEnum$3.call(b, prop))\n        __defNormalProp$3(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps$1 = (a, b) => __defProps$1(a, __getOwnPropDescs$1(b));\nfunction useThrottledRefHistory(source, options = {}) {\n  const { throttle = 200, trailing = true } = options;\n  const filter = throttleFilter(throttle, trailing);\n  const history = useRefHistory(source, __spreadProps$1(__spreadValues$3({}, options), { eventFilter: filter }));\n  return __spreadValues$3({}, history);\n}\n\nvar __defProp$2 = Object.defineProperty;\nvar __getOwnPropSymbols$2 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$2 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$2 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$2 = (obj, key, value) => key in obj ? __defProp$2(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$2 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$2.call(b, prop))\n      __defNormalProp$2(a, prop, b[prop]);\n  if (__getOwnPropSymbols$2)\n    for (var prop of __getOwnPropSymbols$2(b)) {\n      if (__propIsEnum$2.call(b, prop))\n        __defNormalProp$2(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __objRest = (source, exclude) => {\n  var target = {};\n  for (var prop in source)\n    if (__hasOwnProp$2.call(source, prop) && exclude.indexOf(prop) < 0)\n      target[prop] = source[prop];\n  if (source != null && __getOwnPropSymbols$2)\n    for (var prop of __getOwnPropSymbols$2(source)) {\n      if (exclude.indexOf(prop) < 0 && __propIsEnum$2.call(source, prop))\n        target[prop] = source[prop];\n    }\n  return target;\n};\nconst DEFAULT_UNITS = [\n  { max: 6e4, value: 1e3, name: \"second\" },\n  { max: 276e4, value: 6e4, name: \"minute\" },\n  { max: 72e6, value: 36e5, name: \"hour\" },\n  { max: 5184e5, value: 864e5, name: \"day\" },\n  { max: 24192e5, value: 6048e5, name: \"week\" },\n  { max: 28512e6, value: 2592e6, name: \"month\" },\n  { max: Infinity, value: 31536e6, name: \"year\" }\n];\nconst DEFAULT_MESSAGES = {\n  justNow: \"just now\",\n  past: (n) => n.match(/\\d/) ? `${n} ago` : n,\n  future: (n) => n.match(/\\d/) ? `in ${n}` : n,\n  month: (n, past) => n === 1 ? past ? \"last month\" : \"next month\" : `${n} month${n > 1 ? \"s\" : \"\"}`,\n  year: (n, past) => n === 1 ? past ? \"last year\" : \"next year\" : `${n} year${n > 1 ? \"s\" : \"\"}`,\n  day: (n, past) => n === 1 ? past ? \"yesterday\" : \"tomorrow\" : `${n} day${n > 1 ? \"s\" : \"\"}`,\n  week: (n, past) => n === 1 ? past ? \"last week\" : \"next week\" : `${n} week${n > 1 ? \"s\" : \"\"}`,\n  hour: (n) => `${n} hour${n > 1 ? \"s\" : \"\"}`,\n  minute: (n) => `${n} minute${n > 1 ? \"s\" : \"\"}`,\n  second: (n) => `${n} second${n > 1 ? \"s\" : \"\"}`,\n  invalid: \"\"\n};\nfunction DEFAULT_FORMATTER(date) {\n  return date.toISOString().slice(0, 10);\n}\nfunction useTimeAgo(time, options = {}) {\n  const {\n    controls: exposeControls = false,\n    updateInterval = 3e4\n  } = options;\n  const _a = useNow({ interval: updateInterval, controls: true }), { now } = _a, controls = __objRest(_a, [\"now\"]);\n  const timeAgo = computed(() => formatTimeAgo(new Date(toValue(time)), options, toValue(now.value)));\n  if (exposeControls) {\n    return __spreadValues$2({\n      timeAgo\n    }, controls);\n  } else {\n    return timeAgo;\n  }\n}\nfunction formatTimeAgo(from, options = {}, now = Date.now()) {\n  var _a;\n  const {\n    max,\n    messages = DEFAULT_MESSAGES,\n    fullDateFormatter = DEFAULT_FORMATTER,\n    units = DEFAULT_UNITS,\n    showSecond = false,\n    rounding = \"round\"\n  } = options;\n  const roundFn = typeof rounding === \"number\" ? (n) => +n.toFixed(rounding) : Math[rounding];\n  const diff = +now - +from;\n  const absDiff = Math.abs(diff);\n  function getValue(diff2, unit) {\n    return roundFn(Math.abs(diff2) / unit.value);\n  }\n  function format(diff2, unit) {\n    const val = getValue(diff2, unit);\n    const past = diff2 > 0;\n    const str = applyFormat(unit.name, val, past);\n    return applyFormat(past ? \"past\" : \"future\", str, past);\n  }\n  function applyFormat(name, val, isPast) {\n    const formatter = messages[name];\n    if (typeof formatter === \"function\")\n      return formatter(val, isPast);\n    return formatter.replace(\"{0}\", val.toString());\n  }\n  if (absDiff < 6e4 && !showSecond)\n    return messages.justNow;\n  if (typeof max === \"number\" && absDiff > max)\n    return fullDateFormatter(new Date(from));\n  if (typeof max === \"string\") {\n    const unitMax = (_a = units.find((i) => i.name === max)) == null ? void 0 : _a.max;\n    if (unitMax && absDiff > unitMax)\n      return fullDateFormatter(new Date(from));\n  }\n  for (const [idx, unit] of units.entries()) {\n    const val = getValue(diff, unit);\n    if (val <= 0 && units[idx - 1])\n      return format(diff, units[idx - 1]);\n    if (absDiff < unit.max)\n      return format(diff, unit);\n  }\n  return messages.invalid;\n}\n\nfunction useTimeoutPoll(fn, interval, timeoutPollOptions) {\n  const { start } = useTimeoutFn(loop, interval);\n  const isActive = ref(false);\n  async function loop() {\n    if (!isActive.value)\n      return;\n    await fn();\n    start();\n  }\n  function resume() {\n    if (!isActive.value) {\n      isActive.value = true;\n      loop();\n    }\n  }\n  function pause() {\n    isActive.value = false;\n  }\n  if (timeoutPollOptions == null ? void 0 : timeoutPollOptions.immediate)\n    resume();\n  tryOnScopeDispose(pause);\n  return {\n    isActive,\n    pause,\n    resume\n  };\n}\n\nvar __defProp$1 = Object.defineProperty;\nvar __getOwnPropSymbols$1 = Object.getOwnPropertySymbols;\nvar __hasOwnProp$1 = Object.prototype.hasOwnProperty;\nvar __propIsEnum$1 = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues$1 = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp$1.call(b, prop))\n      __defNormalProp$1(a, prop, b[prop]);\n  if (__getOwnPropSymbols$1)\n    for (var prop of __getOwnPropSymbols$1(b)) {\n      if (__propIsEnum$1.call(b, prop))\n        __defNormalProp$1(a, prop, b[prop]);\n    }\n  return a;\n};\nfunction useTimestamp(options = {}) {\n  const {\n    controls: exposeControls = false,\n    offset = 0,\n    immediate = true,\n    interval = \"requestAnimationFrame\",\n    callback\n  } = options;\n  const ts = ref(timestamp() + offset);\n  const update = () => ts.value = timestamp() + offset;\n  const cb = callback ? () => {\n    update();\n    callback(ts.value);\n  } : update;\n  const controls = interval === \"requestAnimationFrame\" ? useRafFn(cb, { immediate }) : useIntervalFn(cb, interval, { immediate });\n  if (exposeControls) {\n    return __spreadValues$1({\n      timestamp: ts\n    }, controls);\n  } else {\n    return ts;\n  }\n}\n\nfunction useTitle(newTitle = null, options = {}) {\n  var _a, _b;\n  const {\n    document = defaultDocument\n  } = options;\n  const title = toRef((_a = newTitle != null ? newTitle : document == null ? void 0 : document.title) != null ? _a : null);\n  const isReadonly = newTitle && typeof newTitle === \"function\";\n  function format(t) {\n    if (!(\"titleTemplate\" in options))\n      return t;\n    const template = options.titleTemplate || \"%s\";\n    return typeof template === \"function\" ? template(t) : toValue(template).replace(/%s/g, t);\n  }\n  watch(\n    title,\n    (t, o) => {\n      if (t !== o && document)\n        document.title = format(typeof t === \"string\" ? t : \"\");\n    },\n    { immediate: true }\n  );\n  if (options.observe && !options.titleTemplate && document && !isReadonly) {\n    useMutationObserver(\n      (_b = document.head) == null ? void 0 : _b.querySelector(\"title\"),\n      () => {\n        if (document && document.title !== title.value)\n          title.value = format(document.title);\n      },\n      { childList: true }\n    );\n  }\n  return title;\n}\n\nvar __defProp = Object.defineProperty;\nvar __defProps = Object.defineProperties;\nvar __getOwnPropDescs = Object.getOwnPropertyDescriptors;\nvar __getOwnPropSymbols = Object.getOwnPropertySymbols;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __propIsEnum = Object.prototype.propertyIsEnumerable;\nvar __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;\nvar __spreadValues = (a, b) => {\n  for (var prop in b || (b = {}))\n    if (__hasOwnProp.call(b, prop))\n      __defNormalProp(a, prop, b[prop]);\n  if (__getOwnPropSymbols)\n    for (var prop of __getOwnPropSymbols(b)) {\n      if (__propIsEnum.call(b, prop))\n        __defNormalProp(a, prop, b[prop]);\n    }\n  return a;\n};\nvar __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));\nconst _TransitionPresets = {\n  easeInSine: [0.12, 0, 0.39, 0],\n  easeOutSine: [0.61, 1, 0.88, 1],\n  easeInOutSine: [0.37, 0, 0.63, 1],\n  easeInQuad: [0.11, 0, 0.5, 0],\n  easeOutQuad: [0.5, 1, 0.89, 1],\n  easeInOutQuad: [0.45, 0, 0.55, 1],\n  easeInCubic: [0.32, 0, 0.67, 0],\n  easeOutCubic: [0.33, 1, 0.68, 1],\n  easeInOutCubic: [0.65, 0, 0.35, 1],\n  easeInQuart: [0.5, 0, 0.75, 0],\n  easeOutQuart: [0.25, 1, 0.5, 1],\n  easeInOutQuart: [0.76, 0, 0.24, 1],\n  easeInQuint: [0.64, 0, 0.78, 0],\n  easeOutQuint: [0.22, 1, 0.36, 1],\n  easeInOutQuint: [0.83, 0, 0.17, 1],\n  easeInExpo: [0.7, 0, 0.84, 0],\n  easeOutExpo: [0.16, 1, 0.3, 1],\n  easeInOutExpo: [0.87, 0, 0.13, 1],\n  easeInCirc: [0.55, 0, 1, 0.45],\n  easeOutCirc: [0, 0.55, 0.45, 1],\n  easeInOutCirc: [0.85, 0, 0.15, 1],\n  easeInBack: [0.36, 0, 0.66, -0.56],\n  easeOutBack: [0.34, 1.56, 0.64, 1],\n  easeInOutBack: [0.68, -0.6, 0.32, 1.6]\n};\nconst TransitionPresets = /* @__PURE__ */ Object.assign({}, { linear: identity }, _TransitionPresets);\nfunction createEasingFunction([p0, p1, p2, p3]) {\n  const a = (a1, a2) => 1 - 3 * a2 + 3 * a1;\n  const b = (a1, a2) => 3 * a2 - 6 * a1;\n  const c = (a1) => 3 * a1;\n  const calcBezier = (t, a1, a2) => ((a(a1, a2) * t + b(a1, a2)) * t + c(a1)) * t;\n  const getSlope = (t, a1, a2) => 3 * a(a1, a2) * t * t + 2 * b(a1, a2) * t + c(a1);\n  const getTforX = (x) => {\n    let aGuessT = x;\n    for (let i = 0; i < 4; ++i) {\n      const currentSlope = getSlope(aGuessT, p0, p2);\n      if (currentSlope === 0)\n        return aGuessT;\n      const currentX = calcBezier(aGuessT, p0, p2) - x;\n      aGuessT -= currentX / currentSlope;\n    }\n    return aGuessT;\n  };\n  return (x) => p0 === p1 && p2 === p3 ? x : calcBezier(getTforX(x), p1, p3);\n}\nfunction lerp(a, b, alpha) {\n  return a + alpha * (b - a);\n}\nfunction toVec(t) {\n  return (typeof t === \"number\" ? [t] : t) || [];\n}\nfunction executeTransition(source, from, to, options = {}) {\n  var _a, _b;\n  const fromVal = toValue(from);\n  const toVal = toValue(to);\n  const v1 = toVec(fromVal);\n  const v2 = toVec(toVal);\n  const duration = (_a = toValue(options.duration)) != null ? _a : 1e3;\n  const startedAt = Date.now();\n  const endAt = Date.now() + duration;\n  const trans = (_b = toValue(options.transition)) != null ? _b : identity;\n  const ease = typeof trans === \"function\" ? trans : createEasingFunction(trans);\n  return new Promise((resolve) => {\n    source.value = fromVal;\n    const tick = () => {\n      var _a2;\n      if ((_a2 = options.abort) == null ? void 0 : _a2.call(options)) {\n        resolve();\n        return;\n      }\n      const now = Date.now();\n      const alpha = ease((now - startedAt) / duration);\n      const arr = toVec(source.value).map((n, i) => lerp(v1[i], v2[i], alpha));\n      if (Array.isArray(source.value))\n        source.value = arr.map((n, i) => {\n          var _a3, _b2;\n          return lerp((_a3 = v1[i]) != null ? _a3 : 0, (_b2 = v2[i]) != null ? _b2 : 0, alpha);\n        });\n      else if (typeof source.value === \"number\")\n        source.value = arr[0];\n      if (now < endAt) {\n        requestAnimationFrame(tick);\n      } else {\n        source.value = toVal;\n        resolve();\n      }\n    };\n    tick();\n  });\n}\nfunction useTransition(source, options = {}) {\n  let currentId = 0;\n  const sourceVal = () => {\n    const v = toValue(source);\n    return typeof v === \"number\" ? v : v.map(toValue);\n  };\n  const outputRef = ref(sourceVal());\n  watch(sourceVal, async (to) => {\n    var _a, _b;\n    if (toValue(options.disabled))\n      return;\n    const id = ++currentId;\n    if (options.delay)\n      await promiseTimeout(toValue(options.delay));\n    if (id !== currentId)\n      return;\n    const toVal = Array.isArray(to) ? to.map(toValue) : toValue(to);\n    (_a = options.onStarted) == null ? void 0 : _a.call(options);\n    await executeTransition(outputRef, outputRef.value, toVal, __spreadProps(__spreadValues({}, options), {\n      abort: () => {\n        var _a2;\n        return id !== currentId || ((_a2 = options.abort) == null ? void 0 : _a2.call(options));\n      }\n    }));\n    (_b = options.onFinished) == null ? void 0 : _b.call(options);\n  }, { deep: true });\n  watch(() => toValue(options.disabled), (disabled) => {\n    if (disabled) {\n      currentId++;\n      outputRef.value = sourceVal();\n    }\n  });\n  tryOnScopeDispose(() => {\n    currentId++;\n  });\n  return computed(() => toValue(options.disabled) ? sourceVal() : outputRef.value);\n}\n\nfunction useUrlSearchParams(mode = \"history\", options = {}) {\n  const {\n    initialValue = {},\n    removeNullishValues = true,\n    removeFalsyValues = false,\n    write: enableWrite = true,\n    window = defaultWindow\n  } = options;\n  if (!window)\n    return reactive(initialValue);\n  const state = reactive({});\n  function getRawParams() {\n    if (mode === \"history\") {\n      return window.location.search || \"\";\n    } else if (mode === \"hash\") {\n      const hash = window.location.hash || \"\";\n      const index = hash.indexOf(\"?\");\n      return index > 0 ? hash.slice(index) : \"\";\n    } else {\n      return (window.location.hash || \"\").replace(/^#/, \"\");\n    }\n  }\n  function constructQuery(params) {\n    const stringified = params.toString();\n    if (mode === \"history\")\n      return `${stringified ? `?${stringified}` : \"\"}${window.location.hash || \"\"}`;\n    if (mode === \"hash-params\")\n      return `${window.location.search || \"\"}${stringified ? `#${stringified}` : \"\"}`;\n    const hash = window.location.hash || \"#\";\n    const index = hash.indexOf(\"?\");\n    if (index > 0)\n      return `${hash.slice(0, index)}${stringified ? `?${stringified}` : \"\"}`;\n    return `${hash}${stringified ? `?${stringified}` : \"\"}`;\n  }\n  function read() {\n    return new URLSearchParams(getRawParams());\n  }\n  function updateState(params) {\n    const unusedKeys = new Set(Object.keys(state));\n    for (const key of params.keys()) {\n      const paramsForKey = params.getAll(key);\n      state[key] = paramsForKey.length > 1 ? paramsForKey : params.get(key) || \"\";\n      unusedKeys.delete(key);\n    }\n    Array.from(unusedKeys).forEach((key) => delete state[key]);\n  }\n  const { pause, resume } = pausableWatch(\n    state,\n    () => {\n      const params = new URLSearchParams(\"\");\n      Object.keys(state).forEach((key) => {\n        const mapEntry = state[key];\n        if (Array.isArray(mapEntry))\n          mapEntry.forEach((value) => params.append(key, value));\n        else if (removeNullishValues && mapEntry == null)\n          params.delete(key);\n        else if (removeFalsyValues && !mapEntry)\n          params.delete(key);\n        else\n          params.set(key, mapEntry);\n      });\n      write(params);\n    },\n    { deep: true }\n  );\n  function write(params, shouldUpdate) {\n    pause();\n    if (shouldUpdate)\n      updateState(params);\n    window.history.replaceState(\n      window.history.state,\n      window.document.title,\n      window.location.pathname + constructQuery(params)\n    );\n    resume();\n  }\n  function onChanged() {\n    if (!enableWrite)\n      return;\n    write(read(), true);\n  }\n  useEventListener(window, \"popstate\", onChanged, false);\n  if (mode !== \"history\")\n    useEventListener(window, \"hashchange\", onChanged, false);\n  const initial = read();\n  if (initial.keys().next().value)\n    updateState(initial);\n  else\n    Object.assign(state, initialValue);\n  return state;\n}\n\nfunction useUserMedia(options = {}) {\n  var _a, _b;\n  const enabled = ref((_a = options.enabled) != null ? _a : false);\n  const autoSwitch = ref((_b = options.autoSwitch) != null ? _b : true);\n  const constraints = ref(options.constraints);\n  const { navigator = defaultNavigator } = options;\n  const isSupported = useSupported(() => {\n    var _a2;\n    return (_a2 = navigator == null ? void 0 : navigator.mediaDevices) == null ? void 0 : _a2.getUserMedia;\n  });\n  const stream = shallowRef();\n  function getDeviceOptions(type) {\n    switch (type) {\n      case \"video\": {\n        if (constraints.value)\n          return constraints.value.video || false;\n        break;\n      }\n      case \"audio\": {\n        if (constraints.value)\n          return constraints.value.audio || false;\n        break;\n      }\n    }\n  }\n  async function _start() {\n    if (!isSupported.value || stream.value)\n      return;\n    stream.value = await navigator.mediaDevices.getUserMedia({\n      video: getDeviceOptions(\"video\"),\n      audio: getDeviceOptions(\"audio\")\n    });\n    return stream.value;\n  }\n  function _stop() {\n    var _a2;\n    (_a2 = stream.value) == null ? void 0 : _a2.getTracks().forEach((t) => t.stop());\n    stream.value = void 0;\n  }\n  function stop() {\n    _stop();\n    enabled.value = false;\n  }\n  async function start() {\n    await _start();\n    if (stream.value)\n      enabled.value = true;\n    return stream.value;\n  }\n  async function restart() {\n    _stop();\n    return await start();\n  }\n  watch(\n    enabled,\n    (v) => {\n      if (v)\n        _start();\n      else\n        _stop();\n    },\n    { immediate: true }\n  );\n  watch(\n    constraints,\n    () => {\n      if (autoSwitch.value && stream.value)\n        restart();\n    },\n    { immediate: true }\n  );\n  return {\n    isSupported,\n    stream,\n    start,\n    stop,\n    restart,\n    constraints,\n    enabled,\n    autoSwitch\n  };\n}\n\nfunction useVModel(props, key, emit, options = {}) {\n  var _a, _b, _c, _d, _e;\n  const {\n    clone = false,\n    passive = false,\n    eventName,\n    deep = false,\n    defaultValue,\n    shouldEmit\n  } = options;\n  const vm = getCurrentInstance();\n  const _emit = emit || (vm == null ? void 0 : vm.emit) || ((_a = vm == null ? void 0 : vm.$emit) == null ? void 0 : _a.bind(vm)) || ((_c = (_b = vm == null ? void 0 : vm.proxy) == null ? void 0 : _b.$emit) == null ? void 0 : _c.bind(vm == null ? void 0 : vm.proxy));\n  let event = eventName;\n  if (!key) {\n    if (isVue2) {\n      const modelOptions = (_e = (_d = vm == null ? void 0 : vm.proxy) == null ? void 0 : _d.$options) == null ? void 0 : _e.model;\n      key = (modelOptions == null ? void 0 : modelOptions.value) || \"value\";\n      if (!eventName)\n        event = (modelOptions == null ? void 0 : modelOptions.event) || \"input\";\n    } else {\n      key = \"modelValue\";\n    }\n  }\n  event = eventName || event || `update:${key.toString()}`;\n  const cloneFn = (val) => !clone ? val : typeof clone === \"function\" ? clone(val) : cloneFnJSON(val);\n  const getValue = () => isDef(props[key]) ? cloneFn(props[key]) : defaultValue;\n  const triggerEmit = (value) => {\n    if (shouldEmit) {\n      if (shouldEmit(value))\n        _emit(event, value);\n    } else {\n      _emit(event, value);\n    }\n  };\n  if (passive) {\n    const initialValue = getValue();\n    const proxy = ref(initialValue);\n    watch(\n      () => props[key],\n      (v) => proxy.value = cloneFn(v)\n    );\n    watch(\n      proxy,\n      (v) => {\n        if (v !== props[key] || deep)\n          triggerEmit(v);\n      },\n      { deep }\n    );\n    return proxy;\n  } else {\n    return computed({\n      get() {\n        return getValue();\n      },\n      set(value) {\n        triggerEmit(value);\n      }\n    });\n  }\n}\n\nfunction useVModels(props, emit, options = {}) {\n  const ret = {};\n  for (const key in props)\n    ret[key] = useVModel(props, key, emit, options);\n  return ret;\n}\n\nfunction useVibrate(options) {\n  const {\n    pattern = [],\n    interval = 0,\n    navigator = defaultNavigator\n  } = options || {};\n  const isSupported = useSupported(() => typeof navigator !== \"undefined\" && \"vibrate\" in navigator);\n  const patternRef = toRef(pattern);\n  let intervalControls;\n  const vibrate = (pattern2 = patternRef.value) => {\n    if (isSupported.value)\n      navigator.vibrate(pattern2);\n  };\n  const stop = () => {\n    if (isSupported.value)\n      navigator.vibrate(0);\n    intervalControls == null ? void 0 : intervalControls.pause();\n  };\n  if (interval > 0) {\n    intervalControls = useIntervalFn(\n      vibrate,\n      interval,\n      {\n        immediate: false,\n        immediateCallback: false\n      }\n    );\n  }\n  return {\n    isSupported,\n    pattern,\n    intervalControls,\n    vibrate,\n    stop\n  };\n}\n\nfunction useVirtualList(list, options) {\n  const { containerStyle, wrapperProps, scrollTo, calculateRange, currentList, containerRef } = \"itemHeight\" in options ? useVerticalVirtualList(options, list) : useHorizontalVirtualList(options, list);\n  return {\n    list: currentList,\n    scrollTo,\n    containerProps: {\n      ref: containerRef,\n      onScroll: () => {\n        calculateRange();\n      },\n      style: containerStyle\n    },\n    wrapperProps\n  };\n}\nfunction useVirtualListResources(list) {\n  const containerRef = ref(null);\n  const size = useElementSize(containerRef);\n  const currentList = ref([]);\n  const source = shallowRef(list);\n  const state = ref({ start: 0, end: 10 });\n  return { state, source, currentList, size, containerRef };\n}\nfunction createGetViewCapacity(state, source, itemSize) {\n  return (containerSize) => {\n    if (typeof itemSize === \"number\")\n      return Math.ceil(containerSize / itemSize);\n    const { start = 0 } = state.value;\n    let sum = 0;\n    let capacity = 0;\n    for (let i = start; i < source.value.length; i++) {\n      const size = itemSize(i);\n      sum += size;\n      capacity = i;\n      if (sum > containerSize)\n        break;\n    }\n    return capacity - start;\n  };\n}\nfunction createGetOffset(source, itemSize) {\n  return (scrollDirection) => {\n    if (typeof itemSize === \"number\")\n      return Math.floor(scrollDirection / itemSize) + 1;\n    let sum = 0;\n    let offset = 0;\n    for (let i = 0; i < source.value.length; i++) {\n      const size = itemSize(i);\n      sum += size;\n      if (sum >= scrollDirection) {\n        offset = i;\n        break;\n      }\n    }\n    return offset + 1;\n  };\n}\nfunction createCalculateRange(type, overscan, getOffset, getViewCapacity, { containerRef, state, currentList, source }) {\n  return () => {\n    const element = containerRef.value;\n    if (element) {\n      const offset = getOffset(type === \"vertical\" ? element.scrollTop : element.scrollLeft);\n      const viewCapacity = getViewCapacity(type === \"vertical\" ? element.clientHeight : element.clientWidth);\n      const from = offset - overscan;\n      const to = offset + viewCapacity + overscan;\n      state.value = {\n        start: from < 0 ? 0 : from,\n        end: to > source.value.length ? source.value.length : to\n      };\n      currentList.value = source.value.slice(state.value.start, state.value.end).map((ele, index) => ({\n        data: ele,\n        index: index + state.value.start\n      }));\n    }\n  };\n}\nfunction createGetDistance(itemSize, source) {\n  return (index) => {\n    if (typeof itemSize === \"number\") {\n      const size2 = index * itemSize;\n      return size2;\n    }\n    const size = source.value.slice(0, index).reduce((sum, _, i) => sum + itemSize(i), 0);\n    return size;\n  };\n}\nfunction useWatchForSizes(size, list, calculateRange) {\n  watch([size.width, size.height, list], () => {\n    calculateRange();\n  });\n}\nfunction createComputedTotalSize(itemSize, source) {\n  return computed(() => {\n    if (typeof itemSize === \"number\")\n      return source.value.length * itemSize;\n    return source.value.reduce((sum, _, index) => sum + itemSize(index), 0);\n  });\n}\nconst scrollToDictionaryForElementScrollKey = {\n  horizontal: \"scrollLeft\",\n  vertical: \"scrollTop\"\n};\nfunction createScrollTo(type, calculateRange, getDistance, containerRef) {\n  return (index) => {\n    if (containerRef.value) {\n      containerRef.value[scrollToDictionaryForElementScrollKey[type]] = getDistance(index);\n      calculateRange();\n    }\n  };\n}\nfunction useHorizontalVirtualList(options, list) {\n  const resources = useVirtualListResources(list);\n  const { state, source, currentList, size, containerRef } = resources;\n  const containerStyle = { overflowX: \"auto\" };\n  const { itemWidth, overscan = 5 } = options;\n  const getViewCapacity = createGetViewCapacity(state, source, itemWidth);\n  const getOffset = createGetOffset(source, itemWidth);\n  const calculateRange = createCalculateRange(\"horizontal\", overscan, getOffset, getViewCapacity, resources);\n  const getDistanceLeft = createGetDistance(itemWidth, source);\n  const offsetLeft = computed(() => getDistanceLeft(state.value.start));\n  const totalWidth = createComputedTotalSize(itemWidth, source);\n  useWatchForSizes(size, list, calculateRange);\n  const scrollTo = createScrollTo(\"horizontal\", calculateRange, getDistanceLeft, containerRef);\n  const wrapperProps = computed(() => {\n    return {\n      style: {\n        height: \"100%\",\n        width: `${totalWidth.value - offsetLeft.value}px`,\n        marginLeft: `${offsetLeft.value}px`,\n        display: \"flex\"\n      }\n    };\n  });\n  return {\n    scrollTo,\n    calculateRange,\n    wrapperProps,\n    containerStyle,\n    currentList,\n    containerRef\n  };\n}\nfunction useVerticalVirtualList(options, list) {\n  const resources = useVirtualListResources(list);\n  const { state, source, currentList, size, containerRef } = resources;\n  const containerStyle = { overflowY: \"auto\" };\n  const { itemHeight, overscan = 5 } = options;\n  const getViewCapacity = createGetViewCapacity(state, source, itemHeight);\n  const getOffset = createGetOffset(source, itemHeight);\n  const calculateRange = createCalculateRange(\"vertical\", overscan, getOffset, getViewCapacity, resources);\n  const getDistanceTop = createGetDistance(itemHeight, source);\n  const offsetTop = computed(() => getDistanceTop(state.value.start));\n  const totalHeight = createComputedTotalSize(itemHeight, source);\n  useWatchForSizes(size, list, calculateRange);\n  const scrollTo = createScrollTo(\"vertical\", calculateRange, getDistanceTop, containerRef);\n  const wrapperProps = computed(() => {\n    return {\n      style: {\n        width: \"100%\",\n        height: `${totalHeight.value - offsetTop.value}px`,\n        marginTop: `${offsetTop.value}px`\n      }\n    };\n  });\n  return {\n    calculateRange,\n    scrollTo,\n    containerStyle,\n    wrapperProps,\n    currentList,\n    containerRef\n  };\n}\n\nfunction useWakeLock(options = {}) {\n  const {\n    navigator = defaultNavigator,\n    document = defaultDocument\n  } = options;\n  let wakeLock;\n  const isSupported = useSupported(() => navigator && \"wakeLock\" in navigator);\n  const isActive = ref(false);\n  async function onVisibilityChange() {\n    if (!isSupported.value || !wakeLock)\n      return;\n    if (document && document.visibilityState === \"visible\")\n      wakeLock = await navigator.wakeLock.request(\"screen\");\n    isActive.value = !wakeLock.released;\n  }\n  if (document)\n    useEventListener(document, \"visibilitychange\", onVisibilityChange, { passive: true });\n  async function request(type) {\n    if (!isSupported.value)\n      return;\n    wakeLock = await navigator.wakeLock.request(type);\n    isActive.value = !wakeLock.released;\n  }\n  async function release() {\n    if (!isSupported.value || !wakeLock)\n      return;\n    await wakeLock.release();\n    isActive.value = !wakeLock.released;\n    wakeLock = null;\n  }\n  return {\n    isSupported,\n    isActive,\n    request,\n    release\n  };\n}\n\nfunction useWebNotification(defaultOptions = {}) {\n  const {\n    window = defaultWindow\n  } = defaultOptions;\n  const isSupported = useSupported(() => !!window && \"Notification\" in window);\n  const notification = ref(null);\n  const requestPermission = async () => {\n    if (!isSupported.value)\n      return;\n    if (\"permission\" in Notification && Notification.permission !== \"denied\")\n      await Notification.requestPermission();\n  };\n  const { on: onClick, trigger: clickTrigger } = createEventHook();\n  const { on: onShow, trigger: showTrigger } = createEventHook();\n  const { on: onError, trigger: errorTrigger } = createEventHook();\n  const { on: onClose, trigger: closeTrigger } = createEventHook();\n  const show = async (overrides) => {\n    if (!isSupported.value)\n      return;\n    await requestPermission();\n    const options = Object.assign({}, defaultOptions, overrides);\n    notification.value = new Notification(options.title || \"\", options);\n    notification.value.onclick = clickTrigger;\n    notification.value.onshow = showTrigger;\n    notification.value.onerror = errorTrigger;\n    notification.value.onclose = closeTrigger;\n    return notification.value;\n  };\n  const close = () => {\n    if (notification.value)\n      notification.value.close();\n    notification.value = null;\n  };\n  tryOnMounted(async () => {\n    if (isSupported.value)\n      await requestPermission();\n  });\n  tryOnScopeDispose(close);\n  if (isSupported.value && window) {\n    const document = window.document;\n    useEventListener(document, \"visibilitychange\", (e) => {\n      e.preventDefault();\n      if (document.visibilityState === \"visible\") {\n        close();\n      }\n    });\n  }\n  return {\n    isSupported,\n    notification,\n    show,\n    close,\n    onClick,\n    onShow,\n    onError,\n    onClose\n  };\n}\n\nconst DEFAULT_PING_MESSAGE = \"ping\";\nfunction resolveNestedOptions(options) {\n  if (options === true)\n    return {};\n  return options;\n}\nfunction useWebSocket(url, options = {}) {\n  const {\n    onConnected,\n    onDisconnected,\n    onError,\n    onMessage,\n    immediate = true,\n    autoClose = true,\n    protocols = []\n  } = options;\n  const data = ref(null);\n  const status = ref(\"CLOSED\");\n  const wsRef = ref();\n  const urlRef = toRef(url);\n  let heartbeatPause;\n  let heartbeatResume;\n  let explicitlyClosed = false;\n  let retried = 0;\n  let bufferedData = [];\n  let pongTimeoutWait;\n  const close = (code = 1e3, reason) => {\n    if (!wsRef.value)\n      return;\n    explicitlyClosed = true;\n    heartbeatPause == null ? void 0 : heartbeatPause();\n    wsRef.value.close(code, reason);\n  };\n  const _sendBuffer = () => {\n    if (bufferedData.length && wsRef.value && status.value === \"OPEN\") {\n      for (const buffer of bufferedData)\n        wsRef.value.send(buffer);\n      bufferedData = [];\n    }\n  };\n  const resetHeartbeat = () => {\n    clearTimeout(pongTimeoutWait);\n    pongTimeoutWait = void 0;\n  };\n  const send = (data2, useBuffer = true) => {\n    if (!wsRef.value || status.value !== \"OPEN\") {\n      if (useBuffer)\n        bufferedData.push(data2);\n      return false;\n    }\n    _sendBuffer();\n    wsRef.value.send(data2);\n    return true;\n  };\n  const _init = () => {\n    if (explicitlyClosed || typeof urlRef.value === \"undefined\")\n      return;\n    const ws = new WebSocket(urlRef.value, protocols);\n    wsRef.value = ws;\n    status.value = \"CONNECTING\";\n    ws.onopen = () => {\n      status.value = \"OPEN\";\n      onConnected == null ? void 0 : onConnected(ws);\n      heartbeatResume == null ? void 0 : heartbeatResume();\n      _sendBuffer();\n    };\n    ws.onclose = (ev) => {\n      status.value = \"CLOSED\";\n      wsRef.value = void 0;\n      onDisconnected == null ? void 0 : onDisconnected(ws, ev);\n      if (!explicitlyClosed && options.autoReconnect) {\n        const {\n          retries = -1,\n          delay = 1e3,\n          onFailed\n        } = resolveNestedOptions(options.autoReconnect);\n        retried += 1;\n        if (typeof retries === \"number\" && (retries < 0 || retried < retries))\n          setTimeout(_init, delay);\n        else if (typeof retries === \"function\" && retries())\n          setTimeout(_init, delay);\n        else\n          onFailed == null ? void 0 : onFailed();\n      }\n    };\n    ws.onerror = (e) => {\n      onError == null ? void 0 : onError(ws, e);\n    };\n    ws.onmessage = (e) => {\n      if (options.heartbeat) {\n        resetHeartbeat();\n        const {\n          message = DEFAULT_PING_MESSAGE\n        } = resolveNestedOptions(options.heartbeat);\n        if (e.data === message)\n          return;\n      }\n      data.value = e.data;\n      onMessage == null ? void 0 : onMessage(ws, e);\n    };\n  };\n  if (options.heartbeat) {\n    const {\n      message = DEFAULT_PING_MESSAGE,\n      interval = 1e3,\n      pongTimeout = 1e3\n    } = resolveNestedOptions(options.heartbeat);\n    const { pause, resume } = useIntervalFn(\n      () => {\n        send(message, false);\n        if (pongTimeoutWait != null)\n          return;\n        pongTimeoutWait = setTimeout(() => {\n          close();\n        }, pongTimeout);\n      },\n      interval,\n      { immediate: false }\n    );\n    heartbeatPause = pause;\n    heartbeatResume = resume;\n  }\n  if (autoClose) {\n    useEventListener(window, \"beforeunload\", () => close());\n    tryOnScopeDispose(close);\n  }\n  const open = () => {\n    close();\n    explicitlyClosed = false;\n    retried = 0;\n    _init();\n  };\n  if (immediate)\n    watch(urlRef, open, { immediate: true });\n  return {\n    data,\n    status,\n    close,\n    send,\n    open,\n    ws: wsRef\n  };\n}\n\nfunction useWebWorker(arg0, workerOptions, options) {\n  const {\n    window = defaultWindow\n  } = options != null ? options : {};\n  const data = ref(null);\n  const worker = shallowRef();\n  const post = function post2(val) {\n    if (!worker.value)\n      return;\n    worker.value.postMessage(val);\n  };\n  const terminate = function terminate2() {\n    if (!worker.value)\n      return;\n    worker.value.terminate();\n  };\n  if (window) {\n    if (typeof arg0 === \"string\")\n      worker.value = new Worker(arg0, workerOptions);\n    else if (typeof arg0 === \"function\")\n      worker.value = arg0();\n    else\n      worker.value = arg0;\n    worker.value.onmessage = (e) => {\n      data.value = e.data;\n    };\n    tryOnScopeDispose(() => {\n      if (worker.value)\n        worker.value.terminate();\n    });\n  }\n  return {\n    data,\n    post,\n    terminate,\n    worker\n  };\n}\n\nfunction jobRunner(userFunc) {\n  return (e) => {\n    const userFuncArgs = e.data[0];\n    return Promise.resolve(userFunc.apply(void 0, userFuncArgs)).then((result) => {\n      postMessage([\"SUCCESS\", result]);\n    }).catch((error) => {\n      postMessage([\"ERROR\", error]);\n    });\n  };\n}\n\nfunction depsParser(deps) {\n  if (deps.length === 0)\n    return \"\";\n  const depsString = deps.map((dep) => `'${dep}'`).toString();\n  return `importScripts(${depsString})`;\n}\n\nfunction createWorkerBlobUrl(fn, deps) {\n  const blobCode = `${depsParser(deps)}; onmessage=(${jobRunner})(${fn})`;\n  const blob = new Blob([blobCode], { type: \"text/javascript\" });\n  const url = URL.createObjectURL(blob);\n  return url;\n}\n\nfunction useWebWorkerFn(fn, options = {}) {\n  const {\n    dependencies = [],\n    timeout,\n    window = defaultWindow\n  } = options;\n  const worker = ref();\n  const workerStatus = ref(\"PENDING\");\n  const promise = ref({});\n  const timeoutId = ref();\n  const workerTerminate = (status = \"PENDING\") => {\n    if (worker.value && worker.value._url && window) {\n      worker.value.terminate();\n      URL.revokeObjectURL(worker.value._url);\n      promise.value = {};\n      worker.value = void 0;\n      window.clearTimeout(timeoutId.value);\n      workerStatus.value = status;\n    }\n  };\n  workerTerminate();\n  tryOnScopeDispose(workerTerminate);\n  const generateWorker = () => {\n    const blobUrl = createWorkerBlobUrl(fn, dependencies);\n    const newWorker = new Worker(blobUrl);\n    newWorker._url = blobUrl;\n    newWorker.onmessage = (e) => {\n      const { resolve = () => {\n      }, reject = () => {\n      } } = promise.value;\n      const [status, result] = e.data;\n      switch (status) {\n        case \"SUCCESS\":\n          resolve(result);\n          workerTerminate(status);\n          break;\n        default:\n          reject(result);\n          workerTerminate(\"ERROR\");\n          break;\n      }\n    };\n    newWorker.onerror = (e) => {\n      const { reject = () => {\n      } } = promise.value;\n      reject(e);\n      workerTerminate(\"ERROR\");\n    };\n    if (timeout) {\n      timeoutId.value = setTimeout(\n        () => workerTerminate(\"TIMEOUT_EXPIRED\"),\n        timeout\n      );\n    }\n    return newWorker;\n  };\n  const callWorker = (...fnArgs) => new Promise((resolve, reject) => {\n    promise.value = {\n      resolve,\n      reject\n    };\n    worker.value && worker.value.postMessage([[...fnArgs]]);\n    workerStatus.value = \"RUNNING\";\n  });\n  const workerFn = (...fnArgs) => {\n    if (workerStatus.value === \"RUNNING\") {\n      console.error(\n        \"[useWebWorkerFn] You can only run one instance of the worker at a time.\"\n      );\n      return Promise.reject();\n    }\n    worker.value = generateWorker();\n    return callWorker(...fnArgs);\n  };\n  return {\n    workerFn,\n    workerStatus,\n    workerTerminate\n  };\n}\n\nfunction useWindowFocus({ window = defaultWindow } = {}) {\n  if (!window)\n    return ref(false);\n  const focused = ref(window.document.hasFocus());\n  useEventListener(window, \"blur\", () => {\n    focused.value = false;\n  });\n  useEventListener(window, \"focus\", () => {\n    focused.value = true;\n  });\n  return focused;\n}\n\nfunction useWindowScroll({ window = defaultWindow } = {}) {\n  if (!window) {\n    return {\n      x: ref(0),\n      y: ref(0)\n    };\n  }\n  const x = ref(window.scrollX);\n  const y = ref(window.scrollY);\n  useEventListener(\n    window,\n    \"scroll\",\n    () => {\n      x.value = window.scrollX;\n      y.value = window.scrollY;\n    },\n    {\n      capture: false,\n      passive: true\n    }\n  );\n  return { x, y };\n}\n\nfunction useWindowSize(options = {}) {\n  const {\n    window = defaultWindow,\n    initialWidth = Infinity,\n    initialHeight = Infinity,\n    listenOrientation = true,\n    includeScrollbar = true\n  } = options;\n  const width = ref(initialWidth);\n  const height = ref(initialHeight);\n  const update = () => {\n    if (window) {\n      if (includeScrollbar) {\n        width.value = window.innerWidth;\n        height.value = window.innerHeight;\n      } else {\n        width.value = window.document.documentElement.clientWidth;\n        height.value = window.document.documentElement.clientHeight;\n      }\n    }\n  };\n  update();\n  tryOnMounted(update);\n  useEventListener(\"resize\", update, { passive: true });\n  if (listenOrientation) {\n    const matches = useMediaQuery(\"(orientation: portrait)\");\n    watch(matches, () => update());\n  }\n  return { width, height };\n}\n\nexport { DefaultMagicKeysAliasMap, StorageSerializers, TransitionPresets, computedAsync as asyncComputed, breakpointsAntDesign, breakpointsBootstrapV5, breakpointsMasterCss, breakpointsQuasar, breakpointsSematic, breakpointsTailwind, breakpointsVuetify, cloneFnJSON, computedAsync, computedInject, createFetch, createReusableTemplate, createTemplatePromise, createUnrefFn, customStorageEventName, defaultDocument, defaultLocation, defaultNavigator, defaultWindow, executeTransition, formatTimeAgo, getSSRHandler, mapGamepadToXbox360Controller, onClickOutside, onKeyDown, onKeyPressed, onKeyStroke, onKeyUp, onLongPress, onStartTyping, setSSRHandler, templateRef, unrefElement, useActiveElement, useAnimate, useAsyncQueue, useAsyncState, useBase64, useBattery, useBluetooth, useBreakpoints, useBroadcastChannel, useBrowserLocation, useCached, useClipboard, useCloned, useColorMode, useConfirmDialog, useCssVar, useCurrentElement, useCycleList, useDark, useDebouncedRefHistory, useDeviceMotion, useDeviceOrientation, useDevicePixelRatio, useDevicesList, useDisplayMedia, useDocumentVisibility, useDraggable, useDropZone, useElementBounding, useElementByPoint, useElementHover, useElementSize, useElementVisibility, useEventBus, useEventListener, useEventSource, useEyeDropper, useFavicon, useFetch, useFileDialog, useFileSystemAccess, useFocus, useFocusWithin, useFps, useFullscreen, useGamepad, useGeolocation, useIdle, useImage, useInfiniteScroll, useIntersectionObserver, useKeyModifier, useLocalStorage, useMagicKeys, useManualRefHistory, useMediaControls, useMediaQuery, useMemoize, useMemory, useMounted, useMouse, useMouseInElement, useMousePressed, useMutationObserver, useNavigatorLanguage, useNetwork, useNow, useObjectUrl, useOffsetPagination, useOnline, usePageLeave, useParallax, useParentElement, usePerformanceObserver, usePermission, usePointer, usePointerLock, usePointerSwipe, usePreferredColorScheme, usePreferredContrast, usePreferredDark, usePreferredLanguages, usePreferredReducedMotion, usePrevious, useRafFn, useRefHistory, useResizeObserver, useScreenOrientation, useScreenSafeArea, useScriptTag, useScroll, useScrollLock, useSessionStorage, useShare, useSorted, useSpeechRecognition, useSpeechSynthesis, useStepper, useStorage, useStorageAsync, useStyleTag, useSupported, useSwipe, useTemplateRefsList, useTextDirection, useTextSelection, useTextareaAutosize, useThrottledRefHistory, useTimeAgo, useTimeoutPoll, useTimestamp, useTitle, useTransition, useUrlSearchParams, useUserMedia, useVModel, useVModels, useVibrate, useVirtualList, useWakeLock, useWebNotification, useWebSocket, useWebWorker, useWebWorkerFn, useWindowFocus, useWindowScroll, useWindowSize };\n","<template>\n  <form class=\"m-products__sort\">\n    <select @change=\"emit('update:modelValue', update($event))\" class=\"a-select\"\n      :class=\"{ 'a-select--checkout': props.type === 'checkout' }\" :id=\"id\" name=\"sort\">\n      <template v-for=\"(option) in props.options\" :key=\"option.id\">\n        <option :value=\"option.id\" :selected=\"props.modelValue?.id === option.id\">{{ option.label }}</option>\n      </template>\n    </select>\n    <div class=\"a-select__icon\">\n      <svg class=\"a-icon a-icon--pagination\" aria-hidden=\"true\">\n        <use href=\"#chevron-down\" />\n      </svg>\n    </div>\n  </form>\n</template>\n\n<script setup lang=\"ts\">\nimport { v4 as uuidv4 } from 'uuid'\nimport { ref } from 'vue'\n\nexport interface Option {\n  id: any\n  label: string\n}\n\nconst props = defineProps({\n  type: {\n    type: String,\n  },\n  modelValue: {\n    type: Object as () => Option | null,\n    default: null,\n  },\n  options: {\n    type: Array<Option>,\n    default: [],\n  }\n})\n\nconst emit = defineEmits<{\n  (e: 'update:modelValue', value: Option | null): void\n}>()\n\nconst id = ref('select_' + uuidv4())\n\nfunction update($event: Event): Option | null {\n  const eventTarget = $event.target as HTMLSelectElement\n\n  for (const option of props.options) {\n    if (option.id == eventTarget.value) {\n      return option\n    }\n  }\n\n  return null\n}\n</script>\n","import { notify } from \"@kyvg/vue3-notification\"\nimport i18n from '../i18n'\nconst { t } = i18n.global\n\nexport async function handleErrorResponse(response: Response) {\n    const body = await response.json()\n    notify({\n        title: body?.error?.title ?? t('error.default.title'),\n        text: body?.message ?? body?.error?.detail ?? t('error.default.detail'),\n        type: 'error',\n    })\n}\n\nexport async function handleErrorResponseLegacyMethod(response: any) {\n    let errorMessage = t('error.default.detail')\n\n    // Check if we have a normal error message response like:\n    // { \"code\": \"invalid\", \"message\" : \"Product X niet op voorraad.\" }\n    const errorMsg = response?.message ?? null\n    if (errorMsg) {\n        errorMessage = errorMsg\n    }\n\n    let errors = []\n    if (Array.isArray(response.errors)) {\n        errors = response.errors\n    } else if (typeof response.errors === 'object') {\n        // It is an object with the field name as key and error messages as value.\n        // We need to convert it to an array of error messages\n        for (const key in response.errors) {\n            if (Array.isArray(response.errors[key])) {\n                errors.push(...response.errors[key])\n            } else {\n                errors.push(response.errors[key])\n            }\n        }\n\n    }\n\n    if (errors.length > 0) {\n        errorMessage = '<ul>'\n        errors.forEach((error: string) => {\n            errorMessage += '<li>' + error + '</li>'\n        })\n        errorMessage += '</ul>'\n    }\n\n    notify({\n        title: t('error.default.title'),\n        text: errorMessage,\n        type: 'error',\n        duration: 7000,\n    })\n}","import { defineStore } from \"pinia\";\nimport { computed, ComputedRef, ref, Ref } from \"vue\";\nimport {\n    handleErrorResponse,\n    handleErrorResponseLegacyMethod,\n} from \"../helper/api\";\nimport { RemovableRef, StorageSerializers, useSessionStorage } from \"@vueuse/core\";\nimport {\n    CheckoutStepCreateOrder,\n    CheckoutStepUpdateOrder,\n    emitEvent,\n    EventCartAdd,\n    EventCartRemove,\n    EventCheckoutStep,\n} from \"../helper/tracking-events\";\nimport { generateRoute } from \"../helper-functions\";\n\nconst locale = document.documentElement.lang ?? \"nl\";\n\nexport const useCartStore = defineStore(\"cart\", () => {\n    let isPopoverOpened: Ref<Boolean> = ref(false);\n    let loadingCart: Ref<Boolean> = ref(true);\n    let cartInitialized: Ref<Boolean> = ref(false);\n    let cart: Ref<Cart> = ref({\n        products: [],\n        checkout_method: null,\n        coupon: null,\n        postnl_data: null,\n        wrapping_paper: null,\n        country: null,\n        invoice_address: null,\n        shipping_address: null,\n        order_id: null,\n        total: 0,\n    });\n\n    async function initCart() {\n        if (cartInitialized.value) {\n            return;\n        }\n        cartInitialized.value = true;\n        loadingCart.value = true;\n\n        try {\n            await getCart();\n\n            if (cart.value.coupon !== null) {\n                couponCode.value = cart.value.coupon.code;\n            }\n\n            await getCountries();\n            postNLApiOnline.value = await isPostNLOnline();\n            await getShippingMethods();\n            await getPaymentMethods();\n\n            // Check if the checkout method in the cart is the same as the one in the session storage.\n            // If it is not the same, we need to update the checkout method in the session storage.\n            const checkoutMethod = cart.value.checkout_method?.ID ?? null\n            if (checkoutMethod !== null) {\n                if (selectedPayMethod.value?.checkout_method_id != checkoutMethod) {\n                    const paymentMethod = paymentMethods.value.find(\n                        (payMethod) => payMethod.checkout_method_id == checkoutMethod,\n                    );\n\n                    if (paymentMethod !== undefined) {\n                        setPaymentMethod(paymentMethod);\n                    }\n                }\n            }\n\n            await getDefaultTimeFrames();\n            await initGiftWrapItems();\n        } catch (e) {\n            console.error(\"there was an error fetching the cart: \", e);\n        }\n        loadingCart.value = false;\n    }\n\n    let wrappingPaper: Ref<CartWrappingPaper | null> = ref(null);\n    let productCount: ComputedRef<number> = computed(() => {\n        let count = 0;\n        if (cart.value.products.length === 0) {\n            return 0;\n        }\n\n        cart.value.products.forEach((product) => {\n            count += product.quantity;\n        });\n        return count;\n    });\n\n    let giftWrapItems: Ref<CartWrappingPaper[]> = ref([]);\n    let checkoutCountries: Ref<CartCountry[]> = ref([]);\n    let selectedCountry: Ref<CartCountry | null> = ref(null);\n    let shippingMethods: Ref<CartShippingMethod[]> = ref([]);\n    let paymentMethods: Ref<CartPaymentMethod[]> = ref([]);\n    let selectedPayMethod: RemovableRef<CartPaymentMethod | null> =\n        useSessionStorage(\n            \"cloudcommerce.checkout.selected_pay_method_id\",\n            null,\n            { serializer: StorageSerializers.object },\n        );\n    let invoiceAddress: RemovableRef<CartAddress> = useSessionStorage(\n        \"cloudcommerce.checkout.invoice_address\",\n        emptyAddress(),\n    );\n    let sameShippingAddress: RemovableRef<boolean> = useSessionStorage(\n        \"cloudcommerce.checkout.same_shipping_address\",\n        true,\n    );\n    let shippingAddress: RemovableRef<CartAddress> = useSessionStorage(\n        \"cloudcommerce.checkout.shipping_address\",\n        emptyAddress(),\n    );\n    let orderComment: RemovableRef<string> = useSessionStorage(\n        \"cloudcommerce.checkout.order_comment\",\n        \"\",\n    );\n    let termsOfServiceAccepted: RemovableRef<boolean> = useSessionStorage(\n        \"cloudcommerce.checkout.terms_of_service_accepted\",\n        false,\n    );\n    let newsletterAccepted: RemovableRef<boolean> = useSessionStorage(\n        \"cloudcommerce.checkout.newsletter_accepted\",\n        false,\n    );\n    let couponCode: RemovableRef<string> = useSessionStorage(\n        \"cloudcommerce.checkout.coupon_code\",\n        \"\",\n    );\n    let selectedTimeFrame: Ref<PostnlTimeFrame | null> = ref(null);\n    let customerAge: RemovableRef<Date> = useSessionStorage(\n        \"cloudcommerce.checkout.customer_age\",\n        new Date(),\n    );\n    let customerGender: RemovableRef<CustomerGenders> =\n        useSessionStorage<CustomerGenders>(\n            \"cloudcommerce.checkout.customer_gender\",\n            CustomerGenders.None,\n        );\n    let customerIban: RemovableRef<string> = useSessionStorage(\n        \"cloudcommerce.checkout.customer_iban\",\n        \"\",\n    );\n    let postNLApiOnline: Ref<boolean> = ref(true);\n\n    function openCart() {\n        isPopoverOpened.value = true;\n    }\n\n    function closeCart() {\n        isPopoverOpened.value = false;\n    }\n\n    async function add(\n        productId: string,\n        amount: number = 1,\n        configurationOf: string | null = null,\n    ) {\n        loadingCart.value = true;\n        isPopoverOpened.value = true;\n\n        let url = `/cart/add?product=${productId}&amount=${amount}`;\n        if (configurationOf !== null) {\n            url = url + `&configuration_of=${configurationOf}`;\n        }\n\n        const response = await fetch(url, {\n            method: \"PUT\",\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n        }\n\n        await getCart();\n\n        if (amount !== null && amount > 0) {\n            const product = cart.value.products.find(\n                (product) => product.ID === productId,\n            );\n            if (product !== undefined) {\n                emitEvent(EventCartAdd, productEventData(product));\n            }\n        }\n\n        loadingCart.value = false;\n    }\n\n    function productEventData(product: Product, qty: number | null = null) {\n        let attributes: { [key: string]: string } = {};\n        for (let [key, attributeValue] of Object.entries(product.attributes)) {\n            attributes[key] = attributeValue.value;\n        }\n\n        const payload = {\n            ID: product.ID,\n            name: product.name,\n            configurationOf: product.configuration_of,\n            price: product.price, // The price in cents, equivalent to €59.99.\n            qty: qty !== null ? qty : product.quantity,\n            attributes: attributes,\n        };\n\n        return payload;\n    }\n\n    async function remove(productId: string, amount: number = 1) {\n        const product = cart.value.products.find(\n            (product) => product.ID === productId,\n        );\n        if (typeof product === \"undefined\") {\n            // Product is not in current cart so not going to do anything.\n            return;\n        }\n\n        loadingCart.value = true;\n\n        const response = await fetch(\n            `/cart/remove?product=${productId}&amount=${amount}`,\n            {\n                method: \"PUT\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n        }\n\n        // Fetch new cart.\n        await getCart();\n\n        if (amount !== null) {\n            emitEvent(EventCartRemove, productEventData(product, amount));\n        }\n\n        loadingCart.value = false;\n    }\n\n    async function getCart() {\n        loadingCart.value = true;\n\n        const response = await fetch(`/cart/list?lang=${locale}`, {\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            loadingCart.value = false;\n            return;\n        }\n        let data = await response.json();\n        cart.value = data;\n        loadingCart.value = false;\n    }\n\n    async function initGiftWrapItems() {\n        const response = await fetch(\n            `/cart/wrapping_options/list?lang=${locale}`,\n            {\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            giftWrapItems.value = [];\n            return;\n        }\n\n        giftWrapItems.value = await response.json();\n    }\n\n    async function setWrappingPaper(ID: string) {\n        const response = await fetch(\n            `/cart/wrapping_options/set/${ID}?lang=${locale}`,\n            {\n                method: \"POST\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n\n        await getCart();\n    }\n\n    async function removeWrappingPaper() {\n        const response = await fetch(\n            `/cart/wrapping_options/remove?lang=${locale}`,\n            {\n                method: \"POST\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n\n        await getCart();\n    }\n\n    async function addCoupon(code: string) {\n        const response = await fetch(`/cart/coupon/add?lang=${locale}`, {\n            method: \"POST\",\n            body: JSON.stringify({\n                code: code,\n            }),\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n\n        await getCart();\n    }\n\n    async function removeCoupon() {\n        const response = await fetch(`/cart/coupon/remove?lang=${locale}`, {\n            method: \"POST\",\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n        couponCode.value = \"\";\n        await getCart();\n    }\n\n    async function getCountries() {\n        const response = await fetch(`/checkout/countries/get?lang=${locale}`, {\n            method: \"GET\",\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n\n        const respBody = await response.json();\n        checkoutCountries.value = respBody.map(\n            (country: {\n                id: string;\n                name: string;\n                shortCode: string;\n                isDefault: boolean;\n            }) => {\n                return {\n                    ID: country.id,\n                    name: country.name,\n                    shortCode: country.shortCode,\n                    is_default: country.isDefault,\n                };\n            },\n        );\n    }\n\n    async function setCheckoutCountry(countryID: string) {\n        const response = await fetch(\n            `/cart/update_country/${countryID}?lang=${locale}`,\n            {\n                method: \"POST\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n\n        await getShippingMethods();\n        await getCart();\n    }\n\n    async function getShippingMethods() {\n        const response = await fetch(`/cart/shipping_methods?lang=${locale}`, {\n            method: \"GET\",\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n\n        const respBody = await response.json();\n        shippingMethods.value = respBody;\n    }\n\n    async function getPaymentMethods() {\n        if (cart.value.products.length === 0) {\n            return;\n        }\n\n        // Only load payment methods when we are on a checkout page.\n        if (window.location.pathname.indexOf(\"/checkout\") === -1) {\n            return;\n        }\n\n        loadingCart.value = true;\n\n        const response = await fetch(\n            `/checkout/get_payment_methods?lang=${locale}`,\n            {\n                method: \"GET\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            loadingCart.value = false;\n            return;\n        }\n\n        const respBody = await response.json();\n        paymentMethods.value = respBody.map(\n            (payMethod: {\n                internal_name: string;\n                name: string;\n                checkoutMethod: string;\n                validate_age: boolean;\n                validate_gender: boolean;\n                validate_iban: boolean;\n            }) => {\n                let cartPaymentMethod: CartPaymentMethod = {\n                    name: payMethod.name,\n                    internalName: payMethod.internal_name,\n                    checkout_method_id: payMethod.checkoutMethod,\n                    validateAge: payMethod.validate_age ?? false,\n                    validateGender: payMethod.validate_gender ?? false,\n                    validateIban: payMethod.validate_iban ?? false,\n                };\n\n                return cartPaymentMethod;\n            },\n        );\n\n        // Set default payment method\n        if (\n            !selectePayMethodExists(selectedPayMethod.value?.internalName ?? \"\")\n        ) {\n            selectDefaultPayMethod();\n        }\n        loadingCart.value = false;\n    }\n\n    async function setCheckoutMethod(checkoutMethod: string) {\n        loadingCart.value = true;\n\n        const response = await fetch(\n            `/cart/checkout_method/${checkoutMethod}?lang=${locale}`,\n            {\n                method: \"PUT\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n\n            // Reset state.\n            await getShippingMethods();\n            await getCart();\n            loadingCart.value = false;\n            return;\n        }\n\n        await getShippingMethods();\n        await getCart();\n\n        loadingCart.value = false;\n    }\n\n    async function getAddressAutocomplete(\n        zipcode: string,\n        houseNumber: string,\n    ): Promise<CartAddressAutocomplete | null> {\n        const response = await fetch(`/checkout/get_address_information`, {\n            method: \"POST\",\n            body: JSON.stringify({\n                zipcode: zipcode + '',\n                house_number: houseNumber + '',\n            }),\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            return null;\n        }\n\n        const respBody = await response.json();\n        return respBody as CartAddressAutocomplete;\n    }\n\n    async function saveAddresses(): Promise<boolean> {\n        const request: {\n            address: {\n                first_name: string;\n                middle_name: string;\n                last_name: string;\n                street: string;\n                house_number: string;\n                house_number_ext: string;\n                zipcode: string;\n                city: string;\n                email: string;\n                phone: string;\n                company_name: string;\n            };\n            delivery_address: {\n                first_name: string;\n                middle_name: string;\n                last_name: string;\n                street: string;\n                house_number: string;\n                house_number_ext: string;\n                zipcode: string;\n                city: string;\n                email: string;\n                phone: string;\n                company_name: string;\n            } | null;\n            use_alternative_address: boolean;\n            should_update: boolean;\n            order_comment: string;\n        } = {\n            address: {\n                first_name: invoiceAddress.value.first_name,\n                middle_name: invoiceAddress.value.middle_name,\n                last_name: invoiceAddress.value.last_name,\n                street: invoiceAddress.value.street,\n                house_number: invoiceAddress.value.house_number.toString(),\n                house_number_ext: invoiceAddress.value.house_number_addition,\n                zipcode: invoiceAddress.value.zipcode,\n                city: invoiceAddress.value.city,\n                email: invoiceAddress.value.email,\n                phone: invoiceAddress.value.phone_number,\n                company_name: invoiceAddress.value.company_name,\n            },\n            delivery_address: null,\n            use_alternative_address: sameShippingAddress.value !== true,\n            // No idea why this is needed.\n            should_update: true,\n            order_comment: orderComment.value,\n        };\n\n        if (shippingAddress.value && !sameShippingAddress.value) {\n            request.delivery_address = {\n                first_name: shippingAddress.value.first_name,\n                middle_name: shippingAddress.value.middle_name,\n                last_name: shippingAddress.value.last_name,\n                street: shippingAddress.value.street,\n                house_number: shippingAddress.value.house_number.toString(),\n                house_number_ext: shippingAddress.value.house_number_addition,\n                zipcode: shippingAddress.value.zipcode,\n                city: shippingAddress.value.city,\n                company_name: shippingAddress.value.company_name,\n                // Use values from the invoice address.\n                email: invoiceAddress.value.email,\n                phone: invoiceAddress.value.phone_number,\n            };\n        }\n\n        const response = await fetch(\n            `/checkout/save_addresses?lang=${locale}`,\n            {\n                method: \"POST\",\n                body: JSON.stringify(request),\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            const responseBody = await response.json();\n            await handleErrorResponseLegacyMethod(responseBody);\n            return false;\n        }\n\n        return true;\n    }\n\n    function selectePayMethodExists(id: string): boolean {\n        return (\n            paymentMethods.value.filter(\n                (payMethod) => payMethod.internalName === id,\n            ).length > 0\n        );\n    }\n\n    function selectDefaultPayMethod() {\n        if (paymentMethods.value.length === 0) {\n            return;\n        }\n\n        // TODO: Remove this logic in favour of selecting this in the admin backend.\n        let payMethod: CartPaymentMethod | null =\n            paymentMethods.value.filter(\n                (payMethod) => payMethod.internalName.toUpperCase() === \"IDEAL\",\n            )[0] ?? null;\n        if (payMethod === null) {\n            payMethod = paymentMethods.value[0];\n        }\n\n        selectedPayMethod.value = payMethod;\n    }\n\n    function emptyAddress(): CartAddress {\n        return {\n            first_name: \"\",\n            middle_name: \"\",\n            last_name: \"\",\n            street: \"\",\n            house_number: \"\",\n            house_number_addition: \"\",\n            zipcode: \"\",\n            city: \"\",\n            email: \"\",\n            phone_number: \"\",\n            company_name: \"\",\n        } as CartAddress;\n    }\n\n    async function createOrder() {\n        if (!termsOfServiceAccepted.value) {\n            return false;\n        }\n\n        if (!selectedPayMethod.value) {\n            return false;\n        }\n\n        const request: InsertOrderRequest = {\n            internal_name: selectedPayMethod.value?.internalName ?? \"\",\n            checkoutMethod: selectedPayMethod.value?.checkout_method_id,\n            orderComment: orderComment.value,\n            iban: \"\",\n            riverty: null,\n            subscribeNewsletter: newsletterAccepted.value,\n        };\n\n        if (selectedPayMethod.value?.validateIban) {\n            request.iban = customerIban.value;\n        }\n\n        if (selectedPayMethod.value?.validateAge) {\n            request.riverty = {\n                dobDay: customerAge.value.getDate(),\n                dobMonth: customerAge.value.getMonth() + 1,\n                dobYear: customerAge.value.getFullYear(),\n                gender: \"none\",\n            };\n        }\n\n        if (\n            selectedPayMethod.value?.validateGender &&\n            (CustomerGenders.Male === customerGender.value ||\n                CustomerGenders.Female === customerGender.value)\n        ) {\n            if (request.riverty === null) {\n                request.riverty = {\n                    dobDay: new Date().getDate(),\n                    dobMonth: new Date().getMonth() + 1,\n                    dobYear: new Date().getFullYear(),\n                    gender: \"none\",\n                };\n            }\n\n            request.riverty.gender = customerGender.value;\n        }\n\n        if (selectedPayMethod.value?.validateIban) {\n            request.iban = customerIban.value;\n        }\n\n        let response: Response;\n        let checkoutStep = CheckoutStepCreateOrder;\n\n        const orderID = cart.value.order_id ?? null\n        if (orderID !== null) {\n            response = await fetch(`/checkout/update_order?lang=${locale}`, {\n                method: \"POST\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n                body: JSON.stringify(request),\n            });\n            checkoutStep = CheckoutStepUpdateOrder;\n        } else {\n            response = await fetch(`/checkout/insert_order?lang=${locale}`, {\n                method: \"POST\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n                body: JSON.stringify(request),\n            });\n        }\n\n        if (response.status !== 200) {\n            const respBody = await response.json();\n\n            if (\n                typeof respBody.redirect_url === \"string\" &&\n                respBody.redirect_url !== \"\"\n            ) {\n                window.location.href = respBody.redirect_url;\n                return false;\n            }\n\n            await handleErrorResponseLegacyMethod(respBody);\n            return false;\n        }\n\n        const respBody = await response.json();\n        // Kunnen wij dit event aanpassen/vervangen.\n        emitEvent(EventCheckoutStep, {\n            step: checkoutStep,\n            products: (respBody.products ?? []).map(\n                (product: {\n                    id: string;\n                    name: string;\n                    configurationOf: string;\n                    price: number;\n                    quantity: number;\n                    attributes: {\n                        [key: string]: {\n                            name: string;\n                            value: string;\n                        };\n                    };\n                }) => {\n                    const attributes: Record<string, string> = {};\n                    Object.keys(product.attributes).forEach((key) => {\n                        attributes[key] = product.attributes[key].value;\n                    });\n\n                    return {\n                        ID: product.id ?? (product as any).ID,\n                        name: product.name,\n                        configurationOf: product.configurationOf ?? (product as any).configuration_of,\n                        price: product.price,\n                        qty: product.quantity,\n                        attributes: attributes,\n                    };\n                },\n            ),\n        });\n\n        const url = new URL(generateRoute(\"checkout_payment\"), window.location.href)\n        if (respBody.hash !== undefined) {\n            url.searchParams.set(\"hash\", respBody.hash);\n        }\n\n        window.location.href = url.href;\n        return true;\n    }\n\n    async function getDefaultTimeFrames() {\n        if (!postNLApiOnline.value) {\n            return;\n        }\n        const timeFrames = await getTimeFrames();\n        if (timeFrames === null || timeFrames.length === 0) {\n            return;\n        }\n\n        selectedTimeFrame.value =\n            timeFrames.filter((t) => t.option.toLowerCase() === \"daytime\")[0] ??\n            null;\n        if (selectedTimeFrame.value === null) {\n            selectedTimeFrame.value = timeFrames[0] ?? null;\n        }\n\n        const orderID = cart.value.order_id ?? null\n        if (\n            isPostNLCheckoutMethod() &&\n            cart.value.postnl_data === null &&\n            selectedTimeFrame.value !== null &&\n            orderID === null\n        ) {\n            await setTimeFrame(selectedTimeFrame.value);\n        }\n    }\n\n    async function getTimeFrames(): Promise<PostnlTimeFrame[] | null> {\n        if (!postNLApiOnline.value) {\n            return null;\n        }\n\n        let url = `/checkout/postnl/timeframes/default`;\n        if (\n            invoiceAddress.value.zipcode !== \"\" &&\n            invoiceAddress.value.house_number !== \"\"\n        ) {\n            url = `/checkout/postnl/timeframes/${invoiceAddress.value.zipcode.replace(\" \", \"\")}/${invoiceAddress.value.house_number}`;\n        } else if (\n            shippingAddress.value.zipcode !== \"\" &&\n            shippingAddress.value.house_number !== \"\"\n        ) {\n            url = `/checkout/postnl/timeframes/${shippingAddress.value.zipcode.replace(\" \", \"\")}/${shippingAddress.value.house_number}`;\n        }\n\n        url = url + `?lang=${locale}`;\n\n        const response = await fetch(url, {\n            method: \"GET\",\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            let error = await response.json();\n            if (typeof error.code === \"number\" && error.code === 1) {\n                postNLApiOnline.value = false;\n            }\n\n            return null;\n        }\n\n        return await response.json();\n    }\n\n    async function setTimeFrame(\n        timeFrame: PostnlTimeFrame | null = null,\n    ): Promise<void> {\n        if (!postNLApiOnline.value || timeFrame === null) {\n            selectedTimeFrame.value = null;\n            return;\n        }\n\n        const response = await fetch(\n            `/checkout/postnl/set_postnl_timeframe_data?lang=${locale}`,\n            {\n                method: \"POST\",\n                body: JSON.stringify(timeFrame),\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return;\n        }\n\n        selectedTimeFrame.value = timeFrame;\n        await getCart();\n    }\n\n    async function isPostNLOnline(): Promise<boolean> {\n        const response = await fetch(`/checkout/postnl/is_online`, {\n            method: \"GET\",\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            return false;\n        }\n\n        const respBody: { isOnline: boolean } = await response.json();\n        return respBody?.isOnline ?? false;\n    }\n\n    async function getPickupPoints(\n        zipcode: string,\n        countryCode: \"nl\" | \"be\" = \"nl\",\n    ): Promise<PostnlPickupPoint[] | null> {\n        if (!postNLApiOnline.value) {\n            return null;\n        }\n\n        const response = await fetch(\n            `/checkout/postnl/nearest_locations/${zipcode}/${countryCode}?lang=${locale}`,\n            {\n                method: \"GET\",\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            let error = await response.json();\n            if (typeof error.code === \"number\" && error.code === 1) {\n                postNLApiOnline.value = false;\n            }\n\n            return null;\n        }\n\n        const respBody = await response.json();\n        return respBody as PostnlPickupPoint[];\n    }\n\n    async function setPickupPoint(\n        pickupPoint: PostnlPickupPoint,\n    ): Promise<boolean> {\n        if (!postNLApiOnline.value) {\n            return false;\n        }\n\n        const response = await fetch(\n            `/checkout/postnl/set_postnl_pickup_data?lang=${locale}`,\n            {\n                method: \"POST\",\n                body: JSON.stringify(pickupPoint),\n                headers: {\n                    \"Content-Type\": \"application/json\",\n                },\n            },\n        );\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return false;\n        }\n\n        return true;\n    }\n\n    function setPaymentMethod(paymentMethod: CartPaymentMethod | null): void {\n        selectedPayMethod.value = paymentMethod;\n    }\n\n    async function clearCart(): Promise<boolean> {\n        const response = await fetch(`/cart/clear`, {\n            method: \"POST\",\n            headers: {\n                \"Content-Type\": \"application/json\",\n            },\n        });\n        if (response.status !== 200) {\n            await handleErrorResponse(response);\n            return false;\n        }\n\n        clearLocalStorage()\n\n        return true;\n    }\n\n    function clearLocalStorage(): void {\n        selectedPayMethod.value = null;\n        invoiceAddress.value = emptyAddress();\n        sameShippingAddress.value = true;\n        shippingAddress.value = emptyAddress();\n        orderComment.value = \"\";\n        termsOfServiceAccepted.value = false;\n        newsletterAccepted.value = false;\n        couponCode.value = \"\";\n        selectedTimeFrame.value = null;\n        customerAge.value = new Date();\n        customerGender.value = CustomerGenders.None;\n        customerIban.value = \"\";\n    }\n\n    function isPostNLCheckoutMethod(): boolean {\n        return (\n            cart.value.checkout_method?.shipping_method.internal_name.toLowerCase() ===\n            \"postnl\"\n        );\n    }\n\n    function isPostNLPickupCheckoutMethod(): boolean {\n        return (\n            cart.value.checkout_method?.shipping_method.internal_name.toLowerCase() ===\n            \"postnlpickup\"\n        );\n    }\n\n    return {\n        // State\n        isPopoverOpened: computed(() => isPopoverOpened.value),\n        loadingCart: computed(() => loadingCart.value),\n        cart: computed(() => cart.value),\n        wrappingPaper: computed(() => wrappingPaper.value),\n        productCount,\n        checkoutCountries: computed(() => checkoutCountries.value),\n\n        giftWrapItems: computed(() => giftWrapItems.value),\n\n        shippingMethods: computed(() => shippingMethods.value),\n\n        paymentMethods: computed(() => paymentMethods.value),\n\n        selectedPayMethod: computed(() => selectedPayMethod.value),\n\n        selectedCountry: computed(() => selectedCountry.value),\n\n        selectedTimeFrame: computed(() => selectedTimeFrame.value),\n        isPostNLApiOnline: computed(() => postNLApiOnline.value),\n\n        invoiceAddress: invoiceAddress,\n        shippingAddress: shippingAddress,\n        sameShippingAddress: sameShippingAddress,\n        termsOfServiceAccepted,\n        newsletterAccepted,\n\n        orderComment: orderComment,\n\n        couponCode: couponCode,\n        age: customerAge,\n        gender: customerGender,\n        iban: customerIban,\n\n        // Actions\n        init: initCart,\n        openCart,\n        closeCart,\n        clearCart,\n        clearLocalStorage,\n\n        // Product actions\n        add,\n        remove,\n\n        // Wrapping paper actions\n        setWrappingPaper,\n        removeWrappingPaper,\n\n        // Coupon actions\n        addCoupon,\n        removeCoupon,\n\n        // Country actions\n        getCountries,\n        setCheckoutCountry,\n\n        // Checkout method actions\n        setCheckoutMethod,\n\n        // Address actions\n        getAddressAutocomplete,\n        saveAddresses,\n\n        // PostNL actions\n        getTimeFrames,\n        setTimeFrame,\n        getPickupPoints,\n        setPickupPoint,\n        isPostNLCheckoutMethod: computed(() => isPostNLCheckoutMethod()),\n        isPostNLPickupCheckoutMethod: computed(() =>\n            isPostNLPickupCheckoutMethod(),\n        ),\n\n        // Payment actions\n        setPaymentMethod,\n\n        createOrder,\n    };\n});\n\nexport const CustomerGenders = {\n    None: \"none\",\n    Male: \"male\",\n    Female: \"female\",\n} as const;\n\nexport type CustomerGenders =\n    (typeof CustomerGenders)[keyof typeof CustomerGenders];\n\nexport interface Product {\n    ID: string;\n    name: string;\n    quantity: number;\n    price: number;\n    original_price: number;\n    configuration_of: string | null;\n    attributes: Record<\n        string,\n        {\n            name: string;\n            value: string;\n        }\n    >;\n    image_url: string;\n}\n\ninterface Cart {\n    products: Product[];\n    coupon: CartCoupon | null;\n    checkout_method: CartCheckoutMethod | null;\n    wrapping_paper: CartWrappingPaper | null;\n    postnl_data: PostnlData | null;\n    country: CartCountry | null;\n    invoice_address: CartAddress | null;\n    shipping_address: CartAddress | null;\n    order_id: string | null;\n    total: number;\n}\n\ninterface CartCoupon {\n    ID: number;\n    name: string;\n    code: string;\n    discount: number;\n}\n\ninterface CartCheckoutMethod {\n    ID: string;\n    name: string;\n    price: number;\n    shipping_method: CartShippingMethod;\n    payment_method: CartPaymentMethod;\n}\n\ninterface CartWrappingPaper {\n    ID: string;\n    name: string;\n    image_url: string;\n    price: number;\n}\n\nexport interface CartCountry {\n    ID: string;\n    name: string;\n    short_code: string;\n    is_default: boolean;\n}\n\ninterface PostnlData {\n    type: \"postnl\" | \"postnl-pickup-point\";\n    pickup_point_address: any;\n    data: any;\n    price: number;\n}\n\ninterface PostnlTimeFrame {\n    label: string;\n    date: string;\n    option: string;\n    shipping_price: number;\n}\n\ninterface CartShippingMethod {\n    ID: string;\n    checkout_method_id: string;\n    name: string;\n    internal_name: string;\n}\n\nexport interface CartPaymentMethod {\n    checkout_method_id: string;\n    internalName: string;\n    name: string;\n    validateAge: boolean;\n    validateGender: boolean;\n    validateIban: boolean;\n}\n\nexport interface CartPaymentMethodOption {\n    ID: string;\n    name: string;\n}\n\nexport interface CartAddress {\n    first_name: string;\n    middle_name: string;\n    last_name: string;\n    company_name: string;\n    city: string;\n    street: string;\n    house_number: string;\n    house_number_addition: string;\n    zipcode: string;\n    phone_number: string;\n    email: string;\n}\n\ninterface CartAddressAutocomplete {\n    city: string;\n    house_number: string;\n    latitude: number;\n    longitude: number;\n    province: string;\n    province_code: string;\n    street: string;\n    zipcode: string;\n}\n\ninterface InsertOrderRequest {\n    iban: string;\n    internal_name: string;\n    checkoutMethod: string;\n    riverty: InsertOrderRivertyData | null;\n    subscribeNewsletter: boolean;\n    orderComment: string;\n}\n\ninterface InsertOrderRivertyData {\n    dobDay: number;\n    dobMonth: number;\n    dobYear: number;\n    gender: \"male\" | \"female\" | \"none\";\n}\n\ninterface PostnlPickupPoint {\n    city: string;\n    country_code: string;\n    house_number: string;\n    house_number_extension: string;\n    remark: string;\n    street: string;\n    zipcode: string;\n    distance: number;\n    delivery_options: string[];\n    latitude: number;\n    longitude: number;\n    location_code: string;\n    name: string;\n    opening_hours: OpeningHours;\n    partner_name: string;\n    phone_number: string;\n    retail_network_id: string;\n    saleschannel: string;\n    terminal_type: string;\n}\n\ninterface OpeningHours {\n    monday: string[];\n    tuesday: string[];\n    wednesday: string[];\n    thursday: string[];\n    friday: string[];\n    saturday: string[];\n    sunday: string[];\n}\n","export default \"__VITE_ASSET__5d08589e__\"","import { isReactive, isReadonly, computed, unref, ref, watch, isRef, reactive, nextTick, inject, provide, getCurrentInstance, onBeforeMount, onBeforeUnmount } from 'vue-demi';\n\nfunction ownKeys(object, enumerableOnly) {\n  var keys = Object.keys(object);\n\n  if (Object.getOwnPropertySymbols) {\n    var symbols = Object.getOwnPropertySymbols(object);\n    enumerableOnly && (symbols = symbols.filter(function (sym) {\n      return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n    })), keys.push.apply(keys, symbols);\n  }\n\n  return keys;\n}\n\nfunction _objectSpread2(target) {\n  for (var i = 1; i < arguments.length; i++) {\n    var source = null != arguments[i] ? arguments[i] : {};\n    i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {\n      _defineProperty(target, key, source[key]);\n    }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {\n      Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n    });\n  }\n\n  return target;\n}\n\nfunction _defineProperty(obj, key, value) {\n  if (key in obj) {\n    Object.defineProperty(obj, key, {\n      value: value,\n      enumerable: true,\n      configurable: true,\n      writable: true\n    });\n  } else {\n    obj[key] = value;\n  }\n\n  return obj;\n}\n\nfunction unwrapObj(obj) {\n  let ignoreKeys = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];\n  return Object.keys(obj).reduce((o, k) => {\n    if (ignoreKeys.includes(k)) return o;\n    o[k] = unref(obj[k]);\n    return o;\n  }, {});\n}\nfunction isFunction(val) {\n  return typeof val === 'function';\n}\nfunction isProxy(value) {\n  return isReactive(value) || isReadonly(value);\n}\nfunction get(obj, stringPath, def) {\n  let current = obj;\n  const path = stringPath.split('.');\n\n  for (let i = 0; i < path.length; i++) {\n    if (!current[path[i]]) return def;\n    current = current[path[i]];\n  }\n\n  return current;\n}\nfunction gatherBooleanGroupProperties(group, nestedResults, property) {\n  return computed(() => {\n    return group.some(path => {\n      return get(nestedResults, path, {\n        [property]: false\n      })[property];\n    });\n  });\n}\nfunction gatherArrayGroupProperties(group, nestedResults, property) {\n  return computed(() => {\n    return group.reduce((all, path) => {\n      const fetchedProperty = get(nestedResults, path, {\n        [property]: false\n      })[property] || [];\n      return all.concat(fetchedProperty);\n    }, []);\n  });\n}\n\nfunction callRule(rule, value, siblingState, instance) {\n  return rule.call(instance, unref(value), unref(siblingState), instance);\n}\n\nfunction normalizeValidatorResponse(result) {\n  return result.$valid !== undefined ? !result.$valid : !result;\n}\n\nfunction createAsyncResult(rule, model, $pending, $dirty, _ref, $response, instance) {\n  let {\n    $lazy,\n    $rewardEarly\n  } = _ref;\n  let watchTargets = arguments.length > 7 && arguments[7] !== undefined ? arguments[7] : [];\n  let siblingState = arguments.length > 8 ? arguments[8] : undefined;\n  let $lastInvalidState = arguments.length > 9 ? arguments[9] : undefined;\n  let $lastCommittedOn = arguments.length > 10 ? arguments[10] : undefined;\n  const $invalid = ref(!!$dirty.value);\n  const $pendingCounter = ref(0);\n  $pending.value = false;\n  const $unwatch = watch([model, $dirty].concat(watchTargets, $lastCommittedOn), () => {\n    if ($lazy && !$dirty.value || $rewardEarly && !$lastInvalidState.value && !$pending.value) {\n      return;\n    }\n\n    let ruleResult;\n\n    try {\n      ruleResult = callRule(rule, model, siblingState, instance);\n    } catch (err) {\n      ruleResult = Promise.reject(err);\n    }\n\n    $pendingCounter.value++;\n    $pending.value = !!$pendingCounter.value;\n    $invalid.value = false;\n    Promise.resolve(ruleResult).then(data => {\n      $pendingCounter.value--;\n      $pending.value = !!$pendingCounter.value;\n      $response.value = data;\n      $invalid.value = normalizeValidatorResponse(data);\n    }).catch(error => {\n      $pendingCounter.value--;\n      $pending.value = !!$pendingCounter.value;\n      $response.value = error;\n      $invalid.value = true;\n    });\n  }, {\n    immediate: true,\n    deep: typeof model === 'object'\n  });\n  return {\n    $invalid,\n    $unwatch\n  };\n}\n\nfunction createSyncResult(rule, model, $dirty, _ref2, $response, instance, siblingState, $lastInvalidState) {\n  let {\n    $lazy,\n    $rewardEarly\n  } = _ref2;\n\n  const $unwatch = () => ({});\n\n  const $invalid = computed(() => {\n    if ($lazy && !$dirty.value || $rewardEarly && !$lastInvalidState.value) {\n      return false;\n    }\n\n    let returnValue = true;\n\n    try {\n      const result = callRule(rule, model, siblingState, instance);\n      $response.value = result;\n      returnValue = normalizeValidatorResponse(result);\n    } catch (err) {\n      $response.value = err;\n    }\n\n    return returnValue;\n  });\n  return {\n    $unwatch,\n    $invalid\n  };\n}\n\nfunction createValidatorResult(rule, model, $dirty, config, instance, validatorName, propertyKey, propertyPath, siblingState, $lastInvalidState, $lastCommittedOn) {\n  const $pending = ref(false);\n  const $params = rule.$params || {};\n  const $response = ref(null);\n  let $invalid;\n  let $unwatch;\n\n  if (rule.$async) {\n    ({\n      $invalid,\n      $unwatch\n    } = createAsyncResult(rule.$validator, model, $pending, $dirty, config, $response, instance, rule.$watchTargets, siblingState, $lastInvalidState, $lastCommittedOn));\n  } else {\n    ({\n      $invalid,\n      $unwatch\n    } = createSyncResult(rule.$validator, model, $dirty, config, $response, instance, siblingState, $lastInvalidState));\n  }\n\n  const message = rule.$message;\n  const $message = isFunction(message) ? computed(() => message(unwrapObj({\n    $pending,\n    $invalid,\n    $params: unwrapObj($params),\n    $model: model,\n    $response,\n    $validator: validatorName,\n    $propertyPath: propertyPath,\n    $property: propertyKey\n  }))) : message || '';\n  return {\n    $message,\n    $params,\n    $pending,\n    $invalid,\n    $response,\n    $unwatch\n  };\n}\n\nfunction sortValidations() {\n  let validationsRaw = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n  const validations = unref(validationsRaw);\n  const validationKeys = Object.keys(validations);\n  const rules = {};\n  const nestedValidators = {};\n  const config = {};\n  let validationGroups = null;\n  validationKeys.forEach(key => {\n    const v = validations[key];\n\n    switch (true) {\n      case isFunction(v.$validator):\n        rules[key] = v;\n        break;\n\n      case isFunction(v):\n        rules[key] = {\n          $validator: v\n        };\n        break;\n\n      case key === '$validationGroups':\n        validationGroups = v;\n        break;\n\n      case key.startsWith('$'):\n        config[key] = v;\n        break;\n\n      default:\n        nestedValidators[key] = v;\n    }\n  });\n  return {\n    rules,\n    nestedValidators,\n    config,\n    validationGroups\n  };\n}\n\nconst ROOT_PATH = '__root';\n\nfunction createValidationResults(rules, model, key, resultsCache, path, config, instance, externalResults, siblingState) {\n  const ruleKeys = Object.keys(rules);\n  const cachedResult = resultsCache.get(path, rules);\n  const $dirty = ref(false);\n  const $lastInvalidState = ref(false);\n  const $lastCommittedOn = ref(0);\n\n  if (cachedResult) {\n    if (!cachedResult.$partial) return cachedResult;\n    cachedResult.$unwatch();\n    $dirty.value = cachedResult.$dirty.value;\n  }\n\n  const result = {\n    $dirty,\n    $path: path,\n    $touch: () => {\n      if (!$dirty.value) $dirty.value = true;\n    },\n    $reset: () => {\n      if ($dirty.value) $dirty.value = false;\n    },\n    $commit: () => {}\n  };\n\n  if (!ruleKeys.length) {\n    cachedResult && resultsCache.set(path, rules, result);\n    return result;\n  }\n\n  ruleKeys.forEach(ruleKey => {\n    result[ruleKey] = createValidatorResult(rules[ruleKey], model, result.$dirty, config, instance, ruleKey, key, path, siblingState, $lastInvalidState, $lastCommittedOn);\n  });\n  result.$externalResults = computed(() => {\n    if (!externalResults.value) return [];\n    return [].concat(externalResults.value).map((stringError, index) => ({\n      $propertyPath: path,\n      $property: key,\n      $validator: '$externalResults',\n      $uid: `${path}-externalResult-${index}`,\n      $message: stringError,\n      $params: {},\n      $response: null,\n      $pending: false\n    }));\n  });\n  result.$invalid = computed(() => {\n    const r = ruleKeys.some(ruleKey => unref(result[ruleKey].$invalid));\n    $lastInvalidState.value = r;\n    return !!result.$externalResults.value.length || r;\n  });\n  result.$pending = computed(() => ruleKeys.some(ruleKey => unref(result[ruleKey].$pending)));\n  result.$error = computed(() => result.$dirty.value ? result.$pending.value || result.$invalid.value : false);\n  result.$silentErrors = computed(() => ruleKeys.filter(ruleKey => unref(result[ruleKey].$invalid)).map(ruleKey => {\n    const res = result[ruleKey];\n    return reactive({\n      $propertyPath: path,\n      $property: key,\n      $validator: ruleKey,\n      $uid: `${path}-${ruleKey}`,\n      $message: res.$message,\n      $params: res.$params,\n      $response: res.$response,\n      $pending: res.$pending\n    });\n  }).concat(result.$externalResults.value));\n  result.$errors = computed(() => result.$dirty.value ? result.$silentErrors.value : []);\n\n  result.$unwatch = () => ruleKeys.forEach(ruleKey => {\n    result[ruleKey].$unwatch();\n  });\n\n  result.$commit = () => {\n    $lastInvalidState.value = true;\n    $lastCommittedOn.value = Date.now();\n  };\n\n  resultsCache.set(path, rules, result);\n  return result;\n}\n\nfunction collectNestedValidationResults(validations, nestedState, path, resultsCache, config, instance, nestedExternalResults) {\n  const nestedValidationKeys = Object.keys(validations);\n  if (!nestedValidationKeys.length) return {};\n  return nestedValidationKeys.reduce((results, nestedKey) => {\n    results[nestedKey] = setValidations({\n      validations: validations[nestedKey],\n      state: nestedState,\n      key: nestedKey,\n      parentKey: path,\n      resultsCache,\n      globalConfig: config,\n      instance,\n      externalResults: nestedExternalResults\n    });\n    return results;\n  }, {});\n}\n\nfunction createMetaFields(results, nestedResults, childResults) {\n  const allResults = computed(() => [nestedResults, childResults].filter(res => res).reduce((allRes, res) => {\n    return allRes.concat(Object.values(unref(res)));\n  }, []));\n  const $dirty = computed({\n    get() {\n      return results.$dirty.value || (allResults.value.length ? allResults.value.every(r => r.$dirty) : false);\n    },\n\n    set(v) {\n      results.$dirty.value = v;\n    }\n\n  });\n  const $silentErrors = computed(() => {\n    const modelErrors = unref(results.$silentErrors) || [];\n    const nestedErrors = allResults.value.filter(result => (unref(result).$silentErrors || []).length).reduce((errors, result) => {\n      return errors.concat(...result.$silentErrors);\n    }, []);\n    return modelErrors.concat(nestedErrors);\n  });\n  const $errors = computed(() => {\n    const modelErrors = unref(results.$errors) || [];\n    const nestedErrors = allResults.value.filter(result => (unref(result).$errors || []).length).reduce((errors, result) => {\n      return errors.concat(...result.$errors);\n    }, []);\n    return modelErrors.concat(nestedErrors);\n  });\n  const $invalid = computed(() => allResults.value.some(r => r.$invalid) || unref(results.$invalid) || false);\n  const $pending = computed(() => allResults.value.some(r => unref(r.$pending)) || unref(results.$pending) || false);\n  const $anyDirty = computed(() => allResults.value.some(r => r.$dirty) || allResults.value.some(r => r.$anyDirty) || $dirty.value);\n  const $error = computed(() => $dirty.value ? $pending.value || $invalid.value : false);\n\n  const $touch = () => {\n    results.$touch();\n    allResults.value.forEach(result => {\n      result.$touch();\n    });\n  };\n\n  const $commit = () => {\n    results.$commit();\n    allResults.value.forEach(result => {\n      result.$commit();\n    });\n  };\n\n  const $reset = () => {\n    results.$reset();\n    allResults.value.forEach(result => {\n      result.$reset();\n    });\n  };\n\n  if (allResults.value.length && allResults.value.every(nr => nr.$dirty)) $touch();\n  return {\n    $dirty,\n    $errors,\n    $invalid,\n    $anyDirty,\n    $error,\n    $pending,\n    $touch,\n    $reset,\n    $silentErrors,\n    $commit\n  };\n}\n\nfunction setValidations(_ref) {\n  let {\n    validations,\n    state,\n    key,\n    parentKey,\n    childResults,\n    resultsCache,\n    globalConfig = {},\n    instance,\n    externalResults\n  } = _ref;\n  const path = parentKey ? `${parentKey}.${key}` : key;\n  const {\n    rules,\n    nestedValidators,\n    config,\n    validationGroups\n  } = sortValidations(validations);\n\n  const mergedConfig = _objectSpread2(_objectSpread2({}, globalConfig), config);\n\n  const nestedState = key ? computed(() => {\n    const s = unref(state);\n    return s ? unref(s[key]) : undefined;\n  }) : state;\n\n  const cachedExternalResults = _objectSpread2({}, unref(externalResults) || {});\n\n  const nestedExternalResults = computed(() => {\n    const results = unref(externalResults);\n    if (!key) return results;\n    return results ? unref(results[key]) : undefined;\n  });\n  const results = createValidationResults(rules, nestedState, key, resultsCache, path, mergedConfig, instance, nestedExternalResults, state);\n  const nestedResults = collectNestedValidationResults(nestedValidators, nestedState, path, resultsCache, mergedConfig, instance, nestedExternalResults);\n  const $validationGroups = {};\n\n  if (validationGroups) {\n    Object.entries(validationGroups).forEach(_ref2 => {\n      let [key, group] = _ref2;\n      $validationGroups[key] = {\n        $invalid: gatherBooleanGroupProperties(group, nestedResults, '$invalid'),\n        $error: gatherBooleanGroupProperties(group, nestedResults, '$error'),\n        $pending: gatherBooleanGroupProperties(group, nestedResults, '$pending'),\n        $errors: gatherArrayGroupProperties(group, nestedResults, '$errors'),\n        $silentErrors: gatherArrayGroupProperties(group, nestedResults, '$silentErrors')\n      };\n    });\n  }\n\n  const {\n    $dirty,\n    $errors,\n    $invalid,\n    $anyDirty,\n    $error,\n    $pending,\n    $touch,\n    $reset,\n    $silentErrors,\n    $commit\n  } = createMetaFields(results, nestedResults, childResults);\n  const $model = key ? computed({\n    get: () => unref(nestedState),\n    set: val => {\n      $dirty.value = true;\n      const s = unref(state);\n      const external = unref(externalResults);\n\n      if (external) {\n        external[key] = cachedExternalResults[key];\n      }\n\n      if (isRef(s[key])) {\n        s[key].value = val;\n      } else {\n        s[key] = val;\n      }\n    }\n  }) : null;\n\n  if (key && mergedConfig.$autoDirty) {\n    watch(nestedState, () => {\n      if (!$dirty.value) $touch();\n      const external = unref(externalResults);\n\n      if (external) {\n        external[key] = cachedExternalResults[key];\n      }\n    }, {\n      flush: 'sync'\n    });\n  }\n\n  async function $validate() {\n    $touch();\n\n    if (mergedConfig.$rewardEarly) {\n      $commit();\n      await nextTick();\n    }\n\n    await nextTick();\n    return new Promise(resolve => {\n      if (!$pending.value) return resolve(!$invalid.value);\n      const unwatch = watch($pending, () => {\n        resolve(!$invalid.value);\n        unwatch();\n      });\n    });\n  }\n\n  function $getResultsForChild(key) {\n    return (childResults.value || {})[key];\n  }\n\n  function $clearExternalResults() {\n    if (isRef(externalResults)) {\n      externalResults.value = cachedExternalResults;\n    } else {\n      if (Object.keys(cachedExternalResults).length === 0) {\n        Object.keys(externalResults).forEach(k => {\n          delete externalResults[k];\n        });\n      } else {\n        Object.assign(externalResults, cachedExternalResults);\n      }\n    }\n  }\n\n  return reactive(_objectSpread2(_objectSpread2(_objectSpread2({}, results), {}, {\n    $model,\n    $dirty,\n    $error,\n    $errors,\n    $invalid,\n    $anyDirty,\n    $pending,\n    $touch,\n    $reset,\n    $path: path || ROOT_PATH,\n    $silentErrors,\n    $validate,\n    $commit\n  }, childResults && {\n    $getResultsForChild,\n    $clearExternalResults,\n    $validationGroups\n  }), nestedResults));\n}\n\nclass ResultsStorage {\n  constructor() {\n    this.storage = new Map();\n  }\n\n  set(path, rules, result) {\n    this.storage.set(path, {\n      rules,\n      result\n    });\n  }\n\n  checkRulesValidity(path, rules, storedRules) {\n    const storedRulesKeys = Object.keys(storedRules);\n    const newRulesKeys = Object.keys(rules);\n    if (newRulesKeys.length !== storedRulesKeys.length) return false;\n    const hasAllValidators = newRulesKeys.every(ruleKey => storedRulesKeys.includes(ruleKey));\n    if (!hasAllValidators) return false;\n    return newRulesKeys.every(ruleKey => {\n      if (!rules[ruleKey].$params) return true;\n      return Object.keys(rules[ruleKey].$params).every(paramKey => {\n        return unref(storedRules[ruleKey].$params[paramKey]) === unref(rules[ruleKey].$params[paramKey]);\n      });\n    });\n  }\n\n  get(path, rules) {\n    const storedRuleResultPair = this.storage.get(path);\n    if (!storedRuleResultPair) return undefined;\n    const {\n      rules: storedRules,\n      result\n    } = storedRuleResultPair;\n    const isValidCache = this.checkRulesValidity(path, rules, storedRules);\n    const $unwatch = result.$unwatch ? result.$unwatch : () => ({});\n    if (!isValidCache) return {\n      $dirty: result.$dirty,\n      $partial: true,\n      $unwatch\n    };\n    return result;\n  }\n\n}\n\nconst CollectFlag = {\n  COLLECT_ALL: true,\n  COLLECT_NONE: false\n};\nconst VuelidateInjectChildResults = Symbol('vuelidate#injectChildResults');\nconst VuelidateRemoveChildResults = Symbol('vuelidate#removeChildResults');\nfunction nestedValidations(_ref) {\n  let {\n    $scope,\n    instance\n  } = _ref;\n  const childResultsRaw = {};\n  const childResultsKeys = ref([]);\n  const childResults = computed(() => childResultsKeys.value.reduce((results, key) => {\n    results[key] = unref(childResultsRaw[key]);\n    return results;\n  }, {}));\n\n  function injectChildResultsIntoParent(results, _ref2) {\n    let {\n      $registerAs: key,\n      $scope: childScope,\n      $stopPropagation\n    } = _ref2;\n    if ($stopPropagation || $scope === CollectFlag.COLLECT_NONE || childScope === CollectFlag.COLLECT_NONE || $scope !== CollectFlag.COLLECT_ALL && $scope !== childScope) return;\n    childResultsRaw[key] = results;\n    childResultsKeys.value.push(key);\n  }\n\n  instance.__vuelidateInjectInstances = [].concat(instance.__vuelidateInjectInstances || [], injectChildResultsIntoParent);\n\n  function removeChildResultsFromParent(key) {\n    childResultsKeys.value = childResultsKeys.value.filter(childKey => childKey !== key);\n    delete childResultsRaw[key];\n  }\n\n  instance.__vuelidateRemoveInstances = [].concat(instance.__vuelidateRemoveInstances || [], removeChildResultsFromParent);\n  const sendValidationResultsToParent = inject(VuelidateInjectChildResults, []);\n  provide(VuelidateInjectChildResults, instance.__vuelidateInjectInstances);\n  const removeValidationResultsFromParent = inject(VuelidateRemoveChildResults, []);\n  provide(VuelidateRemoveChildResults, instance.__vuelidateRemoveInstances);\n  return {\n    childResults,\n    sendValidationResultsToParent,\n    removeValidationResultsFromParent\n  };\n}\n\nfunction ComputedProxyFactory(target) {\n  return new Proxy(target, {\n    get(target, prop) {\n      return typeof target[prop] === 'object' ? ComputedProxyFactory(target[prop]) : computed(() => target[prop]);\n    }\n\n  });\n}\n\nlet uid = 0;\nfunction useVuelidate(validations, state) {\n  var _getCurrentInstance;\n\n  let globalConfig = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n\n  if (arguments.length === 1) {\n    globalConfig = validations;\n    validations = undefined;\n    state = undefined;\n  }\n\n  let {\n    $registerAs,\n    $scope = CollectFlag.COLLECT_ALL,\n    $stopPropagation,\n    $externalResults,\n    currentVueInstance\n  } = globalConfig;\n  const instance = currentVueInstance || ((_getCurrentInstance = getCurrentInstance()) === null || _getCurrentInstance === void 0 ? void 0 : _getCurrentInstance.proxy);\n  const componentOptions = instance ? instance.$options : {};\n\n  if (!$registerAs) {\n    uid += 1;\n    $registerAs = `_vuelidate_${uid}`;\n  }\n\n  const validationResults = ref({});\n  const resultsCache = new ResultsStorage();\n  const {\n    childResults,\n    sendValidationResultsToParent,\n    removeValidationResultsFromParent\n  } = instance ? nestedValidations({\n    $scope,\n    instance\n  }) : {\n    childResults: ref({})\n  };\n\n  if (!validations && componentOptions.validations) {\n    const rules = componentOptions.validations;\n    state = ref({});\n    onBeforeMount(() => {\n      state.value = instance;\n      watch(() => isFunction(rules) ? rules.call(state.value, new ComputedProxyFactory(state.value)) : rules, validations => {\n        validationResults.value = setValidations({\n          validations,\n          state,\n          childResults,\n          resultsCache,\n          globalConfig,\n          instance,\n          externalResults: $externalResults || instance.vuelidateExternalResults\n        });\n      }, {\n        immediate: true\n      });\n    });\n    globalConfig = componentOptions.validationsConfig || globalConfig;\n  } else {\n    const validationsWatchTarget = isRef(validations) || isProxy(validations) ? validations : reactive(validations || {});\n    watch(validationsWatchTarget, newValidationRules => {\n      validationResults.value = setValidations({\n        validations: newValidationRules,\n        state,\n        childResults,\n        resultsCache,\n        globalConfig,\n        instance: instance !== null && instance !== void 0 ? instance : {},\n        externalResults: $externalResults\n      });\n    }, {\n      immediate: true\n    });\n  }\n\n  if (instance) {\n    sendValidationResultsToParent.forEach(f => f(validationResults, {\n      $registerAs,\n      $scope,\n      $stopPropagation\n    }));\n    onBeforeUnmount(() => removeValidationResultsFromParent.forEach(f => f($registerAs)));\n  }\n\n  return computed(() => {\n    return _objectSpread2(_objectSpread2({}, unref(validationResults.value)), childResults.value);\n  });\n}\n\nexport { CollectFlag, useVuelidate as default, useVuelidate };\n","import { unref } from 'vue-demi';\n\nfunction ownKeys(object, enumerableOnly) {\n  var keys = Object.keys(object);\n\n  if (Object.getOwnPropertySymbols) {\n    var symbols = Object.getOwnPropertySymbols(object);\n    enumerableOnly && (symbols = symbols.filter(function (sym) {\n      return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n    })), keys.push.apply(keys, symbols);\n  }\n\n  return keys;\n}\n\nfunction _objectSpread2(target) {\n  for (var i = 1; i < arguments.length; i++) {\n    var source = null != arguments[i] ? arguments[i] : {};\n    i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {\n      _defineProperty(target, key, source[key]);\n    }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {\n      Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n    });\n  }\n\n  return target;\n}\n\nfunction _defineProperty(obj, key, value) {\n  if (key in obj) {\n    Object.defineProperty(obj, key, {\n      value: value,\n      enumerable: true,\n      configurable: true,\n      writable: true\n    });\n  } else {\n    obj[key] = value;\n  }\n\n  return obj;\n}\n\nfunction isFunction(val) {\n  return typeof val === 'function';\n}\nfunction isObject(o) {\n  return o !== null && typeof o === 'object' && !Array.isArray(o);\n}\nfunction normalizeValidatorObject(validator) {\n  return isFunction(validator.$validator) ? _objectSpread2({}, validator) : {\n    $validator: validator\n  };\n}\nfunction isPromise(object) {\n  return isObject(object) && isFunction(object.then);\n}\nfunction unwrapValidatorResponse(result) {\n  if (typeof result === 'object') return result.$valid;\n  return result;\n}\nfunction unwrapNormalizedValidator(validator) {\n  return validator.$validator || validator;\n}\n\nfunction withParams($params, $validator) {\n  if (!isObject($params)) throw new Error(`[@vuelidate/validators]: First parameter to \"withParams\" should be an object, provided ${typeof $params}`);\n  if (!isObject($validator) && !isFunction($validator)) throw new Error(`[@vuelidate/validators]: Validator must be a function or object with $validator parameter`);\n  const validatorObj = normalizeValidatorObject($validator);\n  validatorObj.$params = _objectSpread2(_objectSpread2({}, validatorObj.$params || {}), $params);\n  return validatorObj;\n}\n\nfunction withMessage($message, $validator) {\n  if (!isFunction($message) && typeof unref($message) !== 'string') throw new Error(`[@vuelidate/validators]: First parameter to \"withMessage\" should be string or a function returning a string, provided ${typeof $message}`);\n  if (!isObject($validator) && !isFunction($validator)) throw new Error(`[@vuelidate/validators]: Validator must be a function or object with $validator parameter`);\n  const validatorObj = normalizeValidatorObject($validator);\n  validatorObj.$message = $message;\n  return validatorObj;\n}\n\nfunction withAsync($validator) {\n  let $watchTargets = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];\n  const validatorObj = normalizeValidatorObject($validator);\n  return _objectSpread2(_objectSpread2({}, validatorObj), {}, {\n    $async: true,\n    $watchTargets\n  });\n}\n\nfunction forEach(validators) {\n  return {\n    $validator(collection) {\n      for (var _len = arguments.length, others = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n        others[_key - 1] = arguments[_key];\n      }\n\n      return unref(collection).reduce((previous, collectionItem, index) => {\n        const collectionEntryResult = Object.entries(collectionItem).reduce((all, _ref) => {\n          let [property, $model] = _ref;\n          const innerValidators = validators[property] || {};\n          const propertyResult = Object.entries(innerValidators).reduce((all, _ref2) => {\n            let [validatorName, currentValidator] = _ref2;\n            const validatorFunction = unwrapNormalizedValidator(currentValidator);\n            const $response = validatorFunction.call(this, $model, collectionItem, index, ...others);\n            const $valid = unwrapValidatorResponse($response);\n            all.$data[validatorName] = $response;\n            all.$data.$invalid = !$valid || !!all.$data.$invalid;\n            all.$data.$error = all.$data.$invalid;\n\n            if (!$valid) {\n              let $message = currentValidator.$message || '';\n              const $params = currentValidator.$params || {};\n\n              if (typeof $message === 'function') {\n                $message = $message({\n                  $pending: false,\n                  $invalid: !$valid,\n                  $params,\n                  $model,\n                  $response\n                });\n              }\n\n              all.$errors.push({\n                $property: property,\n                $message,\n                $params,\n                $response,\n                $model,\n                $pending: false,\n                $validator: validatorName\n              });\n            }\n\n            return {\n              $valid: all.$valid && $valid,\n              $data: all.$data,\n              $errors: all.$errors\n            };\n          }, {\n            $valid: true,\n            $data: {},\n            $errors: []\n          });\n          all.$data[property] = propertyResult.$data;\n          all.$errors[property] = propertyResult.$errors;\n          return {\n            $valid: all.$valid && propertyResult.$valid,\n            $data: all.$data,\n            $errors: all.$errors\n          };\n        }, {\n          $valid: true,\n          $data: {},\n          $errors: {}\n        });\n        return {\n          $valid: previous.$valid && collectionEntryResult.$valid,\n          $data: previous.$data.concat(collectionEntryResult.$data),\n          $errors: previous.$errors.concat(collectionEntryResult.$errors)\n        };\n      }, {\n        $valid: true,\n        $data: [],\n        $errors: []\n      });\n    },\n\n    $message: _ref3 => {\n      let {\n        $response\n      } = _ref3;\n      return $response ? $response.$errors.map(context => {\n        return Object.values(context).map(errors => errors.map(error => error.$message)).reduce((a, b) => a.concat(b), []);\n      }) : [];\n    }\n  };\n}\n\nconst req = value => {\n  value = unref(value);\n  if (Array.isArray(value)) return !!value.length;\n\n  if (value === undefined || value === null) {\n    return false;\n  }\n\n  if (value === false) {\n    return true;\n  }\n\n  if (value instanceof Date) {\n    return !isNaN(value.getTime());\n  }\n\n  if (typeof value === 'object') {\n    for (let _ in value) return true;\n\n    return false;\n  }\n\n  return !!String(value).length;\n};\nconst len = value => {\n  value = unref(value);\n  if (Array.isArray(value)) return value.length;\n\n  if (typeof value === 'object') {\n    return Object.keys(value).length;\n  }\n\n  return String(value).length;\n};\nfunction regex() {\n  for (var _len = arguments.length, expr = new Array(_len), _key = 0; _key < _len; _key++) {\n    expr[_key] = arguments[_key];\n  }\n\n  return value => {\n    value = unref(value);\n    return !req(value) || expr.every(reg => {\n      reg.lastIndex = 0;\n      return reg.test(value);\n    });\n  };\n}\n\nvar common = /*#__PURE__*/Object.freeze({\n  __proto__: null,\n  forEach: forEach,\n  len: len,\n  normalizeValidatorObject: normalizeValidatorObject,\n  regex: regex,\n  req: req,\n  unwrap: unref,\n  unwrapNormalizedValidator: unwrapNormalizedValidator,\n  unwrapValidatorResponse: unwrapValidatorResponse,\n  withAsync: withAsync,\n  withMessage: withMessage,\n  withParams: withParams\n});\n\nvar alpha$1 = regex(/^[a-zA-Z]*$/);\n\nvar alpha = {\n  $validator: alpha$1,\n  $message: 'The value is not alphabetical',\n  $params: {\n    type: 'alpha'\n  }\n};\n\nvar alphaNum$1 = regex(/^[a-zA-Z0-9]*$/);\n\nvar alphaNum = {\n  $validator: alphaNum$1,\n  $message: 'The value must be alpha-numeric',\n  $params: {\n    type: 'alphaNum'\n  }\n};\n\nvar numeric$1 = regex(/^\\d*(\\.\\d+)?$/);\n\nvar numeric = {\n  $validator: numeric$1,\n  $message: 'Value must be numeric',\n  $params: {\n    type: 'numeric'\n  }\n};\n\nfunction between$1 (min, max) {\n  return value => !req(value) || (!/\\s/.test(value) || value instanceof Date) && +unref(min) <= +value && +unref(max) >= +value;\n}\n\nfunction between (min, max) {\n  return {\n    $validator: between$1(min, max),\n    $message: _ref => {\n      let {\n        $params\n      } = _ref;\n      return `The value must be between ${$params.min} and ${$params.max}`;\n    },\n    $params: {\n      min,\n      max,\n      type: 'between'\n    }\n  };\n}\n\nconst emailRegex = /^(?:[A-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\.[A-z0-9!#$%&'*+/=?^_`{|}~-]+)*|\"(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21\\x23-\\x5b\\x5d-\\x7f]|[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])*\")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9]{2,}(?:[a-z0-9-]*[a-z0-9])?|\\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21-\\x5a\\x53-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])+)\\])$/i;\nvar email$1 = regex(emailRegex);\n\nvar email = {\n  $validator: email$1,\n  $message: 'Value is not a valid email address',\n  $params: {\n    type: 'email'\n  }\n};\n\nfunction ipAddress$1 (value) {\n  if (!req(value)) {\n    return true;\n  }\n\n  if (typeof value !== 'string') {\n    return false;\n  }\n\n  const nibbles = value.split('.');\n  return nibbles.length === 4 && nibbles.every(nibbleValid);\n}\n\nconst nibbleValid = nibble => {\n  if (nibble.length > 3 || nibble.length === 0) {\n    return false;\n  }\n\n  if (nibble[0] === '0' && nibble !== '0') {\n    return false;\n  }\n\n  if (!nibble.match(/^\\d+$/)) {\n    return false;\n  }\n\n  const numeric = +nibble | 0;\n  return numeric >= 0 && numeric <= 255;\n};\n\nvar ipAddress = {\n  $validator: ipAddress$1,\n  $message: 'The value is not a valid IP address',\n  $params: {\n    type: 'ipAddress'\n  }\n};\n\nfunction macAddress$1 () {\n  let separator = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ':';\n  return value => {\n    separator = unref(separator);\n\n    if (!req(value)) {\n      return true;\n    }\n\n    if (typeof value !== 'string') {\n      return false;\n    }\n\n    const parts = typeof separator === 'string' && separator !== '' ? value.split(separator) : value.length === 12 || value.length === 16 ? value.match(/.{2}/g) : null;\n    return parts !== null && (parts.length === 6 || parts.length === 8) && parts.every(hexValid);\n  };\n}\n\nconst hexValid = hex => hex.toLowerCase().match(/^[0-9a-f]{2}$/);\n\nfunction macAddress (separator) {\n  return {\n    $validator: macAddress$1(separator),\n    $message: 'The value is not a valid MAC Address',\n    $params: {\n      type: 'macAddress'\n    }\n  };\n}\n\nfunction maxLength$1 (length) {\n  return value => !req(value) || len(value) <= unref(length);\n}\n\nfunction maxLength (max) {\n  return {\n    $validator: maxLength$1(max),\n    $message: _ref => {\n      let {\n        $params\n      } = _ref;\n      return `The maximum length allowed is ${$params.max}`;\n    },\n    $params: {\n      max,\n      type: 'maxLength'\n    }\n  };\n}\n\nfunction minLength$1 (length) {\n  return value => !req(value) || len(value) >= unref(length);\n}\n\nfunction minLength (min) {\n  return {\n    $validator: minLength$1(min),\n    $message: _ref => {\n      let {\n        $params\n      } = _ref;\n      return `This field should be at least ${$params.min} characters long`;\n    },\n    $params: {\n      min,\n      type: 'minLength'\n    }\n  };\n}\n\nfunction required$1 (value) {\n  if (typeof value === 'string') {\n    value = value.trim();\n  }\n\n  return req(value);\n}\n\nvar required = {\n  $validator: required$1,\n  $message: 'Value is required',\n  $params: {\n    type: 'required'\n  }\n};\n\nconst validate$1 = (prop, val) => prop ? req(typeof val === 'string' ? val.trim() : val) : true;\n\nfunction requiredIf$1(propOrFunction) {\n  return function (value, parentVM) {\n    if (typeof propOrFunction !== 'function') {\n      return validate$1(unref(propOrFunction), value);\n    }\n\n    const result = propOrFunction.call(this, value, parentVM);\n    return validate$1(result, value);\n  };\n}\n\nfunction requiredIf (prop) {\n  return {\n    $validator: requiredIf$1(prop),\n    $message: 'The value is required',\n    $params: {\n      type: 'requiredIf',\n      prop\n    }\n  };\n}\n\nconst validate = (prop, val) => !prop ? req(typeof val === 'string' ? val.trim() : val) : true;\n\nfunction requiredUnless$1(propOrFunction) {\n  return function (value, parentVM) {\n    if (typeof propOrFunction !== 'function') {\n      return validate(unref(propOrFunction), value);\n    }\n\n    const result = propOrFunction.call(this, value, parentVM);\n    return validate(result, value);\n  };\n}\n\nfunction requiredUnless (prop) {\n  return {\n    $validator: requiredUnless$1(prop),\n    $message: 'The value is required',\n    $params: {\n      type: 'requiredUnless',\n      prop\n    }\n  };\n}\n\nfunction sameAs$1 (equalTo) {\n  return value => unref(value) === unref(equalTo);\n}\n\nfunction sameAs (equalTo) {\n  let otherName = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'other';\n  return {\n    $validator: sameAs$1(equalTo),\n    $message: _ref => {\n      return `The value must be equal to the ${otherName} value`;\n    },\n    $params: {\n      equalTo,\n      otherName,\n      type: 'sameAs'\n    }\n  };\n}\n\nconst urlRegex = /^(?:(?:(?:https?|ftp):)?\\/\\/)(?:\\S+(?::\\S*)?@)?(?:(?!(?:10|127)(?:\\.\\d{1,3}){3})(?!(?:169\\.254|192\\.168)(?:\\.\\d{1,3}){2})(?!172\\.(?:1[6-9]|2\\d|3[0-1])(?:\\.\\d{1,3}){2})(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[1-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z0-9\\u00a1-\\uffff][a-z0-9\\u00a1-\\uffff_-]{0,62})?[a-z0-9\\u00a1-\\uffff]\\.)+(?:[a-z\\u00a1-\\uffff]{2,}\\.?))(?::\\d{2,5})?(?:[/?#]\\S*)?$/i;\nvar url$1 = regex(urlRegex);\n\nvar url = {\n  $validator: url$1,\n  $message: 'The value is not a valid URL address',\n  $params: {\n    type: 'url'\n  }\n};\n\nfunction syncOr(validators) {\n  return function () {\n    for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n      args[_key] = arguments[_key];\n    }\n\n    return validators.reduce((valid, fn) => {\n      if (unwrapValidatorResponse(valid)) return valid;\n      return unwrapNormalizedValidator(fn).apply(this, args);\n    }, false);\n  };\n}\n\nfunction asyncOr(validators) {\n  return function () {\n    for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n      args[_key2] = arguments[_key2];\n    }\n\n    return validators.reduce(async (valid, fn) => {\n      const r = await valid;\n      if (unwrapValidatorResponse(r)) return r;\n      return unwrapNormalizedValidator(fn).apply(this, args);\n    }, Promise.resolve(false));\n  };\n}\n\nfunction or$1() {\n  for (var _len3 = arguments.length, validators = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {\n    validators[_key3] = arguments[_key3];\n  }\n\n  const $async = validators.some(v => v.$async);\n  const $watchTargets = validators.reduce((all, v) => {\n    if (!v.$watchTargets) return all;\n    return all.concat(v.$watchTargets);\n  }, []);\n\n  let $validator = () => false;\n\n  if (validators.length) $validator = $async ? asyncOr(validators) : syncOr(validators);\n  return {\n    $async,\n    $validator,\n    $watchTargets\n  };\n}\n\nfunction or () {\n  return withParams({\n    type: 'or'\n  }, withMessage('The value does not match any of the provided validators', or$1(...arguments)));\n}\n\nfunction syncAnd(validators) {\n  return function () {\n    for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n      args[_key] = arguments[_key];\n    }\n\n    return validators.reduce((valid, fn) => {\n      if (!unwrapValidatorResponse(valid)) return valid;\n      return unwrapNormalizedValidator(fn).apply(this, args);\n    }, true);\n  };\n}\n\nfunction asyncAnd(validators) {\n  return function () {\n    for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n      args[_key2] = arguments[_key2];\n    }\n\n    return validators.reduce(async (valid, fn) => {\n      const r = await valid;\n      if (!unwrapValidatorResponse(r)) return r;\n      return unwrapNormalizedValidator(fn).apply(this, args);\n    }, Promise.resolve(true));\n  };\n}\n\nfunction and$1() {\n  for (var _len3 = arguments.length, validators = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {\n    validators[_key3] = arguments[_key3];\n  }\n\n  const $async = validators.some(v => v.$async);\n  const $watchTargets = validators.reduce((all, v) => {\n    if (!v.$watchTargets) return all;\n    return all.concat(v.$watchTargets);\n  }, []);\n\n  let $validator = () => false;\n\n  if (validators.length) $validator = $async ? asyncAnd(validators) : syncAnd(validators);\n  return {\n    $async,\n    $validator,\n    $watchTargets\n  };\n}\n\nfunction and () {\n  return withParams({\n    type: 'and'\n  }, withMessage('The value does not match all of the provided validators', and$1(...arguments)));\n}\n\nfunction not$1 (validator) {\n  return function (value, vm) {\n    if (!req(value)) return true;\n    const response = unwrapNormalizedValidator(validator).call(this, value, vm);\n    if (!isPromise(response)) return !unwrapValidatorResponse(response);\n    return response.then(r => !unwrapValidatorResponse(r));\n  };\n}\n\nfunction not (validator) {\n  return {\n    $validator: not$1(validator),\n    $message: `The value does not match the provided validator`,\n    $params: {\n      type: 'not'\n    }\n  };\n}\n\nfunction minValue$1 (min) {\n  return value => !req(value) || (!/\\s/.test(value) || value instanceof Date) && +value >= +unref(min);\n}\n\nfunction minValue (min) {\n  return {\n    $validator: minValue$1(min),\n    $message: _ref => {\n      let {\n        $params\n      } = _ref;\n      return `The minimum value allowed is ${$params.min}`;\n    },\n    $params: {\n      min,\n      type: 'minValue'\n    }\n  };\n}\n\nfunction maxValue$1 (max) {\n  return value => !req(value) || (!/\\s/.test(value) || value instanceof Date) && +value <= +unref(max);\n}\n\nvar maxValue = (max => ({\n  $validator: maxValue$1(max),\n  $message: _ref => {\n    let {\n      $params\n    } = _ref;\n    return `The maximum value allowed is ${$params.max}`;\n  },\n  $params: {\n    max,\n    type: 'maxValue'\n  }\n}));\n\nvar integer$1 = regex(/(^[0-9]*$)|(^-[0-9]+$)/);\n\nvar integer = {\n  $validator: integer$1,\n  $message: 'Value is not an integer',\n  $params: {\n    type: 'integer'\n  }\n};\n\nvar decimal$1 = regex(/^[-]?\\d*(\\.\\d+)?$/);\n\nvar decimal = {\n  $validator: decimal$1,\n  $message: 'Value must be decimal',\n  $params: {\n    type: 'decimal'\n  }\n};\n\nfunction createI18nMessage(_ref) {\n  let {\n    t,\n    messagePath = _ref2 => {\n      let {\n        $validator\n      } = _ref2;\n      return `validations.${$validator}`;\n    },\n    messageParams = params => params\n  } = _ref;\n  return function withI18nMessage(validator) {\n    let {\n      withArguments = false,\n      messagePath: localMessagePath = messagePath,\n      messageParams: localMessageParams = messageParams\n    } = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n\n    function message(props) {\n      return t(localMessagePath(props), localMessageParams(_objectSpread2({\n        model: props.$model,\n        property: props.$property,\n        pending: props.$pending,\n        invalid: props.$invalid,\n        response: props.$response,\n        validator: props.$validator,\n        propertyPath: props.$propertyPath\n      }, props.$params)));\n    }\n\n    if (withArguments && typeof validator === 'function') {\n      return function () {\n        return withMessage(message, validator(...arguments));\n      };\n    }\n\n    return withMessage(message, validator);\n  };\n}\n\nexport { alpha, alphaNum, and, between, createI18nMessage, decimal, email, common as helpers, integer, ipAddress, macAddress, maxLength, maxValue, minLength, minValue, not, numeric, or, required, requiredIf, requiredUnless, sameAs, url };\n","import { ValidationArgs, ValidationRule, ValidationRuleWithoutParams, ValidationRuleWithParams } from '@vuelidate/core'\nimport {\n    alpha as alphaImport,\n    alphaNum as alphaNumImport,\n    and as andImport,\n    between as betweenImport,\n    decimal as decimalImport,\n    email as emailImport,\n    integer as integerImport,\n    ipAddress as ipAddressImport,\n    macAddress as macAddressImport,\n    not as notImport,\n    numeric as numericImport,\n    or as orImport,\n    requiredUnless as requiredUnlessImport,\n    sameAs as sameAsImport,\n    url as urlImport,\n    minLength as minLengthImport,\n    minValue as minValueImport,\n    maxLength as maxLengthImport,\n    maxValue as maxValueImport,\n    required as requiredImport,\n    requiredIf as requiredIfImport,\n    helpers as helpersImport,\n    MessageProps,\n} from '@vuelidate/validators'\nimport { Ref } from 'vue'\nimport i18n from '../i18n'\n\nconst { t } = i18n.global\n\nexport const alpha: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.alpha'), alphaImport)\n\nexport const alphaNum: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.alpha-num'), alphaNumImport)\n\nexport const and: <T = unknown>(\n    ...validators: ValidationRule<T>[]\n) => ValidationRuleWithoutParams = andImport\n\nexport const between: (\n    min: number | Ref<number>,\n    max: number | Ref<number>\n) => ValidationRuleWithParams = (min, max) => helpersImport.withMessage(({\n    $pending,\n    $invalid,\n    $params,\n    $model,\n}) => {\n    return t('forms.errors.between', { min: $params.min, max: $params.max })\n}, betweenImport(min, max))\n\nexport const regex: (pattern: any) => ValidationRuleWithoutParams | ValidationRuleWithParams = (pattern) => helpersImport.withMessage(t('forms.errors.regex', { pattern: pattern }), helpersImport.regex(pattern))\n\nexport const decimal: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.decimal'), decimalImport)\n\nexport const email: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.email'), emailImport)\n\nexport const integer: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.integer'), integerImport)\n\nexport const ipAddress: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.ip-address'), ipAddressImport)\n\nexport const color: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.color'), helpersImport.regex(/#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/))\n\nexport const macAddress: (separator: string | Ref<string>) => ValidationRuleWithoutParams | ValidationRuleWithParams =\n    (separator) => helpersImport.withMessage(() => {\n        return t('forms.errors.mac-address')\n    }, macAddressImport(separator))\n\nexport const maxLength: (max: number | Ref<number>) => ValidationRuleWithParams =\n    (max) => helpersImport.withMessage(({\n        $pending,\n        $invalid,\n        $params,\n        $model,\n    }) => {\n        return t('forms.errors.max-length', { max: $params.max })\n    }, maxLengthImport(max))\n\nexport const maxValue: (\n    max: number | Ref<number> | string | Ref<string>) => ValidationRuleWithParams = (max) => helpersImport.withMessage(({\n        $pending,\n        $invalid,\n        $params,\n        $model,\n    }) => {\n        return t('forms.errors.max-value', { max: $params.max })\n    }, maxValueImport(max))\n\nexport const minLength: (min: number | Ref<number>) => ValidationRuleWithParams =\n    (min) => helpersImport.withMessage(({\n        $pending,\n        $invalid,\n        $params,\n        $model,\n    }) => {\n        return t('forms.errors.min-length', { min: $params.min })\n    }, minLengthImport(min))\n\nexport const minValue: (\n    min: number | Ref<number> | string | Ref<string>) => ValidationRuleWithParams = (min) => helpersImport.withMessage(({\n        $pending,\n        $invalid,\n        $params,\n        $model,\n    }) => {\n        return t('forms.errors.min-value', { min: $params.min })\n    }, minValueImport(min))\n\nexport const not: <T = unknown>(validator: ValidationRule<T>) => ValidationRuleWithoutParams | ValidationRuleWithParams = validator =>\n    helpersImport.withMessage(t('forms.errors.not'), notImport(validator))\n\nexport const numeric: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.numeric'), numericImport)\n\nexport const or: <T = unknown>(...validators: ValidationRule<T>[]) => ValidationRuleWithoutParams = orImport\n\nexport const required: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.required'), requiredImport)\n\nexport const requiredIf: (prop: boolean | Ref<boolean> | string | (() => boolean | Promise<boolean>)) => ValidationRuleWithoutParams | ValidationRuleWithParams =\n    (prop) => helpersImport.withMessage(() => {\n        return t('forms.errors.required')\n    }, requiredIfImport(prop))\n\nexport const requiredUnless: (prop: boolean | Ref<boolean> | string | (() => boolean | Promise<boolean>)) => ValidationRuleWithoutParams | ValidationRuleWithParams =\n    (prop) => helpersImport.withMessage(() => {\n        return t('forms.errors.required')\n    }, requiredUnlessImport(prop))\n\nexport const sameAs: <E = unknown>(equalTo: E | Ref<E>, otherName?: string) => ValidationRuleWithParams =\n    (equalTo, otherName) => helpersImport.withMessage(t('forms.errors.same-as'), sameAsImport(equalTo, otherName))\n\nexport const url: ValidationRuleWithoutParams | ValidationRuleWithParams = helpersImport.withMessage(t('forms.errors.url'), urlImport)\n\nexport const helpers: {\n    withParams: <T = unknown>(params: object, validator: ValidationRule<T>) => ValidationRuleWithParams\n    withMessage: <T = unknown>(message: string | ((params: MessageProps) => string), validator: ValidationRule<T>) => ValidationRuleWithParams\n    req: Function\n    len: Function\n    regex: Function\n    unwrap: Function\n    withAsync: Function,\n    forEach: (validators: ValidationArgs) => { $validator: ValidationRule, $message: () => string }\n} = helpersImport\n\nexport const unique = (param: Array<any>) => helpers.withMessage(t('forms.errors.unique'), uniqueCheck(param))\n\nfunction uniqueCheck(param: Array<any>) {\n    return helpers.withParams(\n        { type: 'array', value: param },\n        value => !helpers.req(value) || param.filter(element => element === value).length === 1,\n    )\n}","<template v-if=\"!cartStore.loadingCart\">\n  <div class=\"m-shipment__head\">\n    <h2 class=\"m-shipment__head-title a-h4\">\n      {{ t('cart.shipment.title') }}\n    </h2>\n    <span class=\"m-shipment__head-text\">\n      {{ t('cart.shipment.description') }}\n    </span>\n  </div>\n  <base-select type=\"checkout\" v-model=\"selectedCheckoutCountry\" @update:model-value=\"setCountry($event)\" :options=\"countries\" />\n  <fieldset class=\"m-shipment__methods\">\n    <legend class=\"u-screen-reader-only\">\n      {{ t('cart.shipment.description') }}\n    </legend>\n    <div class=\"m-shipment__method\"\n      :class=\"{ active: shippingMethod.ID.toString() === cartStore.cart.checkout_method?.shipping_method?.ID.toString() }\"\n      v-for=\"shippingMethod of cartStore.shippingMethods\">\n      <input type=\"radio\" :value=\"shippingMethod.ID\"\n        @change=\"cartStore.setCheckoutMethod(shippingMethod.checkout_method_id)\" name=\"shipping_method\"\n        :id=\"'shipping_' + shippingMethod.ID.toString() + selectedCheckoutCountry?.id\"\n        :checked=\"shippingMethod.ID.toString() === cartStore.cart.checkout_method?.shipping_method?.ID.toString()\" />\n      <label :for=\"'shipping_' + shippingMethod.ID.toString() + selectedCheckoutCountry?.id\">\n        <span class=\"m-shipment__method-title\">\n          {{ shippingMethod.name }}\n        </span>\n        <div class=\"m-shipment__method-details\"\n          v-if=\"shippingMethod.internal_name.toLowerCase() === 'postnl' && cartStore.selectedTimeFrame !== null\">\n          <span>\n            {{ cartStore.selectedTimeFrame?.label }}\n          </span>\n        </div>\n      </label>\n    </div>\n  </fieldset>\n\n  <a :href=\"generateRoute('checkout')\" class=\"m-shipment__btn a-btn a-btn--checkout\">\n    {{ t('cart.button.checkout') }}\n  </a>\n</template>\n\n<script setup lang=\"ts\">\nimport { Ref, computed, onMounted, ref, watch } from 'vue'\nimport { useCartStore } from '../../stores/cart'\nimport BaseSelect, { Option } from '../BaseSelect.vue'\nimport { useI18n } from 'vue-i18n'\nimport { generateRoute } from '../../helper-functions'\n\nconst { t } = useI18n()\nconst cartStore = useCartStore()\nconst selectedCheckoutCountry: Ref<Option | null> = ref(null)\nconst countries = computed(() => {\n  return cartStore.checkoutCountries.map(country => {\n    return {\n      id: country.ID,\n      label: country.name,\n    }\n  })\n})\n\nonMounted(async () => {\n  await cartStore.init()\n\n  updateSelectedValues()\n})\n\nwatch(() => cartStore.cart, () => {\n  updateSelectedValues()\n})\n\nfunction updateSelectedValues() {\n  if (cartStore.cart.country === null) {\n    return\n  }\n\n  selectedCheckoutCountry.value = {\n    id: cartStore.cart.country.ID,\n    label: cartStore.cart.country.name,\n  }\n}\n\nfunction setCountry(event: Option | null) {\n  if (event === null || event.id === cartStore.cart.country?.ID) {\n    return\n  }\n\n  cartStore.setCheckoutCountry(event.id)\n}\n</script>\n","<template>\n  <form class=\"m-checkout__coupons\">\n    <div class=\"m-cart__coupon-input\">\n      <input class=\"a-input\" :placeholder=\"t('cart.coupon.placeholder')\" v-model=\"cartStore.couponCode\" :disabled=\"cartStore.cart.coupon !== null\">\n      <button class=\"a-btn a-btn--cart\" type=\"button\" @click=\"cartStore.addCoupon(cartStore.couponCode)\" v-if=\"cartStore.cart.coupon === null\" >{{ t('cart.button.apply_coupon') }}</button>\n      <button v-if=\"cartStore.cart.coupon !== null\" class=\"a-btn a-btn--cart\" type=\"button\"\n        :title=\"t('cart.button.remove_coupon')\" @click=\"cartStore.removeCoupon()\">\n        <svg class=\"a-icon a-icon--close\" aria-hidden=\"true\">\n          <use href=\"#close\" />\n        </svg>\n      </button>\n    </div>\n  </form>\n</template>\n\n<script setup lang=\"ts\">\nimport { useI18n } from 'vue-i18n';\nimport { useCartStore } from '../../stores/cart';\nimport { onMounted } from 'vue';\n\nconst { t } = useI18n();\nconst cartStore = useCartStore()\n\nonMounted(async () => {\n  await cartStore.init()\n})\n</script>\n","<template>\n  <div class=\"m-cart__product-total\" v-if=\"!loading\">\n    <transition-group class=\"m-cart__products\" name=\"cart-list\" tag=\"ul\" aria-label=\"cart products\">\n      <li class=\"m-cart__product\" v-for=\"product in cartStore.cart.products\" :key=\"product.ID\">\n        <div class=\"m-cart__product-img\">\n          <!-- @TODO Fix images with correct sources padding-ratio alt and stuff -->\n          <picture class=\"a-image a-image--contain\" style=\"--padding-ratio: calc(1 / 1);\" v-if=\"product.image_url !== ''\">\n            <img class=\"a-image__img\"\n              width=\"100\" height=\"100\"\n              :src=\"product.image_url + '?width=5&height=5'\"\n              :data-src=\"product.image_url + '?width=100&height=100'\"\n              :alt=\"product.name\" loading=\"lazy\"/>\n          </picture>\n        </div>\n        <div class=\"m-cart__product-right\">\n          <div class=\"m-cart__product-info\">\n            <a href=\"#\" class=\"m-cart__product-title\">\n              {{ product.name }}\n            </a>\n            <span class=\"m-cart__product-size\" v-for=\"[name, attributeValue] of Object.entries(product.attributes)\">\n              {{ attributeValue.name }}: {{ attributeValue.value }}\n            </span>\n          </div>\n          <div class=\"m-cart__product-actions\">\n            <input class=\"m-cart__product-amount a-input a-input--amount\" type=\"number\" v-model=\"newCartQuantity[product.ID]\">\n            <button class=\"a-btn m-cart__product-delete\" type=\"button\" v-if=\"(newCartQuantity[product.ID] ?? 0) !== product.quantity\" @click=\"changeValue(product)\">\n              {{ t('cart.button.save') }}\n            </button>\n            <button class=\"a-btn m-cart__product-delete\" type=\"button\" @click=\"remove(product.ID)\">\n              {{ t('cart.button.delete') }}\n            </button>\n          </div>\n          <div class=\"m-cart__product-prices\">\n            <span class=\"m-cart__product-price m-cart__product-price--old\" v-if=\"product.price < product.original_price\">\n              {{ displayPrice(product.original_price) }}\n            </span>\n            <span class=\"m-cart__product-price\" :class=\"{ 'm-cart__product-price--sale': product.price < product.original_price }\">\n              {{ displayPrice(product.price) }}\n            </span>\n          </div>\n        </div>\n      </li>\n    </transition-group>\n    <transition v-if=\"!loading\">\n      <div class=\"m-cart__empty\" v-if=\"cartStore.cart.products.length <= 0\">\n        <span>\n          {{ translate('cart.empty.text') }}\n        </span>\n      </div>\n    </transition>\n\n    <div class=\"m-cart__bottom\" v-if=\"cartStore.cart.products.length > 0\">\n      <div class=\"m-cart__coupon\">\n        <span>\n          {{ t('cart.coupon.title') }}\n        </span>\n        <base-coupon />\n      </div>\n      <div class=\"m-cart__prices\">\n        <span class=\"m-cart__price\" v-if=\"cartStore.cart.postnl_data !== null && (cartStore.cart.postnl_data?.price ?? 0) > 0\">\n          {{ t('cart.postnl.title') }}\n          <span>\n            {{ displayPrice(cartStore.cart.postnl_data?.price ?? 0, t('checkout.price.free')) }}\n          </span>\n        </span>\n        <span class=\"m-cart__price\">\n          {{ cartStore.cart.checkout_method?.name }}\n          <span>\n            {{ displayPrice(cartStore.cart.checkout_method?.price ?? 0, t('checkout.price.free')) }}\n          </span>\n        </span>\n\n        <span class=\"m-cart__price\" v-if=\"cartStore.cart.coupon !== null\">\n          {{ t('cart.general.coupon_price.label', { code: cartStore.cart.coupon?.code }) }}\n          <span>\n            {{\n              displayPrice((cartStore.cart.coupon?.discount ?? 0) * -1) }}\n          </span>\n        </span>\n        <span class=\"m-cart__price\">\n          {{ t('cart.general.price_total') }}\n          <span>\n            {{ displayPrice(cartStore.cart.total ?? 0, t('checkout.price.free')) }}\n          </span>\n        </span>\n      </div>\n    </div>\n    <div class=\"m-cart__wrapping\" v-if=\"cartStore.cart.products.length > 0 && cartStore.giftWrapItems.length > 0\">\n      <span class=\"m-cart__wrapping-text\">\n        {{ t('cart.gift_wrap.description') }}\n      </span>\n      <fieldset class=\"m-cart__wrapping-fieldset\">\n        <legend class=\"u-screen-reader-only\">\n          {{ t('cart.gift_wrap.description') }}\n        </legend>\n        <div class=\"a-checkbox a-checkbox--wrapping\" v-for=\"giftWrapItem of cartStore.giftWrapItems\">\n          <input class=\"a-checkbox__input\" type=\"checkbox\" :name=\"giftWrapItem.name\" :value=\"giftWrapItem.ID\" :id=\"giftWrapItem.ID\" :checked=\"cartStore.cart.wrapping_paper?.ID === giftWrapItem.ID\" @click=\"toggleWrappingPaper(giftWrapItem.ID)\" />\n          <label class=\"a-checkbox__box\" :for=\"giftWrapItem.ID\">\n            <!-- @TODO Fix images with correct sources padding-ratio alt and stuff -->\n            <picture class=\"a-image a-image--contain\" style=\"--padding-bottom: calc(1/1)\">\n              <img class=\"a-image__image\"\n                :src=\"giftWrapItem.image_url + '?width=150&height=140'\"\n                :alt=\"giftWrapItem.name\" />\n            </picture>\n            <span class=\"a-checkbox__label\">\n              {{ giftWrapItem.name }}\n            </span>\n            <span class=\"a-checkbox__label\">\n              {{ displayPrice(giftWrapItem.price, t('checkout.price.free')) }}\n            </span>\n          </label>\n        </div>\n      </fieldset>\n      <div class=\"m-cart__wrapping-overview\" v-if=\"cartStore.cart.wrapping_paper\">\n        {{ t('cart.gift_wrap.selected_description') }} <strong>{{ cartStore.cart.wrapping_paper.name }}</strong>\n      </div>\n    </div>\n  </div>\n  <div v-else class=\"m-cart__product-total\">\n    <div class=\"m-cart__products\">\n      <div class=\"m-cart__product m-cart__product--skeleton\">\n        <div class=\"m-cart__product-img\">\n        </div>\n        <div class=\"m-cart__product-right\">\n          <div class=\"m-cart__product-info\">\n            <span class=\"m-cart__product-title\"></span>\n            <span class=\"m-cart__product-size\"></span>\n          </div>\n          <div class=\"m-cart__product-actions\">\n            <span class=\"m-cart__product-amount a-input a-input--amount\"></span>\n          </div>\n          <div class=\"m-cart__product-prices\">\n            <span class=\"m-cart__product-price\"></span>\n          </div>\n        </div>\n      </div>\n    </div>\n  </div>\n</template>\n\n<script setup lang=\"ts\">\nimport { Ref, ref, onMounted, watch, ComputedRef, computed, nextTick } from 'vue'\nimport { useCartStore } from '../../stores/cart'\nimport { displayPrice } from '../../helper/currency'\nimport BaseCoupon from './BaseCoupon.vue'\nimport { useI18n } from 'vue-i18n'\nimport { translate } from '../../helper-functions'\nimport { lazyLoadUpdate } from '../../lazyload'\n\nconst { t } = useI18n()\nconst cartStore = useCartStore()\nconst componentLoading: Ref<boolean> = ref(true)\nconst loading: ComputedRef<Boolean> = computed(() => cartStore.loadingCart || componentLoading.value)\n\nlet newCartQuantity: Ref<Record<string, number>> = ref({})\n\nonMounted(async () => {\n  await cartStore.init()\n  componentLoading.value = false\n  nextTick(()=>{\n    lazyLoadUpdate()\n  })\n})\n\nwatch(() => cartStore.cart, async () => {\n  await cartStore.init()\n  // Set or reset the new quantity for the current cart\n  for (let product of cartStore.cart.products) {\n    newCartQuantity.value[product.ID] = product.quantity\n  }\n\n  nextTick(()=>{\n    lazyLoadUpdate()\n  })\n})\n\nasync function toggleWrappingPaper(ID: string) {\n  if (cartStore.cart.wrapping_paper?.ID === ID) {\n    await cartStore.removeWrappingPaper()\n    return\n  }\n\n  cartStore.setWrappingPaper(ID)\n}\n\nasync function changeValue(product: { ID: string, quantity: number, configuration_of: string|null }) {\n  componentLoading.value = true\n  const newQuantity = newCartQuantity.value[product.ID] ?? 0\n  if (newQuantity === product.quantity) {\n    return\n  }\n\n  if (product.quantity < newQuantity) {\n    await cartStore.add(product.ID, newQuantity - product.quantity, product.configuration_of)\n  } else if (product.quantity > newQuantity) {\n    await cartStore.remove(product.ID, product.quantity - newQuantity)\n  }\n\n  componentLoading.value = false\n}\n\nasync function remove(productID: string) {\n  componentLoading.value = true\n  const quantity = newCartQuantity.value[productID] ?? 0\n  if (quantity === 0) {\n    return\n  }\n\n  await cartStore.remove(productID, quantity)\n  componentLoading.value = false\n}\n\n</script>\n","<template v-if=\"!cartStore.loading\">\n  <div class=\"o-container a-layout\">\n    <div class=\"u-col-span:12 m-checkout__heading\">\n      <h1 class=\"m-checkout__title a-h2 u-col-span:12@md\">{{ t('cart.general.title') }}</h1>\n      <a :href=\"generateRoute('homepage')\" class=\"m-checkout__back a-btn a-btn--arrow\">\n        <svg class=\"a-icon a-icon--back\" aria-hidden=\"true\">\n          <use href=\"#chevron-left\"></use>\n        </svg>\n        {{ t('cart.button.continue_shopping') }}\n      </a>\n    </div>\n    <div class=\"u-col-span:8@md\">\n      <base-cart />\n    </div>\n    <div class=\"u-col-span:4@md m-shipment\" v-if=\"cartStore.cart.products.length > 0\">\n      <base-shipment-select></base-shipment-select>\n    </div>\n  </div>\n</template>\n<script setup lang=\"ts\">\nimport { onMounted } from 'vue'\nimport { Product, useCartStore } from '../../stores/cart'\nimport BaseCart from './BaseCart.vue'\nimport BaseShipmentSelect from './BaseShipmentSelect.vue'\nimport { useI18n } from 'vue-i18n'\nimport { CheckoutStepCart, EventCheckoutStep, emitEvent } from '../../helper/tracking-events'\nimport { generateRoute } from '../../helper-functions';\n\nconst { t } = useI18n()\n\nconst cartStore = useCartStore()\nonMounted(async () => {\n  await cartStore.init()\n\n  emitEvent(EventCheckoutStep, {\n    step: CheckoutStepCart,\n    products: (cartStore.cart.products ?? []).map((product: Product) => {\n      let attributes: { [key: string]: string } = {}\n      for (let [key, attributeValue] of Object.entries(product.attributes)) {\n        attributes[key] = attributeValue.value\n      }\n\n      return {\n        ID: product.ID,\n        name: product.name,\n        configurationOf: product.configuration_of,\n        price: product.price,\n        qty: product.quantity,\n        attributes: attributes,\n      }\n    }),\n  })\n})\n</script>\n"],"names":["makeMap","str","expectsLowerCase","map","list","val","GLOBALS_WHITE_LISTED","isGloballyWhitelisted","specialBooleanAttrs","isSpecialBooleanAttr","includeBooleanAttr","value","normalizeStyle","isArray","res","i","item","normalized","isString","parseStringStyle","key","isObject","listDelimiterRE","propertyDelimiterRE","cssText","ret","tmp","normalizeClass","name","normalizeProps","props","klass","style","HTML_TAGS","SVG_TAGS","VOID_TAGS","isHTMLTag","isSVGTag","isVoidTag","looseCompareArrays","a","b","equal","looseEqual","aValidType","isDate","bValidType","isSymbol","aKeysCount","bKeysCount","aHasKey","bHasKey","looseIndexOf","arr","toDisplayString","objectToString","isFunction","replacer","_key","isMap","entries","isSet","isPlainObject","EMPTY_OBJ","EMPTY_ARR","NOOP","NO","onRE","isOn","isModelListener","extend","remove","el","hasOwnProperty","hasOwn","toTypeString","isPromise","toRawType","isIntegerKey","isReservedProp","isBuiltInDirective","cacheStringFunction","fn","cache","camelizeRE","camelize","_","c","hyphenateRE","hyphenate","capitalize","toHandlerKey","hasChanged","oldValue","invokeArrayFns","fns","arg","def","obj","toNumber","n","_globalThis","getGlobalThis","activeEffectScope","EffectScope","detached","currentEffectScope","fromParent","l","last","effectScope","recordEffectScope","effect","scope","getCurrentScope","onScopeDispose","createDep","effects","dep","wasTracked","trackOpBit","newTracked","initDepMarkers","deps","finalizeDepMarkers","ptr","targetMap","effectTrackDepth","maxMarkerBits","activeEffect","ITERATE_KEY","MAP_KEY_ITERATE_KEY","ReactiveEffect","scheduler","parent","lastShouldTrack","shouldTrack","cleanupEffect","options","_effect","runner","stop","trackStack","pauseTracking","resetTracking","track","target","type","depsMap","trackEffects","debuggerEventExtraInfo","trigger","newValue","oldTarget","triggerEffects","triggerEffect","isNonTrackableKeys","builtInSymbols","get","createGetter","shallowGet","readonlyGet","shallowReadonlyGet","arrayInstrumentations","createArrayInstrumentations","instrumentations","args","toRaw","isReadonly","shallow","receiver","shallowReadonlyMap","readonlyMap","shallowReactiveMap","reactiveMap","targetIsArray","isRef","readonly","reactive","set","createSetter","shallowSet","isShallow","hadKey","result","deleteProperty","has","ownKeys","mutableHandlers","readonlyHandlers","shallowReactiveHandlers","shallowReadonlyHandlers","toShallow","getProto","v","get$1","rawTarget","rawKey","wrap","toReadonly","toReactive","has$1","size","add","set$1","deleteEntry","clear","hadItems","createForEach","callback","thisArg","observed","createIterableMethod","method","targetIsMap","isPair","isKeyOnly","innerIterator","done","createReadonlyMethod","createInstrumentations","mutableInstrumentations","shallowInstrumentations","readonlyInstrumentations","shallowReadonlyInstrumentations","createInstrumentationGetter","mutableCollectionHandlers","shallowCollectionHandlers","readonlyCollectionHandlers","shallowReadonlyCollectionHandlers","targetTypeMap","rawType","getTargetType","createReactiveObject","shallowReactive","shallowReadonly","baseHandlers","collectionHandlers","proxyMap","existingProxy","targetType","proxy","isReactive","isProxy","raw","markRaw","trackRefValue","ref","triggerRefValue","newVal","r","createRef","shallowRef","rawValue","RefImpl","__v_isShallow","triggerRef","unref","shallowUnwrapHandlers","proxyRefs","objectWithRefs","CustomRefImpl","factory","customRef","toRefs","object","toRef","ObjectRefImpl","_object","_defaultValue","defaultValue","ComputedRefImpl","getter","_setter","isSSR","self","computed","getterOrOptions","debugOptions","setter","onlyGetter","stack","warn","msg","instance","appWarnHandler","trace","getComponentTrace","callWithErrorHandling","vnode","formatComponentName","warnArgs","formatTrace","currentVNode","normalizedStack","parentInstance","logs","entry","formatTraceEntry","recurseCount","postfix","isRoot","open","close","formatProps","keys","formatProp","err","handleError","callWithAsyncErrorHandling","values","throwInDev","contextVNode","cur","exposedInstance","errorInfo","errorCapturedHooks","appErrorHandler","logError","isFlushing","isFlushPending","queue","flushIndex","pendingPreFlushCbs","activePreFlushCbs","preFlushIndex","pendingPostFlushCbs","activePostFlushCbs","postFlushIndex","resolvedPromise","currentFlushPromise","currentPreFlushParentJob","nextTick","p","findInsertionIndex","id","start","end","middle","getId","queueJob","job","queueFlush","flushJobs","invalidateJob","queueCb","cb","activeQueue","pendingQueue","index","queuePreFlushCb","queuePostFlushCb","flushPreFlushCbs","seen","parentJob","flushPostFlushCbs","deduped","check","devtools","buffer","setDevtoolsHook","hook","_a","_b","event","newHook","emit$1","rawArgs","modelArg","modifiersKey","number","trim","handlerName","handler","onceHandler","normalizeEmitsOptions","comp","appContext","asMixin","cached","hasExtends","extendEmits","normalizedFromExtend","isEmitListener","currentRenderingInstance","currentScopeId","setCurrentRenderingInstance","prev","pushScopeId","popScopeId","withScopeId","_id","withCtx","ctx","isNonScopedSlot","renderFnWithContext","setBlockTracking","prevInstance","renderComponentRoot","Component","withProxy","propsOptions","slots","attrs","emit","render","renderCache","data","setupState","inheritAttrs","fallthroughAttrs","proxyToUse","normalizeVNode","getFunctionalFallthrough","blockStack","createVNode","Comment","root","shapeFlag","filterModelListeners","cloneVNode","filterSingleRoot","children","singleRoot","child","isVNode","shouldUpdateComponent","prevVNode","nextVNode","optimized","prevProps","prevChildren","component","nextProps","nextChildren","patchFlag","emits","hasPropsChanged","dynamicProps","emitsOptions","nextKeys","updateHOCHostEl","isSuspense","SuspenseImpl","n1","n2","container","anchor","parentComponent","parentSuspense","isSVG","slotScopeIds","rendererInternals","mountSuspense","patchSuspense","hydrateSuspense","createSuspenseBoundary","normalizeSuspenseChildren","Suspense","triggerEvent","eventListener","patch","createElement","hiddenContainer","suspense","setActiveBranch","unmount","newBranch","newFallback","activeBranch","pendingBranch","isInFallback","isHydrating","isSameVNodeType","timeout","pendingId","move","next","parentNode","resume","delayEnter","hasUnresolvedAncestor","fallbackVNode","mountFallback","setupRenderEffect","isInPendingSuspense","hydratedEl","asyncSetupResult","handleSetupResult","placeholder","doRemove","node","hydrateNode","isSlotChildren","normalizeSuspenseSlot","s","block","trackBlock","isBlockTreeEnabled","openBlock","currentBlock","closeBlock","queueEffectWithSuspense","branch","provide","currentInstance","provides","parentProvides","inject","treatDefaultAsFactory","watchEffect","doWatch","watchPostEffect","watchSyncEffect","INITIAL_WATCHER_VALUE","watch","source","immediate","deep","flush","onTrack","onTrigger","forceTrigger","isMultiSource","isShallow$1","traverse","cleanup","onCleanup","baseGetter","isInSSRComponentSetup","queuePostRenderEffect","instanceWatch","publicThis","createPathGetter","setCurrentInstance","unsetCurrentInstance","path","segments","useTransitionState","state","onMounted","onBeforeUnmount","TransitionHookValidator","BaseTransitionImpl","getCurrentInstance","prevTransitionKey","getTransitionRawChildren","rawProps","mode","emptyPlaceholder","innerChild","getKeepAliveChild","enterHooks","resolveTransitionHooks","setTransitionHooks","oldChild","oldInnerChild","transitionKeyChanged","getTransitionKey","leavingHooks","earlyRemove","delayedLeave","leavingVNodesCache","getLeavingNodesForType","BaseTransition","leavingVNodes","appear","persisted","onBeforeEnter","onEnter","onAfterEnter","onEnterCancelled","onBeforeLeave","onLeave","onAfterLeave","onLeaveCancelled","onBeforeAppear","onAppear","onAfterAppear","onAppearCancelled","callHook","callAsyncHook","hooks","leavingVNode","afterHook","cancelHook","called","cancelled","isKeepAlive","keepComment","parentKey","keyedFragmentCount","Fragment","defineComponent","isAsyncWrapper","defineAsyncComponent","loader","loadingComponent","errorComponent","delay","suspensible","userOnError","pendingRequest","resolvedComp","retries","retry","load","thisRequest","resolve","reject","createInnerComp","onError","loaded","error","delayed","KeepAliveImpl","sharedContext","current","_unmount","storageContainer","vnodeHook","invokeVNodeHook","resetShapeFlag","pruneCache","filter","getComponentName","pruneCacheEntry","include","exclude","matches","pendingCacheKey","cacheSubtree","getInnerChild","onUpdated","subTree","da","rawVNode","max","cachedVNode","KeepAlive","pattern","onActivated","registerKeepAliveHook","onDeactivated","wrappedHook","injectHook","injectToKeepAliveRoot","keepAliveRoot","injected","onUnmounted","prepend","createHook","lifecycle","onBeforeMount","onBeforeUpdate","onServerPrefetch","onRenderTriggered","onRenderTracked","onErrorCaptured","withDirectives","directives","internalInstance","getExposeProxy","bindings","dir","modifiers","invokeDirectiveHook","oldBindings","binding","COMPONENTS","DIRECTIVES","resolveComponent","maybeSelfReference","resolveAsset","NULL_DYNAMIC_COMPONENT","resolveDynamicComponent","resolveDirective","warnMissing","selfName","registry","renderList","renderItem","createSlots","dynamicSlots","slot","j","renderSlot","fallback","noSlotted","validSlotContent","ensureValidVNode","rendered","createBlock","vnodes","toHandlers","getPublicInstance","isStatefulComponent","publicPropertiesMap","resolveMergedOptions","PublicInstanceProxyHandlers","accessCache","normalizedProps","shouldCacheAccess","publicGetter","cssModule","globalProperties","descriptor","RuntimeCompiledPublicInstanceProxyHandlers","applyOptions","dataOptions","computedOptions","methods","watchOptions","provideOptions","injectOptions","created","beforeMount","mounted","beforeUpdate","updated","activated","deactivated","beforeDestroy","beforeUnmount","destroyed","unmounted","renderTracked","renderTriggered","errorCaptured","serverPrefetch","expose","components","filters","resolveInjections","methodHandler","opt","createWatcher","registerLifecycleHook","register","_hook","exposed","checkDuplicateProperties","unwrapRef","normalizeInject","h","base","mixins","extendsOptions","globalMixins","optionMergeStrategies","resolved","m","mergeOptions","to","from","strats","strat","internalOptionMergeStrats","mergeDataFn","mergeObjectOptions","mergeAsArray","mergeWatchOptions","mergeInject","merged","initProps","isStateful","InternalObjectKey","setFullProps","updateProps","rawPrevProps","rawCurrentProps","hasAttrsChanged","propsToUpdate","camelizedKey","resolvePropValue","kebabKey","needCastKeys","rawCastValues","camelKey","castValues","isAbsent","hasDefault","propsDefaults","normalizePropsOptions","extendProps","normalizedKey","validatePropName","prop","booleanIndex","getTypeIndex","stringIndex","getType","ctor","match","isSameType","expectedTypes","t","isInternalKey","normalizeSlotValue","normalizeSlot","rawSlot","normalizeObjectSlots","rawSlots","normalizeVNodeSlots","initSlots","updateSlots","needDeletionCheck","deletionComparisonTarget","createAppContext","uid","createAppAPI","hydrate","rootComponent","rootProps","context","installedPlugins","isMounted","app","version","plugin","mixin","directive","rootContainer","isHydrate","setRef","rawRef","oldRawRef","isUnmount","refValue","owner","oldRef","refs","_isString","_isRef","doSet","existing","hasMismatch","isSVGContainer","isComment","createHydrationFunctions","mountComponent","patchProp","createText","nextSibling","insert","createComment","isFragmentStart","onMismatch","handleMismatch","domType","nextNode","Text","Static","needToAdoptContent","hydrateFragment","hydrateElement","locateClosingAsyncAnchor","createTextVNode","hydrateChildren","dirs","forcePatchValue","vnodeHooks","parentVNode","fragmentSlotScopeIds","isFragment","createRenderer","baseCreateRenderer","createHydrationRenderer","createHydrationFns","hostInsert","hostRemove","hostPatchProp","hostCreateElement","hostCreateText","hostCreateComment","hostSetText","hostSetElementText","hostParentNode","hostNextSibling","hostSetScopeId","hostCloneNode","hostInsertStaticContent","getNextHostNode","processText","processCommentNode","mountStaticNode","processFragment","processElement","processComponent","internals","moveStaticNode","removeStaticNode","mountElement","patchElement","transition","mountChildren","unmountChildren","setScopeId","needCallTransitionHooks","scopeId","cloneIfMounted","dynamicChildren","oldProps","newProps","toggleRecurse","areChildrenSVG","patchBlockChildren","patchChildren","patchProps","oldChildren","newChildren","fallbackContainer","oldVNode","newVNode","fragmentStartAnchor","fragmentEndAnchor","traverseStaticChildren","updateComponent","initialVNode","createComponentInstance","setupComponent","updateComponentPreRender","componentUpdateFn","bu","u","originNext","nextTree","prevTree","bm","isAsyncWrapperVNode","hydrateSubTree","scopedInitialVNode","update","c1","prevShapeFlag","c2","patchKeyedChildren","patchUnkeyedChildren","oldLength","newLength","commonLength","nextChild","parentAnchor","l2","e1","e2","nextPos","s1","s2","keyToNewIndexMap","patched","toBePatched","moved","maxNewIndexSoFar","newIndexToOldIndexMap","prevChild","newIndex","increasingNewIndexSequence","getSequence","nextIndex","moveType","leave","delayLeave","afterLeave","performLeave","shouldInvokeDirs","shouldInvokeVnodeHook","unmountComponent","removeFragment","performRemove","bum","um","allowed","ch1","ch2","len","arrI","isTeleport","isTeleportDisabled","isTargetSVG","resolveTarget","select","targetSelector","TeleportImpl","querySelector","disabled","mainAnchor","targetAnchor","mount","wasDisabled","currentContainer","currentAnchor","moveTeleport","nextTarget","hydrateTeleport","isReorder","targetNode","Teleport","disableTracking","setupBlock","createElementBlock","createBaseVNode","transformVNodeArgs","transformer","normalizeKey","normalizeRef","ref_key","ref_for","isBlockNode","needFullChildrenNormalization","normalizeChildren","_createVNode","cloned","isClassComponent","guardReactiveProps","extraProps","mergeRef","mergedProps","mergeProps","text","flag","createStaticVNode","content","numberOfNodes","createCommentVNode","asBlock","slotFlag","toMerge","incoming","emptyAppContext","uid$1","setupResult","setupStatefulComponent","setup","setupContext","createSetupContext","resolvedResult","e","finishComponentSetup","compile","installWithProxy","registerRuntimeCompiler","_compile","isRuntimeOnly","skipOptions","template","isCustomElement","compilerOptions","delimiters","componentCompilerOptions","finalCompilerOptions","createAttrsProxy","classifyRE","classify","includeInferred","inferFromRegistry","computed$1","defineProps","defineEmits","defineExpose","withDefaults","defaults","useSlots","getContext","useAttrs","mergeDefaults","createPropsRestProxy","excludedKeys","withAsyncContext","getAwaitable","awaitable","propsOrChildren","ssrContextKey","useSSRContext","initCustomFormatter","withMemo","memo","isMemoSame","_ssrUtils","ssrUtils","resolveFilter","compatUtils","svgNS","doc","templateContainer","nodeOps","tag","is","selector","before","wrapper","patchClass","transitionClasses","patchStyle","isCssString","setStyle","currentDisplay","importantRE","prefixed","autoPrefix","prefixes","prefixCache","rawName","xlinkNS","patchAttr","isBoolean","patchDOMProp","needRemove","_getNow","skipTimestampCheck","ffMatch","cachedNow","reset","getNow","addEventListener","removeEventListener","patchEvent","prevValue","nextValue","invokers","existingInvoker","parseName","invoker","createInvoker","optionsModifierRE","initialValue","timeStamp","patchStopImmediatePropagation","originalStop","nativeOnRE","shouldSetAsProp","defineCustomElement","Comp","VueCustomElement","VueElement","initialProps","defineSSRCustomElement","BaseClass","_def","_props","mutations","styles","hasOptions","rawKeys","numberProps","camelize$1","asyncDef","shouldReflect","shouldUpdate","css","useCssModule","modules","mod","useCssVars","setVars","setVarsOnVNode","ob","vars","setVarsOnNode","TRANSITION","ANIMATION","Transition","resolveTransitionProps","DOMTransitionPropsValidators","TransitionPropsValidators","hasExplicitCallback","baseProps","duration","enterFromClass","enterActiveClass","enterToClass","appearFromClass","appearActiveClass","appearToClass","leaveFromClass","leaveActiveClass","leaveToClass","durations","normalizeDuration","enterDuration","leaveDuration","finishEnter","isAppear","removeTransitionClass","finishLeave","makeEnterHook","nextFrame","addTransitionClass","whenTransitionEnds","forceReflow","NumberOf","cls","_vtc","endId","expectedType","explicitTimeout","resolveIfNotStale","propCount","getTransitionInfo","endEvent","ended","onEnd","getStyleProperties","transitionDelays","transitionDurations","transitionTimeout","getTimeout","animationDelays","animationDurations","animationTimeout","hasTransform","delays","d","toMs","positionMap","newPositionMap","TransitionGroupImpl","moveClass","hasCSSTransform","callPendingCbs","recordPosition","movedChildren","applyTranslation","cssTransitionProps","TransitionGroup","oldPos","newPos","dx","dy","clone","getModelAssigner","onCompositionStart","onCompositionEnd","vModelText","lazy","castToNumber","domValue","vModelCheckbox","modelValue","elementValue","getValue","checked","assign","found","filtered","getCheckboxValue","setChecked","vModelRadio","vModelSelect","isSetModel","selectedVal","setSelected","_binding","isMultiple","option","optionValue","vModelDynamic","callModelHook","resolveDynamicModel","tagName","initVModelForSSR","modelToUse","systemModifiers","modifierGuards","withModifiers","guard","keyNames","withKeys","eventKey","k","vShow","setDisplay","initVShowForSSR","rendererOptions","renderer","enabledHydration","ensureRenderer","ensureHydrationRenderer","createApp","containerOrSelector","normalizeContainer","createSSRApp","ssrDirectiveInitialized","initDirectivesForSSR","defaultOnError","defaultOnWarn","createCompilerError","code","loc","messages","additionalMessage","FRAGMENT","TELEPORT","SUSPENSE","KEEP_ALIVE","BASE_TRANSITION","OPEN_BLOCK","CREATE_BLOCK","CREATE_ELEMENT_BLOCK","CREATE_VNODE","CREATE_ELEMENT_VNODE","CREATE_COMMENT","CREATE_TEXT","CREATE_STATIC","RESOLVE_COMPONENT","RESOLVE_DYNAMIC_COMPONENT","RESOLVE_DIRECTIVE","RESOLVE_FILTER","WITH_DIRECTIVES","RENDER_LIST","RENDER_SLOT","CREATE_SLOTS","TO_DISPLAY_STRING","MERGE_PROPS","NORMALIZE_CLASS","NORMALIZE_STYLE","NORMALIZE_PROPS","GUARD_REACTIVE_PROPS","TO_HANDLERS","CAMELIZE","CAPITALIZE","TO_HANDLER_KEY","SET_BLOCK_TRACKING","PUSH_SCOPE_ID","POP_SCOPE_ID","WITH_CTX","UNREF","IS_REF","WITH_MEMO","IS_MEMO_SAME","helperNameMap","registerRuntimeHelpers","helpers","locStub","createRoot","createVNodeCall","isBlock","isComponent","getVNodeBlockHelper","getVNodeHelper","createArrayExpression","elements","createObjectExpression","properties","createObjectProperty","createSimpleExpression","isStatic","constType","createCompoundExpression","createCallExpression","callee","createFunctionExpression","params","returns","newline","isSlot","createConditionalExpression","test","consequent","alternate","createCacheExpression","createBlockStatement","body","isStaticExp","isBuiltInType","expected","isCoreComponent","nonIdentifierRE","isSimpleIdentifier","validFirstIdentCharRE","validIdentCharRE","whitespaceRE","isMemberExpressionBrowser","stateStack","currentOpenBracketCount","currentOpenParensCount","currentStringType","char","isMemberExpression","getInnerRange","offset","length","newLoc","advancePositionWithClone","pos","numberOfCharacters","advancePositionWithMutation","linesCount","lastNewLinePos","findDir","allowEmpty","findProp","dynamicOnly","isStaticArgOf","hasDynamicKeyVBind","isText","isVSlot","isTemplateNode","isSlotOutlet","ssr","propsHelperSet","getUnnormalizedProps","callPath","injectProp","propsWithInjection","parentCall","first","alreadyExists","propKeyName","toValidAssetId","searchValue","replaceValue","getMemoedVNodeCall","makeBlock","helper","removeHelper","inSSR","getCompatValue","config","isCompatEnabled","checkCompatEnabled","decodeRE","decodeMap","defaultParserOptions","rawText","p1","baseParse","createParserContext","getCursor","parseChildren","getSelection","rawOptions","ancestors","ns","nodes","isEnd","startsWith","parseInterpolation","emitError","parseComment","parseBogusComment","parseCDATA","advanceBy","parseTag","parseElement","isSpecialTemplateDirective","parseText","pushNode","removedWhitespace","shouldCondense","prevIndex","nestedIndex","contentStart","closeIndex","wasInPre","wasInVPre","element","isPreBoundary","isVPreBoundary","inlineTemplateProp","startsWithEndTagOpen","advanceSpaces","cursor","currentSource","parseAttributes","isSelfClosing","tagType","attributeNames","attr","parseAttribute","nameSet","parseAttributeValue","isPropShorthand","dirName","startOffset","getNewPosition","valueLoc","quote","isQuoted","endIndex","parseTextData","unexpectedChars","innerStart","innerEnd","rawContentLength","rawContent","preTrimContent","endOffset","endTokens","column","line","xs","searchString","hoistStatic","walk","isSingleElementRoot","doNotHoistNode","originalCount","hoistedCount","constantType","getConstantType","codegenNode","getPatchFlag","getGeneratedPropsConstantType","getNodeProps","constantCache","returnType","generatedPropsType","childType","expType","allowHoistedHelperSet","getConstantTypeOfHelperCall","keyType","valueType","createTransformContext","filename","prefixIdentifiers","cacheHandlers","nodeTransforms","directiveTransforms","transformHoist","isBuiltInComponent","expressionPlugins","slotted","ssrCssVars","bindingMetadata","inline","isTS","onWarn","compatConfig","nameMatch","count","currentCount","removalIndex","exp","identifier","transform","traverseNode","createRootCodegen","traverseChildren","nodeRemoved","exitFns","onExit","createStructuralDirectiveTransform","PURE_ANNOTATION","aliasHelper","createCodegenContext","ast","sourceMap","optimizeImports","runtimeGlobalName","runtimeModuleName","ssrRuntimeModuleName","withoutNewLine","generate","push","indent","deindent","hasHelpers","useWithBlock","genFunctionPreamble","functionName","signature","genAssets","genNode","VueBinding","staticHelpers","genHoists","assets","resolver","hoists","genNodeListAsArray","multilines","genNodeList","comma","genText","genExpression","genInterpolation","genCompoundExpression","genComment","genVNodeCall","genCallExpression","genObjectExpression","genArrayExpression","genFunctionExpression","genConditionalExpression","genCacheExpression","pure","genExpressionAsPropertyKey","callHelper","genNullableArgs","needNewline","needsParens","isNested","transformIf","processIf","ifNode","siblings","sibling","createCodegenNodeForBranch","parentCondition","getParentCondition","processCodegen","createIfBranch","isTemplateIf","keyIndex","createChildrenCodegenNode","keyProperty","firstChild","vnodeCall","transformFor","processFor","forNode","renderExp","isTemplate","keyProp","keyExp","isStableFragment","fragmentFlag","childBlock","needFragmentWrapper","slotOutlet","loop","createForLoopParams","parseResult","parseForExpression","addIdentifiers","removeIdentifiers","scopes","forAliasRE","forIteratorRE","stripParensRE","input","inMatch","LHS","RHS","createAliasExpression","valueContent","trimmedOffset","iteratorMatch","keyContent","keyOffset","indexContent","range","memoArgs","createParamsList","defaultFallback","trackSlotScopes","vSlot","buildClientSlotFn","buildSlots","buildSlotFn","slotsProperties","hasDynamicSlots","onComponentSlot","hasTemplateSlots","hasNamedDefaultSlot","implicitDefaultChildren","seenSlotNames","slotElement","slotDir","slotChildren","slotLoc","slotName","slotProps","dirLoc","staticSlotName","slotFunction","vIf","vElse","vFor","buildDynamicSlot","conditional","buildDefaultSlotProperty","isNonWhitespaceContent","hasForwardedSlots","directiveImportMap","transformElement","vnodeTag","resolveComponentType","isDynamicComponent","vnodeProps","vnodeChildren","vnodePatchFlag","vnodeDynamicProps","dynamicPropNames","vnodeDirectives","shouldUseBlock","propsBuildResult","buildProps","buildDirectiveArgs","hasDynamicTextChild","stringifyDynamicPropNames","isExplicitDynamic","isComponentTag","isProp","isDir","builtIn","elementLoc","mergeArgs","runtimeDirectives","hasChildren","hasRef","hasClassBinding","hasStyleBinding","hasHydrationEventBinding","hasDynamicKeys","hasVnodeHook","analyzePatchFlag","isEventHandler","isVBind","isVOn","dedupeProperties","directiveTransform","needRuntime","propsExpression","classKeyIndex","styleKeyIndex","hasDynamicKey","classProp","styleProp","knownProps","dirArgs","runtime","trueExpression","modifier","propsNamesString","transformSlotOutlet","processSlotOutlet","slotArgs","expectedLen","nonNameProps","fnExpRE","transformOn","augmentor","eventName","shouldCache","isMemberExp","isInlineStatement","hasMultipleStatements","transformBind","_node","injectPrefix","prefix","transformText","hasText","callArgs","transformOnce","transformModel","createTransformProps","rawExp","expString","maybeRef","propName","assignmentExp","eventArg","validDivisionCharRE","transformFilter","rewriteFilter","parseFilter","inSingle","inDouble","inTemplateString","inRegex","curly","square","paren","lastFilterIndex","expression","pushFilter","wrapFilter","seen$1","transformMemo","getBaseTransformPreset","baseCompile","isModuleMode","noopDirectiveTransform","V_MODEL_RADIO","V_MODEL_CHECKBOX","V_MODEL_TEXT","V_MODEL_SELECT","V_MODEL_DYNAMIC","V_ON_WITH_MODIFIERS","V_ON_WITH_KEYS","V_SHOW","TRANSITION_GROUP","decoder","decodeHtmlBrowser","asAttr","isRawTextContainer","parserOptions","transformStyle","parseInlineCSS","createDOMCompilerError","transformVHtml","transformVText","baseResult","transformModel$1","directiveToUse","isInvalidType","isEventOptionModifier","isNonKeyModifier","maybeKeyModifier","isKeyboardEvent","resolveModifiers","keyModifiers","nonKeyModifiers","eventOptionModifiers","transformClick","transformOn$1","handlerExp","modifierPostfix","transformShow","ignoreSideEffectTags","DOMNodeTransforms","DOMDirectiveTransforms","compileCache","compileToFunction","runtimeDom","isVue2","activePinia","setActivePinia","pinia","piniaSymbol","o","MutationType","createPinia","_p","toBeInstalled","noop","addSubscription","subscriptions","removeSubscription","idx","triggerSubscriptions","mergeReactiveObjects","patchToApply","subPatch","targetValue","skipHydrateSymbol","shouldHydrate","isComputed","createOptionsStore","hot","actions","getters","initialState","store","localState","computedGetters","createSetupStore","newState","$state","$id","isOptionsStore","optionsForPlugin","$subscribeOptions","isListening","isSyncListening","actionSubscriptions","debuggerEvents","activeListener","$patch","partialStateOrMutator","subscriptionMutation","myListenerId","$reset","$dispose","wrapAction","action","afterCallbackList","onErrorCallbackList","after","partialStore","stopWatcher","setupStore","actionValue","extender","defineStore","idOrOptions","setupOptions","isSetupStore","useStore","storeToRefs","M","C","w","R","V","W","Y","y","G","g","x","$","T","z","F","P","q","L","J","K","f","Q","I","O","S","E","U","X","Z","tt","et","B","D","N","H","it","A","st","at","loadSvg","svgDom","inBrowser","makeSymbol","shareable","generateFormatCacheKey","locale","friendlyJSONstringify","json","isNumber","isRegExp","isEmptyObject","escapeHtml","proto","join","items","separator","incrementer","createPosition","createLocation","RE_ARGS","format","message","CompileErrorCodes","errorMessages","createCompileError","domain","CHAR_SP","CHAR_CR","CHAR_LF","CHAR_LS","CHAR_PS","createScanner","_buf","_index","_line","_column","_peekOffset","isCRLF","isLF","isPS","isLS","isLineEnd","peekOffset","charAt","currentChar","currentPeek","peek","resetPeek","skipToPeek","EOF","DOT","LITERAL_DELIMITER","ERROR_DOMAIN$3","createTokenizer","location","_scnr","currentOffset","currentPosition","_initLoc","_initOffset","_context","getToken","token","getEndToken","eat","scnr","ch","peekSpaces","buf","skipSpaces","isIdentifierStart","cc","isNumberStart","isNamedIdentifierStart","currentType","isListIdentifierStart","isLiteralStart","isLinkedDotStart","isLinkedModifierStart","isLinkedDelimiterStart","isLinkedReferStart","isPluralStart","detectModuloStart","spaces","isTextStart","hasSpace","detectModulo","takeChar","takeIdentifierChar","takeDigit","takeHexDigit","getDigits","num","readModulo","readText","readNamedIdentifier","readListIdentifier","readLiteral","literal","readEscapeSequence","readUnicodeEscapeSequence","unicode","digits","sequence","readInvalidIdentifier","identifiers","closure","readLinkedModifier","readLinkedRefer","detect","readPlural","plural","readTokenInPlaceholder","readTokenInLinked","validNamedIdentifier","validListIdentifier","validLiteral","readToken","isModulo","nextToken","startLoc","endLoc","ERROR_DOMAIN$2","KNOWN_ESCAPES","fromEscapeSequence","codePoint4","codePoint6","codePoint","createParser","tokenzer","startNode","endNode","tokenizer","parseList","parseNamed","parseLiteral","parseLinkedModifier","getTokenCaption","parseLinkedKey","parseLinked","linkedNode","parsed","nextContext","emptyLinkedKeyNode","parseMessage","parsePlural","msgNode","hasEmptyMessage","parseResource","parse","createTransformer","traverseNodes","optimize","optimizeMessageNode","ERROR_DOMAIN$1","minify","resource","cases","valueNode","linked","named","ERROR_DOMAIN","createCodeGenerator","breakLineCode","_needIndent","_newline","withBreakLine","_breakLineCode","withNewLine","level","generateLinkedNode","generator","generateNode","generateMessageNode","needIndent","generatePluralNode","generateResource","assignedOptions","jit","enalbeMinify","enambeOptimize","initFeatureFlags","pathStateMachine","literalValueRE","isLiteral","stripQuotes","getPathCharType","formatSubPath","trimmed","subPathDepth","newChar","typeMap","maybeUnescapeQuote","nextChar","resolveWithKeyValue","resolveValue","hit","DEFAULT_MODIFIER","DEFAULT_MESSAGE","DEFAULT_MESSAGE_DATA_TYPE","DEFAULT_NORMALIZE","DEFAULT_INTERPOLATE","pluralDefault","choice","choicesLength","getPluralIndex","normalizeNamed","pluralIndex","createMessageContext","pluralRule","orgPluralRule","_list","_named","_modifier","normalize","interpolate","arg1","arg2","setDevToolsHook","initI18nDevTools","i18n","meta","translateDevTools","createDevToolsHook","payloads","CoreWarnCodes","getLocale","resolveLocale","_resolveLocale","fallbackWithSimple","fallbackWithLocaleChain","startLocale","DEFAULT_LOCALE","chain","appendBlockToChain","blocks","follow","appendLocaleToChain","tokens","appendItemToChain","VERSION","NOT_REOSLVED","MISSING_RESOLVE_VALUE","getDefaultLinkedModifiers","_compiler","registerMessageCompiler","compiler","_resolver","registerMessageResolver","_fallbacker","registerLocaleFallbacker","fallbacker","_additionalMeta","setAdditionalMeta","getAdditionalMeta","_fallbackContext","setFallbackContext","getFallbackContext","_cid","createCoreContext","_locale","fallbackLocale","datetimeFormats","numberFormats","pluralRules","missing","missingWarn","fallbackWarn","fallbackFormat","unresolving","postTranslation","processor","warnHtmlMessage","escapeParameter","messageCompiler","messageResolver","localeFallbacker","fallbackContext","internalOptions","__datetimeFormatters","__numberFormatters","__meta","handleMissing","updateFallbackLocale","formatParts","formatMessageParts","_static","acm","formatMessagePart","linkedKey","linkedModifier","inc","CoreErrorCodes","createCoreError","defaultOnCacheKey","isMessageAST","detectError","baseCompile$1","cacheKey","NOOP_MESSAGE_FUNCTION","isMessageFunction","translate","parseTranslateArgs","resolvedMessage","defaultMsgOrKey","enableDefaultMsg","escapeParams","formatScope","targetLocale","resolveMessageFormat","cacheBaseKey","occurred","compileMessageFormat","ctxOptions","getMessageContextOptions","msgContext","messaged","evaluateMessage","locales","missingRet","getCompileContext","msgCtx","arg3","datetime","overrides","parseDateTimeArgs","part","datetimeFormat","formatter","DATETIME_FORMAT_OPTIONS_KEYS","arg4","dateTime","clearDateTimeFormat","parseNumberArgs","numberFormat","NUMBER_FORMAT_OPTIONS_KEYS","clearNumberFormat","code$1","inc$1","I18nErrorCodes","createI18nError","TranslateVNodeSymbol","DatetimePartsSymbol","NumberPartsSymbol","SetPluralRulesSymbol","InejctWithOptionSymbol","DisposeSymbol","handleFlatJson","subKeys","lastIndex","currentObj","hasStringValue","getLocaleMessages","__i18n","flatJson","custom","deepCopy","isNotObjectOrIsArray","src","des","getComponentOptions","adjustI18nResources","gl","componentOptions","createTextNode","DEVTOOLS_META","composerID","defineCoreMissingHandler","getMetaInfo","createComposer","VueI18nLegacy","__root","__injectWithOption","_isGlobal","_inheritLocale","_fallbackLocale","_messages","_datetimeFormats","_numberFormats","_missingWarn","_fallbackWarn","_fallbackRoot","_fallbackFormat","_missing","_runtimeMissing","_postTranslation","_warnHtmlMessage","_escapeParameter","_modifiers","_pluralRules","trackReactivityValues","getPostTranslationHandler","setPostTranslationHandler","getMissingHandler","setMissingHandler","wrapWithDeps","argumentParser","warnType","fallbackSuccess","fallbackFail","successCondition","rt","translateVNode","numberParts","datetimeParts","setPluralRules","rules","te","getLocaleMessage","resolveMessages","targetLocaleMessages","messageValue","tm","setLocaleMessage","mergeLocaleMessage","getDateTimeFormat","setDateTimeFormat","mergeDateTimeFormat","getNumberFormat","setNumberFormat","mergeNumberFormat","composer","convertComposerOptions","fallbackRoot","pluralizationRules","inheritLocale","sharedMessages","createVueI18n","__extender","vueI18n","baseFormatProps","getInterpolateArg","getFragmentableTag","TranslationImpl","useI18n","assignedAttrs","Translation","renderFormatter","slotKeys","partFormatter","parts","NumberFormatImpl","NumberFormat","DatetimeFormatImpl","DatetimeFormat","getComposer$2","i18nInternal","vTDirective","_process","parsedValue","parseValue","makeParams","textContent","apply","pluginOptions","useI18nComponentName","defineMixin","vuei18n","optionsI18n","mergeToGlobal","_vueI18n","I18nInjectionKey","createI18n","__legacyMode","__globalInjection","__allowComposition","__instances","globalScope","__global","createGlobal","symbol","__getInstance","__setInstance","__deleteInstance","opts","globalReleaseHandler","injectGlobalFields","unmountApp","getI18nInstance","getGlobalComposer","getScope","useI18nForLegacy","getComposer","composerOptions","setupLifeCycle","legacyMode","useComponent","getParentComponentInstance","_composer","dispose","isLocalScope","warpWithDeps","sync","globalExportProps","globalExportMethods","desc","en","nl","module","this","installedModules","__webpack_require__","moduleId","exports","docElem","currentElement","currentInput","currentIntent","currentTimestamp","shouldPersist","formInputs","functionList","ignoreMap","specificMap","inputMap","isScrolling","mousePos","pointerMap","supportsPassive","setUp","detectWheel","addListeners","setPersist","setInput","setIntent","setElement","clearElement","doUpdate","pointerType","ignoreMatch","specificMatch","validateTouch","persistInput","activeElem","notFormInput","checkClosest","which","fireFunctions","detectScrolling","timestamp","touchIsValid","wheelType","objPos","elem","ElementPrototype","eventType","position","displayPrice","price","zeroValue","discountPercentage","productPrice","productOriginalPrice","originalPrice","replacements","generateRoute","eventbus","emitEvent","eventBus","EventCheckoutStep","EventCartAdd","EventCartRemove","EventCheckoutConfirmation","EventProductClick","EventCollectionImpression","EventProductView","CheckoutStepCart","CheckoutStepCredentials","CheckoutStepPaymentSelection","CheckoutStepCreateOrder","CheckoutStepUpdateOrder","runningOnBrowser","isBot","supportsIntersectionObserver","supportsClassList","isHiDpi","defaultSettings","getExtendedSettings","customSettings","createInstance","classObj","eventString","autoInitialize","optionsItem","SRC","SRCSET","SIZES","POSTER","ORIGINALS","DATA","statusLoading","statusLoaded","statusApplied","statusEntered","statusError","statusNative","dataPrefix","statusDataName","getData","attribute","setData","attrName","getStatus","setStatus","status","resetStatus","hasEmptyStatus","hasStatusLoading","hasStatusError","hasStatusNative","statusesAfterLoading","hadStartedLoading","safeCallback","addClass","className","removeClass","addTempImage","deleteTempImage","getTempImage","unobserve","observer","resetObserver","unobserveEntered","settings","updateLoadingCount","delta","decreaseToLoadCount","setToLoadCount","isSomethingLoading","haveElementsToLoad","getSourceTags","parentTag","sourceTags","childTag","forEachPictureSource","forEachVideoSource","attrsSrc","attrsSrcPoster","attrsSrcSrcsetSizes","attrsData","hasOriginalAttrs","getOriginalAttrs","deleteOriginalAttrs","setOriginalsObject","attributes","originals","saveOriginalBackgroundStyle","setOrResetAttribute","restoreOriginalAttrs","restoreOriginalBgImage","manageApplied","manageLoading","setAttributeIfValue","setImageAttributes","setSourcesImg","imgEl","sourceTag","setSourcesIframe","iframe","setSourcesVideo","videoEl","sourceEl","setSourcesObject","setBackground","bg1xValue","bgHiDpiValue","bgDataValue","setMultiBackground","setImgsetBackground","bgImgSetDataValue","imgSetValues","bgImageValues","setSourcesFunctions","setSourcesNative","setSourcesFunction","setSources","elementsWithLoadEvent","hasLoadEvent","checkFinish","hasEventListeners","addEventListeners","loadHandler","errorHandler","loadEventName","removeEventListeners","eventListeners","doneHandler","goingNative","addOneShotEventListeners","elementToListenTo","loadBackground","loadRegular","loadNative","removeImageAttributes","resetSourcesImg","restoreImg","restoreVideo","restoreIframe","iframeEl","restoreObject","objectEl","restoreFunctions","restoreAttributes","restoreFunction","resetClasses","restore","cancelLoading","dontLoad","tagsWithNativeLazy","shouldUseNative","loadAllNative","isIntersecting","getObserverSettings","intersectionHandler","observeElements","updateObserver","elementsToObserve","setObserver","toArray","nodeSet","queryElements","excludeManagedElements","hasError","filterErrorElements","getElementsToLoad","retryLazyLoad","setOnlineCheck","resetOnlineCheck","LazyLoad","givenNodeset","elementsToLoad","lazyLoadUpdate","getRandomValues","rnds8","rng","REGEX","validate","uuid","byteToHex","stringify","v4","rnds","tryOnScopeDispose","toValue","isClient","createFilterWrapper","bypassFilter","invoke","pausableFilter","extendFilter","isActive","pause","eventFilter","__getOwnPropSymbols$8","__hasOwnProp$8","__propIsEnum$8","__objRest$5","watchWithFilter","__defProp$2","__defProps$2","__getOwnPropDescs$2","__getOwnPropSymbols$2","__hasOwnProp$2","__propIsEnum$2","__defNormalProp$2","__spreadValues$2","__spreadProps$2","__objRest$1","watchPausable","unrefElement","elRef","plain","defaultWindow","useEventListener","events","listeners","cleanups","listener","options2","stopWatch","_global","globalKey","handlers","getHandlers","getSSRHandler","guessSerializerType","rawInit","__defProp$k","__getOwnPropSymbols$n","__hasOwnProp$n","__propIsEnum$n","__defNormalProp$k","__spreadValues$k","StorageSerializers","customStorageEventName","useStorage","storage","listenToStorageChanges","writeDefaults","window","_a2","serializer","pauseWatch","resumeWatch","pausableWatch","write","updateFromCustomEvent","serialized","read","useLocalStorage","useSessionStorage","uuidv4","$event","eventTarget","handleErrorResponse","response","_c","_d","_e","notify","handleErrorResponseLegacyMethod","errorMessage","errorMsg","errors","useCartStore","isPopoverOpened","loadingCart","cartInitialized","cart","initCart","getCart","couponCode","getCountries","postNLApiOnline","isPostNLOnline","getShippingMethods","getPaymentMethods","checkoutMethod","selectedPayMethod","paymentMethod","paymentMethods","payMethod","setPaymentMethod","getDefaultTimeFrames","initGiftWrapItems","wrappingPaper","productCount","product","giftWrapItems","checkoutCountries","selectedCountry","shippingMethods","invoiceAddress","emptyAddress","sameShippingAddress","shippingAddress","orderComment","termsOfServiceAccepted","newsletterAccepted","selectedTimeFrame","customerAge","customerGender","CustomerGenders","customerIban","openCart","closeCart","productId","amount","configurationOf","url","productEventData","qty","attributeValue","setWrappingPaper","ID","removeWrappingPaper","addCoupon","removeCoupon","respBody","country","setCheckoutCountry","countryID","selectePayMethodExists","selectDefaultPayMethod","setCheckoutMethod","getAddressAutocomplete","zipcode","houseNumber","saveAddresses","request","responseBody","createOrder","_f","_g","_h","_i","checkoutStep","timeFrames","getTimeFrames","orderID","isPostNLCheckoutMethod","setTimeFrame","timeFrame","getPickupPoints","countryCode","setPickupPoint","pickupPoint","clearCart","clearLocalStorage","isPostNLPickupCheckoutMethod","_imports_0","enumerableOnly","symbols","sym","_objectSpread2","_defineProperty","unwrapObj","ignoreKeys","stringPath","gatherBooleanGroupProperties","group","nestedResults","property","gatherArrayGroupProperties","all","fetchedProperty","callRule","rule","siblingState","normalizeValidatorResponse","createAsyncResult","model","$pending","$dirty","_ref","$response","$lazy","$rewardEarly","watchTargets","$lastInvalidState","$lastCommittedOn","$invalid","$pendingCounter","$unwatch","ruleResult","createSyncResult","_ref2","returnValue","createValidatorResult","validatorName","propertyKey","propertyPath","$params","sortValidations","validationsRaw","validations","validationKeys","nestedValidators","validationGroups","ROOT_PATH","createValidationResults","resultsCache","externalResults","ruleKeys","cachedResult","ruleKey","stringError","collectNestedValidationResults","nestedState","nestedExternalResults","nestedValidationKeys","results","nestedKey","setValidations","createMetaFields","childResults","allResults","allRes","$silentErrors","modelErrors","nestedErrors","$errors","$anyDirty","$error","$touch","$commit","nr","globalConfig","mergedConfig","cachedExternalResults","$validationGroups","$model","external","$validate","unwatch","$getResultsForChild","$clearExternalResults","ResultsStorage","storedRules","storedRulesKeys","newRulesKeys","paramKey","storedRuleResultPair","isValidCache","CollectFlag","VuelidateInjectChildResults","VuelidateRemoveChildResults","nestedValidations","$scope","childResultsRaw","childResultsKeys","injectChildResultsIntoParent","childScope","$stopPropagation","removeChildResultsFromParent","childKey","sendValidationResultsToParent","removeValidationResultsFromParent","ComputedProxyFactory","useVuelidate","_getCurrentInstance","$registerAs","$externalResults","currentVueInstance","validationResults","validationsWatchTarget","newValidationRules","normalizeValidatorObject","validator","unwrapValidatorResponse","unwrapNormalizedValidator","withParams","$validator","validatorObj","withMessage","$message","withAsync","$watchTargets","forEach","validators","collection","_len","others","previous","collectionItem","collectionEntryResult","innerValidators","propertyResult","currentValidator","$valid","_ref3","req","regex","expr","reg","common","alpha$1","alpha","alphaNum$1","alphaNum","numeric$1","numeric","emailRegex","email$1","email","ipAddress$1","nibbles","nibbleValid","nibble","ipAddress","maxLength$1","maxLength","minLength$1","minLength","min","required$1","required","validate$1","requiredIf$1","propOrFunction","parentVM","requiredIf","urlRegex","url$1","integer$1","integer","decimal$1","decimal","helpersImport","alphaImport","alphaNumImport","decimalImport","emailImport","integerImport","ipAddressImport","maxLengthImport","minLengthImport","numericImport","requiredImport","requiredIfImport","urlImport","cartStore","selectedCheckoutCountry","countries","updateSelectedValues","setCountry","componentLoading","loading","newCartQuantity","toggleWrappingPaper","changeValue","newQuantity","productID","quantity","_j","_k"],"mappings":"AAOA,SAASA,GAAQC,EAAKC,EAAkB,CACpC,MAAMC,EAAM,OAAO,OAAO,IAAI,EACxBC,EAAOH,EAAI,MAAM,GAAG,EAC1B,QAAS,EAAI,EAAG,EAAIG,EAAK,OAAQ,IAC7BD,EAAIC,EAAK,IAAM,GAEnB,OAAOF,EAAmBG,GAAO,CAAC,CAACF,EAAIE,EAAI,YAAa,GAAIA,GAAO,CAAC,CAACF,EAAIE,EAC7E,CA+BA,MAAMC,GAAuB,mMAGvBC,GAAsCP,GAAQM,EAAoB,EAyDlEE,GAAsB,8EACtBC,GAAqCT,GAAQQ,EAAmB,EAYtE,SAASE,GAAmBC,EAAO,CAC/B,MAAO,CAAC,CAACA,GAASA,IAAU,EAChC,CA+FA,SAASC,GAAeD,EAAO,CAC3B,GAAIE,EAAQF,CAAK,EAAG,CAChB,MAAMG,EAAM,CAAA,EACZ,QAASC,EAAI,EAAGA,EAAIJ,EAAM,OAAQI,IAAK,CACnC,MAAMC,EAAOL,EAAM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