PageSourceSearch

https://www.badfoerderung.at/build/bundlefa5b1177e02e083c8be3.js

js badfoerderung.at collected 2026-10-06 06:06:05 UTC 1,082,250 bytes, 32,784 lines download raw bytes

1/******/ (() => { // webpackBootstrap
2/******/ 	var __webpack_modules__ = ({
3
4/***/ 540
5(module) {
6
7"use strict";
8
9
10/* istanbul ignore next  */
11function insertStyleElement(options) {
12  var element = document.createElement("style");
13  options.setAttributes(element, options.attributes);
14  options.insert(element, options.options);
15  return element;
16}
17module.exports = insertStyleElement;
18
19/***/ },
20
21/***/ 603
22(module, __webpack_exports__, __webpack_require__) {
23
24"use strict";
25/* harmony export */ __webpack_require__.d(__webpack_exports__, {
26/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
27/* harmony export */ });
28/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1601);
29/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
30/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6314);
31/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
32// Imports
33
34
35var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
36// Module
37___CSS_LOADER_EXPORT___.push([module.id, `
38body #sp-status-bar {
39    position: fixed;
40    width: 100%;
41    bottom: 0;
42    z-index: 999999;
43    line-height: 1.2;
44    height: 50px;
45    background: linear-gradient(to bottom right, #333, #203135);
46
47    padding: 0 10px;
48    display: flex;
49    align-items: center;
50    justify-content: space-between;
51
52    font-family: "Montserrat", sans-serif;
53
54    box-shadow: 0 5px 25px rgba(0, 0, 0, .8) inset;
55}
56.sp-status-bar__main-area {
57    display: flex;
58    align-items: center;
59}
60.sp-status-bar-admin-button {
61    display: flex;
62    color: #f0f0f0;
63    align-items: center;
64    gap: 10px;
65    font-size: 13px;
66    border-right: 1px solid #666;
67    padding-right: 15px;
68}
69.sp-status-bar-admin-button__icon {
70    height: 30px;
71    width: auto;
72    transition: transform .3s;
73}
74.sp-status-bar-admin-button__font-icon {
75    font-size: 26px;
76}
77.sp-status-bar-admin-button:hover .sp-status-bar-admin-button__icon,
78.sp-status-bar-admin-button:hover .sp-status-bar-admin-button__font-icon {
79    transform: scale(1.1);
80}
81.sp-status-bar-admin-button:active .sp-status-bar-admin-button__icon,
82.sp-status-bar-admin-button:active .sp-status-bar-admin-button__font-icon {
83    transform: scale(0.95);
84}
85.sp-status-bar-button {
86    padding: 5px 15px;
87    color: #f0f0f0;
88    border-radius: 100px;
89    font-size: 13px;
90    font-weight: 500;
91    transition: background .3s, transform .3s;
92    border: 1px solid #f0f0f0;
93
94    margin-left: 15px;
95    display: flex;
96    align-items: center;
97}
98.sp-status-bar-button:hover {
99    background: rgba(255, 255, 255, 0.8);
100    color: #333;
101    transform: scale(1.05);
102}
103.sp-status-bar-button:active {
104    background: rgba(255, 255, 255, 0.6);
105    color: #333;
106    transform: scale(0.95);
107}
108.sp-status-bar-button i {
109    font-size: 16px;
110    margin-right: 5px;
111}
112.sp-status-bar-button--main {
113    background: #f0f0f0;
114    color: #333;
115}
116.sp-status-bar__info,
117.sp-status-bar-status {
118    color: #f0f0f0;
119    font-size: 13px;
120    margin-left: 15px;
121}
122.sp-status-bar-status {
123    display: flex;
124    align-items: center;
125    gap: 5px;
126}
127.sp-status-bar-status__label {
128    font-weight: 500;
129    font-size: 11px;
130    line-height: 1;
131}
132.sp-status-bar-status__indicator {
133    width: 15px;
134    height: 15px;
135    background-color: #ccc;
136    display: inline-block;
137    border-radius: 50%;
138    box-shadow: -3px -3px 3px rgba(0,0,0,0.1) inset, 3px 3px 3px rgba(255,255,255,0.2) inset;
139}
140.sp-status-bar-status__indicator--online {
141    background-color: #3c3;
142}
143.sp-status-bar-status__indicator--noindex {
144    background-color: #f70;
145}
146.sp-status-bar-status__indicator--offline {
147    background-color: #e33;
148}
149@media (max-width: 767px) {
150.sp-status-bar-button__label {
151        display: none;
152}
153.sp-status-bar-button i {
154        margin-right: 0;
155}
156}
157@media (max-width: 599px) {
158.sp-status-bar-status {
159        display: none;
160}
161}
162
163`, ""]);
164// Exports
165/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_
165LOADER_EXPORT___);
166
167
168/***/ },
169
170/***/ 729
171() {
172
173offlinePaymentService =
174{
175    subscriptions: [
176        {
177            "eventName": "payment.confirm",
178            "functionName": "confirm"
179        }
180    ],
181
182    confirm(paymentMethodIdentifier, checkout) {
183
184        let paymentMethodNames = ['cash-on-delivery', 'in-advance', 'on-account', 'on-pickup'];
185        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
186
187        console.debug('Offline payment confirm');
188
189        let authorizationData = []
190        paymentSubscriberNotifier.notify("payment.confirmed", authorizationData);
191    }
192
193}
194
195paymentSubscriberRegistry.register(offlinePaymentService);
196
197/***/ },
198
199/***/ 1016
200(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
201
202"use strict";
203/* harmony export */ __webpack_require__.d(__webpack_exports__, {
204/* harmony export */   M: () => (/* binding */ SecureCookieRemove),
205/* harmony export */   o: () => (/* binding */ SecureCookie)
206/* harmony export */ });
207/* harmony import */ var cookiejs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2051);
208/* harmony import */ var cookiejs__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(cookiejs__WEBPACK_IMPORTED_MODULE_0__);
209
210
211// Shopando Cookie Wrapper
212// uses secure and sameSite none if used in iframe, otherwise sameSite lax
213// also implemented on server side in src/Service/CookieService.php
214function SecureCookie(key, value, expires) {
215
216    // if no value is given it is get cookie
217    
218    if (value === undefined) {
219        return cookiejs__WEBPACK_IMPORTED_MODULE_0___default()(key);
220    }
221
222    let options;
223    if (SP_CONSTANTS.DEVELOPMENT_SERVER) {
224        options = {
225            expires: expires,
226        };
227    } else {
228        options = {
229            expires: expires,
230            secure: true,
231            sameSite: 'None'
232        };
233    }
234
235    if (options.expires == null) delete options.expires;
236
237    cookiejs__WEBPACK_IMPORTED_MODULE_0___default()(key, value, options);
238}
239
240function SecureCookieRemove(key) {
241    cookiejs__WEBPACK_IMPORTED_MODULE_0___default().remove(key);
242}
243
244/***/ },
245
246/***/ 1113
247(module) {
248
249"use strict";
250
251
252/* istanbul ignore next  */
253function styleTagTransform(css, styleElement) {
254  if (styleElement.styleSheet) {
255    styleElement.styleSheet.cssText = css;
256  } else {
257    while (styleElement.firstChild) {
258      styleElement.removeChild(styleElement.firstChild);
259    }
260    styleElement.appendChild(document.createTextNode(css));
261  }
262}
263module.exports = styleTagTransform;
264
265/***/ },
266
267/***/ 1143
268(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
269
270"use strict";
271__webpack_require__.r(__webpack_exports__);
272// extracted by mini-css-extract-plugin
273
274
275/***/ },
276
277/***/ 1174
278(module, __webpack_exports__, __webpack_require__) {
279
280"use strict";
281/* harmony export */ __webpack_require__.d(__webpack_exports__, {
282/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
283/* harmony export */ });
284/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1601);
285/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
286/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6314);
287/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
288// Imports
289
290
291var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
292// Module
293___CSS_LOADER_EXPORT___.push([module.id, `
294.c-o-i__tooltip-button[data-v-dc305a40] {
295	display: inline-block;
296	font-size: 0.9em;
297	width: 1em;
298	line-height: 1;
299	padding: 3px;
300	margin-left: 10px;
301	border-radius: 50%;
302	text-align: center;
303	background-color: #fff;
304	box-sizing: content-box;
305	font-weight: 600;
306    box-shadow: 0 0 3px rgba(0,0,0,0.2);
307	cursor: pointer;
308}
309.c-o-i__tooltip-popup[data-v-dc305a40] {
310	font-size: 0.8em;
311	width: 100%;
312	/* display: none; */
313	margin: 10px 0;
314	background-color: #fff;
315	padding: 8px;
316	border-radius: 4px;
317}
318`, ""]);
319// Exports
320/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_
320LOADER_EXPORT___);
321
322
323/***/ },
324
325/***/ 1425
326(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
327
328"use strict";
329
330// EXPORTS
331__webpack_require__.d(__webpack_exports__, {
332  FK: () => (/* reexport */ Fragment),
333  eB: () => (/* reexport */ Transition),
334  EW: () => (/* reexport */ runtime_core_esm_bundler_computed),
335  Ef: () => (/* reexport */ createApp),
336  Wv: () => (/* reexport */ createBlock),
337  Q3: () => (/* reexport */ createCommentVNode),
338  CE: () => (/* reexport */ createElementBlock),
339  Lk: () => (/* reexport */ createBaseVNode),
340  eW: () => (/* reexport */ createTextVNode),
341  bF: () => (/* reexport */ createVNode),
342  $V: () => (/* reexport */ defineAsyncComponent),
343  uY: () => (/* reexport */ effectScope),
344  h: () => (/* reexport */ h),
345  WQ: () => (/* reexport */ inject),
346  v6: () => (/* reexport */ mergeProps),
347  C4: () => (/* reexport */ normalizeClass),
348  Tr: () => (/* reexport */ normalizeStyle),
349  uX: () => (/* reexport */ openBlock),
350  Kh: () => (/* reexport */ reactive),
351  pI: () => (/* reexport */ renderList),
352  RG: () => (/* reexport */ renderSlot),
353  g2: () => (/* reexport */ resolveComponent),
354  $y: () => (/* reexport */ resolveDynamicComponent),
355  v_: () => (/* reexport */ toDisplayString),
356  lH: () => (/* reexport */ vModelCheckbox),
357  Jo: () => (/* reexport */ vModelText),
358  wB: () => (/* reexport */ runtime_core_esm_bundler_watch),
359  k6: () => (/* reexport */ withCtx),
360  bo: () => (/* reexport */ withDirectives),
361  jR: () => (/* reexport */ withKeys),
362  D$: () => (/* reexport */ withModifiers)
363});
364
365// UNUSED EXPORTS: BaseTransition, BaseTransitionPropsValidators, Comment, DeprecationTypes, EffectScope, ErrorCodes, ErrorTypeStrings, KeepAlive, ReactiveEffect, Static, Suspense, Teleport, Text, TrackOpTypes, TransitionGroup, TriggerOpTypes, VueElement, assertNumber, callWithAsyncErrorHandling, callWithErrorHandling, camelize, capitalize, cloneVNode, compatUtils, compile, createHydrationRenderer, createPropsRestProxy, createRenderer, createSSRApp, createSlots, createStaticVNode, customRef, defineComponent, defineCustomElement, defineEmits, defineExpose, defineModel, defineOptions, defineProps, defineSSRCustomElement, defineSlots, devtools, effect, getCurrentInstance, getCurrentScope, getCurrentWatcher, getTransitionRawChildren, guardReactiveProps, handleError, hasInjectionContext, hydrate, hydrateOnIdle, hydrateOnInteraction, hydrateOnMediaQuery, hydrateOnVisible, initCustomFormatter, initDirectivesForSSR, isMemoSame, isProxy, isReactive, isReadonly, isRef, isRuntimeOnly, isShallow, isVNode, markRaw, mergeDefaults, mergeModels, nextTick, nodeOps, normalizeProps, onActivated, onBeforeMount, onBeforeUnmount, onBeforeUpdate, onDeactivated, onErrorCaptured, onMounted, onRenderTracked, onRenderTriggered, onScopeDispose, onServerPrefetch, onUnmounted, onUpdated, onWatcherCleanup, patchProp, popScopeId, provide, proxyRefs, pushScopeId, queuePostFlushCb, readonly, ref, registerRuntimeCompiler, render, resolveDirective, resolveFilter, resolveTransitionHooks, setBlockTracking, setDevtoolsHook, setTransitionHooks, shallowReactive, shallowReadonly, shallowRef, ssrContextKey, ssrUtils, stop, toHandlerKey, toHandlers, toRaw, toRef, toRefs, toValue, transformVNodeArgs, triggerRef, unref, useAttrs, useCssModule, useCssVars, useHost, useId, useModel, useSSRContext, useShadowRoot, useSlots, useTemplateRef, useTransitionState, vModelDynamic, vModelRadio, vModelSelect, vShow, version, warn, watchEffect, watchPostEffect, watchSyncEffect, withAsyncContext, withDefaults, withMemo, withScopeId
366
367// NAMESPACE OBJECT: ./node_modules/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js
368var runtime_dom_esm_bundler_namespaceObject = {};
369__webpack_require__.r(runtime_dom_esm_bundler_namespaceObject);
370__webpack_require__.d(runtime_dom_esm_bundler_namespaceObject, {
371  BaseTransition: () => (BaseTransition),
372  BaseTransitionPropsValidators: () => (BaseTransitionPropsValidators),
373  Comment: () => (Comment),
374  DeprecationTypes: () => (DeprecationTypes),
375  EffectScope: () => (EffectScope),
376  ErrorCodes: () => (ErrorCodes),
377  ErrorTypeStrings: () => (ErrorTypeStrings),
378  Fragment: () => (Fragment),
379  KeepAlive: () => (KeepAlive),
380  ReactiveEffect: () => (ReactiveEffect),
381  Static: () => (Static),
382  Suspense: () => (Suspense),
383  Teleport: () => (Teleport),
384  Text: () => (Text),
385  TrackOpTypes: () => (TrackOpTypes),
386  Transition: () => (Transition),
387  TransitionGroup: () => (TransitionGroup),
388  TriggerOpTypes: () => (TriggerOpTypes),
389  VueElement: () => (VueElement),
390  assertNumber: () => (assertNumber),
391  callWithAsyncErrorHandling: () => (callWithAsyncErrorHandling),
392  callWithErrorHandling: () => (callWithErrorHandling),
393  camelize: () => (shared_esm_bundler_camelize),
394  capitalize: () => (shared_esm_bundler_capitalize),
395  cloneVNode: () => (cloneVNode),
396  compatUtils: () => (compatUtils),
397  computed: () => (runtime_core_esm_bundler_computed),
398  createApp: () => (createApp),
399  createBlock: () => (createBlock),
400  createCommentVNode: () => (createCommentVNode),
401  createElementBlock: () => (createElementBlock),
402  createElementVNode: () => (createBaseVNode),
403  createHydrationRenderer: () => (createHydrationRenderer),
404  createPropsRestProxy: () => (createPropsRestProxy),
405  createRenderer: () => (createRenderer),
406  createSSRApp: () => (createSSRApp),
407  createSlots: () => (createSlots),
408  createStaticVNode: () => (createStaticVNode),
409  createTextVNode: () => (createTextVNode),
410  createVNode: () => (createVNode),
411  customRef: () => (customRef),
412  defineAsyncComponent: () => (defineAsyncComponent),
413  defineComponent: () => (defineComponent),
414  defineCustomElement: () => (defineCustomElement),
415  defineEmits: () => (defineEmits),
416  defineExpose: () => (defineExpose),
417  defineModel: () => (defineModel),
418  defineOptions: () => (defineOptions),
419  defineProps: () => (defineProps),
420  defineSSRCustomElement: () => (defineSSRCustomElement),
421  defineSlots: () => (defineSlots),
422  devtools: () => (devtools),
423  effect: () => (effect),
424  effectScope: () => (effectScope),
425  getCurrentInstance: () => (getCurrentInstance),
426  getCurrentScope: () => (getCurrentScope),
427  getCurrentWatcher: () => (getCurrentWatcher),
428  getTransitionRawChildren: () => (getTransitionRawChildren),
429  guardReactiveProps: () => (guardReactiveProps),
430  h: () => (h),
431  handleError: () => (handleError),
432  hasInjectionContext: () => (hasInjectionContext),
433  hydrate: () => (hydrate),
434  hydrateOnIdle: () => (hydrateOnIdle),
435  hydrateOnInteraction: () => (hydrateOnInteraction),
436  hydrateOnMediaQuery: () => (hydrateOnMediaQuery),
437  hydrateOnVisible: () => (hydrateOnVisible),
438  initCustomFormatter: () => (runtime_core_esm_bundler_initCustomFormatter),
439  initDirectivesForSSR: () => (initDirectivesForSSR),
440  inject: () => (inject),
441  isMemoSame: () => (isMemoSame),
442  isProxy: () => (isProxy),
443  isReactive: () => (isReactive),
444  isReadonly: () => (isReadonly),
445  isRef: () => (reactivity_esm_bundler_isRef),
446  isRuntimeOnly: () => (runtime_core_esm_bundler_isRuntimeOnly),
447  isShallow: () => (isShallow),
448  isVNode: () => (isVNode),
449  markRaw: () => (markRaw),
450  mergeDefaults: () => (mergeDefaults),
451  mergeModels: () => (mergeModels),
452  mergeProps: () => (mergeProps),
453  nextTick: () => (nextTick),
454  nodeOps: () => (nodeOps),
455  normalizeClass: () => (normalizeClass),
456  normalizeProps: () => (normalizeProps),
457  normalizeStyle: () => (normalizeStyle),
458  onActivated: () => (onActivated),
459  onBeforeMount: () => (onBeforeMount),
460  onBeforeUnmount: () => (onBeforeUnmount),
461  onBeforeUpdate: () => (onBeforeUpdate),
462  onDeactivated: () => (onDeactivated),
463  onErrorCaptured: () => (onErrorCaptured),
464  onMounted: () => (onMounted),
465  onRenderTracked: () => (onRenderTracked),
466  onRenderTriggered: () => (onRenderTriggered),
467  onScopeDispose: () => (onScopeDispose),
468  onServerPrefetch: () => (onServerPrefetch),
469  onUnmounted: () => (onUnmounted),
470  onUpdated: () => (onUpdated),
471  onWatcherCleanup: () => (onWatcherCleanup),
472  openBlock: () => (openBlock),
473  patchProp: () => (patchProp),
474  popScopeId: () => (popScopeId),
475  provide: () => (provide),
476  proxyRefs: () => (proxyRefs),
477  pushScopeId: () => (pushScopeId),
478  queuePostFlushCb: () => (queuePostFlushCb),
479  reactive: () => (reactive),
480  readonly: () => (readonly),
481  ref: () => (ref),
482  registerRuntimeCompiler: () => (registerRuntimeCompiler),
483  render: () => (render),
484  renderList: () => (renderList),
485  renderSlot: () => (renderSlot),
486  resolveComponent: () => (resolveComponent),
487  resolveDirective: () => (resolveDirective),
488  resolveDynamicComponent: () => (resolveDynamicComponent),
489  resolveFilter: () => (resolveFilter),
490  resolveTransitionHooks: () => (resolveTransitionHooks),
491  setBlockTracking: () => (setBlockTracking),
492  setDevtoolsHook: () => (setDevtoolsHook),
493  setTransitionHooks: () => (setTransitionHooks),
494  shallowReactive: () => (shallowReactive),
495  shallowReadonly: () => (shallowReadonly),
496  shallowRef: () => (shallowRef),
497  ssrContextKey: () => (ssrContextKey),
498  ssrUtils: () => (ssrUtils),
499  stop: () => (stop),
500  toDisplayString: () => (toDisplayString),
501  toHandlerKey: () => (toHandlerKey),
502  toHandlers: () => (toHandlers),
503  toRaw: () => (reactivity_esm_bundler_toRaw),
504  toRef: () => (toRef),
505  toRefs: () => (toRefs),
506  toValue: () => (toValue),
507  transformVNodeArgs: () => (transformVNodeArgs),
508  triggerRef: () => (triggerRef),
509  unref: () => (unref),
510  useAttrs: () => (useAttrs),
511  useCssModule: () => (useCssModule),
512  useCssVars: () => (useCssVars),
513  useHost: () => (useHost),
514  useId: () => (useId),
515  useModel: () => (useModel),
516  useSSRContext: () => (useSSRContext),
517  useShadowRoot: () => (useShadowRoot),
518  useSlots: () => (useSlots),
519  useTemplateRef: () => (useTemplateRef),
520  useTransitionState: () => (useTransitionState),
521  vModelCheckbox: () => (vModelCheckbox),
522  vModelDynamic: () => (vModelDynamic),
523  vModelRadio: () => (vModelRadio),
524  vModelSelect: () => (vModelSelect),
525  vModelText: () => (vModelText),
526  vShow: () => (vShow),
527  version: () => (version),
528  warn: () => (runtime_core_esm_bundler_warn),
529  watch: () => (runtime_core_esm_bundler_watch),
530  watchEffect: () => (watchEffect),
531  watchPostEffect: () => (watchPostEffect),
532  watchSyncEffect: () => (watchSyncEffect),
533  withAsyncContext: () => (withAsyncContext),
534  withCtx: () => (withCtx),
535  withDefaults: () => (withDefaults),
536  withDirectives: () => (withDirectives),
537  withKeys: () => (withKeys),
538  withMemo: () => (withMemo),
539  withModifiers: () => (withModifiers),
540  withScopeId: () => (withScopeId)
541});
542
543;// ./node_modules/@vue/shared/dist/shared.esm-bundler.js
544/**
545* @vue/shared v3.5.25
546* (c) 2018-present Yuxi (Evan) You and Vue contributors
547* @license MIT
vendor: 6,292 bytes, lines 548-748
548**/
549// @__NO_SIDE_EFFECTS__
550function shared_esm_bundler_makeMap(str) {
551  const map = /* @__PURE__ */ Object.create(null);
552  for (const key of str.split(",")) map[key] = 1;
553  return (val) => val in map;
554}
555
556const EMPTY_OBJ =  false ? 0 : {};
557const EMPTY_ARR =  false ? 0 : [];
558const shared_esm_bundler_NOOP = () => {
559};
560const NO = () => false;
561const isOn = (key) => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && // uppercase letter
562(key.charCodeAt(2) > 122 || key.charCodeAt(2) < 97);
563const isModelListener = (key) => key.startsWith("onUpdate:");
564const shared_esm_bundler_extend = Object.assign;
565const remove = (arr, el) => {
566  const i = arr.indexOf(el);
567  if (i > -1) {
568    arr.splice(i, 1);
569  }
570};
571const shared_esm_bundler_hasOwnProperty = Object.prototype.hasOwnProperty;
572const hasOwn = (val, key) => shared_esm_bundler_hasOwnProperty.call(val, key);
573const shared_esm_bundler_isArray = Array.isArray;
574const isMap = (val) => toTypeString(val) === "[object Map]";
575const isSet = (val) => toTypeString(val) === "[object Set]";
576const isDate = (val) => toTypeString(val) === "[object Date]";
577const isRegExp = (val) => toTypeString(val) === "[object RegExp]";
578const shared_esm_bundler_isFunction = (val) => typeof val === "function";
579const shared_esm_bundler_isString = (val) => typeof val === "string";
580const isSymbol = (val) => typeof val === "symbol";
581const shared_esm_bundler_isObject = (val) => val !== null && typeof val === "object";
582const isPromise = (val) => {
583  return (shared_esm_bundler_isObject(val) || shared_esm_bundler_isFunction(val)) && shared_esm_bundler_isFunction(val.then) && shared_esm_bundler_isFunction(val.catch);
584};
585const objectToString = Object.prototype.toString;
586const toTypeString = (value) => objectToString.call(value);
587const shared_esm_bundler_toRawType = (value) => {
588  return toTypeString(value).slice(8, -1);
589};
590const isPlainObject = (val) => toTypeString(val) === "[object Object]";
591const isIntegerKey = (key) => shared_esm_bundler_isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
592const isReservedProp = /* @__PURE__ */ shared_esm_bundler_makeMap(
593  // the leading comma is intentional so empty string "" is also included
594  ",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"
595);
596const shared_esm_bundler_isBuiltInDirective = /* @__PURE__ */ shared_esm_bundler_makeMap(
597  "bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"
598);
599const cacheStringFunction = (fn) => {
600  const cache = /* @__PURE__ */ Object.create(null);
601  return ((str) => {
602    const hit = cache[str];
603    return hit || (cache[str] = fn(str));
604  });
605};
606const camelizeRE = /-\w/g;
607const shared_esm_bundler_camelize = cacheStringFunction(
608  (str) => {
609    return str.replace(camelizeRE, (c) => c.slice(1).toUpperCase());
610  }
611);
612const hyphenateRE = /\B([A-Z])/g;
613const hyphenate = cacheStringFunction(
614  (str) => str.replace(hyphenateRE, "-$1").toLowerCase()
615);
616const shared_esm_bundler_capitalize = cacheStringFunction((str) => {
617  return str.charAt(0).toUpperCase() + str.slice(1);
618});
619const toHandlerKey = cacheStringFunction(
620  (str) => {
621    const s = str ? `on${shared_esm_bundler_capitalize(str)}` : ``;
622    return s;
623  }
624);
625const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
626const invokeArrayFns = (fns, ...arg) => {
627  for (let i = 0; i < fns.length; i++) {
628    fns[i](...arg);
629  }
630};
631const def = (obj, key, value, writable = false) => {
632  Object.defineProperty(obj, key, {
633    configurable: true,
634    enumerable: false,
635    writable,
636    value
637  });
638};
639const looseToNumber = (val) => {
640  const n = parseFloat(val);
641  return isNaN(n) ? val : n;
642};
643const toNumber = (val) => {
644  const n = shared_esm_bundler_isString(val) ? Number(val) : NaN;
645  return isNaN(n) ? val : n;
646};
647let _globalThis;
648const getGlobalThis = () => {
649  return _globalThis || (_globalThis = typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof globalThis !== "undefined" ? globalThis : {});
650};
651const identRE = /^[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*$/;
652function genPropsAccessExp(name) {
653  return identRE.test(name) ? `__props.${name}` : `__props[${JSON.stringify(name)}]`;
654}
655function genCacheKey(source, options) {
656  return source + JSON.stringify(
657    options,
658    (_, val) => typeof val === "function" ? val.toString() : val
659  );
660}
661
662const PatchFlags = {
663  "TEXT": 1,
664  "1": "TEXT",
665  "CLASS": 2,
666  "2": "CLASS",
667  "STYLE": 4,
668  "4": "STYLE",
669  "PROPS": 8,
670  "8": "PROPS",
671  "FULL_PROPS": 16,
672  "16": "FULL_PROPS",
673  "NEED_HYDRATION": 32,
674  "32": "NEED_HYDRATION",
675  "STABLE_FRAGMENT": 64,
676  "64": "STABLE_FRAGMENT",
677  "KEYED_FRAGMENT": 128,
678  "128": "KEYED_FRAGMENT",
679  "UNKEYED_FRAGMENT": 256,
680  "256": "UNKEYED_FRAGMENT",
681  "NEED_PATCH": 512,
682  "512": "NEED_PATCH",
683  "DYNAMIC_SLOTS": 1024,
684  "1024": "DYNAMIC_SLOTS",
685  "DEV_ROOT_FRAGMENT": 2048,
686  "2048": "DEV_ROOT_FRAGMENT",
687  "CACHED": -1,
688  "-1": "CACHED",
689  "BAIL": -2,
690  "-2": "BAIL"
691};
692const PatchFlagNames = {
693  [1]: `TEXT`,
694  [2]: `CLASS`,
695  [4]: `STYLE`,
696  [8]: `PROPS`,
697  [16]: `FULL_PROPS`,
698  [32]: `NEED_HYDRATION`,
699  [64]: `STABLE_FRAGMENT`,
700  [128]: `KEYED_FRAGMENT`,
701  [256]: `UNKEYED_FRAGMENT`,
702  [512]: `NEED_PATCH`,
703  [1024]: `DYNAMIC_SLOTS`,
704  [2048]: `DEV_ROOT_FRAGMENT`,
705  [-1]: `CACHED`,
706  [-2]: `BAIL`
707};
708
709const ShapeFlags = {
710  "ELEMENT": 1,
711  "1": "ELEMENT",
712  "FUNCTIONAL_COMPONENT": 2,
713  "2": "FUNCTIONAL_COMPONENT",
714  "STATEFUL_COMPONENT": 4,
715  "4": "STATEFUL_COMPONENT",
716  "TEXT_CHILDREN": 8,
717  "8": "TEXT_CHILDREN",
718  "ARRAY_CHILDREN": 16,
719  "16": "ARRAY_CHILDREN",
720  "SLOTS_CHILDREN": 32,
721  "32": "SLOTS_CHILDREN",
722  "TELEPORT": 64,
723  "64": "TELEPORT",
724  "SUSPENSE": 128,
725  "128": "SUSPENSE",
726  "COMPONENT_SHOULD_KEEP_ALIVE": 256,
727  "256": "COMPONENT_SHOULD_KEEP_ALIVE",
728  "COMPONENT_KEPT_ALIVE": 512,
729  "512": "COMPONENT_KEPT_ALIVE",
730  "COMPONENT": 6,
731  "6": "COMPONENT"
732};
733
734const SlotFlags = {
735  "STABLE": 1,
736  "1": "STABLE",
737  "DYNAMIC": 2,
738  "2": "DYNAMIC",
739  "FORWARDED": 3,
740  "3": "FORWARDED"
741};
742const slotFlagsText = {
743  [1]: "STABLE",
744  [2]: "DYNAMIC",
745  [3]: "FORWARDED"
746};
747
748const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decode
vendor: 6,542 bytes, lines 748-881
748URI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol";
749const isGloballyAllowed = /* @__PURE__ */ shared_esm_bundler_makeMap(GLOBALS_ALLOWED);
750const isGloballyWhitelisted = (/* unused pure expression or super */ null && (isGloballyAllowed));
751
752const range = 2;
753function generateCodeFrame(source, start = 0, end = source.length) {
754  start = Math.max(0, Math.min(start, source.length));
755  end = Math.max(0, Math.min(end, source.length));
756  if (start > end) return "";
757  let lines = source.split(/(\r?\n)/);
758  const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
759  lines = lines.filter((_, idx) => idx % 2 === 0);
760  let count = 0;
761  const res = [];
762  for (let i = 0; i < lines.length; i++) {
763    count += lines[i].length + (newlineSequences[i] && newlineSequences[i].length || 0);
764    if (count >= start) {
765      for (let j = i - range; j <= i + range || end > count; j++) {
766        if (j < 0 || j >= lines.length) continue;
767        const line = j + 1;
768        res.push(
769          `${line}${" ".repeat(Math.max(3 - String(line).length, 0))}|  ${lines[j]}`
770        );
771        const lineLength = lines[j].length;
772        const newLineSeqLength = newlineSequences[j] && newlineSequences[j].length || 0;
773        if (j === i) {
774          const pad = start - (count - (lineLength + newLineSeqLength));
775          const length = Math.max(
776            1,
777            end > count ? lineLength - pad : end - start
778          );
779          res.push(`   |  ` + " ".repeat(pad) + "^".repeat(length));
780        } else if (j > i) {
781          if (end > count) {
782            const length = Math.max(Math.min(end - count, lineLength), 1);
783            res.push(`   |  ` + "^".repeat(length));
784          }
785          count += lineLength + newLineSeqLength;
786        }
787      }
788      break;
789    }
790  }
791  return res.join("\n");
792}
793
794function normalizeStyle(value) {
795  if (shared_esm_bundler_isArray(value)) {
796    const res = {};
797    for (let i = 0; i < value.length; i++) {
798      const item = value[i];
799      const normalized = shared_esm_bundler_isString(item) ? parseStringStyle(item) : normalizeStyle(item);
800      if (normalized) {
801        for (const key in normalized) {
802          res[key] = normalized[key];
803        }
804      }
805    }
806    return res;
807  } else if (shared_esm_bundler_isString(value) || shared_esm_bundler_isObject(value)) {
808    return value;
809  }
810}
811const listDelimiterRE = /;(?![^(]*\))/g;
812const propertyDelimiterRE = /:([^]+)/;
813const styleCommentRE = /\/\*[^]*?\*\//g;
814function parseStringStyle(cssText) {
815  const ret = {};
816  cssText.replace(styleCommentRE, "").split(listDelimiterRE).forEach((item) => {
817    if (item) {
818      const tmp = item.split(propertyDelimiterRE);
819      tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
820    }
821  });
822  return ret;
823}
824function stringifyStyle(styles) {
825  if (!styles) return "";
826  if (shared_esm_bundler_isString(styles)) return styles;
827  let ret = "";
828  for (const key in styles) {
829    const value = styles[key];
830    if (shared_esm_bundler_isString(value) || typeof value === "number") {
831      const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);
832      ret += `${normalizedKey}:${value};`;
833    }
834  }
835  return ret;
836}
837function normalizeClass(value) {
838  let res = "";
839  if (shared_esm_bundler_isString(value)) {
840    res = value;
841  } else if (shared_esm_bundler_isArray(value)) {
842    for (let i = 0; i < value.length; i++) {
843      const normalized = normalizeClass(value[i]);
844      if (normalized) {
845        res += normalized + " ";
846      }
847    }
848  } else if (shared_esm_bundler_isObject(value)) {
849    for (const name in value) {
850      if (value[name]) {
851        res += name + " ";
852      }
853    }
854  }
855  return res.trim();
856}
857function normalizeProps(props) {
858  if (!props) return null;
859  let { class: klass, style } = props;
860  if (klass && !shared_esm_bundler_isString(klass)) {
861    props.class = normalizeClass(klass);
862  }
863  if (style) {
864    props.style = normalizeStyle(style);
865  }
866  return props;
867}
868
869const HTML_TAGS = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot";
870const SVG_TAGS = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view";
871const MATH_TAGS = "annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics";
872const VOID_TAGS = "area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr";
873const shared_esm_bundler_isHTMLTag = /* @__PURE__ */ shared_esm_bundler_makeMap(HTML_TAGS);
874const shared_esm_bundler_isSVGTag = /* @__PURE__ */ shared_esm_bundler_makeMap(SVG_TAGS);
875const shared_esm_bundler_isMathMLTag = /* @__PURE__ */ shared_esm_bundler_makeMap(MATH_TAGS);
876const isVoidTag = /* @__PURE__ */ shared_esm_bundler_makeMap(VOID_TAGS);
877
878const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
879const isSpecialBooleanAttr = /* @__PURE__ */ shared_esm_bundler_makeMap(specialBooleanAttrs);
880const isBooleanAttr = /* @__PURE__ */ shared_esm_bundler_makeMap(
881  specialBooleanAttrs + `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,inert,loop,open,required,reversed,scoped,seamless,
881checked,muted,multiple,selected`
882);
883function includeBooleanAttr(value) {
884  return !!value || value === "";
885}
886const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/;
887const attrValidationCache = {};
888function isSSRSafeAttrName(name) {
889  if (attrValidationCache.hasOwnProperty(name)) {
890    return attrValidationCache[name];
891  }
892  const isUnsafe = unsafeAttrCharRE.test(name);
893  if (isUnsafe) {
894    console.error(`unsafe attribute name: ${name}`);
895  }
896  return attrValidationCache[name] = !isUnsafe;
897}
898const propsToAttrMap = {
899  acceptCharset: "accept-charset",
900  className: "class",
901  htmlFor: "for",
902  httpEquiv: "http-equiv"
903};
904const isKnownHtmlAttr = /* @__PURE__ */ shared_esm_bundler_makeMap(
905  `accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap`
906);
907const isKnownSvgAttr = /* @__PURE__ */ shared_esm_bundler_makeMap(
908  `xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode
908-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`
909);
910const isKnownMathMLAttr = /* @__PURE__ */ (/* unused pure expression or super */ null && (shared_esm_bundler_makeMap(
911  `accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns`
912)));
913function isRenderableAttrValue(value) {
914  if (value == null) {
915    return false;
916  }
917  const type = typeof value;
918  return type === "string" || type === "number" || type === "boolean";
919}
920
921const escapeRE = /["'&<>]/;
922function escapeHtml(string) {
923  const str = "" + string;
924  const match = escapeRE.exec(str);
925  if (!match) {
926    return str;
927  }
928  let html = "";
929  let escaped;
930  let index;
931  let lastIndex = 0;
932  for (index = match.index; index < str.length; index++) {
933    switch (str.charCodeAt(index)) {
934      case 34:
935        escaped = "&quot;";
936        break;
937      case 38:
938        escaped = "&amp;";
939        break;
940      case 39:
941        escaped = "&#39;";
942        break;
943      case 60:
944        escaped = "&lt;";
945        break;
946      case 62:
947        escaped = "&gt;";
948        break;
949      default:
950        continue;
951    }
952    if (lastIndex !== index) {
953      html += str.slice(lastIndex, index);
954    }
955    lastIndex = index + 1;
956    html += escaped;
957  }
958  return lastIndex !== index ? html + str.slice(lastIndex, index) : html;
959}
960const commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;
961function escapeHtmlComment(src) {
962  return src.replace(commentStripRE, "");
963}
964const cssVarNameEscapeSymbolsRE = /[ !"#$%&'()*+,./:;<=>?@[\\\]^`{|}~]/g;
965function getEscapedCssVarName(key, doubleEscape) {
966  return key.replace(
967    cssVarNameEscapeSymbolsRE,
968    (s) => doubleEscape ? s === '"' ? '\\\\\\"' : `\\\\${s}` : `\\${s}`
969  );
970}
971
972function looseCompareArrays(a, b) {
973  if (a.length !== b.length) return false;
974  let equal = true;
975  for (let i = 0; equal && i < a.length; i++) {
976    equal = looseEqual(a[i], b[i]);
977  }
978  return equal;
979}
980function looseEqual(a, b) {
981  if (a === b) return true;
982  let aValidType = isDate(a);
983  let bValidType = isDate(b);
984  if (aValidType || bValidType) {
985    return aValidType && bValidType ? a.getTime() === b.getTime() : false;
986  }
987  aValidType = isSymbol(a);
988  bValidType = isSymbol(b);
989  if (aValidType || bValidType) {
990    return a === b;
991  }
992  aValidType = shared_esm_bundler_isArray(a);
993  bValidType = shared_esm_bundler_isArray(b);
994  if (aValidType || bValidType) {
995    return aValidType && bValidType ? looseCompareArrays(a, b) : false;
996  }
997  aValidType = shared_esm_bundler_isObject(a);
998  bValidType = shared_esm_bundler_isObject(b);
999  if (aValidType || bValidType) {
1000    if (!aValidType || !bValidType) {
1001      return false;
1002    }
1003    const aKeysCount = Object.keys(a).length;
1004    const bKeysCount = Object.keys(b).length;
1005    if (aKeysCount !== bKeysCount) {
1006      return false;
1007    }
1008    for (const key in a) {
1009      const aHasKey = a.hasOwnProperty(key);
1010      const bHasKey = b.hasOwnProperty(key);
1011      if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key])) {
1012        return false;
vendor: 1,983 bytes, lines 1013-1081
1013      }
1014    }
1015  }
1016  return String(a) === String(b);
1017}
1018function looseIndexOf(arr, val) {
1019  return arr.findIndex((item) => looseEqual(item, val));
1020}
1021
1022const isRef = (val) => {
1023  return !!(val && val["__v_isRef"] === true);
1024};
1025const toDisplayString = (val) => {
1026  return shared_esm_bundler_isString(val) ? val : val == null ? "" : shared_esm_bundler_isArray(val) || shared_esm_bundler_isObject(val) && (val.toString === objectToString || !shared_esm_bundler_isFunction(val.toString)) ? isRef(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val);
1027};
1028const replacer = (_key, val) => {
1029  if (isRef(val)) {
1030    return replacer(_key, val.value);
1031  } else if (isMap(val)) {
1032    return {
1033      [`Map(${val.size})`]: [...val.entries()].reduce(
1034        (entries, [key, val2], i) => {
1035          entries[stringifySymbol(key, i) + " =>"] = val2;
1036          return entries;
1037        },
1038        {}
1039      )
1040    };
1041  } else if (isSet(val)) {
1042    return {
1043      [`Set(${val.size})`]: [...val.values()].map((v) => stringifySymbol(v))
1044    };
1045  } else if (isSymbol(val)) {
1046    return stringifySymbol(val);
1047  } else if (shared_esm_bundler_isObject(val) && !shared_esm_bundler_isArray(val) && !isPlainObject(val)) {
1048    return String(val);
1049  }
1050  return val;
1051};
1052const stringifySymbol = (v, i = "") => {
1053  var _a;
1054  return (
1055    // Symbol.description in es2019+ so we need to cast here to pass
1056    // the lib: es2016 check
1057    isSymbol(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v
1058  );
1059};
1060
1061function normalizeCssVarValue(value) {
1062  if (value == null) {
1063    return "initial";
1064  }
1065  if (typeof value === "string") {
1066    return value === "" ? " " : value;
1067  }
1068  if (typeof value !== "number" || !Number.isFinite(value)) {
1069    if (false) // removed by dead control flow
1070{}
1071  }
1072  return String(value);
1073}
1074
1075
1076
1077;// ./node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js
1078/**
1079* @vue/reactivity v3.5.25
1080* (c) 2018-present Yuxi (Evan) You and Vue contributors
1081* @license MIT
1082**/
1083
1084
1085function reactivity_esm_bundler_warn(msg, ...args) {
1086  console.warn(`[Vue warn] ${msg}`, ...args);
1087}
1088
1089let activeEffectScope;
1090class EffectScope {
1091  constructor(detached = false) {
1092    this.detached = detached;
1093    /**
1094     * @internal
1095     */
1096    this._active = true;
1097    /**
1098     * @internal track `on` calls, allow `on` call multiple times
1099     */
1100    this._on = 0;
1101    /**
1102     * @internal
1103     */
1104    this.effects = [];
1105    /**
1106     * @internal
1107     */
1108    this.cleanups = [];
1109    this._isPaused = false;
1110    this.parent = activeEffectScope;
1111    if (!detached && activeEffectScope) {
1112      this.index = (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(
1113        this
1114      ) - 1;
1115    }
1116  }
1117  get active() {
1118    return this._active;
1119  }
1120  pause() {
1121    if (this._active) {
1122      this._isPaused = true;
1123      let i, l;
1124      if (this.scopes) {
1125        for (i = 0, l = this.scopes.length; i < l; i++) {
1126          this.scopes[i].pause();
1127        }
1128      }
1129      for (i = 0, l = this.effects.length; i < l; i++) {
1130        this.effects[i].pause();
1131      }
1132    }
1133  }
1134  /**
1135   * Resumes the effect scope, including all child scopes and effects.
1136   */
1137  resume() {
1138    if (this._active) {
1139      if (this._isPaused) {
1140        this._isPaused = false;
1141        let i, l;
1142        if (this.scopes) {
1143          for (i = 0, l = this.scopes.length; i < l; i++) {
1144            this.scopes[i].resume();
1145          }
1146        }
1147        for (i = 0, l = this.effects.length; i < l; i++) {
1148          this.effects[i].resume();
1149        }
1150      }
1151    }
1152  }
1153  run(fn) {
1154    if (this._active) {
1155      const currentEffectScope = activeEffectScope;
1156      try {
1157        activeEffectScope = this;
1158        return fn();
1159      } finally {
1160        activeEffectScope = currentEffectScope;
1161      }
1162    } else if (false) // removed by dead control flow
1163{}
1164  }
1165  /**
1166   * This should only be called on non-detached scopes
1167   * @internal
1168   */
1169  on() {
1170    if (++this._on === 1) {
1171      this.prevScope = activeEffectScope;
1172      activeEffectScope = this;
1173    }
1174  }
1175  /**
1176   * This should only be called on non-detached scopes
1177   * @internal
1178   */
1179  off() {
1180    if (this._on > 0 && --this._on === 0) {
1181      activeEffectScope = this.prevScope;
1182      this.prevScope = void 0;
1183    }
1184  }
1185  stop(fromParent) {
1186    if (this._active) {
1187      this._active = false;
1188      let i, l;
1189      for (i = 0, l = this.effects.length; i < l; i++) {
1190        this.effects[i].stop();
1191      }
1192      this.effects.length = 0;
1193      for (i = 0, l = this.cleanups.length; i < l; i++) {
1194        this.cleanups[i]();
1195      }
1196      this.cleanups.length = 0;
1197      if (this.scopes) {
1198        for (i = 0, l = this.scopes.length; i < l; i++) {
1199          this.scopes[i].stop(true);
1200        }
1201        this.scopes.length = 0;
1202      }
1203      if (!this.detached && this.parent && !fromParent) {
1204        const last = this.parent.scopes.pop();
1205        if (last && last !== this) {
1206          this.parent.scopes[this.index] = last;
1207          last.index = this.index;
1208        }
1209      }
1210      this.parent = void 0;
1211    }
1212  }
1213}
1214function effectScope(detached) {
1215  return new EffectScope(detached);
1216}
1217function getCurrentScope() {
1218  return activeEffectScope;
1219}
1220function onScopeDispose(fn, failSilently = false) {
1221  if (activeEffectScope) {
1222    activeEffectScope.cleanups.push(fn);
1223  } else if (false) // removed by dead control flow
1224{}
1225}
1226
1227let activeSub;
1228const EffectFlags = {
1229  "ACTIVE": 1,
1230  "1": "ACTIVE",
1231  "RUNNING": 2,
1232  "2": "RUNNING",
1233  "TRACKING": 4,
1234  "4": "TRACKING",
1235  "NOTIFIED": 8,
1236  "8": "NOTIFIED",
1237  "DIRTY": 16,
1238  "16": "DIRTY",
1239  "ALLOW_RECURSE": 32,
1240  "32": "ALLOW_RECURSE",
1241  "PAUSED": 64,
1242  "64": "PAUSED",
1243  "EVALUATED": 128,
1244  "128": "EVALUATED"
1245};
1246const pausedQueueEffects = /* @__PURE__ */ new WeakSet();
1247class ReactiveEffect {
1248  constructor(fn) {
1249    this.fn = fn;
1250    /**
1251     * @internal
1252     */
1253    this.deps = void 0;
1254    /**
1255     * @internal
1256     */
1257    this.depsTail = void 0;
1258    /**
1259     * @internal
1260     */
1261    this.flags = 1 | 4;
1262    /**
1263     * @internal
1264     */
1265    this.next = void 0;
1266    /**
1267     * @internal
1268     */
1269    this.cleanup = void 0;
1270    this.scheduler = void 0;
1271    if (activeEffectScope && activeEffectScope.active) {
1272      activeEffectScope.effects.push(this);
1273    }
1274  }
1275  pause() {
1276    this.flags |= 64;
1277  }
1278  resume() {
1279    if (this.flags & 64) {
1280      this.flags &= -65;
vendor: 4,758 bytes, lines 1281-1498
1281      if (pausedQueueEffects.has(this)) {
1282        pausedQueueEffects.delete(this);
1283        this.trigger();
1284      }
1285    }
1286  }
1287  /**
1288   * @internal
1289   */
1290  notify() {
1291    if (this.flags & 2 && !(this.flags & 32)) {
1292      return;
1293    }
1294    if (!(this.flags & 8)) {
1295      batch(this);
1296    }
1297  }
1298  run() {
1299    if (!(this.flags & 1)) {
1300      return this.fn();
1301    }
1302    this.flags |= 2;
1303    cleanupEffect(this);
1304    prepareDeps(this);
1305    const prevEffect = activeSub;
1306    const prevShouldTrack = shouldTrack;
1307    activeSub = this;
1308    shouldTrack = true;
1309    try {
1310      return this.fn();
1311    } finally {
1312      if (false) // removed by dead control flow
1313{}
1314      cleanupDeps(this);
1315      activeSub = prevEffect;
1316      shouldTrack = prevShouldTrack;
1317      this.flags &= -3;
1318    }
1319  }
1320  stop() {
1321    if (this.flags & 1) {
1322      for (let link = this.deps; link; link = link.nextDep) {
1323        removeSub(link);
1324      }
1325      this.deps = this.depsTail = void 0;
1326      cleanupEffect(this);
1327      this.onStop && this.onStop();
1328      this.flags &= -2;
1329    }
1330  }
1331  trigger() {
1332    if (this.flags & 64) {
1333      pausedQueueEffects.add(this);
1334    } else if (this.scheduler) {
1335      this.scheduler();
1336    } else {
1337      this.runIfDirty();
1338    }
1339  }
1340  /**
1341   * @internal
1342   */
1343  runIfDirty() {
1344    if (isDirty(this)) {
1345      this.run();
1346    }
1347  }
1348  get dirty() {
1349    return isDirty(this);
1350  }
1351}
1352let batchDepth = 0;
1353let batchedSub;
1354let batchedComputed;
1355function batch(sub, isComputed = false) {
1356  sub.flags |= 8;
1357  if (isComputed) {
1358    sub.next = batchedComputed;
1359    batchedComputed = sub;
1360    return;
1361  }
1362  sub.next = batchedSub;
1363  batchedSub = sub;
1364}
1365function startBatch() {
1366  batchDepth++;
1367}
1368function endBatch() {
1369  if (--batchDepth > 0) {
1370    return;
1371  }
1372  if (batchedComputed) {
1373    let e = batchedComputed;
1374    batchedComputed = void 0;
1375    while (e) {
1376      const next = e.next;
1377      e.next = void 0;
1378      e.flags &= -9;
1379      e = next;
1380    }
1381  }
1382  let error;
1383  while (batchedSub) {
1384    let e = batchedSub;
1385    batchedSub = void 0;
1386    while (e) {
1387      const next = e.next;
1388      e.next = void 0;
1389      e.flags &= -9;
1390      if (e.flags & 1) {
1391        try {
1392          ;
1393          e.trigger();
1394        } catch (err) {
1395          if (!error) error = err;
1396        }
1397      }
1398      e = next;
1399    }
1400  }
1401  if (error) throw error;
1402}
1403function prepareDeps(sub) {
1404  for (let link = sub.deps; link; link = link.nextDep) {
1405    link.version = -1;
1406    link.prevActiveLink = link.dep.activeLink;
1407    link.dep.activeLink = link;
1408  }
1409}
1410function cleanupDeps(sub) {
1411  let head;
1412  let tail = sub.depsTail;
1413  let link = tail;
1414  while (link) {
1415    const prev = link.prevDep;
1416    if (link.version === -1) {
1417      if (link === tail) tail = prev;
1418      removeSub(link);
1419      removeDep(link);
1420    } else {
1421      head = link;
1422    }
1423    link.dep.activeLink = link.prevActiveLink;
1424    link.prevActiveLink = void 0;
1425    link = prev;
1426  }
1427  sub.deps = head;
1428  sub.depsTail = tail;
1429}
1430function isDirty(sub) {
1431  for (let link = sub.deps; link; link = link.nextDep) {
1432    if (link.dep.version !== link.version || link.dep.computed && (refreshComputed(link.dep.computed) || link.dep.version !== link.version)) {
1433      return true;
1434    }
1435  }
1436  if (sub._dirty) {
1437    return true;
1438  }
1439  return false;
1440}
1441function refreshComputed(computed) {
1442  if (computed.flags & 4 && !(computed.flags & 16)) {
1443    return;
1444  }
1445  computed.flags &= -17;
1446  if (computed.globalVersion === globalVersion) {
1447    return;
1448  }
1449  computed.globalVersion = globalVersion;
1450  if (!computed.isSSR && computed.flags & 128 && (!computed.deps && !computed._dirty || !isDirty(computed))) {
1451    return;
1452  }
1453  computed.flags |= 2;
1454  const dep = computed.dep;
1455  const prevSub = activeSub;
1456  const prevShouldTrack = shouldTrack;
1457  activeSub = computed;
1458  shouldTrack = true;
1459  try {
1460    prepareDeps(computed);
1461    const value = computed.fn(computed._value);
1462    if (dep.version === 0 || hasChanged(value, computed._value)) {
1463      computed.flags |= 128;
1464      computed._value = value;
1465      dep.version++;
1466    }
1467  } catch (err) {
1468    dep.version++;
1469    throw err;
1470  } finally {
1471    activeSub = prevSub;
1472    shouldTrack = prevShouldTrack;
1473    cleanupDeps(computed);
1474    computed.flags &= -3;
1475  }
1476}
1477function removeSub(link, soft = false) {
1478  const { dep, prevSub, nextSub } = link;
1479  if (prevSub) {
1480    prevSub.nextSub = nextSub;
1481    link.prevSub = void 0;
1482  }
1483  if (nextSub) {
1484    nextSub.prevSub = prevSub;
1485    link.nextSub = void 0;
1486  }
1487  if (false) // removed by dead control flow
1488{}
1489  if (dep.subs === link) {
1490    dep.subs = prevSub;
1491    if (!prevSub && dep.computed) {
1492      dep.computed.flags &= -5;
1493      for (let l = dep.computed.deps; l; l = l.nextDep) {
1494        removeSub(l, true);
1495      }
1496    }
1497  }
1498  if (!soft && !--dep.sc && dep.map) {
vendor: 5,238 bytes, lines 1499-1726
1499    dep.map.delete(dep.key);
1500  }
1501}
1502function removeDep(link) {
1503  const { prevDep, nextDep } = link;
1504  if (prevDep) {
1505    prevDep.nextDep = nextDep;
1506    link.prevDep = void 0;
1507  }
1508  if (nextDep) {
1509    nextDep.prevDep = prevDep;
1510    link.nextDep = void 0;
1511  }
1512}
1513function effect(fn, options) {
1514  if (fn.effect instanceof ReactiveEffect) {
1515    fn = fn.effect.fn;
1516  }
1517  const e = new ReactiveEffect(fn);
1518  if (options) {
1519    shared_esm_bundler_extend(e, options);
1520  }
1521  try {
1522    e.run();
1523  } catch (err) {
1524    e.stop();
1525    throw err;
1526  }
1527  const runner = e.run.bind(e);
1528  runner.effect = e;
1529  return runner;
1530}
1531function stop(runner) {
1532  runner.effect.stop();
1533}
1534let shouldTrack = true;
1535const trackStack = [];
1536function pauseTracking() {
1537  trackStack.push(shouldTrack);
1538  shouldTrack = false;
1539}
1540function enableTracking() {
1541  trackStack.push(shouldTrack);
1542  shouldTrack = true;
1543}
1544function resetTracking() {
1545  const last = trackStack.pop();
1546  shouldTrack = last === void 0 ? true : last;
1547}
1548function onEffectCleanup(fn, failSilently = false) {
1549  if (activeSub instanceof ReactiveEffect) {
1550    activeSub.cleanup = fn;
1551  } else if (false) // removed by dead control flow
1552{}
1553}
1554function cleanupEffect(e) {
1555  const { cleanup } = e;
1556  e.cleanup = void 0;
1557  if (cleanup) {
1558    const prevSub = activeSub;
1559    activeSub = void 0;
1560    try {
1561      cleanup();
1562    } finally {
1563      activeSub = prevSub;
1564    }
1565  }
1566}
1567
1568let globalVersion = 0;
1569class Link {
1570  constructor(sub, dep) {
1571    this.sub = sub;
1572    this.dep = dep;
1573    this.version = dep.version;
1574    this.nextDep = this.prevDep = this.nextSub = this.prevSub = this.prevActiveLink = void 0;
1575  }
1576}
1577class Dep {
1578  // TODO isolatedDeclarations "__v_skip"
1579  constructor(computed) {
1580    this.computed = computed;
1581    this.version = 0;
1582    /**
1583     * Link between this dep and the current active effect
1584     */
1585    this.activeLink = void 0;
1586    /**
1587     * Doubly linked list representing the subscribing effects (tail)
1588     */
1589    this.subs = void 0;
1590    /**
1591     * For object property deps cleanup
1592     */
1593    this.map = void 0;
1594    this.key = void 0;
1595    /**
1596     * Subscriber counter
1597     */
1598    this.sc = 0;
1599    /**
1600     * @internal
1601     */
1602    this.__v_skip = true;
1603    if (false) // removed by dead control flow
1604{}
1605  }
1606  track(debugInfo) {
1607    if (!activeSub || !shouldTrack || activeSub === this.computed) {
1608      return;
1609    }
1610    let link = this.activeLink;
1611    if (link === void 0 || link.sub !== activeSub) {
1612      link = this.activeLink = new Link(activeSub, this);
1613      if (!activeSub.deps) {
1614        activeSub.deps = activeSub.depsTail = link;
1615      } else {
1616        link.prevDep = activeSub.depsTail;
1617        activeSub.depsTail.nextDep = link;
1618        activeSub.depsTail = link;
1619      }
1620      addSub(link);
1621    } else if (link.version === -1) {
1622      link.version = this.version;
1623      if (link.nextDep) {
1624        const next = link.nextDep;
1625        next.prevDep = link.prevDep;
1626        if (link.prevDep) {
1627          link.prevDep.nextDep = next;
1628        }
1629        link.prevDep = activeSub.depsTail;
1630        link.nextDep = void 0;
1631        activeSub.depsTail.nextDep = link;
1632        activeSub.depsTail = link;
1633        if (activeSub.deps === link) {
1634          activeSub.deps = next;
1635        }
1636      }
1637    }
1638    if (false) // removed by dead control flow
1639{}
1640    return link;
1641  }
1642  trigger(debugInfo) {
1643    this.version++;
1644    globalVersion++;
1645    this.notify(debugInfo);
1646  }
1647  notify(debugInfo) {
1648    startBatch();
1649    try {
1650      if (false) // removed by dead control flow
1651{}
1652      for (let link = this.subs; link; link = link.prevSub) {
1653        if (link.sub.notify()) {
1654          ;
1655          link.sub.dep.notify();
1656        }
1657      }
1658    } finally {
1659      endBatch();
1660    }
1661  }
1662}
1663function addSub(link) {
1664  link.dep.sc++;
1665  if (link.sub.flags & 4) {
1666    const computed = link.dep.computed;
1667    if (computed && !link.dep.subs) {
1668      computed.flags |= 4 | 16;
1669      for (let l = computed.deps; l; l = l.nextDep) {
1670        addSub(l);
1671      }
1672    }
1673    const currentTail = link.dep.subs;
1674    if (currentTail !== link) {
1675      link.prevSub = currentTail;
1676      if (currentTail) currentTail.nextSub = link;
1677    }
1678    if (false) // removed by dead control flow
1679{}
1680    link.dep.subs = link;
1681  }
1682}
1683const targetMap = /* @__PURE__ */ new WeakMap();
1684const ITERATE_KEY = Symbol(
1685   false ? 0 : ""
1686);
1687const MAP_KEY_ITERATE_KEY = Symbol(
1688   false ? 0 : ""
1689);
1690const ARRAY_ITERATE_KEY = Symbol(
1691   false ? 0 : ""
1692);
1693function reactivity_esm_bundler_track(target, type, key) {
1694  if (shouldTrack && activeSub) {
1695    let depsMap = targetMap.get(target);
1696    if (!depsMap) {
1697      targetMap.set(target, depsMap = /* @__PURE__ */ new Map());
1698    }
1699    let dep = depsMap.get(key);
1700    if (!dep) {
1701      depsMap.set(key, dep = new Dep());
1702      dep.map = depsMap;
1703      dep.key = key;
1704    }
1705    if (false) // removed by dead control flow
1706{} else {
1707      dep.track();
1708    }
1709  }
1710}
1711function trigger(target, type, key, newValue, oldValue, oldTarget) {
1712  const depsMap = targetMap.get(target);
1713  if (!depsMap) {
1714    globalVersion++;
1715    return;
1716  }
1717  const run = (dep) => {
1718    if (dep) {
1719      if (false) // removed by dead control flow
1720{} else {
1721        dep.trigger();
1722      }
1723    }
1724  };
1725  startBatch();
1726  if (type === "clear") {
vendor: 9,852 bytes, lines 1727-2051
1727    depsMap.forEach(run);
1728  } else {
1729    const targetIsArray = shared_esm_bundler_isArray(target);
1730    const isArrayIndex = targetIsArray && isIntegerKey(key);
1731    if (targetIsArray && key === "length") {
1732      const newLength = Number(newValue);
1733      depsMap.forEach((dep, key2) => {
1734        if (key2 === "length" || key2 === ARRAY_ITERATE_KEY || !isSymbol(key2) && key2 >= newLength) {
1735          run(dep);
1736        }
1737      });
1738    } else {
1739      if (key !== void 0 || depsMap.has(void 0)) {
1740        run(depsMap.get(key));
1741      }
1742      if (isArrayIndex) {
1743        run(depsMap.get(ARRAY_ITERATE_KEY));
1744      }
1745      switch (type) {
1746        case "add":
1747          if (!targetIsArray) {
1748            run(depsMap.get(ITERATE_KEY));
1749            if (isMap(target)) {
1750              run(depsMap.get(MAP_KEY_ITERATE_KEY));
1751            }
1752          } else if (isArrayIndex) {
1753            run(depsMap.get("length"));
1754          }
1755          break;
1756        case "delete":
1757          if (!targetIsArray) {
1758            run(depsMap.get(ITERATE_KEY));
1759            if (isMap(target)) {
1760              run(depsMap.get(MAP_KEY_ITERATE_KEY));
1761            }
1762          }
1763          break;
1764        case "set":
1765          if (isMap(target)) {
1766            run(depsMap.get(ITERATE_KEY));
1767          }
1768          break;
1769      }
1770    }
1771  }
1772  endBatch();
1773}
1774function getDepFromReactive(object, key) {
1775  const depMap = targetMap.get(object);
1776  return depMap && depMap.get(key);
1777}
1778
1779function reactiveReadArray(array) {
1780  const raw = reactivity_esm_bundler_toRaw(array);
1781  if (raw === array) return raw;
1782  reactivity_esm_bundler_track(raw, "iterate", ARRAY_ITERATE_KEY);
1783  return isShallow(array) ? raw : raw.map(toReactive);
1784}
1785function shallowReadArray(arr) {
1786  reactivity_esm_bundler_track(arr = reactivity_esm_bundler_toRaw(arr), "iterate", ARRAY_ITERATE_KEY);
1787  return arr;
1788}
1789function toWrapped(target, item) {
1790  if (isReadonly(target)) {
1791    return isReactive(target) ? toReadonly(toReactive(item)) : toReadonly(item);
1792  }
1793  return toReactive(item);
1794}
1795const arrayInstrumentations = {
1796  __proto__: null,
1797  [Symbol.iterator]() {
1798    return iterator(this, Symbol.iterator, (item) => toWrapped(this, item));
1799  },
1800  concat(...args) {
1801    return reactiveReadArray(this).concat(
1802      ...args.map((x) => shared_esm_bundler_isArray(x) ? reactiveReadArray(x) : x)
1803    );
1804  },
1805  entries() {
1806    return iterator(this, "entries", (value) => {
1807      value[1] = toWrapped(this, value[1]);
1808      return value;
1809    });
1810  },
1811  every(fn, thisArg) {
1812    return apply(this, "every", fn, thisArg, void 0, arguments);
1813  },
1814  filter(fn, thisArg) {
1815    return apply(
1816      this,
1817      "filter",
1818      fn,
1819      thisArg,
1820      (v) => v.map((item) => toWrapped(this, item)),
1821      arguments
1822    );
1823  },
1824  find(fn, thisArg) {
1825    return apply(
1826      this,
1827      "find",
1828      fn,
1829      thisArg,
1830      (item) => toWrapped(this, item),
1831      arguments
1832    );
1833  },
1834  findIndex(fn, thisArg) {
1835    return apply(this, "findIndex", fn, thisArg, void 0, arguments);
1836  },
1837  findLast(fn, thisArg) {
1838    return apply(
1839      this,
1840      "findLast",
1841      fn,
1842      thisArg,
1843      (item) => toWrapped(this, item),
1844      arguments
1845    );
1846  },
1847  findLastIndex(fn, thisArg) {
1848    return apply(this, "findLastIndex", fn, thisArg, void 0, arguments);
1849  },
1850  // flat, flatMap could benefit from ARRAY_ITERATE but are not straight-forward to implement
1851  forEach(fn, thisArg) {
1852    return apply(this, "forEach", fn, thisArg, void 0, arguments);
1853  },
1854  includes(...args) {
1855    return searchProxy(this, "includes", args);
1856  },
1857  indexOf(...args) {
1858    return searchProxy(this, "indexOf", args);
1859  },
1860  join(separator) {
1861    return reactiveReadArray(this).join(separator);
1862  },
1863  // keys() iterator only reads `length`, no optimization required
1864  lastIndexOf(...args) {
1865    return searchProxy(this, "lastIndexOf", args);
1866  },
1867  map(fn, thisArg) {
1868    return apply(this, "map", fn, thisArg, void 0, arguments);
1869  },
1870  pop() {
1871    return noTracking(this, "pop");
1872  },
1873  push(...args) {
1874    return noTracking(this, "push", args);
1875  },
1876  reduce(fn, ...args) {
1877    return reduce(this, "reduce", fn, args);
1878  },
1879  reduceRight(fn, ...args) {
1880    return reduce(this, "reduceRight", fn, args);
1881  },
1882  shift() {
1883    return noTracking(this, "shift");
1884  },
1885  // slice could use ARRAY_ITERATE but also seems to beg for range tracking
1886  some(fn, thisArg) {
1887    return apply(this, "some", fn, thisArg, void 0, arguments);
1888  },
1889  splice(...args) {
1890    return noTracking(this, "splice", args);
1891  },
1892  toReversed() {
1893    return reactiveReadArray(this).toReversed();
1894  },
1895  toSorted(comparer) {
1896    return reactiveReadArray(this).toSorted(comparer);
1897  },
1898  toSpliced(...args) {
1899    return reactiveReadArray(this).toSpliced(...args);
1900  },
1901  unshift(...args) {
1902    return noTracking(this, "unshift", args);
1903  },
1904  values() {
1905    return iterator(this, "values", (item) => toWrapped(this, item));
1906  }
1907};
1908function iterator(self, method, wrapValue) {
1909  const arr = shallowReadArray(self);
1910  const iter = arr[method]();
1911  if (arr !== self && !isShallow(self)) {
1912    iter._next = iter.next;
1913    iter.next = () => {
1914      const result = iter._next();
1915      if (!result.done) {
1916        result.value = wrapValue(result.value);
1917      }
1918      return result;
1919    };
1920  }
1921  return iter;
1922}
1923const arrayProto = Array.prototype;
1924function apply(self, method, fn, thisArg, wrappedRetFn, args) {
1925  const arr = shallowReadArray(self);
1926  const needsWrap = arr !== self && !isShallow(self);
1927  const methodFn = arr[method];
1928  if (methodFn !== arrayProto[method]) {
1929    const result2 = methodFn.apply(self, args);
1930    return needsWrap ? toReactive(result2) : result2;
1931  }
1932  let wrappedFn = fn;
1933  if (arr !== self) {
1934    if (needsWrap) {
1935      wrappedFn = function(item, index) {
1936        return fn.call(this, toWrapped(self, item), index, self);
1937      };
1938    } else if (fn.length > 2) {
1939      wrappedFn = function(item, index) {
1940        return fn.call(this, item, index, self);
1941      };
1942    }
1943  }
1944  const result = methodFn.call(arr, wrappedFn, thisArg);
1945  return needsWrap && wrappedRetFn ? wrappedRetFn(result) : result;
1946}
1947function reduce(self, method, fn, args) {
1948  const arr = shallowReadArray(self);
1949  let wrappedFn = fn;
1950  if (arr !== self) {
1951    if (!isShallow(self)) {
1952      wrappedFn = function(acc, item, index) {
1953        return fn.call(this, acc, toWrapped(self, item), index, self);
1954      };
1955    } else if (fn.length > 3) {
1956      wrappedFn = function(acc, item, index) {
1957        return fn.call(this, acc, item, index, self);
1958      };
1959    }
1960  }
1961  return arr[method](wrappedFn, ...args);
1962}
1963function searchProxy(self, method, args) {
1964  const arr = reactivity_esm_bundler_toRaw(self);
1965  reactivity_esm_bundler_track(arr, "iterate", ARRAY_ITERATE_KEY);
1966  const res = arr[method](...args);
1967  if ((res === -1 || res === false) && isProxy(args[0])) {
1968    args[0] = reactivity_esm_bundler_toRaw(args[0]);
1969    return arr[method](...args);
1970  }
1971  return res;
1972}
1973function noTracking(self, method, args = []) {
1974  pauseTracking();
1975  startBatch();
1976  const res = reactivity_esm_bundler_toRaw(self)[method].apply(self, args);
1977  endBatch();
1978  resetTracking();
1979  return res;
1980}
1981
1982const isNonTrackableKeys = /* @__PURE__ */ shared_esm_bundler_makeMap(`__proto__,__v_isRef,__isVue`);
1983const builtInSymbols = new Set(
1984  /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((key) => key !== "arguments" && key !== "caller").map((key) => Symbol[key]).filter(isSymbol)
1985);
1986function reactivity_esm_bundler_hasOwnProperty(key) {
1987  if (!isSymbol(key)) key = String(key);
1988  const obj = reactivity_esm_bundler_toRaw(this);
1989  reactivity_esm_bundler_track(obj, "has", key);
1990  return obj.hasOwnProperty(key);
1991}
1992class BaseReactiveHandler {
1993  constructor(_isReadonly = false, _isShallow = false) {
1994    this._isReadonly = _isReadonly;
1995    this._isShallow = _isShallow;
1996  }
1997  get(target, key, receiver) {
1998    if (key === "__v_skip") return target["__v_skip"];
1999    const isReadonly2 = this._isReadonly, isShallow2 = this._isShallow;
2000    if (key === "__v_isReactive") {
2001      return !isReadonly2;
2002    } else if (key === "__v_isReadonly") {
2003      return isReadonly2;
2004    } else if (key === "__v_isShallow") {
2005      return isShallow2;
2006    } else if (key === "__v_raw") {
2007      if (receiver === (isReadonly2 ? isShallow2 ? shallowReadonlyMap : readonlyMap : isShallow2 ? shallowReactiveMap : reactiveMap).get(target) || // receiver is not the reactive proxy, but has the same prototype
2008      // this means the receiver is a user proxy of the reactive proxy
2009      Object.getPrototypeOf(target) === Object.getPrototypeOf(receiver)) {
2010        return target;
2011      }
2012      return;
2013    }
2014    const targetIsArray = shared_esm_bundler_isArray(target);
2015    if (!isReadonly2) {
2016      let fn;
2017      if (targetIsArray && (fn = arrayInstrumentations[key])) {
2018        return fn;
2019      }
2020      if (key === "hasOwnProperty") {
2021        return reactivity_esm_bundler_hasOwnProperty;
2022      }
2023    }
2024    const res = Reflect.get(
2025      target,
2026      key,
2027      // if this is a proxy wrapping a ref, return methods using the raw ref
2028      // as receiver so that we don't have to call `toRaw` on the ref in all
2029      // its class methods
2030      reactivity_esm_bundler_isRef(target) ? target : receiver
2031    );
2032    if (isSymbol(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {
2033      return res;
2034    }
2035    if (!isReadonly2) {
2036      reactivity_esm_bundler_track(target, "get", key);
2037    }
2038    if (isShallow2) {
2039      return res;
2040    }
2041    if (reactivity_esm_bundler_isRef(res)) {
2042      const value = targetIsArray && isIntegerKey(key) ? res : res.value;
2043      return isReadonly2 && shared_esm_bundler_isObject(value) ? readonly(value) : value;
2044    }
2045    if (shared_esm_bundler_isObject(res)) {
2046      return isReadonly2 ? readonly(res) : reactive(res);
2047    }
2048    return res;
2049  }
2050}
2051class MutableReactiveHandler extends BaseReactiveHandler {
vendor: 26,149 bytes, lines 2052-2949
2052  constructor(isShallow2 = false) {
2053    super(false, isShallow2);
2054  }
2055  set(target, key, value, receiver) {
2056    let oldValue = target[key];
2057    const isArrayWithIntegerKey = shared_esm_bundler_isArray(target) && isIntegerKey(key);
2058    if (!this._isShallow) {
2059      const isOldValueReadonly = isReadonly(oldValue);
2060      if (!isShallow(value) && !isReadonly(value)) {
2061        oldValue = reactivity_esm_bundler_toRaw(oldValue);
2062        value = reactivity_esm_bundler_toRaw(value);
2063      }
2064      if (!isArrayWithIntegerKey && reactivity_esm_bundler_isRef(oldValue) && !reactivity_esm_bundler_isRef(value)) {
2065        if (isOldValueReadonly) {
2066          if (false) // removed by dead control flow
2067{}
2068          return true;
2069        } else {
2070          oldValue.value = value;
2071          return true;
2072        }
2073      }
2074    }
2075    const hadKey = isArrayWithIntegerKey ? Number(key) < target.length : hasOwn(target, key);
2076    const result = Reflect.set(
2077      target,
2078      key,
2079      value,
2080      reactivity_esm_bundler_isRef(target) ? target : receiver
2081    );
2082    if (target === reactivity_esm_bundler_toRaw(receiver)) {
2083      if (!hadKey) {
2084        trigger(target, "add", key, value);
2085      } else if (hasChanged(value, oldValue)) {
2086        trigger(target, "set", key, value, oldValue);
2087      }
2088    }
2089    return result;
2090  }
2091  deleteProperty(target, key) {
2092    const hadKey = hasOwn(target, key);
2093    const oldValue = target[key];
2094    const result = Reflect.deleteProperty(target, key);
2095    if (result && hadKey) {
2096      trigger(target, "delete", key, void 0, oldValue);
2097    }
2098    return result;
2099  }
2100  has(target, key) {
2101    const result = Reflect.has(target, key);
2102    if (!isSymbol(key) || !builtInSymbols.has(key)) {
2103      reactivity_esm_bundler_track(target, "has", key);
2104    }
2105    return result;
2106  }
2107  ownKeys(target) {
2108    reactivity_esm_bundler_track(
2109      target,
2110      "iterate",
2111      shared_esm_bundler_isArray(target) ? "length" : ITERATE_KEY
2112    );
2113    return Reflect.ownKeys(target);
2114  }
2115}
2116class ReadonlyReactiveHandler extends BaseReactiveHandler {
2117  constructor(isShallow2 = false) {
2118    super(true, isShallow2);
2119  }
2120  set(target, key) {
2121    if (false) // removed by dead control flow
2122{}
2123    return true;
2124  }
2125  deleteProperty(target, key) {
2126    if (false) // removed by dead control flow
2127{}
2128    return true;
2129  }
2130}
2131const mutableHandlers = /* @__PURE__ */ new MutableReactiveHandler();
2132const readonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler();
2133const shallowReactiveHandlers = /* @__PURE__ */ new MutableReactiveHandler(true);
2134const shallowReadonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler(true);
2135
2136const toShallow = (value) => value;
2137const getProto = (v) => Reflect.getPrototypeOf(v);
2138function createIterableMethod(method, isReadonly2, isShallow2) {
2139  return function(...args) {
2140    const target = this["__v_raw"];
2141    const rawTarget = reactivity_esm_bundler_toRaw(target);
2142    const targetIsMap = isMap(rawTarget);
2143    const isPair = method === "entries" || method === Symbol.iterator && targetIsMap;
2144    const isKeyOnly = method === "keys" && targetIsMap;
2145    const innerIterator = target[method](...args);
2146    const wrap = isShallow2 ? toShallow : isReadonly2 ? toReadonly : toReactive;
2147    !isReadonly2 && reactivity_esm_bundler_track(
2148      rawTarget,
2149      "iterate",
2150      isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY
2151    );
2152    return {
2153      // iterator protocol
2154      next() {
2155        const { value, done } = innerIterator.next();
2156        return done ? { value, done } : {
2157          value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),
2158          done
2159        };
2160      },
2161      // iterable protocol
2162      [Symbol.iterator]() {
2163        return this;
2164      }
2165    };
2166  };
2167}
2168function createReadonlyMethod(type) {
2169  return function(...args) {
2170    if (false) // removed by dead control flow
2171{}
2172    return type === "delete" ? false : type === "clear" ? void 0 : this;
2173  };
2174}
2175function createInstrumentations(readonly, shallow) {
2176  const instrumentations = {
2177    get(key) {
2178      const target = this["__v_raw"];
2179      const rawTarget = reactivity_esm_bundler_toRaw(target);
2180      const rawKey = reactivity_esm_bundler_toRaw(key);
2181      if (!readonly) {
2182        if (hasChanged(key, rawKey)) {
2183          reactivity_esm_bundler_track(rawTarget, "get", key);
2184        }
2185        reactivity_esm_bundler_track(rawTarget, "get", rawKey);
2186      }
2187      const { has } = getProto(rawTarget);
2188      const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
2189      if (has.call(rawTarget, key)) {
2190        return wrap(target.get(key));
2191      } else if (has.call(rawTarget, rawKey)) {
2192        return wrap(target.get(rawKey));
2193      } else if (target !== rawTarget) {
2194        target.get(key);
2195      }
2196    },
2197    get size() {
2198      const target = this["__v_raw"];
2199      !readonly && reactivity_esm_bundler_track(reactivity_esm_bundler_toRaw(target), "iterate", ITERATE_KEY);
2200      return target.size;
2201    },
2202    has(key) {
2203      const target = this["__v_raw"];
2204      const rawTarget = reactivity_esm_bundler_toRaw(target);
2205      const rawKey = reactivity_esm_bundler_toRaw(key);
2206      if (!readonly) {
2207        if (hasChanged(key, rawKey)) {
2208          reactivity_esm_bundler_track(rawTarget, "has", key);
2209        }
2210        reactivity_esm_bundler_track(rawTarget, "has", rawKey);
2211      }
2212      return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
2213    },
2214    forEach(callback, thisArg) {
2215      const observed = this;
2216      const target = observed["__v_raw"];
2217      const rawTarget = reactivity_esm_bundler_toRaw(target);
2218      const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
2219      !readonly && reactivity_esm_bundler_track(rawTarget, "iterate", ITERATE_KEY);
2220      return target.forEach((value, key) => {
2221        return callback.call(thisArg, wrap(value), wrap(key), observed);
2222      });
2223    }
2224  };
2225  shared_esm_bundler_extend(
2226    instrumentations,
2227    readonly ? {
2228      add: createReadonlyMethod("add"),
2229      set: createReadonlyMethod("set"),
2230      delete: createReadonlyMethod("delete"),
2231      clear: createReadonlyMethod("clear")
2232    } : {
2233      add(value) {
2234        if (!shallow && !isShallow(value) && !isReadonly(value)) {
2235          value = reactivity_esm_bundler_toRaw(value);
2236        }
2237        const target = reactivity_esm_bundler_toRaw(this);
2238        const proto = getProto(target);
2239        const hadKey = proto.has.call(target, value);
2240        if (!hadKey) {
2241          target.add(value);
2242          trigger(target, "add", value, value);
2243        }
2244        return this;
2245      },
2246      set(key, value) {
2247        if (!shallow && !isShallow(value) && !isReadonly(value)) {
2248          value = reactivity_esm_bundler_toRaw(value);
2249        }
2250        const target = reactivity_esm_bundler_toRaw(this);
2251        const { has, get } = getProto(target);
2252        let hadKey = has.call(target, key);
2253        if (!hadKey) {
2254          key = reactivity_esm_bundler_toRaw(key);
2255          hadKey = has.call(target, key);
2256        } else if (false) // removed by dead control flow
2257{}
2258        const oldValue = get.call(target, key);
2259        target.set(key, value);
2260        if (!hadKey) {
2261          trigger(target, "add", key, value);
2262        } else if (hasChanged(value, oldValue)) {
2263          trigger(target, "set", key, value, oldValue);
2264        }
2265        return this;
2266      },
2267      delete(key) {
2268        const target = reactivity_esm_bundler_toRaw(this);
2269        const { has, get } = getProto(target);
2270        let hadKey = has.call(target, key);
2271        if (!hadKey) {
2272          key = reactivity_esm_bundler_toRaw(key);
2273          hadKey = has.call(target, key);
2274        } else if (false) // removed by dead control flow
2275{}
2276        const oldValue = get ? get.call(target, key) : void 0;
2277        const result = target.delete(key);
2278        if (hadKey) {
2279          trigger(target, "delete", key, void 0, oldValue);
2280        }
2281        return result;
2282      },
2283      clear() {
2284        const target = reactivity_esm_bundler_toRaw(this);
2285        const hadItems = target.size !== 0;
2286        const oldTarget =  false ? 0 : void 0;
2287        const result = target.clear();
2288        if (hadItems) {
2289          trigger(
2290            target,
2291            "clear",
2292            void 0,
2293            void 0,
2294            oldTarget
2295          );
2296        }
2297        return result;
2298      }
2299    }
2300  );
2301  const iteratorMethods = [
2302    "keys",
2303    "values",
2304    "entries",
2305    Symbol.iterator
2306  ];
2307  iteratorMethods.forEach((method) => {
2308    instrumentations[method] = createIterableMethod(method, readonly, shallow);
2309  });
2310  return instrumentations;
2311}
2312function createInstrumentationGetter(isReadonly2, shallow) {
2313  const instrumentations = createInstrumentations(isReadonly2, shallow);
2314  return (target, key, receiver) => {
2315    if (key === "__v_isReactive") {
2316      return !isReadonly2;
2317    } else if (key === "__v_isReadonly") {
2318      return isReadonly2;
2319    } else if (key === "__v_raw") {
2320      return target;
2321    }
2322    return Reflect.get(
2323      hasOwn(instrumentations, key) && key in target ? instrumentations : target,
2324      key,
2325      receiver
2326    );
2327  };
2328}
2329const mutableCollectionHandlers = {
2330  get: /* @__PURE__ */ createInstrumentationGetter(false, false)
2331};
2332const shallowCollectionHandlers = {
2333  get: /* @__PURE__ */ createInstrumentationGetter(false, true)
2334};
2335const readonlyCollectionHandlers = {
2336  get: /* @__PURE__ */ createInstrumentationGetter(true, false)
2337};
2338const shallowReadonlyCollectionHandlers = {
2339  get: /* @__PURE__ */ createInstrumentationGetter(true, true)
2340};
2341function checkIdentityKeys(target, has, key) {
2342  const rawKey = reactivity_esm_bundler_toRaw(key);
2343  if (rawKey !== key && has.call(target, rawKey)) {
2344    const type = toRawType(target);
2345    reactivity_esm_bundler_warn(
2346      `Reactive ${type} contains both the raw and reactive versions of the same object${type === `Map` ? ` as keys` : ``}, which can lead to inconsistencies. Avoid differentiating between the raw and reactive versions of an object and only use the reactive version if possible.`
2347    );
2348  }
2349}
2350
2351const reactiveMap = /* @__PURE__ */ new WeakMap();
2352const shallowReactiveMap = /* @__PURE__ */ new WeakMap();
2353const readonlyMap = /* @__PURE__ */ new WeakMap();
2354const shallowReadonlyMap = /* @__PURE__ */ new WeakMap();
2355function targetTypeMap(rawType) {
2356  switch (rawType) {
2357    case "Object":
2358    case "Array":
2359      return 1 /* COMMON */;
2360    case "Map":
2361    case "Set":
2362    case "WeakMap":
2363    case "WeakSet":
2364      return 2 /* COLLECTION */;
2365    default:
2366      return 0 /* INVALID */;
2367  }
2368}
2369function getTargetType(value) {
2370  return value["__v_skip"] || !Object.isExtensible(value) ? 0 /* INVALID */ : targetTypeMap(shared_esm_bundler_toRawType(value));
2371}
2372function reactive(target) {
2373  if (isReadonly(target)) {
2374    return target;
2375  }
2376  return createReactiveObject(
2377    target,
2378    false,
2379    mutableHandlers,
2380    mutableCollectionHandlers,
2381    reactiveMap
2382  );
2383}
2384function shallowReactive(target) {
2385  return createReactiveObject(
2386    target,
2387    false,
2388    shallowReactiveHandlers,
2389    shallowCollectionHandlers,
2390    shallowReactiveMap
2391  );
2392}
2393function readonly(target) {
2394  return createReactiveObject(
2395    target,
2396    true,
2397    readonlyHandlers,
2398    readonlyCollectionHandlers,
2399    readonlyMap
2400  );
2401}
2402function shallowReadonly(target) {
2403  return createReactiveObject(
2404    target,
2405    true,
2406    shallowReadonlyHandlers,
2407    shallowReadonlyCollectionHandlers,
2408    shallowReadonlyMap
2409  );
2410}
2411function createReactiveObject(target, isReadonly2, baseHandlers, collectionHandlers, proxyMap) {
2412  if (!shared_esm_bundler_isObject(target)) {
2413    if (false) // removed by dead control flow
2414{}
2415    return target;
2416  }
2417  if (target["__v_raw"] && !(isReadonly2 && target["__v_isReactive"])) {
2418    return target;
2419  }
2420  const targetType = getTargetType(target);
2421  if (targetType === 0 /* INVALID */) {
2422    return target;
2423  }
2424  const existingProxy = proxyMap.get(target);
2425  if (existingProxy) {
2426    return existingProxy;
2427  }
2428  const proxy = new Proxy(
2429    target,
2430    targetType === 2 /* COLLECTION */ ? collectionHandlers : baseHandlers
2431  );
2432  proxyMap.set(target, proxy);
2433  return proxy;
2434}
2435function isReactive(value) {
2436  if (isReadonly(value)) {
2437    return isReactive(value["__v_raw"]);
2438  }
2439  return !!(value && value["__v_isReactive"]);
2440}
2441function isReadonly(value) {
2442  return !!(value && value["__v_isReadonly"]);
2443}
2444function isShallow(value) {
2445  return !!(value && value["__v_isShallow"]);
2446}
2447function isProxy(value) {
2448  return value ? !!value["__v_raw"] : false;
2449}
2450function reactivity_esm_bundler_toRaw(observed) {
2451  const raw = observed && observed["__v_raw"];
2452  return raw ? reactivity_esm_bundler_toRaw(raw) : observed;
2453}
2454function markRaw(value) {
2455  if (!hasOwn(value, "__v_skip") && Object.isExtensible(value)) {
2456    def(value, "__v_skip", true);
2457  }
2458  return value;
2459}
2460const toReactive = (value) => shared_esm_bundler_isObject(value) ? reactive(value) : value;
2461const toReadonly = (value) => shared_esm_bundler_isObject(value) ? readonly(value) : value;
2462
2463function reactivity_esm_bundler_isRef(r) {
2464  return r ? r["__v_isRef"] === true : false;
2465}
2466function ref(value) {
2467  return createRef(value, false);
2468}
2469function shallowRef(value) {
2470  return createRef(value, true);
2471}
2472function createRef(rawValue, shallow) {
2473  if (reactivity_esm_bundler_isRef(rawValue)) {
2474    return rawValue;
2475  }
2476  return new RefImpl(rawValue, shallow);
2477}
2478class RefImpl {
2479  constructor(value, isShallow2) {
2480    this.dep = new Dep();
2481    this["__v_isRef"] = true;
2482    this["__v_isShallow"] = false;
2483    this._rawValue = isShallow2 ? value : reactivity_esm_bundler_toRaw(value);
2484    this._value = isShallow2 ? value : toReactive(value);
2485    this["__v_isShallow"] = isShallow2;
2486  }
2487  get value() {
2488    if (false) // removed by dead control flow
2489{} else {
2490      this.dep.track();
2491    }
2492    return this._value;
2493  }
2494  set value(newValue) {
2495    const oldValue = this._rawValue;
2496    const useDirectValue = this["__v_isShallow"] || isShallow(newValue) || isReadonly(newValue);
2497    newValue = useDirectValue ? newValue : reactivity_esm_bundler_toRaw(newValue);
2498    if (hasChanged(newValue, oldValue)) {
2499      this._rawValue = newValue;
2500      this._value = useDirectValue ? newValue : toReactive(newValue);
2501      if (false) // removed by dead control flow
2502{} else {
2503        this.dep.trigger();
2504      }
2505    }
2506  }
2507}
2508function triggerRef(ref2) {
2509  if (ref2.dep) {
2510    if (false) // removed by dead control flow
2511{} else {
2512      ref2.dep.trigger();
2513    }
2514  }
2515}
2516function unref(ref2) {
2517  return reactivity_esm_bundler_isRef(ref2) ? ref2.value : ref2;
2518}
2519function toValue(source) {
2520  return shared_esm_bundler_isFunction(source) ? source() : unref(source);
2521}
2522const shallowUnwrapHandlers = {
2523  get: (target, key, receiver) => key === "__v_raw" ? target : unref(Reflect.get(target, key, receiver)),
2524  set: (target, key, value, receiver) => {
2525    const oldValue = target[key];
2526    if (reactivity_esm_bundler_isRef(oldValue) && !reactivity_esm_bundler_isRef(value)) {
2527      oldValue.value = value;
2528      return true;
2529    } else {
2530      return Reflect.set(target, key, value, receiver);
2531    }
2532  }
2533};
2534function proxyRefs(objectWithRefs) {
2535  return isReactive(objectWithRefs) ? objectWithRefs : new Proxy(objectWithRefs, shallowUnwrapHandlers);
2536}
2537class CustomRefImpl {
2538  constructor(factory) {
2539    this["__v_isRef"] = true;
2540    this._value = void 0;
2541    const dep = this.dep = new Dep();
2542    const { get, set } = factory(dep.track.bind(dep), dep.trigger.bind(dep));
2543    this._get = get;
2544    this._set = set;
2545  }
2546  get value() {
2547    return this._value = this._get();
2548  }
2549  set value(newVal) {
2550    this._set(newVal);
2551  }
2552}
2553function customRef(factory) {
2554  return new CustomRefImpl(factory);
2555}
2556function toRefs(object) {
2557  if (false) // removed by dead control flow
2558{}
2559  const ret = shared_esm_bundler_isArray(object) ? new Array(object.length) : {};
2560  for (const key in object) {
2561    ret[key] = propertyToRef(object, key);
2562  }
2563  return ret;
2564}
2565class ObjectRefImpl {
2566  constructor(_object, _key, _defaultValue) {
2567    this._object = _object;
2568    this._key = _key;
2569    this._defaultValue = _defaultValue;
2570    this["__v_isRef"] = true;
2571    this._value = void 0;
2572    this._raw = reactivity_esm_bundler_toRaw(_object);
2573    let shallow = true;
2574    let obj = _object;
2575    if (!shared_esm_bundler_isArray(_object) || !isIntegerKey(String(_key))) {
2576      do {
2577        shallow = !isProxy(obj) || isShallow(obj);
2578      } while (shallow && (obj = obj["__v_raw"]));
2579    }
2580    this._shallow = shallow;
2581  }
2582  get value() {
2583    let val = this._object[this._key];
2584    if (this._shallow) {
2585      val = unref(val);
2586    }
2587    return this._value = val === void 0 ? this._defaultValue : val;
2588  }
2589  set value(newVal) {
2590    if (this._shallow && reactivity_esm_bundler_isRef(this._raw[this._key])) {
2591      const nestedRef = this._object[this._key];
2592      if (reactivity_esm_bundler_isRef(nestedRef)) {
2593        nestedRef.value = newVal;
2594        return;
2595      }
2596    }
2597    this._object[this._key] = newVal;
2598  }
2599  get dep() {
2600    return getDepFromReactive(this._raw, this._key);
2601  }
2602}
2603class GetterRefImpl {
2604  constructor(_getter) {
2605    this._getter = _getter;
2606    this["__v_isRef"] = true;
2607    this["__v_isReadonly"] = true;
2608    this._value = void 0;
2609  }
2610  get value() {
2611    return this._value = this._getter();
2612  }
2613}
2614function toRef(source, key, defaultValue) {
2615  if (reactivity_esm_bundler_isRef(source)) {
2616    return source;
2617  } else if (shared_esm_bundler_isFunction(source)) {
2618    return new GetterRefImpl(source);
2619  } else if (shared_esm_bundler_isObject(source) && arguments.length > 1) {
2620    return propertyToRef(source, key, defaultValue);
2621  } else {
2622    return ref(source);
2623  }
2624}
2625function propertyToRef(source, key, defaultValue) {
2626  return new ObjectRefImpl(source, key, defaultValue);
2627}
2628
2629class ComputedRefImpl {
2630  constructor(fn, setter, isSSR) {
2631    this.fn = fn;
2632    this.setter = setter;
2633    /**
2634     * @internal
2635     */
2636    this._value = void 0;
2637    /**
2638     * @internal
2639     */
2640    this.dep = new Dep(this);
2641    /**
2642     * @internal
2643     */
2644    this.__v_isRef = true;
2645    // TODO isolatedDeclarations "__v_isReadonly"
2646    // A computed is also a subscriber that tracks other deps
2647    /**
2648     * @internal
2649     */
2650    this.deps = void 0;
2651    /**
2652     * @internal
2653     */
2654    this.depsTail = void 0;
2655    /**
2656     * @internal
2657     */
2658    this.flags = 16;
2659    /**
2660     * @internal
2661     */
2662    this.globalVersion = globalVersion - 1;
2663    /**
2664     * @internal
2665     */
2666    this.next = void 0;
2667    // for backwards compat
2668    this.effect = this;
2669    this["__v_isReadonly"] = !setter;
2670    this.isSSR = isSSR;
2671  }
2672  /**
2673   * @internal
2674   */
2675  notify() {
2676    this.flags |= 16;
2677    if (!(this.flags & 8) && // avoid infinite self recursion
2678    activeSub !== this) {
2679      batch(this, true);
2680      return true;
2681    } else if (false) // removed by dead control flow
2682{}
2683  }
2684  get value() {
2685    const link =  false ? 0 : this.dep.track();
2686    refreshComputed(this);
2687    if (link) {
2688      link.version = this.dep.version;
2689    }
2690    return this._value;
2691  }
2692  set value(newValue) {
2693    if (this.setter) {
2694      this.setter(newValue);
2695    } else if (false) // removed by dead control flow
2696{}
2697  }
2698}
2699function computed(getterOrOptions, debugOptions, isSSR = false) {
2700  let getter;
2701  let setter;
2702  if (shared_esm_bundler_isFunction(getterOrOptions)) {
2703    getter = getterOrOptions;
2704  } else {
2705    getter = getterOrOptions.get;
2706    setter = getterOrOptions.set;
2707  }
2708  const cRef = new ComputedRefImpl(getter, setter, isSSR);
2709  if (false) // removed by dead control flow
2710{}
2711  return cRef;
2712}
2713
2714const TrackOpTypes = {
2715  "GET": "get",
2716  "HAS": "has",
2717  "ITERATE": "iterate"
2718};
2719const TriggerOpTypes = {
2720  "SET": "set",
2721  "ADD": "add",
2722  "DELETE": "delete",
2723  "CLEAR": "clear"
2724};
2725const ReactiveFlags = {
2726  "SKIP": "__v_skip",
2727  "IS_REACTIVE": "__v_isReactive",
2728  "IS_READONLY": "__v_isReadonly",
2729  "IS_SHALLOW": "__v_isShallow",
2730  "RAW": "__v_raw",
2731  "IS_REF": "__v_isRef"
2732};
2733
2734const WatchErrorCodes = {
2735  "WATCH_GETTER": 2,
2736  "2": "WATCH_GETTER",
2737  "WATCH_CALLBACK": 3,
2738  "3": "WATCH_CALLBACK",
2739  "WATCH_CLEANUP": 4,
2740  "4": "WATCH_CLEANUP"
2741};
2742const INITIAL_WATCHER_VALUE = {};
2743const cleanupMap = /* @__PURE__ */ new WeakMap();
2744let activeWatcher = void 0;
2745function getCurrentWatcher() {
2746  return activeWatcher;
2747}
2748function onWatcherCleanup(cleanupFn, failSilently = false, owner = activeWatcher) {
2749  if (owner) {
2750    let cleanups = cleanupMap.get(owner);
2751    if (!cleanups) cleanupMap.set(owner, cleanups = []);
2752    cleanups.push(cleanupFn);
2753  } else if (false) // removed by dead control flow
2754{}
2755}
2756function watch(source, cb, options = EMPTY_OBJ) {
2757  const { immediate, deep, once, scheduler, augmentJob, call } = options;
2758  const warnInvalidSource = (s) => {
2759    (options.onWarn || reactivity_esm_bundler_warn)(
2760      `Invalid watch source: `,
2761      s,
2762      `A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types.`
2763    );
2764  };
2765  const reactiveGetter = (source2) => {
2766    if (deep) return source2;
2767    if (isShallow(source2) || deep === false || deep === 0)
2768      return traverse(source2, 1);
2769    return traverse(source2);
2770  };
2771  let effect;
2772  let getter;
2773  let cleanup;
2774  let boundCleanup;
2775  let forceTrigger = false;
2776  let isMultiSource = false;
2777  if (reactivity_esm_bundler_isRef(source)) {
2778    getter = () => source.value;
2779    forceTrigger = isShallow(source);
2780  } else if (isReactive(source)) {
2781    getter = () => reactiveGetter(source);
2782    forceTrigger = true;
2783  } else if (shared_esm_bundler_isArray(source)) {
2784    isMultiSource = true;
2785    forceTrigger = source.some((s) => isReactive(s) || isShallow(s));
2786    getter = () => source.map((s) => {
2787      if (reactivity_esm_bundler_isRef(s)) {
2788        return s.value;
2789      } else if (isReactive(s)) {
2790        return reactiveGetter(s);
2791      } else if (shared_esm_bundler_isFunction(s)) {
2792        return call ? call(s, 2) : s();
2793      } else {
2794         false && 0;
2795      }
2796    });
2797  } else if (shared_esm_bundler_isFunction(source)) {
2798    if (cb) {
2799      getter = call ? () => call(source, 2) : source;
2800    } else {
2801      getter = () => {
2802        if (cleanup) {
2803          pauseTracking();
2804          try {
2805            cleanup();
2806          } finally {
2807            resetTracking();
2808          }
2809        }
2810        const currentEffect = activeWatcher;
2811        activeWatcher = effect;
2812        try {
2813          return call ? call(source, 3, [boundCleanup]) : source(boundCleanup);
2814        } finally {
2815          activeWatcher = currentEffect;
2816        }
2817      };
2818    }
2819  } else {
2820    getter = shared_esm_bundler_NOOP;
2821     false && 0;
2822  }
2823  if (cb && deep) {
2824    const baseGetter = getter;
2825    const depth = deep === true ? Infinity : deep;
2826    getter = () => traverse(baseGetter(), depth);
2827  }
2828  const scope = getCurrentScope();
2829  const watchHandle = () => {
2830    effect.stop();
2831    if (scope && scope.active) {
2832      remove(scope.effects, effect);
2833    }
2834  };
2835  if (once && cb) {
2836    const _cb = cb;
2837    cb = (...args) => {
2838      _cb(...args);
2839      watchHandle();
2840    };
2841  }
2842  let oldValue = isMultiSource ? new Array(source.length).fill(INITIAL_WATCHER_VALUE) : INITIAL_WATCHER_VALUE;
2843  const job = (immediateFirstRun) => {
2844    if (!(effect.flags & 1) || !effect.dirty && !immediateFirstRun) {
2845      return;
2846    }
2847    if (cb) {
2848      const newValue = effect.run();
2849      if (deep || forceTrigger || (isMultiSource ? newValue.some((v, i) => hasChanged(v, oldValue[i])) : hasChanged(newValue, oldValue))) {
2850        if (cleanup) {
2851          cleanup();
2852        }
2853        const currentWatcher = activeWatcher;
2854        activeWatcher = effect;
2855        try {
2856          const args = [
2857            newValue,
2858            // pass undefined as the old value when it's changed for the first time
2859            oldValue === INITIAL_WATCHER_VALUE ? void 0 : isMultiSource && oldValue[0] === INITIAL_WATCHER_VALUE ? [] : oldValue,
2860            boundCleanup
2861          ];
2862          oldValue = newValue;
2863          call ? call(cb, 3, args) : (
2864            // @ts-expect-error
2865            cb(...args)
2866          );
2867        } finally {
2868          activeWatcher = currentWatcher;
2869        }
2870      }
2871    } else {
2872      effect.run();
2873    }
2874  };
2875  if (augmentJob) {
2876    augmentJob(job);
2877  }
2878  effect = new ReactiveEffect(getter);
2879  effect.scheduler = scheduler ? () => scheduler(job, false) : job;
2880  boundCleanup = (fn) => onWatcherCleanup(fn, false, effect);
2881  cleanup = effect.onStop = () => {
2882    const cleanups = cleanupMap.get(effect);
2883    if (cleanups) {
2884      if (call) {
2885        call(cleanups, 4);
2886      } else {
2887        for (const cleanup2 of cleanups) cleanup2();
2888      }
2889      cleanupMap.delete(effect);
2890    }
2891  };
2892  if (false) // removed by dead control flow
2893{}
2894  if (cb) {
2895    if (immediate) {
2896      job(true);
2897    } else {
2898      oldValue = effect.run();
2899    }
2900  } else if (scheduler) {
2901    scheduler(job.bind(null, true), true);
2902  } else {
2903    effect.run();
2904  }
2905  watchHandle.pause = effect.pause.bind(effect);
2906  watchHandle.resume = effect.resume.bind(effect);
2907  watchHandle.stop = watchHandle;
2908  return watchHandle;
2909}
2910function traverse(value, depth = Infinity, seen) {
2911  if (depth <= 0 || !shared_esm_bundler_isObject(value) || value["__v_skip"]) {
2912    return value;
2913  }
2914  seen = seen || /* @__PURE__ */ new Map();
2915  if ((seen.get(value) || 0) >= depth) {
2916    return value;
2917  }
2918  seen.set(value, depth);
2919  depth--;
2920  if (reactivity_esm_bundler_isRef(value)) {
2921    traverse(value.value, depth, seen);
2922  } else if (shared_esm_bundler_isArray(value)) {
2923    for (let i = 0; i < value.length; i++) {
2924      traverse(value[i], depth, seen);
2925    }
2926  } else if (isSet(value) || isMap(value)) {
2927    value.forEach((v) => {
2928      traverse(v, depth, seen);
2929    });
2930  } else if (isPlainObject(value)) {
2931    for (const key in value) {
2932      traverse(value[key], depth, seen);
2933    }
2934    for (const key of Object.getOwnPropertySymbols(value)) {
2935      if (Object.prototype.propertyIsEnumerable.call(value, key)) {
2936        traverse(value[key], depth, seen);
2937      }
2938    }
2939  }
2940  return value;
2941}
2942
2943
2944
2945;// ./node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js
2946/**
2947* @vue/runtime-core v3.5.25
2948* (c) 2018-present Yuxi (Evan) You and Vue contributors
2949* @license MIT
vendor: 6,319 bytes, lines 2950-3170
2950**/
2951
2952
2953
2954
2955
2956const stack = [];
2957function pushWarningContext(vnode) {
2958  stack.push(vnode);
2959}
2960function popWarningContext() {
2961  stack.pop();
2962}
2963let isWarning = false;
2964function warn$1(msg, ...args) {
2965  if (isWarning) return;
2966  isWarning = true;
2967  pauseTracking();
2968  const instance = stack.length ? stack[stack.length - 1].component : null;
2969  const appWarnHandler = instance && instance.appContext.config.warnHandler;
2970  const trace = getComponentTrace();
2971  if (appWarnHandler) {
2972    callWithErrorHandling(
2973      appWarnHandler,
2974      instance,
2975      11,
2976      [
2977        // eslint-disable-next-line no-restricted-syntax
2978        msg + args.map((a) => {
2979          var _a, _b;
2980          return (_b = (_a = a.toString) == null ? void 0 : _a.call(a)) != null ? _b : JSON.stringify(a);
2981        }).join(""),
2982        instance && instance.proxy,
2983        trace.map(
2984          ({ vnode }) => `at <${formatComponentName(instance, vnode.type)}>`
2985        ).join("\n"),
2986        trace
2987      ]
2988    );
2989  } else {
2990    const warnArgs = [`[Vue warn]: ${msg}`, ...args];
2991    if (trace.length && // avoid spamming console during tests
2992    true) {
2993      warnArgs.push(`
2994`, ...formatTrace(trace));
2995    }
2996    console.warn(...warnArgs);
2997  }
2998  resetTracking();
2999  isWarning = false;
3000}
3001function getComponentTrace() {
3002  let currentVNode = stack[stack.length - 1];
3003  if (!currentVNode) {
3004    return [];
3005  }
3006  const normalizedStack = [];
3007  while (currentVNode) {
3008    const last = normalizedStack[0];
3009    if (last && last.vnode === currentVNode) {
3010      last.recurseCount++;
3011    } else {
3012      normalizedStack.push({
3013        vnode: currentVNode,
3014        recurseCount: 0
3015      });
3016    }
3017    const parentInstance = currentVNode.component && currentVNode.component.parent;
3018    currentVNode = parentInstance && parentInstance.vnode;
3019  }
3020  return normalizedStack;
3021}
3022function formatTrace(trace) {
3023  const logs = [];
3024  trace.forEach((entry, i) => {
3025    logs.push(...i === 0 ? [] : [`
3026`], ...formatTraceEntry(entry));
3027  });
3028  return logs;
3029}
3030function formatTraceEntry({ vnode, recurseCount }) {
3031  const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;
3032  const isRoot = vnode.component ? vnode.component.parent == null : false;
3033  const open = ` at <${formatComponentName(
3034    vnode.component,
3035    vnode.type,
3036    isRoot
3037  )}`;
3038  const close = `>` + postfix;
3039  return vnode.props ? [open, ...formatProps(vnode.props), close] : [open + close];
3040}
3041function formatProps(props) {
3042  const res = [];
3043  const keys = Object.keys(props);
3044  keys.slice(0, 3).forEach((key) => {
3045    res.push(...formatProp(key, props[key]));
3046  });
3047  if (keys.length > 3) {
3048    res.push(` ...`);
3049  }
3050  return res;
3051}
3052function formatProp(key, value, raw) {
3053  if (shared_esm_bundler_isString(value)) {
3054    value = JSON.stringify(value);
3055    return raw ? value : [`${key}=${value}`];
3056  } else if (typeof value === "number" || typeof value === "boolean" || value == null) {
3057    return raw ? value : [`${key}=${value}`];
3058  } else if (reactivity_esm_bundler_isRef(value)) {
3059    value = formatProp(key, reactivity_esm_bundler_toRaw(value.value), true);
3060    return raw ? value : [`${key}=Ref<`, value, `>`];
3061  } else if (shared_esm_bundler_isFunction(value)) {
3062    return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];
3063  } else {
3064    value = reactivity_esm_bundler_toRaw(value);
3065    return raw ? value : [`${key}=`, value];
3066  }
3067}
3068function assertNumber(val, type) {
3069  if (true) return;
3070  // removed by dead control flow
3071
3072}
3073
3074const ErrorCodes = {
3075  "SETUP_FUNCTION": 0,
3076  "0": "SETUP_FUNCTION",
3077  "RENDER_FUNCTION": 1,
3078  "1": "RENDER_FUNCTION",
3079  "NATIVE_EVENT_HANDLER": 5,
3080  "5": "NATIVE_EVENT_HANDLER",
3081  "COMPONENT_EVENT_HANDLER": 6,
3082  "6": "COMPONENT_EVENT_HANDLER",
3083  "VNODE_HOOK": 7,
3084  "7": "VNODE_HOOK",
3085  "DIRECTIVE_HOOK": 8,
3086  "8": "DIRECTIVE_HOOK",
3087  "TRANSITION_HOOK": 9,
3088  "9": "TRANSITION_HOOK",
3089  "APP_ERROR_HANDLER": 10,
3090  "10": "APP_ERROR_HANDLER",
3091  "APP_WARN_HANDLER": 11,
3092  "11": "APP_WARN_HANDLER",
3093  "FUNCTION_REF": 12,
3094  "12": "FUNCTION_REF",
3095  "ASYNC_COMPONENT_LOADER": 13,
3096  "13": "ASYNC_COMPONENT_LOADER",
3097  "SCHEDULER": 14,
3098  "14": "SCHEDULER",
3099  "COMPONENT_UPDATE": 15,
3100  "15": "COMPONENT_UPDATE",
3101  "APP_UNMOUNT_CLEANUP": 16,
3102  "16": "APP_UNMOUNT_CLEANUP"
3103};
3104const ErrorTypeStrings$1 = {
3105  ["sp"]: "serverPrefetch hook",
3106  ["bc"]: "beforeCreate hook",
3107  ["c"]: "created hook",
3108  ["bm"]: "beforeMount hook",
3109  ["m"]: "mounted hook",
3110  ["bu"]: "beforeUpdate hook",
3111  ["u"]: "updated",
3112  ["bum"]: "beforeUnmount hook",
3113  ["um"]: "unmounted hook",
3114  ["a"]: "activated hook",
3115  ["da"]: "deactivated hook",
3116  ["ec"]: "errorCaptured hook",
3117  ["rtc"]: "renderTracked hook",
3118  ["rtg"]: "renderTriggered hook",
3119  [0]: "setup function",
3120  [1]: "render function",
3121  [2]: "watcher getter",
3122  [3]: "watcher callback",
3123  [4]: "watcher cleanup function",
3124  [5]: "native event handler",
3125  [6]: "component event handler",
3126  [7]: "vnode hook",
3127  [8]: "directive hook",
3128  [9]: "transition hook",
3129  [10]: "app errorHandler",
3130  [11]: "app warnHandler",
3131  [12]: "ref function",
3132  [13]: "async component loader",
3133  [14]: "scheduler flush",
3134  [15]: "component update",
3135  [16]: "app unmount cleanup function"
3136};
3137function callWithErrorHandling(fn, instance, type, args) {
3138  try {
3139    return args ? fn(...args) : fn();
3140  } catch (err) {
3141    handleError(err, instance, type);
3142  }
3143}
3144function callWithAsyncErrorHandling(fn, instance, type, args) {
3145  if (shared_esm_bundler_isFunction(fn)) {
3146    const res = callWithErrorHandling(fn, instance, type, args);
3147    if (res && isPromise(res)) {
3148      res.catch((err) => {
3149        handleError(err, instance, type);
3150      });
3151    }
3152    return res;
3153  }
3154  if (shared_esm_bundler_isArray(fn)) {
3155    const values = [];
3156    for (let i = 0; i < fn.length; i++) {
3157      values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));
3158    }
3159    return values;
3160  } else if (false) // removed by dead control flow
3161{}
3162}
3163function handleError(err, instance, type, throwInDev = true) {
3164  const contextVNode = instance ? instance.vnode : null;
3165  const { errorHandler, throwUnhandledErrorInProduction } = instance && instance.appContext.config || EMPTY_OBJ;
3166  if (instance) {
3167    let cur = instance.parent;
3168    const exposedInstance = instance.proxy;
3169    const errorInfo =  false ? 0 : `https://vuejs.org/error-reference/#runtime-${type}`;
3170    while (cur) {
vendor: 5,361 bytes, lines 3171-3365
3171      const errorCapturedHooks = cur.ec;
3172      if (errorCapturedHooks) {
3173        for (let i = 0; i < errorCapturedHooks.length; i++) {
3174          if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {
3175            return;
3176          }
3177        }
3178      }
3179      cur = cur.parent;
3180    }
3181    if (errorHandler) {
3182      pauseTracking();
3183      callWithErrorHandling(errorHandler, null, 10, [
3184        err,
3185        exposedInstance,
3186        errorInfo
3187      ]);
3188      resetTracking();
3189      return;
3190    }
3191  }
3192  logError(err, type, contextVNode, throwInDev, throwUnhandledErrorInProduction);
3193}
3194function logError(err, type, contextVNode, throwInDev = true, throwInProd = false) {
3195  if (false) // removed by dead control flow
3196{} else if (throwInProd) {
3197    throw err;
3198  } else {
3199    console.error(err);
3200  }
3201}
3202
3203const queue = [];
3204let flushIndex = -1;
3205const pendingPostFlushCbs = [];
3206let activePostFlushCbs = null;
3207let postFlushIndex = 0;
3208const resolvedPromise = /* @__PURE__ */ Promise.resolve();
3209let currentFlushPromise = null;
3210const RECURSION_LIMIT = 100;
3211function nextTick(fn) {
3212  const p = currentFlushPromise || resolvedPromise;
3213  return fn ? p.then(this ? fn.bind(this) : fn) : p;
3214}
3215function findInsertionIndex(id) {
3216  let start = flushIndex + 1;
3217  let end = queue.length;
3218  while (start < end) {
3219    const middle = start + end >>> 1;
3220    const middleJob = queue[middle];
3221    const middleJobId = getId(middleJob);
3222    if (middleJobId < id || middleJobId === id && middleJob.flags & 2) {
3223      start = middle + 1;
3224    } else {
3225      end = middle;
3226    }
3227  }
3228  return start;
3229}
3230function queueJob(job) {
3231  if (!(job.flags & 1)) {
3232    const jobId = getId(job);
3233    const lastJob = queue[queue.length - 1];
3234    if (!lastJob || // fast path when the job id is larger than the tail
3235    !(job.flags & 2) && jobId >= getId(lastJob)) {
3236      queue.push(job);
3237    } else {
3238      queue.splice(findInsertionIndex(jobId), 0, job);
3239    }
3240    job.flags |= 1;
3241    queueFlush();
3242  }
3243}
3244function queueFlush() {
3245  if (!currentFlushPromise) {
3246    currentFlushPromise = resolvedPromise.then(flushJobs);
3247  }
3248}
3249function queuePostFlushCb(cb) {
3250  if (!shared_esm_bundler_isArray(cb)) {
3251    if (activePostFlushCbs && cb.id === -1) {
3252      activePostFlushCbs.splice(postFlushIndex + 1, 0, cb);
3253    } else if (!(cb.flags & 1)) {
3254      pendingPostFlushCbs.push(cb);
3255      cb.flags |= 1;
3256    }
3257  } else {
3258    pendingPostFlushCbs.push(...cb);
3259  }
3260  queueFlush();
3261}
3262function flushPreFlushCbs(instance, seen, i = flushIndex + 1) {
3263  if (false) // removed by dead control flow
3264{}
3265  for (; i < queue.length; i++) {
3266    const cb = queue[i];
3267    if (cb && cb.flags & 2) {
3268      if (instance && cb.id !== instance.uid) {
3269        continue;
3270      }
3271      if (false) // removed by dead control flow
3272{}
3273      queue.splice(i, 1);
3274      i--;
3275      if (cb.flags & 4) {
3276        cb.flags &= -2;
3277      }
3278      cb();
3279      if (!(cb.flags & 4)) {
3280        cb.flags &= -2;
3281      }
3282    }
3283  }
3284}
3285function flushPostFlushCbs(seen) {
3286  if (pendingPostFlushCbs.length) {
3287    const deduped = [...new Set(pendingPostFlushCbs)].sort(
3288      (a, b) => getId(a) - getId(b)
3289    );
3290    pendingPostFlushCbs.length = 0;
3291    if (activePostFlushCbs) {
3292      activePostFlushCbs.push(...deduped);
3293      return;
3294    }
3295    activePostFlushCbs = deduped;
3296    if (false) // removed by dead control flow
3297{}
3298    for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {
3299      const cb = activePostFlushCbs[postFlushIndex];
3300      if (false) // removed by dead control flow
3301{}
3302      if (cb.flags & 4) {
3303        cb.flags &= -2;
3304      }
3305      if (!(cb.flags & 8)) cb();
3306      cb.flags &= -2;
3307    }
3308    activePostFlushCbs = null;
3309    postFlushIndex = 0;
3310  }
3311}
3312const getId = (job) => job.id == null ? job.flags & 2 ? -1 : Infinity : job.id;
3313function flushJobs(seen) {
3314  if (false) // removed by dead control flow
3315{}
3316  const check =  false ? 0 : shared_esm_bundler_NOOP;
3317  try {
3318    for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {
3319      const job = queue[flushIndex];
3320      if (job && !(job.flags & 8)) {
3321        if (false) // removed by dead control flow
3322{}
3323        if (job.flags & 4) {
3324          job.flags &= ~1;
3325        }
3326        callWithErrorHandling(
3327          job,
3328          job.i,
3329          job.i ? 15 : 14
3330        );
3331        if (!(job.flags & 4)) {
3332          job.flags &= ~1;
3333        }
3334      }
3335    }
3336  } finally {
3337    for (; flushIndex < queue.length; flushIndex++) {
3338      const job = queue[flushIndex];
3339      if (job) {
3340        job.flags &= -2;
3341      }
3342    }
3343    flushIndex = -1;
3344    queue.length = 0;
3345    flushPostFlushCbs(seen);
3346    currentFlushPromise = null;
3347    if (queue.length || pendingPostFlushCbs.length) {
3348      flushJobs(seen);
3349    }
3350  }
3351}
3352function checkRecursiveUpdates(seen, fn) {
3353  const count = seen.get(fn) || 0;
3354  if (count > RECURSION_LIMIT) {
3355    const instance = fn.i;
3356    const componentName = instance && getComponentName(instance.type);
3357    handleError(
3358      `Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`,
3359      null,
3360      10
3361    );
3362    return true;
3363  }
3364  seen.set(fn, count + 1);
3365  return false;
vendor: 9,043 bytes, lines 3366-3672
3366}
3367
3368let isHmrUpdating = false;
3369const hmrDirtyComponents = /* @__PURE__ */ new Map();
3370if (false) // removed by dead control flow
3371{}
3372const map = /* @__PURE__ */ new Map();
3373function registerHMR(instance) {
3374  const id = instance.type.__hmrId;
3375  let record = map.get(id);
3376  if (!record) {
3377    createRecord(id, instance.type);
3378    record = map.get(id);
3379  }
3380  record.instances.add(instance);
3381}
3382function unregisterHMR(instance) {
3383  map.get(instance.type.__hmrId).instances.delete(instance);
3384}
3385function createRecord(id, initialDef) {
3386  if (map.has(id)) {
3387    return false;
3388  }
3389  map.set(id, {
3390    initialDef: normalizeClassComponent(initialDef),
3391    instances: /* @__PURE__ */ new Set()
3392  });
3393  return true;
3394}
3395function normalizeClassComponent(component) {
3396  return isClassComponent(component) ? component.__vccOpts : component;
3397}
3398function rerender(id, newRender) {
3399  const record = map.get(id);
3400  if (!record) {
3401    return;
3402  }
3403  record.initialDef.render = newRender;
3404  [...record.instances].forEach((instance) => {
3405    if (newRender) {
3406      instance.render = newRender;
3407      normalizeClassComponent(instance.type).render = newRender;
3408    }
3409    instance.renderCache = [];
3410    isHmrUpdating = true;
3411    if (!(instance.job.flags & 8)) {
3412      instance.update();
3413    }
3414    isHmrUpdating = false;
3415  });
3416}
3417function reload(id, newComp) {
3418  const record = map.get(id);
3419  if (!record) return;
3420  newComp = normalizeClassComponent(newComp);
3421  updateComponentDef(record.initialDef, newComp);
3422  const instances = [...record.instances];
3423  for (let i = 0; i < instances.length; i++) {
3424    const instance = instances[i];
3425    const oldComp = normalizeClassComponent(instance.type);
3426    let dirtyInstances = hmrDirtyComponents.get(oldComp);
3427    if (!dirtyInstances) {
3428      if (oldComp !== record.initialDef) {
3429        updateComponentDef(oldComp, newComp);
3430      }
3431      hmrDirtyComponents.set(oldComp, dirtyInstances = /* @__PURE__ */ new Set());
3432    }
3433    dirtyInstances.add(instance);
3434    instance.appContext.propsCache.delete(instance.type);
3435    instance.appContext.emitsCache.delete(instance.type);
3436    instance.appContext.optionsCache.delete(instance.type);
3437    if (instance.ceReload) {
3438      dirtyInstances.add(instance);
3439      instance.ceReload(newComp.styles);
3440      dirtyInstances.delete(instance);
3441    } else if (instance.parent) {
3442      queueJob(() => {
3443        if (!(instance.job.flags & 8)) {
3444          isHmrUpdating = true;
3445          instance.parent.update();
3446          isHmrUpdating = false;
3447          dirtyInstances.delete(instance);
3448        }
3449      });
3450    } else if (instance.appContext.reload) {
3451      instance.appContext.reload();
3452    } else if (typeof window !== "undefined") {
3453      window.location.reload();
3454    } else {
3455      console.warn(
3456        "[HMR] Root or manually mounted instance modified. Full reload required."
3457      );
3458    }
3459    if (instance.root.ce && instance !== instance.root) {
3460      instance.root.ce._removeChildStyle(oldComp);
3461    }
3462  }
3463  queuePostFlushCb(() => {
3464    hmrDirtyComponents.clear();
3465  });
3466}
3467function updateComponentDef(oldComp, newComp) {
3468  extend(oldComp, newComp);
3469  for (const key in oldComp) {
3470    if (key !== "__file" && !(key in newComp)) {
3471      delete oldComp[key];
3472    }
3473  }
3474}
3475function tryWrap(fn) {
3476  return (id, arg) => {
3477    try {
3478      return fn(id, arg);
3479    } catch (e) {
3480      console.error(e);
3481      console.warn(
3482        `[HMR] Something went wrong during Vue component hot-reload. Full reload required.`
3483      );
3484    }
3485  };
3486}
3487
3488let devtools$1;
3489let buffer = [];
3490let devtoolsNotInstalled = false;
3491function emit$1(event, ...args) {
3492  if (devtools$1) {
3493    devtools$1.emit(event, ...args);
3494  } else if (!devtoolsNotInstalled) {
3495    buffer.push({ event, args });
3496  }
3497}
3498function setDevtoolsHook$1(hook, target) {
3499  var _a, _b;
3500  devtools$1 = hook;
3501  if (devtools$1) {
3502    devtools$1.enabled = true;
3503    buffer.forEach(({ event, args }) => devtools$1.emit(event, ...args));
3504    buffer = [];
3505  } else if (
3506    // handle late devtools injection - only do this if we are in an actual
3507    // browser environment to avoid the timer handle stalling test runner exit
3508    // (#4815)
3509    typeof window !== "undefined" && // some envs mock window but not fully
3510    window.HTMLElement && // also exclude jsdom
3511    // eslint-disable-next-line no-restricted-syntax
3512    !((_b = (_a = window.navigator) == null ? void 0 : _a.userAgent) == null ? void 0 : _b.includes("jsdom"))
3513  ) {
3514    const replay = target.__VUE_DEVTOOLS_HOOK_REPLAY__ = target.__VUE_DEVTOOLS_HOOK_REPLAY__ || [];
3515    replay.push((newHook) => {
3516      setDevtoolsHook$1(newHook, target);
3517    });
3518    setTimeout(() => {
3519      if (!devtools$1) {
3520        target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null;
3521        devtoolsNotInstalled = true;
3522        buffer = [];
3523      }
3524    }, 3e3);
3525  } else {
3526    devtoolsNotInstalled = true;
3527    buffer = [];
3528  }
3529}
3530function devtoolsInitApp(app, version) {
3531  emit$1("app:init" /* APP_INIT */, app, version, {
3532    Fragment,
3533    Text,
3534    Comment,
3535    Static
3536  });
3537}
3538function devtoolsUnmountApp(app) {
3539  emit$1("app:unmount" /* APP_UNMOUNT */, app);
3540}
3541const devtoolsComponentAdded = /* @__PURE__ */ createDevtoolsComponentHook("component:added" /* COMPONENT_ADDED */);
3542const devtoolsComponentUpdated = /* @__PURE__ */ createDevtoolsComponentHook("component:updated" /* COMPONENT_UPDATED */);
3543const _devtoolsComponentRemoved = /* @__PURE__ */ createDevtoolsComponentHook(
3544  "component:removed" /* COMPONENT_REMOVED */
3545);
3546const devtoolsComponentRemoved = (component) => {
3547  if (devtools$1 && typeof devtools$1.cleanupBuffer === "function" && // remove the component if it wasn't buffered
3548  !devtools$1.cleanupBuffer(component)) {
3549    _devtoolsComponentRemoved(component);
3550  }
3551};
3552// @__NO_SIDE_EFFECTS__
3553function createDevtoolsComponentHook(hook) {
3554  return (component) => {
3555    emit$1(
3556      hook,
3557      component.appContext.app,
3558      component.uid,
3559      component.parent ? component.parent.uid : void 0,
3560      component
3561    );
3562  };
3563}
3564const devtoolsPerfStart = /* @__PURE__ */ (/* unused pure expression or super */ null && (createDevtoolsPerformanceHook("perf:start" /* PERFORMANCE_START */)));
3565const devtoolsPerfEnd = /* @__PURE__ */ (/* unused pure expression or super */ null && (createDevtoolsPerformanceHook("perf:end" /* PERFORMANCE_END */)));
3566function createDevtoolsPerformanceHook(hook) {
3567  return (component, type, time) => {
3568    emit$1(hook, component.appContext.app, component.uid, component, type, time);
3569  };
3570}
3571function devtoolsComponentEmit(component, event, params) {
3572  emit$1(
3573    "component:emit" /* COMPONENT_EMIT */,
3574    component.appContext.app,
3575    component,
3576    event,
3577    params
3578  );
3579}
3580
3581let currentRenderingInstance = null;
3582let currentScopeId = null;
3583function setCurrentRenderingInstance(instance) {
3584  const prev = currentRenderingInstance;
3585  currentRenderingInstance = instance;
3586  currentScopeId = instance && instance.type.__scopeId || null;
3587  return prev;
3588}
3589function pushScopeId(id) {
3590  currentScopeId = id;
3591}
3592function popScopeId() {
3593  currentScopeId = null;
3594}
3595const withScopeId = (_id) => withCtx;
3596function withCtx(fn, ctx = currentRenderingInstance, isNonScopedSlot) {
3597  if (!ctx) return fn;
3598  if (fn._n) {
3599    return fn;
3600  }
3601  const renderFnWithContext = (...args) => {
3602    if (renderFnWithContext._d) {
3603      setBlockTracking(-1);
3604    }
3605    const prevInstance = setCurrentRenderingInstance(ctx);
3606    let res;
3607    try {
3608      res = fn(...args);
3609    } finally {
3610      setCurrentRenderingInstance(prevInstance);
3611      if (renderFnWithContext._d) {
3612        setBlockTracking(1);
3613      }
3614    }
3615    if ( false || __VUE_PROD_DEVTOOLS__) {
3616      devtoolsComponentUpdated(ctx);
3617    }
3618    return res;
3619  };
3620  renderFnWithContext._n = true;
3621  renderFnWithContext._c = true;
3622  renderFnWithContext._d = true;
3623  return renderFnWithContext;
3624}
3625
3626function validateDirectiveName(name) {
3627  if (isBuiltInDirective(name)) {
3628    warn$1("Do not use built-in directive ids as custom directive id: " + name);
3629  }
3630}
3631function withDirectives(vnode, directives) {
3632  if (currentRenderingInstance === null) {
3633     false && 0;
3634    return vnode;
3635  }
3636  const instance = getComponentPublicInstance(currentRenderingInstance);
3637  const bindings = vnode.dirs || (vnode.dirs = []);
3638  for (let i = 0; i < directives.length; i++) {
3639    let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];
3640    if (dir) {
3641      if (shared_esm_bundler_isFunction(dir)) {
3642        dir = {
3643          mounted: dir,
3644          updated: dir
3645        };
3646      }
3647      if (dir.deep) {
3648        traverse(value);
3649      }
3650      bindings.push({
3651        dir,
3652        instance,
3653        value,
3654        oldValue: void 0,
3655        arg,
3656        modifiers
3657      });
3658    }
3659  }
3660  return vnode;
3661}
3662function invokeDirectiveHook(vnode, prevVNode, instance, name) {
3663  const bindings = vnode.dirs;
3664  const oldBindings = prevVNode && prevVNode.dirs;
3665  for (let i = 0; i < bindings.length; i++) {
3666    const binding = bindings[i];
3667    if (oldBindings) {
3668      binding.oldValue = oldBindings[i].value;
3669    }
3670    let hook = binding.dir[name];
3671    if (hook) {
3672      pauseTracking();
3673      callWithAsyncErrorHandling(hook, instance, 8, [
3674        vnode.el,
3675        binding,
3676        vnode,
3677        prevVNode
3678      ]);
3679      resetTracking();
3680    }
3681  }
3682}
3683
3684const TeleportEndKey = Symbol("_vte");
3685const isTeleport = (type) => type.__isTeleport;
3686const isTeleportDisabled = (props) => props && (props.disabled || props.disabled === "");
3687const isTeleportDeferred = (props) => props && (props.defer || props.defer === "");
3688const isTargetSVG = (target) => typeof SVGElement !== "undefined" && target instanceof SVGElement;
3689const isTargetMathML = (target) => typeof MathMLElement === "function" && target instanceof MathMLElement;
3690const resolveTarget = (props, select) => {
3691  const targetSelector = props && props.to;
3692  if (shared_esm_bundler_isString(targetSelector)) {
3693    if (!select) {
3694       false && 0;
3695      return null;
3696    } else {
3697      const target = select(targetSelector);
3698      if (false) // removed by dead control flow
3699{}
3700      return target;
3701    }
3702  } else {
3703    if (false) // removed by dead control flow
3704{}
3705    return targetSelector;
3706  }
3707};
3708const TeleportImpl = {
3709  name: "Teleport",
3710  __isTeleport: true,
3711  process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, internals) {
3712    const {
3713      mc: mountChildren,
3714      pc: patchChildren,
3715      pbc: patchBlockChildren,
3716      o: { insert, querySelector, createText, createComment }
3717    } = internals;
3718    const disabled = isTeleportDisabled(n2.props);
3719    let { shapeFlag, children, dynamicChildren } = n2;
3720    if (false) // removed by dead control flow
3721{}
3722    if (n1 == null) {
3723      const placeholder = n2.el =  false ? 0 : createText("");
3724      const mainAnchor = n2.anchor =  false ? 0 : createText("");
3725      insert(placeholder, container, anchor);
3726      insert(mainAnchor, container, anchor);
3727      const mount = (container2, anchor2) => {
3728        if (shapeFlag & 16) {
3729          mountChildren(
3730            children,
3731            container2,
3732            anchor2,
3733            parentComponent,
3734            parentSuspense,
3735            namespace,
3736            slotScopeIds,
3737            optimized
3738          );
3739        }
3740      };
3741      const mountToTarget = () => {
3742        const target = n2.target = resolveTarget(n2.props, querySelector);
3743        const targetAnchor = prepareAnchor(target, n2, createText, insert);
3744        if (target) {
3745          if (namespace !== "svg" && isTargetSVG(target)) {
3746            namespace = "svg";
3747          } else if (namespace !== "mathml" && isTargetMathML(target)) {
3748            namespace = "mathml";
3749          }
3750          if (parentComponent && parentComponent.isCE) {
3751            (parentComponent.ce._teleportTargets || (parentComponent.ce._teleportTargets = /* @__PURE__ */ new Set())).add(target);
3752          }
3753          if (!disabled) {
3754            mount(target, targetAnchor);
3755            updateCssVars(n2, false);
3756          }
3757        } else if (false) // removed by dead control flow
3758{}
3759      };
3760      if (disabled) {
3761        mount(container, mainAnchor);
3762        updateCssVars(n2, true);
3763      }
3764      if (isTeleportDeferred(n2.props)) {
3765        n2.el.__isMounted = false;
3766        queuePostRenderEffect(() => {
3767          mountToTarget();
3768          delete n2.el.__isMounted;
3769        }, parentSuspense);
3770      } else {
3771        mountToTarget();
3772      }
3773    } else {
3774      if (isTeleportDeferred(n2.props) && n1.el.__isMounted === false) {
3775        queuePostRenderEffect(() => {
3776          TeleportImpl.process(
3777            n1,
3778            n2,
3779            container,
3780            anchor,
3781            parentComponent,
3782            parentSuspense,
3783            namespace,
3784            slotScopeIds,
3785            optimized,
3786            internals
3787          );
3788        }, parentSuspense);
3789        return;
3790      }
3791      n2.el = n1.el;
3792      n2.targetStart = n1.targetStart;
3793      const mainAnchor = n2.anchor = n1.anchor;
3794      const target = n2.target = n1.target;
3795      const targetAnchor = n2.targetAnchor = n1.targetAnchor;
3796      const wasDisabled = isTeleportDisabled(n1.props);
3797      const currentContainer = wasDisabled ? container : target;
3798      const currentAnchor = wasDisabled ? mainAnchor : targetAnchor;
3799      if (namespace === "svg" || isTargetSVG(target)) {
3800        namespace = "svg";
3801      } else if (namespace === "mathml" || isTargetMathML(target)) {
3802        namespace = "mathml";
3803      }
3804      if (dynamicChildren) {
3805        patchBlockChildren(
3806          n1.dynamicChildren,
3807          dynamicChildren,
3808          currentContainer,
3809          parentComponent,
3810          parentSuspense,
3811          namespace,
3812          slotScopeIds
3813        );
vendor: 8,282 bytes, lines 3814-4103
3814        traverseStaticChildren(n1, n2, !!!("production" !== "production"));
3815      } else if (!optimized) {
3816        patchChildren(
3817          n1,
3818          n2,
3819          currentContainer,
3820          currentAnchor,
3821          parentComponent,
3822          parentSuspense,
3823          namespace,
3824          slotScopeIds,
3825          false
3826        );
3827      }
3828      if (disabled) {
3829        if (!wasDisabled) {
3830          moveTeleport(
3831            n2,
3832            container,
3833            mainAnchor,
3834            internals,
3835            1
3836          );
3837        } else {
3838          if (n2.props && n1.props && n2.props.to !== n1.props.to) {
3839            n2.props.to = n1.props.to;
3840          }
3841        }
3842      } else {
3843        if ((n2.props && n2.props.to) !== (n1.props && n1.props.to)) {
3844          const nextTarget = n2.target = resolveTarget(
3845            n2.props,
3846            querySelector
3847          );
3848          if (nextTarget) {
3849            moveTeleport(
3850              n2,
3851              nextTarget,
3852              null,
3853              internals,
3854              0
3855            );
3856          } else if (false) // removed by dead control flow
3857{}
3858        } else if (wasDisabled) {
3859          moveTeleport(
3860            n2,
3861            target,
3862            targetAnchor,
3863            internals,
3864            1
3865          );
3866        }
3867      }
3868      updateCssVars(n2, disabled);
3869    }
3870  },
3871  remove(vnode, parentComponent, parentSuspense, { um: unmount, o: { remove: hostRemove } }, doRemove) {
3872    const {
3873      shapeFlag,
3874      children,
3875      anchor,
3876      targetStart,
3877      targetAnchor,
3878      target,
3879      props
3880    } = vnode;
3881    if (target) {
3882      hostRemove(targetStart);
3883      hostRemove(targetAnchor);
3884    }
3885    doRemove && hostRemove(anchor);
3886    if (shapeFlag & 16) {
3887      const shouldRemove = doRemove || !isTeleportDisabled(props);
3888      for (let i = 0; i < children.length; i++) {
3889        const child = children[i];
3890        unmount(
3891          child,
3892          parentComponent,
3893          parentSuspense,
3894          shouldRemove,
3895          !!child.dynamicChildren
3896        );
3897      }
3898    }
3899  },
3900  move: moveTeleport,
3901  hydrate: hydrateTeleport
3902};
3903function moveTeleport(vnode, container, parentAnchor, { o: { insert }, m: move }, moveType = 2) {
3904  if (moveType === 0) {
3905    insert(vnode.targetAnchor, container, parentAnchor);
3906  }
3907  const { el, anchor, shapeFlag, children, props } = vnode;
3908  const isReorder = moveType === 2;
3909  if (isReorder) {
3910    insert(el, container, parentAnchor);
3911  }
3912  if (!isReorder || isTeleportDisabled(props)) {
3913    if (shapeFlag & 16) {
3914      for (let i = 0; i < children.length; i++) {
3915        move(
3916          children[i],
3917          container,
3918          parentAnchor,
3919          2
3920        );
3921      }
3922    }
3923  }
3924  if (isReorder) {
3925    insert(anchor, container, parentAnchor);
3926  }
3927}
3928function hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, {
3929  o: { nextSibling, parentNode, querySelector, insert, createText }
3930}, hydrateChildren) {
3931  function hydrateDisabledTeleport(node2, vnode2, targetStart, targetAnchor) {
3932    vnode2.anchor = hydrateChildren(
3933      nextSibling(node2),
3934      vnode2,
3935      parentNode(node2),
3936      parentComponent,
3937      parentSuspense,
3938      slotScopeIds,
3939      optimized
3940    );
3941    vnode2.targetStart = targetStart;
3942    vnode2.targetAnchor = targetAnchor;
3943  }
3944  const target = vnode.target = resolveTarget(
3945    vnode.props,
3946    querySelector
3947  );
3948  const disabled = isTeleportDisabled(vnode.props);
3949  if (target) {
3950    const targetNode = target._lpa || target.firstChild;
3951    if (vnode.shapeFlag & 16) {
3952      if (disabled) {
3953        hydrateDisabledTeleport(
3954          node,
3955          vnode,
3956          targetNode,
3957          targetNode && nextSibling(targetNode)
3958        );
3959      } else {
3960        vnode.anchor = nextSibling(node);
3961        let targetAnchor = targetNode;
3962        while (targetAnchor) {
3963          if (targetAnchor && targetAnchor.nodeType === 8) {
3964            if (targetAnchor.data === "teleport start anchor") {
3965              vnode.targetStart = targetAnchor;
3966            } else if (targetAnchor.data === "teleport anchor") {
3967              vnode.targetAnchor = targetAnchor;
3968              target._lpa = vnode.targetAnchor && nextSibling(vnode.targetAnchor);
3969              break;
3970            }
3971          }
3972          targetAnchor = nextSibling(targetAnchor);
3973        }
3974        if (!vnode.targetAnchor) {
3975          prepareAnchor(target, vnode, createText, insert);
3976        }
3977        hydrateChildren(
3978          targetNode && nextSibling(targetNode),
3979          vnode,
3980          target,
3981          parentComponent,
3982          parentSuspense,
3983          slotScopeIds,
3984          optimized
3985        );
3986      }
3987    }
3988    updateCssVars(vnode, disabled);
3989  } else if (disabled) {
3990    if (vnode.shapeFlag & 16) {
3991      hydrateDisabledTeleport(node, vnode, node, nextSibling(node));
3992    }
3993  }
3994  return vnode.anchor && nextSibling(vnode.anchor);
3995}
3996const Teleport = TeleportImpl;
3997function updateCssVars(vnode, isDisabled) {
3998  const ctx = vnode.ctx;
3999  if (ctx && ctx.ut) {
4000    let node, anchor;
4001    if (isDisabled) {
4002      node = vnode.el;
4003      anchor = vnode.anchor;
4004    } else {
4005      node = vnode.targetStart;
4006      anchor = vnode.targetAnchor;
4007    }
4008    while (node && node !== anchor) {
4009      if (node.nodeType === 1) node.setAttribute("data-v-owner", ctx.uid);
4010      node = node.nextSibling;
4011    }
4012    ctx.ut();
4013  }
4014}
4015function prepareAnchor(target, vnode, createText, insert) {
4016  const targetStart = vnode.targetStart = createText("");
4017  const targetAnchor = vnode.targetAnchor = createText("");
4018  targetStart[TeleportEndKey] = targetAnchor;
4019  if (target) {
4020    insert(targetStart, target);
4021    insert(targetAnchor, target);
4022  }
4023  return targetAnchor;
4024}
4025
4026const leaveCbKey = Symbol("_leaveCb");
4027const enterCbKey = Symbol("_enterCb");
4028function useTransitionState() {
4029  const state = {
4030    isMounted: false,
4031    isLeaving: false,
4032    isUnmounting: false,
4033    leavingVNodes: /* @__PURE__ */ new Map()
4034  };
4035  onMounted(() => {
4036    state.isMounted = true;
4037  });
4038  onBeforeUnmount(() => {
4039    state.isUnmounting = true;
4040  });
4041  return state;
4042}
4043const TransitionHookValidator = [Function, Array];
4044const BaseTransitionPropsValidators = {
4045  mode: String,
4046  appear: Boolean,
4047  persisted: Boolean,
4048  // enter
4049  onBeforeEnter: TransitionHookValidator,
4050  onEnter: TransitionHookValidator,
4051  onAfterEnter: TransitionHookValidator,
4052  onEnterCancelled: TransitionHookValidator,
4053  // leave
4054  onBeforeLeave: TransitionHookValidator,
4055  onLeave: TransitionHookValidator,
4056  onAfterLeave: TransitionHookValidator,
4057  onLeaveCancelled: TransitionHookValidator,
4058  // appear
4059  onBeforeAppear: TransitionHookValidator,
4060  onAppear: TransitionHookValidator,
4061  onAfterAppear: TransitionHookValidator,
4062  onAppearCancelled: TransitionHookValidator
4063};
4064const recursiveGetSubtree = (instance) => {
4065  const subTree = instance.subTree;
4066  return subTree.component ? recursiveGetSubtree(subTree.component) : subTree;
4067};
4068const BaseTransitionImpl = {
4069  name: `BaseTransition`,
4070  props: BaseTransitionPropsValidators,
4071  setup(props, { slots }) {
4072    const instance = getCurrentInstance();
4073    const state = useTransitionState();
4074    return () => {
4075      const children = slots.default && getTransitionRawChildren(slots.default(), true);
4076      if (!children || !children.length) {
4077        return;
4078      }
4079      const child = findNonCommentChild(children);
4080      const rawProps = reactivity_esm_bundler_toRaw(props);
4081      const { mode } = rawProps;
4082      if (false) // removed by dead control flow
4083{}
4084      if (state.isLeaving) {
4085        return emptyPlaceholder(child);
4086      }
4087      const innerChild = getInnerChild$1(child);
4088      if (!innerChild) {
4089        return emptyPlaceholder(child);
4090      }
4091      let enterHooks = resolveTransitionHooks(
4092        innerChild,
4093        rawProps,
4094        state,
4095        instance,
4096        // #11061, ensure enterHooks is fresh after clone
4097        (hooks) => enterHooks = hooks
4098      );
4099      if (innerChild.type !== Comment) {
4100        setTransitionHooks(innerChild, enterHooks);
4101      }
4102      let oldInnerChild = instance.subTree && getInnerChild$1(instance.subTree);
4103      if (oldInnerChild && oldInnerChild.type !== Comment && !isSameVNodeType(oldInnerChild, innerChild) && recursiveGetSubtree(instance).type !== Comment) {
vendor: 6,839 bytes, lines 4104-4360
4104        let leavingHooks = resolveTransitionHooks(
4105          oldInnerChild,
4106          rawProps,
4107          state,
4108          instance
4109        );
4110        setTransitionHooks(oldInnerChild, leavingHooks);
4111        if (mode === "out-in" && innerChild.type !== Comment) {
4112          state.isLeaving = true;
4113          leavingHooks.afterLeave = () => {
4114            state.isLeaving = false;
4115            if (!(instance.job.flags & 8)) {
4116              instance.update();
4117            }
4118            delete leavingHooks.afterLeave;
4119            oldInnerChild = void 0;
4120          };
4121          return emptyPlaceholder(child);
4122        } else if (mode === "in-out" && innerChild.type !== Comment) {
4123          leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {
4124            const leavingVNodesCache = getLeavingNodesForType(
4125              state,
4126              oldInnerChild
4127            );
4128            leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;
4129            el[leaveCbKey] = () => {
4130              earlyRemove();
4131              el[leaveCbKey] = void 0;
4132              delete enterHooks.delayedLeave;
4133              oldInnerChild = void 0;
4134            };
4135            enterHooks.delayedLeave = () => {
4136              delayedLeave();
4137              delete enterHooks.delayedLeave;
4138              oldInnerChild = void 0;
4139            };
4140          };
4141        } else {
4142          oldInnerChild = void 0;
4143        }
4144      } else if (oldInnerChild) {
4145        oldInnerChild = void 0;
4146      }
4147      return child;
4148    };
4149  }
4150};
4151function findNonCommentChild(children) {
4152  let child = children[0];
4153  if (children.length > 1) {
4154    let hasFound = false;
4155    for (const c of children) {
4156      if (c.type !== Comment) {
4157        if (false) // removed by dead control flow
4158{}
4159        child = c;
4160        hasFound = true;
4161        if (true) break;
4162      }
4163    }
4164  }
4165  return child;
4166}
4167const BaseTransition = BaseTransitionImpl;
4168function getLeavingNodesForType(state, vnode) {
4169  const { leavingVNodes } = state;
4170  let leavingVNodesCache = leavingVNodes.get(vnode.type);
4171  if (!leavingVNodesCache) {
4172    leavingVNodesCache = /* @__PURE__ */ Object.create(null);
4173    leavingVNodes.set(vnode.type, leavingVNodesCache);
4174  }
4175  return leavingVNodesCache;
4176}
4177function resolveTransitionHooks(vnode, props, state, instance, postClone) {
4178  const {
4179    appear,
4180    mode,
4181    persisted = false,
4182    onBeforeEnter,
4183    onEnter,
4184    onAfterEnter,
4185    onEnterCancelled,
4186    onBeforeLeave,
4187    onLeave,
4188    onAfterLeave,
4189    onLeaveCancelled,
4190    onBeforeAppear,
4191    onAppear,
4192    onAfterAppear,
4193    onAppearCancelled
4194  } = props;
4195  const key = String(vnode.key);
4196  const leavingVNodesCache = getLeavingNodesForType(state, vnode);
4197  const callHook = (hook, args) => {
4198    hook && callWithAsyncErrorHandling(
4199      hook,
4200      instance,
4201      9,
4202      args
4203    );
4204  };
4205  const callAsyncHook = (hook, args) => {
4206    const done = args[1];
4207    callHook(hook, args);
4208    if (shared_esm_bundler_isArray(hook)) {
4209      if (hook.every((hook2) => hook2.length <= 1)) done();
4210    } else if (hook.length <= 1) {
4211      done();
4212    }
4213  };
4214  const hooks = {
4215    mode,
4216    persisted,
4217    beforeEnter(el) {
4218      let hook = onBeforeEnter;
4219      if (!state.isMounted) {
4220        if (appear) {
4221          hook = onBeforeAppear || onBeforeEnter;
4222        } else {
4223          return;
4224        }
4225      }
4226      if (el[leaveCbKey]) {
4227        el[leaveCbKey](
4228          true
4229          /* cancelled */
4230        );
4231      }
4232      const leavingVNode = leavingVNodesCache[key];
4233      if (leavingVNode && isSameVNodeType(vnode, leavingVNode) && leavingVNode.el[leaveCbKey]) {
4234        leavingVNode.el[leaveCbKey]();
4235      }
4236      callHook(hook, [el]);
4237    },
4238    enter(el) {
4239      let hook = onEnter;
4240      let afterHook = onAfterEnter;
4241      let cancelHook = onEnterCancelled;
4242      if (!state.isMounted) {
4243        if (appear) {
4244          hook = onAppear || onEnter;
4245          afterHook = onAfterAppear || onAfterEnter;
4246          cancelHook = onAppearCancelled || onEnterCancelled;
4247        } else {
4248          return;
4249        }
4250      }
4251      let called = false;
4252      const done = el[enterCbKey] = (cancelled) => {
4253        if (called) return;
4254        called = true;
4255        if (cancelled) {
4256          callHook(cancelHook, [el]);
4257        } else {
4258          callHook(afterHook, [el]);
4259        }
4260        if (hooks.delayedLeave) {
4261          hooks.delayedLeave();
4262        }
4263        el[enterCbKey] = void 0;
4264      };
4265      if (hook) {
4266        callAsyncHook(hook, [el, done]);
4267      } else {
4268        done();
4269      }
4270    },
4271    leave(el, remove) {
4272      const key2 = String(vnode.key);
4273      if (el[enterCbKey]) {
4274        el[enterCbKey](
4275          true
4276          /* cancelled */
4277        );
4278      }
4279      if (state.isUnmounting) {
4280        return remove();
4281      }
4282      callHook(onBeforeLeave, [el]);
4283      let called = false;
4284      const done = el[leaveCbKey] = (cancelled) => {
4285        if (called) return;
4286        called = true;
4287        remove();
4288        if (cancelled) {
4289          callHook(onLeaveCancelled, [el]);
4290        } else {
4291          callHook(onAfterLeave, [el]);
4292        }
4293        el[leaveCbKey] = void 0;
4294        if (leavingVNodesCache[key2] === vnode) {
4295          delete leavingVNodesCache[key2];
4296        }
4297      };
4298      leavingVNodesCache[key2] = vnode;
4299      if (onLeave) {
4300        callAsyncHook(onLeave, [el, done]);
4301      } else {
4302        done();
4303      }
4304    },
4305    clone(vnode2) {
4306      const hooks2 = resolveTransitionHooks(
4307        vnode2,
4308        props,
4309        state,
4310        instance,
4311        postClone
4312      );
4313      if (postClone) postClone(hooks2);
4314      return hooks2;
4315    }
4316  };
4317  return hooks;
4318}
4319function emptyPlaceholder(vnode) {
4320  if (isKeepAlive(vnode)) {
4321    vnode = cloneVNode(vnode);
4322    vnode.children = null;
4323    return vnode;
4324  }
4325}
4326function getInnerChild$1(vnode) {
4327  if (!isKeepAlive(vnode)) {
4328    if (isTeleport(vnode.type) && vnode.children) {
4329      return findNonCommentChild(vnode.children);
4330    }
4331    return vnode;
4332  }
4333  if (vnode.component) {
4334    return vnode.component.subTree;
4335  }
4336  const { shapeFlag, children } = vnode;
4337  if (children) {
4338    if (shapeFlag & 16) {
4339      return children[0];
4340    }
4341    if (shapeFlag & 32 && shared_esm_bundler_isFunction(children.default)) {
4342      return children.default();
4343    }
4344  }
4345}
4346function setTransitionHooks(vnode, hooks) {
4347  if (vnode.shapeFlag & 6 && vnode.component) {
4348    vnode.transition = hooks;
4349    setTransitionHooks(vnode.component.subTree, hooks);
4350  } else if (vnode.shapeFlag & 128) {
4351    vnode.ssContent.transition = hooks.clone(vnode.ssContent);
4352    vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);
4353  } else {
4354    vnode.transition = hooks;
4355  }
4356}
4357function getTransitionRawChildren(children, keepComment = false, parentKey) {
4358  let ret = [];
4359  let keyedFragmentCount = 0;
4360  for (let i = 0; i < children.length; i++) {
vendor: 13,366 bytes, lines 4361-4773
4361    let child = children[i];
4362    const key = parentKey == null ? child.key : String(parentKey) + String(child.key != null ? child.key : i);
4363    if (child.type === Fragment) {
4364      if (child.patchFlag & 128) keyedFragmentCount++;
4365      ret = ret.concat(
4366        getTransitionRawChildren(child.children, keepComment, key)
4367      );
4368    } else if (keepComment || child.type !== Comment) {
4369      ret.push(key != null ? cloneVNode(child, { key }) : child);
4370    }
4371  }
4372  if (keyedFragmentCount > 1) {
4373    for (let i = 0; i < ret.length; i++) {
4374      ret[i].patchFlag = -2;
4375    }
4376  }
4377  return ret;
4378}
4379
4380// @__NO_SIDE_EFFECTS__
4381function defineComponent(options, extraOptions) {
4382  return shared_esm_bundler_isFunction(options) ? (
4383    // #8236: extend call and options.name access are considered side-effects
4384    // by Rollup, so we have to wrap it in a pure-annotated IIFE.
4385    /* @__PURE__ */ (() => shared_esm_bundler_extend({ name: options.name }, extraOptions, { setup: options }))()
4386  ) : options;
4387}
4388
4389function useId() {
4390  const i = getCurrentInstance();
4391  if (i) {
4392    return (i.appContext.config.idPrefix || "v") + "-" + i.ids[0] + i.ids[1]++;
4393  } else if (false) // removed by dead control flow
4394{}
4395  return "";
4396}
4397function markAsyncBoundary(instance) {
4398  instance.ids = [instance.ids[0] + instance.ids[2]++ + "-", 0, 0];
4399}
4400
4401const knownTemplateRefs = /* @__PURE__ */ new WeakSet();
4402function useTemplateRef(key) {
4403  const i = getCurrentInstance();
4404  const r = shallowRef(null);
4405  if (i) {
4406    const refs = i.refs === EMPTY_OBJ ? i.refs = {} : i.refs;
4407    let desc;
4408    if (false) // removed by dead control flow
4409{} else {
4410      Object.defineProperty(refs, key, {
4411        enumerable: true,
4412        get: () => r.value,
4413        set: (val) => r.value = val
4414      });
4415    }
4416  } else if (false) // removed by dead control flow
4417{}
4418  const ret =  false ? 0 : r;
4419  if (false) // removed by dead control flow
4420{}
4421  return ret;
4422}
4423
4424const pendingSetRefMap = /* @__PURE__ */ new WeakMap();
4425function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
4426  if (shared_esm_bundler_isArray(rawRef)) {
4427    rawRef.forEach(
4428      (r, i) => setRef(
4429        r,
4430        oldRawRef && (shared_esm_bundler_isArray(oldRawRef) ? oldRawRef[i] : oldRawRef),
4431        parentSuspense,
4432        vnode,
4433        isUnmount
4434      )
4435    );
4436    return;
4437  }
4438  if (isAsyncWrapper(vnode) && !isUnmount) {
4439    if (vnode.shapeFlag & 512 && vnode.type.__asyncResolved && vnode.component.subTree.component) {
4440      setRef(rawRef, oldRawRef, parentSuspense, vnode.component.subTree);
4441    }
4442    return;
4443  }
4444  const refValue = vnode.shapeFlag & 4 ? getComponentPublicInstance(vnode.component) : vnode.el;
4445  const value = isUnmount ? null : refValue;
4446  const { i: owner, r: ref } = rawRef;
4447  if (false) // removed by dead control flow
4448{}
4449  const oldRef = oldRawRef && oldRawRef.r;
4450  const refs = owner.refs === EMPTY_OBJ ? owner.refs = {} : owner.refs;
4451  const setupState = owner.setupState;
4452  const rawSetupState = reactivity_esm_bundler_toRaw(setupState);
4453  const canSetSetupRef = setupState === EMPTY_OBJ ? NO : (key) => {
4454    if (false) // removed by dead control flow
4455{}
4456    return hasOwn(rawSetupState, key);
4457  };
4458  const canSetRef = (ref2) => {
4459    return  true || 0;
4460  };
4461  if (oldRef != null && oldRef !== ref) {
4462    invalidatePendingSetRef(oldRawRef);
4463    if (shared_esm_bundler_isString(oldRef)) {
4464      refs[oldRef] = null;
4465      if (canSetSetupRef(oldRef)) {
4466        setupState[oldRef] = null;
4467      }
4468    } else if (reactivity_esm_bundler_isRef(oldRef)) {
4469      if (canSetRef(oldRef)) {
4470        oldRef.value = null;
4471      }
4472      const oldRawRefAtom = oldRawRef;
4473      if (oldRawRefAtom.k) refs[oldRawRefAtom.k] = null;
4474    }
4475  }
4476  if (shared_esm_bundler_isFunction(ref)) {
4477    callWithErrorHandling(ref, owner, 12, [value, refs]);
4478  } else {
4479    const _isString = shared_esm_bundler_isString(ref);
4480    const _isRef = reactivity_esm_bundler_isRef(ref);
4481    if (_isString || _isRef) {
4482      const doSet = () => {
4483        if (rawRef.f) {
4484          const existing = _isString ? canSetSetupRef(ref) ? setupState[ref] : refs[ref] : canSetRef(ref) || !rawRef.k ? ref.value : refs[rawRef.k];
4485          if (isUnmount) {
4486            shared_esm_bundler_isArray(existing) && remove(existing, refValue);
4487          } else {
4488            if (!shared_esm_bundler_isArray(existing)) {
4489              if (_isString) {
4490                refs[ref] = [refValue];
4491                if (canSetSetupRef(ref)) {
4492                  setupState[ref] = refs[ref];
4493                }
4494              } else {
4495                const newVal = [refValue];
4496                if (canSetRef(ref)) {
4497                  ref.value = newVal;
4498                }
4499                if (rawRef.k) refs[rawRef.k] = newVal;
4500              }
4501            } else if (!existing.includes(refValue)) {
4502              existing.push(refValue);
4503            }
4504          }
4505        } else if (_isString) {
4506          refs[ref] = value;
4507          if (canSetSetupRef(ref)) {
4508            setupState[ref] = value;
4509          }
4510        } else if (_isRef) {
4511          if (canSetRef(ref)) {
4512            ref.value = value;
4513          }
4514          if (rawRef.k) refs[rawRef.k] = value;
4515        } else if (false) // removed by dead control flow
4516{}
4517      };
4518      if (value) {
4519        const job = () => {
4520          doSet();
4521          pendingSetRefMap.delete(rawRef);
4522        };
4523        job.id = -1;
4524        pendingSetRefMap.set(rawRef, job);
4525        queuePostRenderEffect(job, parentSuspense);
4526      } else {
4527        invalidatePendingSetRef(rawRef);
4528        doSet();
4529      }
4530    } else if (false) // removed by dead control flow
4531{}
4532  }
4533}
4534function invalidatePendingSetRef(rawRef) {
4535  const pendingSetRef = pendingSetRefMap.get(rawRef);
4536  if (pendingSetRef) {
4537    pendingSetRef.flags |= 8;
4538    pendingSetRefMap.delete(rawRef);
4539  }
4540}
4541
4542let hasLoggedMismatchError = false;
4543const logMismatchError = () => {
4544  if (hasLoggedMismatchError) {
4545    return;
4546  }
4547  console.error("Hydration completed but contains mismatches.");
4548  hasLoggedMismatchError = true;
4549};
4550const isSVGContainer = (container) => container.namespaceURI.includes("svg") && container.tagName !== "foreignObject";
4551const isMathMLContainer = (container) => container.namespaceURI.includes("MathML");
4552const getContainerType = (container) => {
4553  if (container.nodeType !== 1) return void 0;
4554  if (isSVGContainer(container)) return "svg";
4555  if (isMathMLContainer(container)) return "mathml";
4556  return void 0;
4557};
4558const isComment = (node) => node.nodeType === 8;
4559function createHydrationFunctions(rendererInternals) {
4560  const {
4561    mt: mountComponent,
4562    p: patch,
4563    o: {
4564      patchProp,
4565      createText,
4566      nextSibling,
4567      parentNode,
4568      remove,
4569      insert,
4570      createComment
4571    }
4572  } = rendererInternals;
4573  const hydrate = (vnode, container) => {
4574    if (!container.hasChildNodes()) {
4575      ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(
4576        `Attempting to hydrate existing markup but container is empty. Performing full mount instead.`
4577      );
4578      patch(null, vnode, container);
4579      flushPostFlushCbs();
4580      container._vnode = vnode;
4581      return;
4582    }
4583    hydrateNode(container.firstChild, vnode, null, null, null);
4584    flushPostFlushCbs();
4585    container._vnode = vnode;
4586  };
4587  const hydrateNode = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized = false) => {
4588    optimized = optimized || !!vnode.dynamicChildren;
4589    const isFragmentStart = isComment(node) && node.data === "[";
4590    const onMismatch = () => handleMismatch(
4591      node,
4592      vnode,
4593      parentComponent,
4594      parentSuspense,
4595      slotScopeIds,
4596      isFragmentStart
4597    );
4598    const { type, ref, shapeFlag, patchFlag } = vnode;
4599    let domType = node.nodeType;
4600    vnode.el = node;
4601    if ( false || __VUE_PROD_DEVTOOLS__) {
4602      def(node, "__vnode", vnode, true);
4603      def(node, "__vueParentComponent", parentComponent, true);
4604    }
4605    if (patchFlag === -2) {
4606      optimized = false;
4607      vnode.dynamicChildren = null;
4608    }
4609    let nextNode = null;
4610    switch (type) {
4611      case Text:
4612        if (domType !== 3) {
4613          if (vnode.children === "") {
4614            insert(vnode.el = createText(""), parentNode(node), node);
4615            nextNode = node;
4616          } else {
4617            nextNode = onMismatch();
4618          }
4619        } else {
4620          if (node.data !== vnode.children) {
4621            ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(
4622              `Hydration text mismatch in`,
4623              node.parentNode,
4624              `
4625  - rendered on server: ${JSON.stringify(
4626                node.data
4627              )}
4628  - expected on client: ${JSON.stringify(vnode.children)}`
4629            );
4630            logMismatchError();
4631            node.data = vnode.children;
4632          }
4633          nextNode = nextSibling(node);
4634        }
4635        break;
4636      case Comment:
4637        if (isTemplateNode(node)) {
4638          nextNode = nextSibling(node);
4639          replaceNode(
4640            vnode.el = node.content.firstChild,
4641            node,
4642            parentComponent
4643          );
4644        } else if (domType !== 8 || isFragmentStart) {
4645          nextNode = onMismatch();
4646        } else {
4647          nextNode = nextSibling(node);
4648        }
4649        break;
4650      case Static:
4651        if (isFragmentStart) {
4652          node = nextSibling(node);
4653          domType = node.nodeType;
4654        }
4655        if (domType === 1 || domType === 3) {
4656          nextNode = node;
4657          const needToAdoptContent = !vnode.children.length;
4658          for (let i = 0; i < vnode.staticCount; i++) {
4659            if (needToAdoptContent)
4660              vnode.children += nextNode.nodeType === 1 ? nextNode.outerHTML : nextNode.data;
4661            if (i === vnode.staticCount - 1) {
4662              vnode.anchor = nextNode;
4663            }
4664            nextNode = nextSibling(nextNode);
4665          }
4666          return isFragmentStart ? nextSibling(nextNode) : nextNode;
4667        } else {
4668          onMismatch();
4669        }
4670        break;
4671      case Fragment:
4672        if (!isFragmentStart) {
4673          nextNode = onMismatch();
4674        } else {
4675          nextNode = hydrateFragment(
4676            node,
4677            vnode,
4678            parentComponent,
4679            parentSuspense,
4680            slotScopeIds,
4681            optimized
4682          );
4683        }
4684        break;
4685      default:
4686        if (shapeFlag & 1) {
4687          if ((domType !== 1 || vnode.type.toLowerCase() !== node.tagName.toLowerCase()) && !isTemplateNode(node)) {
4688            nextNode = onMismatch();
4689          } else {
4690            nextNode = hydrateElement(
4691              node,
4692              vnode,
4693              parentComponent,
4694              parentSuspense,
4695              slotScopeIds,
4696              optimized
4697            );
4698          }
4699        } else if (shapeFlag & 6) {
4700          vnode.slotScopeIds = slotScopeIds;
4701          const container = parentNode(node);
4702          if (isFragmentStart) {
4703            nextNode = locateClosingAnchor(node);
4704          } else if (isComment(node) && node.data === "teleport start") {
4705            nextNode = locateClosingAnchor(node, node.data, "teleport end");
4706          } else {
4707            nextNode = nextSibling(node);
4708          }
4709          mountComponent(
4710            vnode,
4711            container,
4712            null,
4713            parentComponent,
4714            parentSuspense,
4715            getContainerType(container),
4716            optimized
4717          );
4718          if (isAsyncWrapper(vnode) && !vnode.type.__asyncResolved) {
4719            let subTree;
4720            if (isFragmentStart) {
4721              subTree = createVNode(Fragment);
4722              subTree.anchor = nextNode ? nextNode.previousSibling : container.lastChild;
4723            } else {
4724              subTree = node.nodeType === 3 ? createTextVNode("") : createVNode("div");
4725            }
4726            subTree.el = node;
4727            vnode.component.subTree = subTree;
4728          }
4729        } else if (shapeFlag & 64) {
4730          if (domType !== 8) {
4731            nextNode = onMismatch();
4732          } else {
4733            nextNode = vnode.type.hydrate(
4734              node,
4735              vnode,
4736              parentComponent,
4737              parentSuspense,
4738              slotScopeIds,
4739              optimized,
4740              rendererInternals,
4741              hydrateChildren
4742            );
4743          }
4744        } else if (shapeFlag & 128) {
4745          nextNode = vnode.type.hydrate(
4746            node,
4747            vnode,
4748            parentComponent,
4749            parentSuspense,
4750            getContainerType(parentNode(node)),
4751            slotScopeIds,
4752            optimized,
4753            rendererInternals,
4754            hydrateNode
4755          );
4756        } else if ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) {
4757          warn$1("Invalid HostVNode type:", type, `(${typeof type})`);
4758        }
4759    }
4760    if (ref != null) {
4761      setRef(ref, null, parentSuspense, vnode);
4762    }
4763    return nextNode;
4764  };
4765  const hydrateElement = (el, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {
4766    optimized = optimized || !!vnode.dynamicChildren;
4767    const { type, props, patchFlag, shapeFlag, dirs, transition } = vnode;
4768    const forcePatch = type === "input" || type === "option";
4769    if ( false || forcePatch || patchFlag !== -1) {
4770      if (dirs) {
4771        invokeDirectiveHook(vnode, null, parentComponent, "created");
4772      }
4773      let needCallTransitionHooks = false;
4774      if (isTemplateNode(el)) {
4775        needCallTransitionHooks = needTransition(
4776          null,
4777          // no need check parentSuspense in hydration
4778          transition
4779        ) && parentComponent && parentComponent.vnode.props && parentComponent.vnode.props.appear;
4780        const content = el.content.firstChild;
4781        if (needCallTransitionHooks) {
4782          const cls = content.getAttribute("class");
4783          if (cls) content.$cls = cls;
4784          transition.beforeEnter(content);
4785        }
4786        replaceNode(content, el, parentComponent);
4787        vnode.el = el = content;
4788      }
4789      if (shapeFlag & 16 && // skip if element has innerHTML / textContent
4790      !(props && (props.innerHTML || props.textContent))) {
4791        let next = hydrateChildren(
4792          el.firstChild,
4793          vnode,
4794          el,
4795          parentComponent,
4796          parentSuspense,
4797          slotScopeIds,
4798          optimized
4799        );
4800        let hasWarned = false;
4801        while (next) {
4802          if (!isMismatchAllowed(el, 1 /* CHILDREN */)) {
4803            if (( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && !hasWarned) {
4804              warn$1(
4805                `Hydration children mismatch on`,
4806                el,
4807                `
4808Server rendered element contains more child nodes than client vdom.`
4809              );
4810              hasWarned = true;
4811            }
4812            logMismatchError();
4813          }
4814          const cur = next;
4815          next = next.nextSibling;
4816          remove(cur);
4817        }
4818      } else if (shapeFlag & 8) {
4819        let clientText = vnode.children;
4820        if (clientText[0] === "\n" && (el.tagName === "PRE" || el.tagName === "TEXTAREA")) {
4821          clientText = clientText.slice(1);
4822        }
4823        const { textContent } = el;
4824        if (textContent !== clientText && // innerHTML normalize \r\n or \r into a single \n in the DOM
4825        textContent !== clientText.replace(/\r\n|\r/g, "\n")) {
4826          if (!isMismatchAllowed(el, 0 /* TEXT */)) {
4827            ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(
4828              `Hydration text content mismatch on`,
4829              el,
4830              `
4831  - rendered on server: ${textContent}
4832  - expected on client: ${clientText}`
4833            );
4834            logMismatchError();
4835          }
4836          el.textContent = vnode.children;
4837        }
4838      }
4839      if (props) {
4840        if ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__ || forcePatch || !optimized || patchFlag & (16 | 32)) {
4841          const isCustomElement = el.tagName.includes("-");
4842          for (const key in props) {
4843            if (( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && // #11189 skip if this node has directives that have created hooks
4844            // as it could have mutated the DOM in any possible way
4845            !(dirs && dirs.some((d) => d.dir.created)) && propHasMismatch(el, key, props[key], vnode, parentComponent)) {
4846              logMismatchError();
4847            }
4848            if (forcePatch && (key.endsWith("value") || key === "indeterminate") || isOn(key) && !isReservedProp(key) || // force hydrate v-bind with .prop modifiers
4849            key[0] === "." || isCustomElement) {
4850              patchProp(el, key, null, props[key], void 0, parentComponent);
4851            }
4852          }
4853        } else if (props.onClick) {
4854          patchProp(
4855            el,
4856            "onClick",
4857            null,
4858            props.onClick,
4859            void 0,
4860            parentComponent
4861          );
4862        } else if (patchFlag & 4 && isReactive(props.style)) {
4863          for (const key in props.style) props.style[key];
4864        }
4865      }
4866      let vnodeHooks;
4867      if (vnodeHooks = props && props.onVnodeBeforeMount) {
4868        invokeVNodeHook(vnodeHooks, parentComponent, vnode);
4869      }
4870      if (dirs) {
4871        invokeDirectiveHook(vnode, null, parentComponent, "beforeMount");
4872      }
4873      if ((vnodeHooks = props && props.onVnodeMounted) || dirs || needCallTransitionHooks) {
4874        queueEffectWithSuspense(() => {
4875          vnodeHooks && invokeVNodeHook(vnodeHooks, parentComponent, vnode);
4876          needCallTransitionHooks && transition.enter(el);
4877          dirs && invokeDirectiveHook(vnode, null, parentComponent, "mounted");
4878        }, parentSuspense);
4879      }
4880    }
4881    return el.nextSibling;
4882  };
4883  const hydrateChildren = (node, parentVNode, container, parentComponent, parentSuspense, slotScopeIds, optimized) => {
4884    optimized = optimized || !!parentVNode.dynamicChildren;
4885    const children = parentVNode.children;
4886    const l = children.length;
4887    let hasWarned = false;
vendor: 5,887 bytes, lines 4888-5085
4888    for (let i = 0; i < l; i++) {
4889      const vnode = optimized ? children[i] : children[i] = normalizeVNode(children[i]);
4890      const isText = vnode.type === Text;
4891      if (node) {
4892        if (isText && !optimized) {
4893          if (i + 1 < l && normalizeVNode(children[i + 1]).type === Text) {
4894            insert(
4895              createText(
4896                node.data.slice(vnode.children.length)
4897              ),
4898              container,
4899              nextSibling(node)
4900            );
4901            node.data = vnode.children;
4902          }
4903        }
4904        node = hydrateNode(
4905          node,
4906          vnode,
4907          parentComponent,
4908          parentSuspense,
4909          slotScopeIds,
4910          optimized
4911        );
4912      } else if (isText && !vnode.children) {
4913        insert(vnode.el = createText(""), container);
4914      } else {
4915        if (!isMismatchAllowed(container, 1 /* CHILDREN */)) {
4916          if (( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && !hasWarned) {
4917            warn$1(
4918              `Hydration children mismatch on`,
4919              container,
4920              `
4921Server rendered element contains fewer child nodes than client vdom.`
4922            );
4923            hasWarned = true;
4924          }
4925          logMismatchError();
4926        }
4927        patch(
4928          null,
4929          vnode,
4930          container,
4931          null,
4932          parentComponent,
4933          parentSuspense,
4934          getContainerType(container),
4935          slotScopeIds
4936        );
4937      }
4938    }
4939    return node;
4940  };
4941  const hydrateFragment = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {
4942    const { slotScopeIds: fragmentSlotScopeIds } = vnode;
4943    if (fragmentSlotScopeIds) {
4944      slotScopeIds = slotScopeIds ? slotScopeIds.concat(fragmentSlotScopeIds) : fragmentSlotScopeIds;
4945    }
4946    const container = parentNode(node);
4947    const next = hydrateChildren(
4948      nextSibling(node),
4949      vnode,
4950      container,
4951      parentComponent,
4952      parentSuspense,
4953      slotScopeIds,
4954      optimized
4955    );
4956    if (next && isComment(next) && next.data === "]") {
4957      return nextSibling(vnode.anchor = next);
4958    } else {
4959      logMismatchError();
4960      insert(vnode.anchor = createComment(`]`), container, next);
4961      return next;
4962    }
4963  };
4964  const handleMismatch = (node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragment) => {
4965    if (!isMismatchAllowed(node.parentElement, 1 /* CHILDREN */)) {
4966      ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(
4967        `Hydration node mismatch:
4968- rendered on server:`,
4969        node,
4970        node.nodeType === 3 ? `(text)` : isComment(node) && node.data === "[" ? `(start of fragment)` : ``,
4971        `
4972- expected on client:`,
4973        vnode.type
4974      );
4975      logMismatchError();
4976    }
4977    vnode.el = null;
4978    if (isFragment) {
4979      const end = locateClosingAnchor(node);
4980      while (true) {
4981        const next2 = nextSibling(node);
4982        if (next2 && next2 !== end) {
4983          remove(next2);
4984        } else {
4985          break;
4986        }
4987      }
4988    }
4989    const next = nextSibling(node);
4990    const container = parentNode(node);
4991    remove(node);
4992    patch(
4993      null,
4994      vnode,
4995      container,
4996      next,
4997      parentComponent,
4998      parentSuspense,
4999      getContainerType(container),
5000      slotScopeIds
5001    );
5002    if (parentComponent) {
5003      parentComponent.vnode.el = vnode.el;
5004      updateHOCHostEl(parentComponent, vnode.el);
5005    }
5006    return next;
5007  };
5008  const locateClosingAnchor = (node, open = "[", close = "]") => {
5009    let match = 0;
5010    while (node) {
5011      node = nextSibling(node);
5012      if (node && isComment(node)) {
5013        if (node.data === open) match++;
5014        if (node.data === close) {
5015          if (match === 0) {
5016            return nextSibling(node);
5017          } else {
5018            match--;
5019          }
5020        }
5021      }
5022    }
5023    return node;
5024  };
5025  const replaceNode = (newNode, oldNode, parentComponent) => {
5026    const parentNode2 = oldNode.parentNode;
5027    if (parentNode2) {
5028      parentNode2.replaceChild(newNode, oldNode);
5029    }
5030    let parent = parentComponent;
5031    while (parent) {
5032      if (parent.vnode.el === oldNode) {
5033        parent.vnode.el = parent.subTree.el = newNode;
5034      }
5035      parent = parent.parent;
5036    }
5037  };
5038  const isTemplateNode = (node) => {
5039    return node.nodeType === 1 && node.tagName === "TEMPLATE";
5040  };
5041  return [hydrate, hydrateNode];
5042}
5043function propHasMismatch(el, key, clientValue, vnode, instance) {
5044  let mismatchType;
5045  let mismatchKey;
5046  let actual;
5047  let expected;
5048  if (key === "class") {
5049    if (el.$cls) {
5050      actual = el.$cls;
5051      delete el.$cls;
5052    } else {
5053      actual = el.getAttribute("class");
5054    }
5055    expected = normalizeClass(clientValue);
5056    if (!isSetEqual(toClassSet(actual || ""), toClassSet(expected))) {
5057      mismatchType = 2 /* CLASS */;
5058      mismatchKey = `class`;
5059    }
5060  } else if (key === "style") {
5061    actual = el.getAttribute("style") || "";
5062    expected = shared_esm_bundler_isString(clientValue) ? clientValue : stringifyStyle(normalizeStyle(clientValue));
5063    const actualMap = toStyleMap(actual);
5064    const expectedMap = toStyleMap(expected);
5065    if (vnode.dirs) {
5066      for (const { dir, value } of vnode.dirs) {
5067        if (dir.name === "show" && !value) {
5068          expectedMap.set("display", "none");
5069        }
5070      }
5071    }
5072    if (instance) {
5073      resolveCssVars(instance, vnode, expectedMap);
5074    }
5075    if (!isMapEqual(actualMap, expectedMap)) {
5076      mismatchType = 3 /* STYLE */;
5077      mismatchKey = "style";
5078    }
5079  } else if (el instanceof SVGElement && isKnownSvgAttr(key) || el instanceof HTMLElement && (isBooleanAttr(key) || isKnownHtmlAttr(key))) {
5080    if (isBooleanAttr(key)) {
5081      actual = el.hasAttribute(key);
5082      expected = includeBooleanAttr(clientValue);
5083    } else if (clientValue == null) {
5084      actual = el.hasAttribute(key);
5085      expected = false;
vendor: 8,992 bytes, lines 5086-5400
5086    } else {
5087      if (el.hasAttribute(key)) {
5088        actual = el.getAttribute(key);
5089      } else if (key === "value" && el.tagName === "TEXTAREA") {
5090        actual = el.value;
5091      } else {
5092        actual = false;
5093      }
5094      expected = isRenderableAttrValue(clientValue) ? String(clientValue) : false;
5095    }
5096    if (actual !== expected) {
5097      mismatchType = 4 /* ATTRIBUTE */;
5098      mismatchKey = key;
5099    }
5100  }
5101  if (mismatchType != null && !isMismatchAllowed(el, mismatchType)) {
5102    const format = (v) => v === false ? `(not rendered)` : `${mismatchKey}="${v}"`;
5103    const preSegment = `Hydration ${MismatchTypeString[mismatchType]} mismatch on`;
5104    const postSegment = `
5105  - rendered on server: ${format(actual)}
5106  - expected on client: ${format(expected)}
5107  Note: this mismatch is check-only. The DOM will not be rectified in production due to performance overhead.
5108  You should fix the source of the mismatch.`;
5109    {
5110      warn$1(preSegment, el, postSegment);
5111    }
5112    return true;
5113  }
5114  return false;
5115}
5116function toClassSet(str) {
5117  return new Set(str.trim().split(/\s+/));
5118}
5119function isSetEqual(a, b) {
5120  if (a.size !== b.size) {
5121    return false;
5122  }
5123  for (const s of a) {
5124    if (!b.has(s)) {
5125      return false;
5126    }
5127  }
5128  return true;
5129}
5130function toStyleMap(str) {
5131  const styleMap = /* @__PURE__ */ new Map();
5132  for (const item of str.split(";")) {
5133    let [key, value] = item.split(":");
5134    key = key.trim();
5135    value = value && value.trim();
5136    if (key && value) {
5137      styleMap.set(key, value);
5138    }
5139  }
5140  return styleMap;
5141}
5142function isMapEqual(a, b) {
5143  if (a.size !== b.size) {
5144    return false;
5145  }
5146  for (const [key, value] of a) {
5147    if (value !== b.get(key)) {
5148      return false;
5149    }
5150  }
5151  return true;
5152}
5153function resolveCssVars(instance, vnode, expectedMap) {
5154  const root = instance.subTree;
5155  if (instance.getCssVars && (vnode === root || root && root.type === Fragment && root.children.includes(vnode))) {
5156    const cssVars = instance.getCssVars();
5157    for (const key in cssVars) {
5158      const value = normalizeCssVarValue(cssVars[key]);
5159      expectedMap.set(`--${getEscapedCssVarName(key, false)}`, value);
5160    }
5161  }
5162  if (vnode === root && instance.parent) {
5163    resolveCssVars(instance.parent, instance.vnode, expectedMap);
5164  }
5165}
5166const allowMismatchAttr = "data-allow-mismatch";
5167const MismatchTypeString = {
5168  [0 /* TEXT */]: "text",
5169  [1 /* CHILDREN */]: "children",
5170  [2 /* CLASS */]: "class",
5171  [3 /* STYLE */]: "style",
5172  [4 /* ATTRIBUTE */]: "attribute"
5173};
5174function isMismatchAllowed(el, allowedType) {
5175  if (allowedType === 0 /* TEXT */ || allowedType === 1 /* CHILDREN */) {
5176    while (el && !el.hasAttribute(allowMismatchAttr)) {
5177      el = el.parentElement;
5178    }
5179  }
5180  const allowedAttr = el && el.getAttribute(allowMismatchAttr);
5181  if (allowedAttr == null) {
5182    return false;
5183  } else if (allowedAttr === "") {
5184    return true;
5185  } else {
5186    const list = allowedAttr.split(",");
5187    if (allowedType === 0 /* TEXT */ && list.includes("children")) {
5188      return true;
5189    }
5190    return list.includes(MismatchTypeString[allowedType]);
5191  }
5192}
5193
5194const requestIdleCallback = getGlobalThis().requestIdleCallback || ((cb) => setTimeout(cb, 1));
5195const cancelIdleCallback = getGlobalThis().cancelIdleCallback || ((id) => clearTimeout(id));
5196const hydrateOnIdle = (timeout = 1e4) => (hydrate) => {
5197  const id = requestIdleCallback(hydrate, { timeout });
5198  return () => cancelIdleCallback(id);
5199};
5200function elementIsVisibleInViewport(el) {
5201  const { top, left, bottom, right } = el.getBoundingClientRect();
5202  const { innerHeight, innerWidth } = window;
5203  return (top > 0 && top < innerHeight || bottom > 0 && bottom < innerHeight) && (left > 0 && left < innerWidth || right > 0 && right < innerWidth);
5204}
5205const hydrateOnVisible = (opts) => (hydrate, forEach) => {
5206  const ob = new IntersectionObserver((entries) => {
5207    for (const e of entries) {
5208      if (!e.isIntersecting) continue;
5209      ob.disconnect();
5210      hydrate();
5211      break;
5212    }
5213  }, opts);
5214  forEach((el) => {
5215    if (!(el instanceof Element)) return;
5216    if (elementIsVisibleInViewport(el)) {
5217      hydrate();
5218      ob.disconnect();
5219      return false;
5220    }
5221    ob.observe(el);
5222  });
5223  return () => ob.disconnect();
5224};
5225const hydrateOnMediaQuery = (query) => (hydrate) => {
5226  if (query) {
5227    const mql = matchMedia(query);
5228    if (mql.matches) {
5229      hydrate();
5230    } else {
5231      mql.addEventListener("change", hydrate, { once: true });
5232      return () => mql.removeEventListener("change", hydrate);
5233    }
5234  }
5235};
5236const hydrateOnInteraction = (interactions = []) => (hydrate, forEach) => {
5237  if (shared_esm_bundler_isString(interactions)) interactions = [interactions];
5238  let hasHydrated = false;
5239  const doHydrate = (e) => {
5240    if (!hasHydrated) {
5241      hasHydrated = true;
5242      teardown();
5243      hydrate();
5244      e.target.dispatchEvent(new e.constructor(e.type, e));
5245    }
5246  };
5247  const teardown = () => {
5248    forEach((el) => {
5249      for (const i of interactions) {
5250        el.removeEventListener(i, doHydrate);
5251      }
5252    });
5253  };
5254  forEach((el) => {
5255    for (const i of interactions) {
5256      el.addEventListener(i, doHydrate, { once: true });
5257    }
5258  });
5259  return teardown;
5260};
5261function forEachElement(node, cb) {
5262  if (isComment(node) && node.data === "[") {
5263    let depth = 1;
5264    let next = node.nextSibling;
5265    while (next) {
5266      if (next.nodeType === 1) {
5267        const result = cb(next);
5268        if (result === false) {
5269          break;
5270        }
5271      } else if (isComment(next)) {
5272        if (next.data === "]") {
5273          if (--depth === 0) break;
5274        } else if (next.data === "[") {
5275          depth++;
5276        }
5277      }
5278      next = next.nextSibling;
5279    }
5280  } else {
5281    cb(node);
5282  }
5283}
5284
5285const isAsyncWrapper = (i) => !!i.type.__asyncLoader;
5286// @__NO_SIDE_EFFECTS__
5287function defineAsyncComponent(source) {
5288  if (shared_esm_bundler_isFunction(source)) {
5289    source = { loader: source };
5290  }
5291  const {
5292    loader,
5293    loadingComponent,
5294    errorComponent,
5295    delay = 200,
5296    hydrate: hydrateStrategy,
5297    timeout,
5298    // undefined = never times out
5299    suspensible = true,
5300    onError: userOnError
5301  } = source;
5302  let pendingRequest = null;
5303  let resolvedComp;
5304  let retries = 0;
5305  const retry = () => {
5306    retries++;
5307    pendingRequest = null;
5308    return load();
5309  };
5310  const load = () => {
5311    let thisRequest;
5312    return pendingRequest || (thisRequest = pendingRequest = loader().catch((err) => {
5313      err = err instanceof Error ? err : new Error(String(err));
5314      if (userOnError) {
5315        return new Promise((resolve, reject) => {
5316          const userRetry = () => resolve(retry());
5317          const userFail = () => reject(err);
5318          userOnError(err, userRetry, userFail, retries + 1);
5319        });
5320      } else {
5321        throw err;
5322      }
5323    }).then((comp) => {
5324      if (thisRequest !== pendingRequest && pendingRequest) {
5325        return pendingRequest;
5326      }
5327      if (false) // removed by dead control flow
5328{}
5329      if (comp && (comp.__esModule || comp[Symbol.toStringTag] === "Module")) {
5330        comp = comp.default;
5331      }
5332      if (false) // removed by dead control flow
5333{}
5334      resolvedComp = comp;
5335      return comp;
5336    }));
5337  };
5338  return defineComponent({
5339    name: "AsyncComponentWrapper",
5340    __asyncLoader: load,
5341    __asyncHydrate(el, instance, hydrate) {
5342      let patched = false;
5343      (instance.bu || (instance.bu = [])).push(() => patched = true);
5344      const performHydrate = () => {
5345        if (patched) {
5346          if (false) // removed by dead control flow
5347{}
5348          return;
5349        }
5350        hydrate();
5351      };
5352      const doHydrate = hydrateStrategy ? () => {
5353        const teardown = hydrateStrategy(
5354          performHydrate,
5355          (cb) => forEachElement(el, cb)
5356        );
5357        if (teardown) {
5358          (instance.bum || (instance.bum = [])).push(teardown);
5359        }
5360      } : performHydrate;
5361      if (resolvedComp) {
5362        doHydrate();
5363      } else {
5364        load().then(() => !instance.isUnmounted && doHydrate());
5365      }
5366    },
5367    get __asyncResolved() {
5368      return resolvedComp;
5369    },
5370    setup() {
5371      const instance = currentInstance;
5372      markAsyncBoundary(instance);
5373      if (resolvedComp) {
5374        return () => createInnerComp(resolvedComp, instance);
5375      }
5376      const onError = (err) => {
5377        pendingRequest = null;
5378        handleError(
5379          err,
5380          instance,
5381          13,
5382          !errorComponent
5383        );
5384      };
5385      if (suspensible && instance.suspense || isInSSRComponentSetup) {
5386        return load().then((comp) => {
5387          return () => createInnerComp(comp, instance);
5388        }).catch((err) => {
5389          onError(err);
5390          return () => errorComponent ? createVNode(errorComponent, {
5391            error: err
5392          }) : null;
5393        });
5394      }
5395      const loaded = ref(false);
5396      const error = ref();
5397      const delayed = ref(!!delay);
5398      if (delay) {
5399        setTimeout(() => {
5400          delayed.value = false;
vendor: 4,418 bytes, lines 5401-5547
5401        }, delay);
5402      }
5403      if (timeout != null) {
5404        setTimeout(() => {
5405          if (!loaded.value && !error.value) {
5406            const err = new Error(
5407              `Async component timed out after ${timeout}ms.`
5408            );
5409            onError(err);
5410            error.value = err;
5411          }
5412        }, timeout);
5413      }
5414      load().then(() => {
5415        loaded.value = true;
5416        if (instance.parent && isKeepAlive(instance.parent.vnode)) {
5417          instance.parent.update();
5418        }
5419      }).catch((err) => {
5420        onError(err);
5421        error.value = err;
5422      });
5423      return () => {
5424        if (loaded.value && resolvedComp) {
5425          return createInnerComp(resolvedComp, instance);
5426        } else if (error.value && errorComponent) {
5427          return createVNode(errorComponent, {
5428            error: error.value
5429          });
5430        } else if (loadingComponent && !delayed.value) {
5431          return createInnerComp(
5432            loadingComponent,
5433            instance
5434          );
5435        }
5436      };
5437    }
5438  });
5439}
5440function createInnerComp(comp, parent) {
5441  const { ref: ref2, props, children, ce } = parent.vnode;
5442  const vnode = createVNode(comp, props, children);
5443  vnode.ref = ref2;
5444  vnode.ce = ce;
5445  delete parent.vnode.ce;
5446  return vnode;
5447}
5448
5449const isKeepAlive = (vnode) => vnode.type.__isKeepAlive;
5450const KeepAliveImpl = {
5451  name: `KeepAlive`,
5452  // Marker for special handling inside the renderer. We are not using a ===
5453  // check directly on KeepAlive in the renderer, because importing it directly
5454  // would prevent it from being tree-shaken.
5455  __isKeepAlive: true,
5456  props: {
5457    include: [String, RegExp, Array],
5458    exclude: [String, RegExp, Array],
5459    max: [String, Number]
5460  },
5461  setup(props, { slots }) {
5462    const instance = getCurrentInstance();
5463    const sharedContext = instance.ctx;
5464    if (!sharedContext.renderer) {
5465      return () => {
5466        const children = slots.default && slots.default();
5467        return children && children.length === 1 ? children[0] : children;
5468      };
5469    }
5470    const cache = /* @__PURE__ */ new Map();
5471    const keys = /* @__PURE__ */ new Set();
5472    let current = null;
5473    if ( false || __VUE_PROD_DEVTOOLS__) {
5474      instance.__v_cache = cache;
5475    }
5476    const parentSuspense = instance.suspense;
5477    const {
5478      renderer: {
5479        p: patch,
5480        m: move,
5481        um: _unmount,
5482        o: { createElement }
5483      }
5484    } = sharedContext;
5485    const storageContainer = createElement("div");
5486    sharedContext.activate = (vnode, container, anchor, namespace, optimized) => {
5487      const instance2 = vnode.component;
5488      move(vnode, container, anchor, 0, parentSuspense);
5489      patch(
5490        instance2.vnode,
5491        vnode,
5492        container,
5493        anchor,
5494        instance2,
5495        parentSuspense,
5496        namespace,
5497        vnode.slotScopeIds,
5498        optimized
5499      );
5500      queuePostRenderEffect(() => {
5501        instance2.isDeactivated = false;
5502        if (instance2.a) {
5503          invokeArrayFns(instance2.a);
5504        }
5505        const vnodeHook = vnode.props && vnode.props.onVnodeMounted;
5506        if (vnodeHook) {
5507          invokeVNodeHook(vnodeHook, instance2.parent, vnode);
5508        }
5509      }, parentSuspense);
5510      if ( false || __VUE_PROD_DEVTOOLS__) {
5511        devtoolsComponentAdded(instance2);
5512      }
5513    };
5514    sharedContext.deactivate = (vnode) => {
5515      const instance2 = vnode.component;
5516      invalidateMount(instance2.m);
5517      invalidateMount(instance2.a);
5518      move(vnode, storageContainer, null, 1, parentSuspense);
5519      queuePostRenderEffect(() => {
5520        if (instance2.da) {
5521          invokeArrayFns(instance2.da);
5522        }
5523        const vnodeHook = vnode.props && vnode.props.onVnodeUnmounted;
5524        if (vnodeHook) {
5525          invokeVNodeHook(vnodeHook, instance2.parent, vnode);
5526        }
5527        instance2.isDeactivated = true;
5528      }, parentSuspense);
5529      if ( false || __VUE_PROD_DEVTOOLS__) {
5530        devtoolsComponentAdded(instance2);
5531      }
5532      if (false) // removed by dead control flow
5533{}
5534    };
5535    function unmount(vnode) {
5536      resetShapeFlag(vnode);
5537      _unmount(vnode, instance, parentSuspense, true);
5538    }
5539    function pruneCache(filter) {
5540      cache.forEach((vnode, key) => {
5541        const name = getComponentName(vnode.type);
5542        if (name && !filter(name)) {
5543          pruneCacheEntry(key);
5544        }
5545      });
5546    }
5547    function pruneCacheEntry(key) {
vendor: 4,049 bytes, lines 5548-5673
5548      const cached = cache.get(key);
5549      if (cached && (!current || !isSameVNodeType(cached, current))) {
5550        unmount(cached);
5551      } else if (current) {
5552        resetShapeFlag(current);
5553      }
5554      cache.delete(key);
5555      keys.delete(key);
5556    }
5557    runtime_core_esm_bundler_watch(
5558      () => [props.include, props.exclude],
5559      ([include, exclude]) => {
5560        include && pruneCache((name) => matches(include, name));
5561        exclude && pruneCache((name) => !matches(exclude, name));
5562      },
5563      // prune post-render after `current` has been updated
5564      { flush: "post", deep: true }
5565    );
5566    let pendingCacheKey = null;
5567    const cacheSubtree = () => {
5568      if (pendingCacheKey != null) {
5569        if (isSuspense(instance.subTree.type)) {
5570          queuePostRenderEffect(() => {
5571            cache.set(pendingCacheKey, getInnerChild(instance.subTree));
5572          }, instance.subTree.suspense);
5573        } else {
5574          cache.set(pendingCacheKey, getInnerChild(instance.subTree));
5575        }
5576      }
5577    };
5578    onMounted(cacheSubtree);
5579    onUpdated(cacheSubtree);
5580    onBeforeUnmount(() => {
5581      cache.forEach((cached) => {
5582        const { subTree, suspense } = instance;
5583        const vnode = getInnerChild(subTree);
5584        if (cached.type === vnode.type && cached.key === vnode.key) {
5585          resetShapeFlag(vnode);
5586          const da = vnode.component.da;
5587          da && queuePostRenderEffect(da, suspense);
5588          return;
5589        }
5590        unmount(cached);
5591      });
5592    });
5593    return () => {
5594      pendingCacheKey = null;
5595      if (!slots.default) {
5596        return current = null;
5597      }
5598      const children = slots.default();
5599      const rawVNode = children[0];
5600      if (children.length > 1) {
5601        if (false) // removed by dead control flow
5602{}
5603        current = null;
5604        return children;
5605      } else if (!isVNode(rawVNode) || !(rawVNode.shapeFlag & 4) && !(rawVNode.shapeFlag & 128)) {
5606        current = null;
5607        return rawVNode;
5608      }
5609      let vnode = getInnerChild(rawVNode);
5610      if (vnode.type === Comment) {
5611        current = null;
5612        return vnode;
5613      }
5614      const comp = vnode.type;
5615      const name = getComponentName(
5616        isAsyncWrapper(vnode) ? vnode.type.__asyncResolved || {} : comp
5617      );
5618      const { include, exclude, max } = props;
5619      if (include && (!name || !matches(include, name)) || exclude && name && matches(exclude, name)) {
5620        vnode.shapeFlag &= -257;
5621        current = vnode;
5622        return rawVNode;
5623      }
5624      const key = vnode.key == null ? comp : vnode.key;
5625      const cachedVNode = cache.get(key);
5626      if (vnode.el) {
5627        vnode = cloneVNode(vnode);
5628        if (rawVNode.shapeFlag & 128) {
5629          rawVNode.ssContent = vnode;
5630        }
5631      }
5632      pendingCacheKey = key;
5633      if (cachedVNode) {
5634        vnode.el = cachedVNode.el;
5635        vnode.component = cachedVNode.component;
5636        if (vnode.transition) {
5637          setTransitionHooks(vnode, vnode.transition);
5638        }
5639        vnode.shapeFlag |= 512;
5640        keys.delete(key);
5641        keys.add(key);
5642      } else {
5643        keys.add(key);
5644        if (max && keys.size > parseInt(max, 10)) {
5645          pruneCacheEntry(keys.values().next().value);
5646        }
5647      }
5648      vnode.shapeFlag |= 256;
5649      current = vnode;
5650      return isSuspense(rawVNode.type) ? rawVNode : vnode;
5651    };
5652  }
5653};
5654const KeepAlive = KeepAliveImpl;
5655function matches(pattern, name) {
5656  if (shared_esm_bundler_isArray(pattern)) {
5657    return pattern.some((p) => matches(p, name));
5658  } else if (shared_esm_bundler_isString(pattern)) {
5659    return pattern.split(",").includes(name);
5660  } else if (isRegExp(pattern)) {
5661    pattern.lastIndex = 0;
5662    return pattern.test(name);
5663  }
5664  return false;
5665}
5666function onActivated(hook, target) {
5667  registerKeepAliveHook(hook, "a", target);
5668}
5669function onDeactivated(hook, target) {
5670  registerKeepAliveHook(hook, "da", target);
5671}
5672function registerKeepAliveHook(hook, type, target = currentInstance) {
5673  const wrappedHook = hook.__wdc || (hook.__wdc = () => {
vendor: 4,229 bytes, lines 5674-5812
5674    let current = target;
5675    while (current) {
5676      if (current.isDeactivated) {
5677        return;
5678      }
5679      current = current.parent;
5680    }
5681    return hook();
5682  });
5683  injectHook(type, wrappedHook, target);
5684  if (target) {
5685    let current = target.parent;
5686    while (current && current.parent) {
5687      if (isKeepAlive(current.parent.vnode)) {
5688        injectToKeepAliveRoot(wrappedHook, type, target, current);
5689      }
5690      current = current.parent;
5691    }
5692  }
5693}
5694function injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {
5695  const injected = injectHook(
5696    type,
5697    hook,
5698    keepAliveRoot,
5699    true
5700    /* prepend */
5701  );
5702  onUnmounted(() => {
5703    remove(keepAliveRoot[type], injected);
5704  }, target);
5705}
5706function resetShapeFlag(vnode) {
5707  vnode.shapeFlag &= -257;
5708  vnode.shapeFlag &= -513;
5709}
5710function getInnerChild(vnode) {
5711  return vnode.shapeFlag & 128 ? vnode.ssContent : vnode;
5712}
5713
5714function injectHook(type, hook, target = currentInstance, prepend = false) {
5715  if (target) {
5716    const hooks = target[type] || (target[type] = []);
5717    const wrappedHook = hook.__weh || (hook.__weh = (...args) => {
5718      pauseTracking();
5719      const reset = setCurrentInstance(target);
5720      const res = callWithAsyncErrorHandling(hook, target, type, args);
5721      reset();
5722      resetTracking();
5723      return res;
5724    });
5725    if (prepend) {
5726      hooks.unshift(wrappedHook);
5727    } else {
5728      hooks.push(wrappedHook);
5729    }
5730    return wrappedHook;
5731  } else if (false) // removed by dead control flow
5732{}
5733}
5734const createHook = (lifecycle) => (hook, target = currentInstance) => {
5735  if (!isInSSRComponentSetup || lifecycle === "sp") {
5736    injectHook(lifecycle, (...args) => hook(...args), target);
5737  }
5738};
5739const onBeforeMount = createHook("bm");
5740const onMounted = createHook("m");
5741const onBeforeUpdate = createHook(
5742  "bu"
5743);
5744const onUpdated = createHook("u");
5745const onBeforeUnmount = createHook(
5746  "bum"
5747);
5748const onUnmounted = createHook("um");
5749const onServerPrefetch = createHook(
5750  "sp"
5751);
5752const onRenderTriggered = createHook("rtg");
5753const onRenderTracked = createHook("rtc");
5754function onErrorCaptured(hook, target = currentInstance) {
5755  injectHook("ec", hook, target);
5756}
5757
5758const COMPONENTS = "components";
5759const DIRECTIVES = "directives";
5760function resolveComponent(name, maybeSelfReference) {
5761  return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
5762}
5763const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
5764function resolveDynamicComponent(component) {
5765  if (shared_esm_bundler_isString(component)) {
5766    return resolveAsset(COMPONENTS, component, false) || component;
5767  } else {
5768    return component || NULL_DYNAMIC_COMPONENT;
5769  }
5770}
5771function resolveDirective(name) {
5772  return resolveAsset(DIRECTIVES, name);
5773}
5774function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
5775  const instance = currentRenderingInstance || currentInstance;
5776  if (instance) {
5777    const Component = instance.type;
5778    if (type === COMPONENTS) {
5779      const selfName = getComponentName(
5780        Component,
5781        false
5782      );
5783      if (selfName && (selfName === name || selfName === shared_esm_bundler_camelize(name) || selfName === shared_esm_bundler_capitalize(shared_esm_bundler_camelize(name)))) {
5784        return Component;
5785      }
5786    }
5787    const res = (
5788      // local registration
5789      // check instance[type] first which is resolved for options API
5790      resolve(instance[type] || Component[type], name) || // global registration
5791      resolve(instance.appContext[type], name)
5792    );
5793    if (!res && maybeSelfReference) {
5794      return Component;
5795    }
5796    if (false) // removed by dead control flow
5797{}
5798    return res;
5799  } else if (false) // removed by dead control flow
5800{}
5801}
5802function resolve(registry, name) {
5803  return registry && (registry[name] || registry[shared_esm_bundler_camelize(name)] || registry[shared_esm_bundler_capitalize(shared_esm_bundler_camelize(name))]);
5804}
5805
5806function renderList(source, renderItem, cache, index) {
5807  let ret;
5808  const cached = cache && cache[index];
5809  const sourceIsArray = shared_esm_bundler_isArray(source);
5810  if (sourceIsArray || shared_esm_bundler_isString(source)) {
5811    const sourceIsReactiveArray = sourceIsArray && isReactive(source);
5812    let needsWrap = false;
vendor: 1,762 bytes, lines 5813-5875
5813    let isReadonlySource = false;
5814    if (sourceIsReactiveArray) {
5815      needsWrap = !isShallow(source);
5816      isReadonlySource = isReadonly(source);
5817      source = shallowReadArray(source);
5818    }
5819    ret = new Array(source.length);
5820    for (let i = 0, l = source.length; i < l; i++) {
5821      ret[i] = renderItem(
5822        needsWrap ? isReadonlySource ? toReadonly(toReactive(source[i])) : toReactive(source[i]) : source[i],
5823        i,
5824        void 0,
5825        cached && cached[i]
5826      );
5827    }
5828  } else if (typeof source === "number") {
5829    if (false) // removed by dead control flow
5830{}
5831    ret = new Array(source);
5832    for (let i = 0; i < source; i++) {
5833      ret[i] = renderItem(i + 1, i, void 0, cached && cached[i]);
5834    }
5835  } else if (shared_esm_bundler_isObject(source)) {
5836    if (source[Symbol.iterator]) {
5837      ret = Array.from(
5838        source,
5839        (item, i) => renderItem(item, i, void 0, cached && cached[i])
5840      );
5841    } else {
5842      const keys = Object.keys(source);
5843      ret = new Array(keys.length);
5844      for (let i = 0, l = keys.length; i < l; i++) {
5845        const key = keys[i];
5846        ret[i] = renderItem(source[key], key, i, cached && cached[i]);
5847      }
5848    }
5849  } else {
5850    ret = [];
5851  }
5852  if (cache) {
5853    cache[index] = ret;
5854  }
5855  return ret;
5856}
5857
5858function createSlots(slots, dynamicSlots) {
5859  for (let i = 0; i < dynamicSlots.length; i++) {
5860    const slot = dynamicSlots[i];
5861    if (shared_esm_bundler_isArray(slot)) {
5862      for (let j = 0; j < slot.length; j++) {
5863        slots[slot[j].name] = slot[j].fn;
5864      }
5865    } else if (slot) {
5866      slots[slot.name] = slot.key ? (...args) => {
5867        const res = slot.fn(...args);
5868        if (res) res.key = slot.key;
5869        return res;
5870      } : slot.fn;
5871    }
5872  }
5873  return slots;
5874}
5875
5876function renderSlot(slots, name, props = {}, fallback, noSlotted) {
5877  if (currentRenderingInstance.ce || currentRenderingInstance.parent && isAsyncWrapper(currentRenderingInstance.parent) && currentRenderingInstance.parent.ce) {
5878    const hasProps = Object.keys(props).length > 0;
5879    if (name !== "default") props.name = name;
5880    return openBlock(), createBlock(
5881      Fragment,
5882      null,
5883      [createVNode("slot", props, fallback && fallback())],
5884      hasProps ? -2 : 64
5885    );
5886  }
5887  let slot = slots[name];
5888  if (false) // removed by dead control flow
5889{}
5890  if (slot && slot._c) {
5891    slot._d = false;
5892  }
5893  openBlock();
5894  const validSlotContent = slot && ensureValidVNode(slot(props));
5895  const slotKey = props.key || // slot content array of a dynamic conditional slot may have a branch
5896  // key attached in the `createSlots` helper, respect that
5897  validSlotContent && validSlotContent.key;
5898  const rendered = createBlock(
5899    Fragment,
5900    {
5901      key: (slotKey && !isSymbol(slotKey) ? slotKey : `_${name}`) + // #7256 force differentiate fallback content from actual content
5902      (!validSlotContent && fallback ? "_fb" : "")
5903    },
5904    validSlotContent || (fallback ? fallback() : []),
5905    validSlotContent && slots._ === 1 ? 64 : -2
5906  );
5907  if (!noSlotted && rendered.scopeId) {
5908    rendered.slotScopeIds = [rendered.scopeId + "-s"];
5909  }
5910  if (slot && slot._c) {
5911    slot._d = true;
5912  }
5913  return rendered;
5914}
5915function ensureValidVNode(vnodes) {
5916  return vnodes.some((child) => {
5917    if (!isVNode(child)) return true;
5918    if (child.type === Comment) return false;
5919    if (child.type === Fragment && !ensureValidVNode(child.children))
5920      return false;
5921    return true;
5922  }) ? vnodes : null;
5923}
5924
5925function toHandlers(obj, preserveCaseIfNecessary) {
5926  const ret = {};
5927  if (false) // removed by dead control flow
5928{}
5929  for (const key in obj) {
5930    ret[preserveCaseIfNecessary && /[A-Z]/.test(key) ? `on:${key}` : toHandlerKey(key)] = obj[key];
5931  }
5932  return ret;
5933}
5934
5935const getPublicInstance = (i) => {
5936  if (!i) return null;
5937  if (isStatefulComponent(i)) return getComponentPublicInstance(i);
5938  return getPublicInstance(i.parent);
5939};
5940const publicPropertiesMap = (
5941  // Move PURE marker to new line to workaround compiler discarding it
5942  // due to type annotation
5943  /* @__PURE__ */ shared_esm_bundler_extend(/* @__PURE__ */ Object.create(null), {
5944    $: (i) => i,
5945    $el: (i) => i.vnode.el,
5946    $data: (i) => i.data,
5947    $props: (i) =>  false ? 0 : i.props,
5948    $attrs: (i) =>  false ? 0 : i.attrs,
5949    $slots: (i) =>  false ? 0 : i.slots,
5950    $refs: (i) =>  false ? 0 : i.refs,
5951    $parent: (i) => getPublicInstance(i.parent),
5952    $root: (i) => getPublicInstance(i.root),
5953    $host: (i) => i.ce,
5954    $emit: (i) => i.emit,
5955    $options: (i) => __VUE_OPTIONS_API__ ? resolveMergedOptions(i) : i.type,
5956    $forceUpdate: (i) => i.f || (i.f = () => {
5957      queueJob(i.update);
5958    }),
5959    $nextTick: (i) => i.n || (i.n = nextTick.bind(i.proxy)),
5960    $watch: (i) => __VUE_OPTIONS_API__ ? instanceWatch.bind(i) : shared_esm_bundler_NOOP
5961  })
5962);
5963const isReservedPrefix = (key) => key === "_" || key === "$";
5964const hasSetupBinding = (state, key) => state !== EMPTY_OBJ && !state.__isScriptSetup && hasOwn(state, key);
5965const PublicInstanceProxyHandlers = {
5966  get({ _: instance }, key) {
5967    if (key === "__v_skip") {
5968      return true;
5969    }
5970    const { ctx, setupState, data, props, accessCache, type, appContext } = instance;
5971    if (false) // removed by dead control flow
5972{}
5973    if (key[0] !== "$") {
5974      const n = accessCache[key];
5975      if (n !== void 0) {
5976        switch (n) {
5977          case 1 /* SETUP */:
5978            return setupState[key];
5979          case 2 /* DATA */:
5980            return data[key];
5981          case 4 /* CONTEXT */:
5982            return ctx[key];
5983          case 3 /* PROPS */:
5984            return props[key];
5985        }
5986      } else if (hasSetupBinding(setupState, key)) {
5987        accessCache[key] = 1 /* SETUP */;
5988        return setupState[key];
5989      } else if (__VUE_OPTIONS_API__ && data !== EMPTY_OBJ && hasOwn(data, key)) {
5990        accessCache[key] = 2 /* DATA */;
5991        return data[key];
5992      } else if (hasOwn(props, key)) {
5993        accessCache[key] = 3 /* PROPS */;
5994        return props[key];
5995      } else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {
5996        accessCache[key] = 4 /* CONTEXT */;
5997        return ctx[key];
5998      } else if (!__VUE_OPTIONS_API__ || shouldCacheAccess) {
5999        accessCache[key] = 0 /* OTHER */;
6000      }
6001    }
6002    const publicGetter = publicPropertiesMap[key];
6003    let cssModule, globalProperties;
6004    if (publicGetter) {
6005      if (key === "$attrs") {
6006        reactivity_esm_bundler_track(instance.attrs, "get", "");
6007         false && 0;
6008      } else if (false) // removed by dead control flow
6009{}
6010      return publicGetter(instance);
6011    } else if (
6012      // css module (injected by vue-loader)
6013      (cssModule = type.__cssModules) && (cssModule = cssModule[key])
6014    ) {
6015      return cssModule;
6016    } else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {
6017      accessCache[key] = 4 /* CONTEXT */;
6018      return ctx[key];
6019    } else if (
6020      // global properties
6021      globalProperties = appContext.config.globalProperties, hasOwn(globalProperties, key)
6022    ) {
6023      {
6024        return globalProperties[key];
6025      }
6026    } else if (false) // removed by dead control flow
6027{}
6028  },
6029  set({ _: instance }, key, value) {
6030    const { data, setupState, ctx } = instance;
6031    if (hasSetupBinding(setupState, key)) {
6032      setupState[key] = value;
6033      return true;
6034    } else if (false) // removed by dead control flow
6035{} else if (__VUE_OPTIONS_API__ && data !== EMPTY_OBJ && hasOwn(data, key)) {
6036      data[key] = value;
6037      return true;
6038    } else if (hasOwn(instance.props, key)) {
6039       false && 0;
6040      return false;
6041    }
6042    if (key[0] === "$" && key.slice(1) in instance) {
6043       false && 0;
6044      return false;
6045    } else {
6046      if (false) // removed by dead control flow
6047{} else {
6048        ctx[key] = value;
6049      }
6050    }
6051    return true;
6052  },
6053  has({
6054    _: { data, setupState, accessCache, ctx, appContext, props, type }
6055  }, key) {
6056    let cssModules;
6057    return !!(accessCache[key] || __VUE_OPTIONS_API__ && data !== EMPTY_OBJ && key[0] !== "$" && hasOwn(data, key) || hasSetupBinding(setupState, key) || hasOwn(props, key) || hasOwn(ctx, key) || hasOwn(publicPropertiesMap, key) || hasOwn(appContext.config.globalProperties, key) || (cssModules = type.__cssModules) && cssModules[key]);
6058  },
6059  defineProperty(target, key, descriptor) {
6060    if (descriptor.get != null) {
6061      target._.accessCache[key] = 0;
6062    } else if (hasOwn(descriptor, "value")) {
6063      this.set(target, key, descriptor.value, null);
6064    }
6065    return Reflect.defineProperty(target, key, descriptor);
6066  }
6067};
6068if (false) // removed by dead control flow
6069{}
6070const RuntimeCompiledPublicInstanceProxyHandlers = /* @__PURE__ */ shared_esm_bundler_extend({}, PublicInstanceProxyHandlers, {
6071  get(target, key) {
6072    if (key === Symbol.unscopables) {
6073      return;
6074    }
6075    return PublicInstanceProxyHandlers.get(target, key, target);
6076  },
6077  has(_, key) {
6078    const has = key[0] !== "_" && !isGloballyAllowed(key);
6079    if (false) // removed by dead control flow
6080{}
6081    return has;
6082  }
6083});
6084function createDevRenderContext(instance) {
6085  const target = {};
6086  Object.defineProperty(target, `_`, {
6087    configurable: true,
6088    enumerable: false,
6089    get: () => instance
6090  });
6091  Object.keys(publicPropertiesMap).forEach((key) => {
6092    Object.defineProperty(target, key, {
6093      configurable: true,
6094      enumerable: false,
6095      get: () => publicPropertiesMap[key](instance),
6096      // intercepted by the proxy so no need for implementation,
6097      // but needed to prevent set errors
6098      set: NOOP
6099    });
6100  });
6101  return target;
6102}
6103function exposePropsOnRenderContext(instance) {
6104  const {
6105    ctx,
6106    propsOptions: [propsOptions]
6107  } = instance;
6108  if (propsOptions) {
6109    Object.keys(propsOptions).forEach((key) => {
6110      Object.defineProperty(ctx, key, {
6111        enumerable: true,
6112        configurable: true,
6113        get: () => instance.props[key],
6114        set: NOOP
6115      });
6116    });
6117  }
6118}
6119function exposeSetupStateOnRenderContext(instance) {
6120  const { ctx, setupState } = instance;
6121  Object.keys(toRaw(setupState)).forEach((key) => {
6122    if (!setupState.__isScriptSetup) {
6123      if (isReservedPrefix(key[0])) {
6124        warn$1(
6125          `setup() return property ${JSON.stringify(
6126            key
6127          )} should not start with "$" or "_" which are reserved prefixes for Vue internals.`
6128        );
6129        return;
6130      }
6131      Object.defineProperty(ctx, key, {
6132        enumerable: true,
6133        configurable: true,
6134        get: () => setupState[key],
6135        set: NOOP
6136      });
6137    }
6138  });
6139}
6140
6141const warnRuntimeUsage = (method) => warn$1(
6142  `${method}() is a compiler-hint helper that is only usable inside <script setup> of a single file component. Its arguments should be compiled away and passing it at runtime has no effect.`
6143);
6144function defineProps() {
6145  if (false) // removed by dead control flow
6146{}
6147  return null;
6148}
6149function defineEmits() {
6150  if (false) // removed by dead control flow
6151{}
6152  return null;
6153}
6154function defineExpose(exposed) {
6155  if (false) // removed by dead control flow
6156{}
6157}
6158function defineOptions(options) {
6159  if (false) // removed by dead control flow
6160{}
6161}
6162function defineSlots() {
6163  if (false) // removed by dead control flow
6164{}
6165  return null;
6166}
6167function defineModel() {
6168  if (false) // removed by dead control flow
6169{}
6170}
6171function withDefaults(props, defaults) {
6172  if (false) // removed by dead control flow
6173{}
6174  return null;
6175}
6176function useSlots() {
6177  return getContext("useSlots").slots;
6178}
6179function useAttrs() {
6180  return getContext("useAttrs").attrs;
6181}
6182function getContext(calledFunctionName) {
6183  const i = getCurrentInstance();
6184  if (false) // removed by dead control flow
6185{}
6186  return i.setupContext || (i.setupContext = createSetupContext(i));
6187}
6188function normalizePropsOrEmits(props) {
6189  return shared_esm_bundler_isArray(props) ? props.reduce(
6190    (normalized, p) => (normalized[p] = null, normalized),
6191    {}
6192  ) : props;
6193}
6194function mergeDefaults(raw, defaults) {
6195  const props = normalizePropsOrEmits(raw);
6196  for (const key in defaults) {
6197    if (key.startsWith("__skip")) continue;
6198    let opt = props[key];
6199    if (opt) {
6200      if (shared_esm_bundler_isArray(opt) || shared_esm_bundler_isFunction(opt)) {
6201        opt = props[key] = { type: opt, default: defaults[key] };
6202      } else {
6203        opt.default = defaults[key];
6204      }
6205    } else if (opt === null) {
6206      opt = props[key] = { default: defaults[key] };
6207    } else if (false) // removed by dead control flow
6208{}
6209    if (opt && defaults[`__skip_${key}`]) {
6210      opt.skipFactory = true;
6211    }
6212  }
6213  return props;
6214}
6215function mergeModels(a, b) {
6216  if (!a || !b) return a || b;
6217  if (shared_esm_bundler_isArray(a) && shared_esm_bundler_isArray(b)) return a.concat(b);
6218  return shared_esm_bundler_extend({}, normalizePropsOrEmits(a), normalizePropsOrEmits(b));
6219}
6220function createPropsRestProxy(props, excludedKeys) {
6221  const ret = {};
6222  for (const key in props) {
6223    if (!excludedKeys.includes(key)) {
6224      Object.defineProperty(ret, key, {
6225        enumerable: true,
6226        get: () => props[key]
6227      });
6228    }
6229  }
6230  return ret;
6231}
6232function withAsyncContext(getAwaitable) {
6233  const ctx = getCurrentInstance();
6234  if (false) // removed by dead control flow
6235{}
6236  let awaitable = getAwaitable();
6237  unsetCurrentInstance();
6238  if (isPromise(awaitable)) {
6239    awaitable = awaitable.catch((e) => {
6240      setCurrentInstance(ctx);
6241      throw e;
6242    });
6243  }
6244  return [awaitable, () => setCurrentInstance(ctx)];
6245}
6246
6247function createDuplicateChecker() {
6248  const cache = /* @__PURE__ */ Object.create(null);
6249  return (type, key) => {
6250    if (cache[key]) {
6251      warn$1(`${type} property "${key}" is already defined in ${cache[key]}.`);
6252    } else {
6253      cache[key] = type;
6254    }
6255  };
6256}
6257let shouldCacheAccess = true;
6258function applyOptions(instance) {
6259  const options = resolveMergedOptions(instance);
6260  const publicThis = instance.proxy;
6261  const ctx = instance.ctx;
6262  shouldCacheAccess = false;
6263  if (options.beforeCreate) {
6264    callHook(options.beforeCreate, instance, "bc");
6265  }
6266  const {
6267    // state
6268    data: dataOptions,
6269    computed: computedOptions,
6270    methods,
6271    watch: watchOptions,
6272    provide: provideOptions,
6273    inject: injectOptions,
6274    // lifecycle
6275    created,
6276    beforeMount,
6277    mounted,
6278    beforeUpdate,
6279    updated,
6280    activated,
6281    deactivated,
6282    beforeDestroy,
6283    beforeUnmount,
6284    destroyed,
6285    unmounted,
6286    render,
6287    renderTracked,
6288    renderTriggered,
6289    errorCaptured,
6290    serverPrefetch,
6291    // public API
6292    expose,
6293    inheritAttrs,
6294    // assets
6295    components,
6296    directives,
6297    filters
6298  } = options;
6299  const checkDuplicateProperties =  false ? 0 : null;
6300  if (false) // removed by dead control flow
6301{}
6302  if (injectOptions) {
6303    resolveInjections(injectOptions, ctx, checkDuplicateProperties);
6304  }
6305  if (methods) {
6306    for (const key in methods) {
6307      const methodHandler = methods[key];
6308      if (shared_esm_bundler_isFunction(methodHandler)) {
6309        if (false) // removed by dead control flow
6310{} else {
6311          ctx[key] = methodHandler.bind(publicThis);
6312        }
6313        if (false) // removed by dead control flow
6314{}
6315      } else if (false) // removed by dead control flow
6316{}
6317    }
6318  }
6319  if (dataOptions) {
6320    if (false) // removed by dead control flow
6321{}
6322    const data = dataOptions.call(publicThis, publicThis);
6323    if (false) // removed by dead control flow
6324{}
6325    if (!shared_esm_bundler_isObject(data)) {
6326       false && 0;
6327    } else {
6328      instance.data = reactive(data);
6329      if (false) // removed by dead control flow
6330{}
6331    }
6332  }
6333  shouldCacheAccess = true;
6334  if (computedOptions) {
6335    for (const key in computedOptions) {
6336      const opt = computedOptions[key];
6337      const get = shared_esm_bundler_isFunction(opt) ? opt.bind(publicThis, publicThis) : shared_esm_bundler_isFunction(opt.get) ? opt.get.bind(publicThis, publicThis) : shared_esm_bundler_NOOP;
6338      if (false) // removed by dead control flow
6339{}
6340      const set = !shared_esm_bundler_isFunction(opt) && shared_esm_bundler_isFunction(opt.set) ? opt.set.bind(publicThis) :  false ? 0 : shared_esm_bundler_NOOP;
6341      const c = runtime_core_esm_bundler_computed({
6342        get,
6343        set
6344      });
6345      Object.defineProperty(ctx, key, {
6346        enumerable: true,
6347        configurable: true,
6348        get: () => c.value,
6349        set: (v) => c.value = v
6350      });
6351      if (false) // removed by dead control flow
6352{}
6353    }
6354  }
6355  if (watchOptions) {
6356    for (const key in watchOptions) {
6357      createWatcher(watchOptions[key], ctx, publicThis, key);
6358    }
6359  }
6360  if (provideOptions) {
6361    const provides = shared_esm_bundler_isFunction(provideOptions) ? provideOptions.call(publicThis) : provideOptions;
6362    Reflect.ownKeys(provides).forEach((key) => {
6363      provide(key, provides[key]);
6364    });
6365  }
6366  if (created) {
6367    callHook(created, instance, "c");
6368  }
6369  function registerLifecycleHook(register, hook) {
6370    if (shared_esm_bundler_isArray(hook)) {
6371      hook.forEach((_hook) => register(_hook.bind(publicThis)));
6372    } else if (hook) {
6373      register(hook.bind(publicThis));
6374    }
6375  }
6376  registerLifecycleHook(onBeforeMount, beforeMount);
6377  registerLifecycleHook(onMounted, mounted);
6378  registerLifecycleHook(onBeforeUpdate, beforeUpdate);
6379  registerLifecycleHook(onUpdated, updated);
6380  registerLifecycleHook(onActivated, activated);
6381  registerLifecycleHook(onDeactivated, deactivated);
6382  registerLifecycleHook(onErrorCaptured, errorCaptured);
6383  registerLifecycleHook(onRenderTracked, renderTracked);
6384  registerLifecycleHook(onRenderTriggered, renderTriggered);
6385  registerLifecycleHook(onBeforeUnmount, beforeUnmount);
6386  registerLifecycleHook(onUnmounted, unmounted);
6387  registerLifecycleHook(onServerPrefetch, serverPrefetch);
6388  if (shared_esm_bundler_isArray(expose)) {
6389    if (expose.length) {
6390      const exposed = instance.exposed || (instance.exposed = {});
6391      expose.forEach((key) => {
6392        Object.defineProperty(exposed, key, {
6393          get: () => publicThis[key],
6394          set: (val) => publicThis[key] = val,
6395          enumerable: true
6396        });
6397      });
6398    } else if (!instance.exposed) {
6399      instance.exposed = {};
6400    }
6401  }
6402  if (render && instance.render === shared_esm_bundler_NOOP) {
6403    instance.render = render;
6404  }
6405  if (inheritAttrs != null) {
6406    instance.inheritAttrs = inheritAttrs;
6407  }
6408  if (components) instance.components = components;
6409  if (directives) instance.directives = directives;
6410  if (serverPrefetch) {
6411    markAsyncBoundary(instance);
6412  }
6413}
6414function resolveInjections(injectOptions, ctx, checkDuplicateProperties = shared_esm_bundler_NOOP) {
6415  if (shared_esm_bundler_isArray(injectOptions)) {
6416    injectOptions = normalizeInject(injectOptions);
6417  }
6418  for (const key in injectOptions) {
6419    const opt = injectOptions[key];
6420    let injected;
6421    if (shared_esm_bundler_isObject(opt)) {
6422      if ("default" in opt) {
6423        injected = inject(
6424          opt.from || key,
6425          opt.default,
6426          true
6427        );
6428      } else {
6429        injected = inject(opt.from || key);
6430      }
6431    } else {
6432      injected = inject(opt);
6433    }
6434    if (reactivity_esm_bundler_isRef(injected)) {
6435      Object.defineProperty(ctx, key, {
6436        enumerable: true,
6437        configurable: true,
6438        get: () => injected.value,
6439        set: (v) => injected.value = v
6440      });
6441    } else {
6442      ctx[key] = injected;
6443    }
6444    if (false) // removed by dead control flow
6445{}
6446  }
6447}
6448function callHook(hook, instance, type) {
6449  callWithAsyncErrorHandling(
6450    shared_esm_bundler_isArray(hook) ? hook.map((h) => h.bind(instance.proxy)) : hook.bind(instance.proxy),
6451    instance,
6452    type
6453  );
6454}
6455function createWatcher(raw, ctx, publicThis, key) {
6456  let getter = key.includes(".") ? createPathGetter(publicThis, key) : () => publicThis[key];
6457  if (shared_esm_bundler_isString(raw)) {
6458    const handler = ctx[raw];
6459    if (shared_esm_bundler_isFunction(handler)) {
6460      {
6461        runtime_core_esm_bundler_watch(getter, handler);
6462      }
6463    } else if (false) // removed by dead control flow
6464{}
6465  } else if (shared_esm_bundler_isFunction(raw)) {
6466    {
6467      runtime_core_esm_bundler_watch(getter, raw.bind(publicThis));
6468    }
6469  } else if (shared_esm_bundler_isObject(raw)) {
6470    if (shared_esm_bundler_isArray(raw)) {
6471      raw.forEach((r) => createWatcher(r, ctx, publicThis, key));
6472    } else {
6473      const handler = shared_esm_bundler_isFunction(raw.handler) ? raw.handler.bind(publicThis) : ctx[raw.handler];
6474      if (shared_esm_bundler_isFunction(handler)) {
6475        runtime_core_esm_bundler_watch(getter, handler, raw);
6476      } else if (false) // removed by dead control flow
6477{}
6478    }
6479  } else if (false) // removed by dead control flow
6480{}
6481}
6482function resolveMergedOptions(instance) {
6483  const base = instance.type;
6484  const { mixins, extends: extendsOptions } = base;
6485  const {
6486    mixins: globalMixins,
6487    optionsCache: cache,
6488    config: { optionMergeStrategies }
6489  } = instance.appContext;
vendor: 2,996 bytes, lines 6490-6601
6490  const cached = cache.get(base);
6491  let resolved;
6492  if (cached) {
6493    resolved = cached;
6494  } else if (!globalMixins.length && !mixins && !extendsOptions) {
6495    {
6496      resolved = base;
6497    }
6498  } else {
6499    resolved = {};
6500    if (globalMixins.length) {
6501      globalMixins.forEach(
6502        (m) => mergeOptions(resolved, m, optionMergeStrategies, true)
6503      );
6504    }
6505    mergeOptions(resolved, base, optionMergeStrategies);
6506  }
6507  if (shared_esm_bundler_isObject(base)) {
6508    cache.set(base, resolved);
6509  }
6510  return resolved;
6511}
6512function mergeOptions(to, from, strats, asMixin = false) {
6513  const { mixins, extends: extendsOptions } = from;
6514  if (extendsOptions) {
6515    mergeOptions(to, extendsOptions, strats, true);
6516  }
6517  if (mixins) {
6518    mixins.forEach(
6519      (m) => mergeOptions(to, m, strats, true)
6520    );
6521  }
6522  for (const key in from) {
6523    if (asMixin && key === "expose") {
6524       false && 0;
6525    } else {
6526      const strat = internalOptionMergeStrats[key] || strats && strats[key];
6527      to[key] = strat ? strat(to[key], from[key]) : from[key];
6528    }
6529  }
6530  return to;
6531}
6532const internalOptionMergeStrats = {
6533  data: mergeDataFn,
6534  props: mergeEmitsOrPropsOptions,
6535  emits: mergeEmitsOrPropsOptions,
6536  // objects
6537  methods: mergeObjectOptions,
6538  computed: mergeObjectOptions,
6539  // lifecycle
6540  beforeCreate: mergeAsArray,
6541  created: mergeAsArray,
6542  beforeMount: mergeAsArray,
6543  mounted: mergeAsArray,
6544  beforeUpdate: mergeAsArray,
6545  updated: mergeAsArray,
6546  beforeDestroy: mergeAsArray,
6547  beforeUnmount: mergeAsArray,
6548  destroyed: mergeAsArray,
6549  unmounted: mergeAsArray,
6550  activated: mergeAsArray,
6551  deactivated: mergeAsArray,
6552  errorCaptured: mergeAsArray,
6553  serverPrefetch: mergeAsArray,
6554  // assets
6555  components: mergeObjectOptions,
6556  directives: mergeObjectOptions,
6557  // watch
6558  watch: mergeWatchOptions,
6559  // provide / inject
6560  provide: mergeDataFn,
6561  inject: mergeInject
6562};
6563function mergeDataFn(to, from) {
6564  if (!from) {
6565    return to;
6566  }
6567  if (!to) {
6568    return from;
6569  }
6570  return function mergedDataFn() {
6571    return (shared_esm_bundler_extend)(
6572      shared_esm_bundler_isFunction(to) ? to.call(this, this) : to,
6573      shared_esm_bundler_isFunction(from) ? from.call(this, this) : from
6574    );
6575  };
6576}
6577function mergeInject(to, from) {
6578  return mergeObjectOptions(normalizeInject(to), normalizeInject(from));
6579}
6580function normalizeInject(raw) {
6581  if (shared_esm_bundler_isArray(raw)) {
6582    const res = {};
6583    for (let i = 0; i < raw.length; i++) {
6584      res[raw[i]] = raw[i];
6585    }
6586    return res;
6587  }
6588  return raw;
6589}
6590function mergeAsArray(to, from) {
6591  return to ? [...new Set([].concat(to, from))] : from;
6592}
6593function mergeObjectOptions(to, from) {
6594  return to ? shared_esm_bundler_extend(/* @__PURE__ */ Object.create(null), to, from) : from;
6595}
6596function mergeEmitsOrPropsOptions(to, from) {
6597  if (to) {
6598    if (shared_esm_bundler_isArray(to) && shared_esm_bundler_isArray(from)) {
6599      return [.../* @__PURE__ */ new Set([...to, ...from])];
6600    }
6601    return shared_esm_bundler_extend(
6602      /* @__PURE__ */ Object.create(null),
6603      normalizePropsOrEmits(to),
6604      normalizePropsOrEmits(from != null ? from : {})
6605    );
6606  } else {
6607    return from;
6608  }
6609}
6610function mergeWatchOptions(to, from) {
6611  if (!to) return from;
6612  if (!from) return to;
6613  const merged = shared_esm_bundler_extend(/* @__PURE__ */ Object.create(null), to);
6614  for (const key in from) {
6615    merged[key] = mergeAsArray(to[key], from[key]);
6616  }
6617  return merged;
6618}
6619
6620function createAppContext() {
6621  return {
6622    app: null,
6623    config: {
6624      isNativeTag: NO,
6625      performance: false,
6626      globalProperties: {},
6627      optionMergeStrategies: {},
6628      errorHandler: void 0,
6629      warnHandler: void 0,
6630      compilerOptions: {}
6631    },
6632    mixins: [],
6633    components: {},
6634    directives: {},
6635    provides: /* @__PURE__ */ Object.create(null),
6636    optionsCache: /* @__PURE__ */ new WeakMap(),
6637    propsCache: /* @__PURE__ */ new WeakMap(),
6638    emitsCache: /* @__PURE__ */ new WeakMap()
6639  };
6640}
6641let uid$1 = 0;
6642function createAppAPI(render, hydrate) {
6643  return function createApp(rootComponent, rootProps = null) {
6644    if (!shared_esm_bundler_isFunction(rootComponent)) {
6645      rootComponent = shared_esm_bundler_extend({}, rootComponent);
6646    }
6647    if (rootProps != null && !shared_esm_bundler_isObject(rootProps)) {
6648       false && 0;
6649      rootProps = null;
6650    }
6651    const context = createAppContext();
6652    const installedPlugins = /* @__PURE__ */ new WeakSet();
6653    const pluginCleanupFns = [];
6654    let isMounted = false;
6655    const app = context.app = {
6656      _uid: uid$1++,
6657      _component: rootComponent,
6658      _props: rootProps,
6659      _container: null,
6660      _context: context,
6661      _instance: null,
6662      version,
6663      get config() {
6664        return context.config;
6665      },
6666      set config(v) {
6667        if (false) // removed by dead control flow
6668{}
6669      },
6670      use(plugin, ...options) {
6671        if (installedPlugins.has(plugin)) {
6672           false && 0;
6673        } else if (plugin && shared_esm_bundler_isFunction(plugin.install)) {
6674          installedPlugins.add(plugin);
6675          plugin.install(app, ...options);
6676        } else if (shared_esm_bundler_isFunction(plugin)) {
6677          installedPlugins.add(plugin);
6678          plugin(app, ...options);
6679        } else if (false) // removed by dead control flow
6680{}
6681        return app;
6682      },
6683      mixin(mixin) {
6684        if (__VUE_OPTIONS_API__) {
6685          if (!context.mixins.includes(mixin)) {
6686            context.mixins.push(mixin);
6687          } else if (false) // removed by dead control flow
6688{}
6689        } else if (false) // removed by dead control flow
6690{}
6691        return app;
6692      },
6693      component(name, component) {
6694        if (false) // removed by dead control flow
6695{}
6696        if (!component) {
6697          return context.components[name];
6698        }
6699        if (false) // removed by dead control flow
6700{}
6701        context.components[name] = component;
6702        return app;
6703      },
6704      directive(name, directive) {
6705        if (false) // removed by dead control flow
6706{}
6707        if (!directive) {
6708          return context.directives[name];
6709        }
6710        if (false) // removed by dead control flow
6711{}
6712        context.directives[name] = directive;
6713        return app;
6714      },
6715      mount(rootContainer, isHydrate, namespace) {
6716        if (!isMounted) {
6717          if (false) // removed by dead control flow
6718{}
6719          const vnode = app._ceVNode || createVNode(rootComponent, rootProps);
6720          vnode.appContext = context;
6721          if (namespace === true) {
6722            namespace = "svg";
6723          } else if (namespace === false) {
6724            namespace = void 0;
6725          }
6726          if (false) // removed by dead control flow
6727{}
6728          if (isHydrate && hydrate) {
6729            hydrate(vnode, rootContainer);
6730          } else {
6731            render(vnode, rootContainer, namespace);
6732          }
6733          isMounted = true;
6734          app._container = rootContainer;
6735          rootContainer.__vue_app__ = app;
6736          if ( false || __VUE_PROD_DEVTOOLS__) {
6737            app._instance = vnode.component;
6738            devtoolsInitApp(app, version);
6739          }
6740          return getComponentPublicInstance(vnode.component);
6741        } else if (false) // removed by dead control flow
6742{}
6743      },
6744      onUnmount(cleanupFn) {
6745        if (false) // removed by dead control flow
6746{}
6747        pluginCleanupFns.push(cleanupFn);
6748      },
6749      unmount() {
6750        if (isMounted) {
6751          callWithAsyncErrorHandling(
6752            pluginCleanupFns,
6753            app._instance,
6754            16
6755          );
6756          render(null, app._container);
6757          if ( false || __VUE_PROD_DEVTOOLS__) {
6758            app._instance = null;
6759            devtoolsUnmountApp(app);
6760          }
6761          delete app._container.__vue_app__;
6762        } else if (false) // removed by dead control flow
6763{}
6764      },
6765      provide(key, value) {
6766        if (false) // removed by dead control flow
6767{}
6768        context.provides[key] = value;
6769        return app;
6770      },
6771      runWithContext(fn) {
6772        const lastApp = currentApp;
6773        currentApp = app;
6774        try {
6775          return fn();
6776        } finally {
6777          currentApp = lastApp;
6778        }
6779      }
6780    };
6781    return app;
6782  };
6783}
6784let currentApp = null;
6785
6786function provide(key, value) {
6787  if (false) // removed by dead control flow
6788{}
6789  if (currentInstance) {
6790    let provides = currentInstance.provides;
6791    const parentProvides = currentInstance.parent && currentInstance.parent.provides;
6792    if (parentProvides === provides) {
6793      provides = currentInstance.provides = Object.create(parentProvides);
6794    }
6795    provides[key] = value;
6796  }
6797}
6798function inject(key, defaultValue, treatDefaultAsFactory = false) {
6799  const instance = getCurrentInstance();
6800  if (instance || currentApp) {
6801    let provides = currentApp ? currentApp._context.provides : instance ? instance.parent == null || instance.ce ? instance.vnode.appContext && instance.vnode.appContext.provides : instance.parent.provides : void 0;
6802    if (provides && key in provides) {
6803      return provides[key];
6804    } else if (arguments.length > 1) {
6805      return treatDefaultAsFactory && shared_esm_bundler_isFunction(defaultValue) ? defaultValue.call(instance && instance.proxy) : defaultValue;
6806    } else if (false) // removed by dead control flow
6807{}
6808  } else if (false) // removed by dead control flow
6809{}
6810}
6811function hasInjectionContext() {
6812  return !!(getCurrentInstance() || currentApp);
6813}
6814
6815const ssrContextKey = Symbol.for("v-scx");
6816const useSSRContext = () => {
6817  {
6818    const ctx = inject(ssrContextKey);
6819    if (!ctx) {
6820       false && 0;
6821    }
6822    return ctx;
6823  }
6824};
6825
6826function watchEffect(effect, options) {
6827  return doWatch(effect, null, options);
6828}
6829function watchPostEffect(effect, options) {
6830  return doWatch(
6831    effect,
6832    null,
6833     false ? 0 : { flush: "post" }
6834  );
6835}
6836function watchSyncEffect(effect, options) {
6837  return doWatch(
6838    effect,
6839    null,
6840     false ? 0 : { flush: "sync" }
6841  );
6842}
6843function runtime_core_esm_bundler_watch(source, cb, options) {
6844  if (false) // removed by dead control flow
6845{}
6846  return doWatch(source, cb, options);
6847}
6848function doWatch(source, cb, options = EMPTY_OBJ) {
6849  const { immediate, deep, flush, once } = options;
6850  if (false) // removed by dead control flow
6851{}
6852  const baseWatchOptions = shared_esm_bundler_extend({}, options);
6853  if (false) // removed by dead control flow
6854{}
6855  const runsImmediately = cb && immediate || !cb && flush !== "post";
6856  let ssrCleanup;
6857  if (isInSSRComponentSetup) {
6858    if (flush === "sync") {
6859      const ctx = useSSRContext();
6860      ssrCleanup = ctx.__watcherHandles || (ctx.__watcherHandles = []);
6861    } else if (!runsImmediately) {
6862      const watchStopHandle = () => {
6863      };
6864      watchStopHandle.stop = shared_esm_bundler_NOOP;
6865      watchStopHandle.resume = shared_esm_bundler_NOOP;
6866      watchStopHandle.pause = shared_esm_bundler_NOOP;
6867      return watchStopHandle;
6868    }
6869  }
6870  const instance = currentInstance;
6871  baseWatchOptions.call = (fn, type, args) => callWithAsyncErrorHandling(fn, instance, type, args);
6872  let isPre = false;
6873  if (flush === "post") {
6874    baseWatchOptions.scheduler = (job) => {
6875      queuePostRenderEffect(job, instance && instance.suspense);
6876    };
6877  } else if (flush !== "sync") {
6878    isPre = true;
6879    baseWatchOptions.scheduler = (job, isFirstRun) => {
6880      if (isFirstRun) {
6881        job();
6882      } else {
6883        queueJob(job);
6884      }
6885    };
6886  }
6887  baseWatchOptions.augmentJob = (job) => {
6888    if (cb) {
6889      job.flags |= 4;
6890    }
6891    if (isPre) {
6892      job.flags |= 2;
6893      if (instance) {
6894        job.id = instance.uid;
6895        job.i = instance;
6896      }
6897    }
6898  };
6899  const watchHandle = watch(source, cb, baseWatchOptions);
6900  if (isInSSRComponentSetup) {
6901    if (ssrCleanup) {
6902      ssrCleanup.push(watchHandle);
6903    } else if (runsImmediately) {
6904      watchHandle();
6905    }
6906  }
6907  return watchHandle;
6908}
6909function instanceWatch(source, value, options) {
6910  const publicThis = this.proxy;
6911  const getter = shared_esm_bundler_isString(source) ? source.includes(".") ? createPathGetter(publicThis, source) : () => publicThis[source] : source.bind(publicThis, publicThis);
6912  let cb;
6913  if (shared_esm_bundler_isFunction(value)) {
6914    cb = value;
6915  } else {
6916    cb = value.handler;
6917    options = value;
6918  }
6919  const reset = setCurrentInstance(this);
6920  const res = doWatch(getter, cb.bind(publicThis), options);
6921  reset();
6922  return res;
6923}
6924function createPathGetter(ctx, path) {
6925  const segments = path.split(".");
6926  return () => {
6927    let cur = ctx;
6928    for (let i = 0; i < segments.length && cur; i++) {
6929      cur = cur[segments[i]];
6930    }
6931    return cur;
6932  };
6933}
6934
6935function useModel(props, name, options = EMPTY_OBJ) {
6936  const i = getCurrentInstance();
6937  if (false) // removed by dead control flow
6938{}
6939  const camelizedName = shared_esm_bundler_camelize(name);
6940  if (false) // removed by dead control flow
6941{}
6942  const hyphenatedName = hyphenate(name);
6943  const modifiers = getModelModifiers(props, camelizedName);
6944  const res = customRef((track, trigger) => {
6945    let localValue;
6946    let prevSetValue = EMPTY_OBJ;
6947    let prevEmittedValue;
6948    watchSyncEffect(() => {
6949      const propValue = props[camelizedName];
6950      if (hasChanged(localValue, propValue)) {
6951        localValue = propValue;
6952        trigger();
6953      }
6954    });
6955    return {
6956      get() {
6957        track();
6958        return options.get ? options.get(localValue) : localValue;
6959      },
6960      set(value) {
6961        const emittedValue = options.set ? options.set(value) : value;
6962        if (!hasChanged(emittedValue, localValue) && !(prevSetValue !== EMPTY_OBJ && hasChanged(value, prevSetValue))) {
6963          return;
6964        }
6965        const rawProps = i.vnode.props;
6966        if (!(rawProps && // check if parent has passed v-model
6967        (name in rawProps || camelizedName in rawProps || hyphenatedName in rawProps) && (`onUpdate:${name}` in rawProps || `onUpdate:${camelizedName}` in rawProps || `onUpdate:${hyphenatedName}` in rawProps))) {
6968          localValue = value;
6969          trigger();
6970        }
6971        i.emit(`update:${name}`, emittedValue);
6972        if (hasChanged(value, emittedValue) && hasChanged(value, prevSetValue) && !hasChanged(emittedValue, prevEmittedValue)) {
6973          trigger();
6974        }
6975        prevSetValue = value;
6976        prevEmittedValue = emittedValue;
6977      }
6978    };
6979  });
6980  res[Symbol.iterator] = () => {
6981    let i2 = 0;
6982    return {
6983      next() {
6984        if (i2 < 2) {
6985          return { value: i2++ ? modifiers || EMPTY_OBJ : res, done: false };
6986        } else {
6987          return { done: true };
6988        }
6989      }
6990    };
6991  };
6992  return res;
6993}
6994const getModelModifiers = (props, modelName) => {
6995  return modelName === "modelValue" || modelName === "model-value" ? props.modelModifiers : props[`${modelName}Modifiers`] || props[`${shared_esm_bundler_camelize(modelName)}Modifiers`] || props[`${hyphenate(modelName)}Modifiers`];
6996};
6997
6998function emit(instance, event, ...rawArgs) {
6999  if (instance.isUnmounted) return;
7000  const props = instance.vnode.props || EMPTY_OBJ;
7001  if (false) // removed by dead control flow
7002{}
7003  let args = rawArgs;
7004  const isModelListener = event.startsWith("update:");
7005  const modifiers = isModelListener && getModelModifiers(props, event.slice(7));
7006  if (modifiers) {
7007    if (modifiers.trim) {
7008      args = rawArgs.map((a) => shared_esm_bundler_isString(a) ? a.trim() : a);
7009    }
7010    if (modifiers.number) {
7011      args = rawArgs.map(looseToNumber);
7012    }
7013  }
7014  if ( false || __VUE_PROD_DEVTOOLS__) {
7015    devtoolsComponentEmit(instance, event, args);
7016  }
7017  if (false) // removed by dead control flow
7018{}
7019  let handlerName;
7020  let handler = props[handlerName = toHandlerKey(event)] || // also try camelCase event handler (#2249)
7021  props[handlerName = toHandlerKey(shared_esm_bundler_camelize(event))];
7022  if (!handler && isModelListener) {
7023    handler = props[handlerName = toHandlerKey(hyphenate(event))];
7024  }
7025  if (handler) {
7026    callWithAsyncErrorHandling(
7027      handler,
7028      instance,
7029      6,
7030      args
7031    );
7032  }
7033  const onceHandler = props[handlerName + `Once`];
7034  if (onceHandler) {
7035    if (!instance.emitted) {
7036      instance.emitted = {};
7037    } else if (instance.emitted[handlerName]) {
7038      return;
7039    }
7040    instance.emitted[handlerName] = true;
7041    callWithAsyncErrorHandling(
7042      onceHandler,
7043      instance,
7044      6,
7045      args
7046    );
7047  }
7048}
7049const mixinEmitsCache = /* @__PURE__ */ new WeakMap();
7050function normalizeEmitsOptions(comp, appContext, asMixin = false) {
7051  const cache = __VUE_OPTIONS_API__ && asMixin ? mixinEmitsCache : appContext.emitsCache;
7052  const cached = cache.get(comp);
7053  if (cached !== void 0) {
7054    return cached;
7055  }
7056  const raw = comp.emits;
7057  let normalized = {};
7058  let hasExtends = false;
7059  if (__VUE_OPTIONS_API__ && !shared_esm_bundler_isFunction(comp)) {
7060    const extendEmits = (raw2) => {
7061      const normalizedFromExtend = normalizeEmitsOptions(raw2, appContext, true);
7062      if (normalizedFromExtend) {
7063        hasExtends = true;
7064        shared_esm_bundler_extend(normalized, normalizedFromExtend);
7065      }
7066    };
7067    if (!asMixin && appContext.mixins.length) {
7068      appContext.mixins.forEach(extendEmits);
7069    }
7070    if (comp.extends) {
7071      extendEmits(comp.extends);
7072    }
7073    if (comp.mixins) {
7074      comp.mixins.forEach(extendEmits);
7075    }
7076  }
7077  if (!raw && !hasExtends) {
7078    if (shared_esm_bundler_isObject(comp)) {
7079      cache.set(comp, null);
7080    }
7081    return null;
7082  }
7083  if (shared_esm_bundler_isArray(raw)) {
7084    raw.forEach((key) => normalized[key] = null);
7085  } else {
7086    shared_esm_bundler_extend(normalized, raw);
7087  }
7088  if (shared_esm_bundler_isObject(comp)) {
7089    cache.set(comp, normalized);
7090  }
7091  return normalized;
7092}
7093function isEmitListener(options, key) {
7094  if (!options || !isOn(key)) {
7095    return false;
7096  }
7097  key = key.slice(2).replace(/Once$/, "");
7098  return hasOwn(options, key[0].toLowerCase() + key.slice(1)) || hasOwn(options, hyphenate(key)) || hasOwn(options, key);
7099}
7100
7101let accessedAttrs = false;
7102function markAttrsAccessed() {
7103  accessedAttrs = true;
7104}
7105function renderComponentRoot(instance) {
7106  const {
7107    type: Component,
7108    vnode,
7109    proxy,
7110    withProxy,
7111    propsOptions: [propsOptions],
7112    slots,
7113    attrs,
7114    emit,
7115    render,
7116    renderCache,
7117    props,
7118    data,
7119    setupState,
7120    ctx,
7121    inheritAttrs
7122  } = instance;
7123  const prev = setCurrentRenderingInstance(instance);
7124  let result;
7125  let fallthroughAttrs;
7126  if (false) // removed by dead control flow
7127{}
7128  try {
7129    if (vnode.shapeFlag & 4) {
7130      const proxyToUse = withProxy || proxy;
7131      const thisProxy =  false ? 0 : proxyToUse;
7132      result = normalizeVNode(
7133        render.call(
7134          thisProxy,
7135          proxyToUse,
7136          renderCache,
7137           false ? 0 : props,
7138          setupState,
7139          data,
7140          ctx
7141        )
7142      );
7143      fallthroughAttrs = attrs;
7144    } else {
7145      const render2 = Component;
7146      if (false) // removed by dead control flow
7147{}
7148      result = normalizeVNode(
7149        render2.length > 1 ? render2(
7150           false ? 0 : props,
7151           false ? 0 : { attrs, slots, emit }
7152        ) : render2(
7153           false ? 0 : props,
7154          null
7155        )
7156      );
7157      fallthroughAttrs = Component.props ? attrs : getFunctionalFallthrough(attrs);
7158    }
7159  } catch (err) {
7160    blockStack.length = 0;
7161    handleError(err, instance, 1);
7162    result = createVNode(Comment);
7163  }
7164  let root = result;
7165  let setRoot = void 0;
7166  if (false) // removed by dead control flow
7167{}
7168  if (fallthroughAttrs && inheritAttrs !== false) {
7169    const keys = Object.keys(fallthroughAttrs);
7170    const { shapeFlag } = root;
7171    if (keys.length) {
7172      if (shapeFlag & (1 | 6)) {
7173        if (propsOptions && keys.some(isModelListener)) {
7174          fallthroughAttrs = filterModelListeners(
7175            fallthroughAttrs,
7176            propsOptions
7177          );
7178        }
7179        root = cloneVNode(root, fallthroughAttrs, false, true);
7180      } else if (false) // removed by dead control flow
7181{}
7182    }
7183  }
7184  if (vnode.dirs) {
7185    if (false) // removed by dead control flow
7186{}
7187    root = cloneVNode(root, null, false, true);
7188    root.dirs = root.dirs ? root.dirs.concat(vnode.dirs) : vnode.dirs;
7189  }
7190  if (vnode.transition) {
7191    if (false) // removed by dead control flow
7192{}
7193    setTransitionHooks(root, vnode.transition);
7194  }
7195  if (false) // removed by dead control flow
7196{} else {
7197    result = root;
7198  }
7199  setCurrentRenderingInstance(prev);
7200  return result;
7201}
7202const getChildRoot = (vnode) => {
7203  const rawChildren = vnode.children;
7204  const dynamicChildren = vnode.dynamicChildren;
7205  const childRoot = filterSingleRoot(rawChildren, false);
7206  if (!childRoot) {
7207    return [vnode, void 0];
7208  } else if (false) // removed by dead control flow
7209{}
7210  const index = rawChildren.indexOf(childRoot);
7211  const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1;
7212  const setRoot = (updatedRoot) => {
7213    rawChildren[index] = updatedRoot;
7214    if (dynamicChildren) {
7215      if (dynamicIndex > -1) {
7216        dynamicChildren[dynamicIndex] = updatedRoot;
7217      } else if (updatedRoot.patchFlag > 0) {
7218        vnode.dynamicChildren = [...dynamicChildren, updatedRoot];
7219      }
7220    }
7221  };
7222  return [normalizeVNode(childRoot), setRoot];
7223};
7224function filterSingleRoot(children, recurse = true) {
7225  let singleRoot;
7226  for (let i = 0; i < children.length; i++) {
7227    const child = children[i];
7228    if (isVNode(child)) {
7229      if (child.type !== Comment || child.children === "v-if") {
7230        if (singleRoot) {
7231          return;
7232        } else {
7233          singleRoot = child;
7234          if (false) // removed by dead control flow
7235{}
7236        }
7237      }
7238    } else {
7239      return;
7240    }
7241  }
7242  return singleRoot;
7243}
7244const getFunctionalFallthrough = (attrs) => {
7245  let res;
7246  for (const key in attrs) {
7247    if (key === "class" || key === "style" || isOn(key)) {
7248      (res || (res = {}))[key] = attrs[key];
7249    }
7250  }
7251  return res;
7252};
7253const filterModelListeners = (attrs, props) => {
7254  const res = {};
7255  for (const key in attrs) {
7256    if (!isModelListener(key) || !(key.slice(9) in props)) {
7257      res[key] = attrs[key];
7258    }
7259  }
7260  return res;
7261};
7262const isElementRoot = (vnode) => {
7263  return vnode.shapeFlag & (6 | 1) || vnode.type === Comment;
7264};
7265function shouldUpdateComponent(prevVNode, nextVNode, optimized) {
7266  const { props: prevProps, children: prevChildren, component } = prevVNode;
7267  const { props: nextProps, children: nextChildren, patchFlag } = nextVNode;
7268  const emits = component.emitsOptions;
7269  if (false) // removed by dead control flow
7270{}
7271  if (nextVNode.dirs || nextVNode.transition) {
7272    return true;
7273  }
7274  if (optimized && patchFlag >= 0) {
7275    if (patchFlag & 1024) {
7276      return true;
7277    }
7278    if (patchFlag & 16) {
7279      if (!prevProps) {
7280        return !!nextProps;
7281      }
7282      return hasPropsChanged(prevProps, nextProps, emits);
7283    } else if (patchFlag & 8) {
7284      const dynamicProps = nextVNode.dynamicProps;
7285      for (let i = 0; i < dynamicProps.length; i++) {
vendor: 4,131 bytes, lines 7286-7430
7286        const key = dynamicProps[i];
7287        if (nextProps[key] !== prevProps[key] && !isEmitListener(emits, key)) {
7288          return true;
7289        }
7290      }
7291    }
7292  } else {
7293    if (prevChildren || nextChildren) {
7294      if (!nextChildren || !nextChildren.$stable) {
7295        return true;
7296      }
7297    }
7298    if (prevProps === nextProps) {
7299      return false;
7300    }
7301    if (!prevProps) {
7302      return !!nextProps;
7303    }
7304    if (!nextProps) {
7305      return true;
7306    }
7307    return hasPropsChanged(prevProps, nextProps, emits);
7308  }
7309  return false;
7310}
7311function hasPropsChanged(prevProps, nextProps, emitsOptions) {
7312  const nextKeys = Object.keys(nextProps);
7313  if (nextKeys.length !== Object.keys(prevProps).length) {
7314    return true;
7315  }
7316  for (let i = 0; i < nextKeys.length; i++) {
7317    const key = nextKeys[i];
7318    if (nextProps[key] !== prevProps[key] && !isEmitListener(emitsOptions, key)) {
7319      return true;
7320    }
7321  }
7322  return false;
7323}
7324function updateHOCHostEl({ vnode, parent }, el) {
7325  while (parent) {
7326    const root = parent.subTree;
7327    if (root.suspense && root.suspense.activeBranch === vnode) {
7328      root.el = vnode.el;
7329    }
7330    if (root === vnode) {
7331      (vnode = parent.vnode).el = el;
7332      parent = parent.parent;
7333    } else {
7334      break;
7335    }
7336  }
7337}
7338
7339const internalObjectProto = {};
7340const createInternalObject = () => Object.create(internalObjectProto);
7341const isInternalObject = (obj) => Object.getPrototypeOf(obj) === internalObjectProto;
7342
7343function initProps(instance, rawProps, isStateful, isSSR = false) {
7344  const props = {};
7345  const attrs = createInternalObject();
7346  instance.propsDefaults = /* @__PURE__ */ Object.create(null);
7347  setFullProps(instance, rawProps, props, attrs);
7348  for (const key in instance.propsOptions[0]) {
7349    if (!(key in props)) {
7350      props[key] = void 0;
7351    }
7352  }
7353  if (false) // removed by dead control flow
7354{}
7355  if (isStateful) {
7356    instance.props = isSSR ? props : shallowReactive(props);
7357  } else {
7358    if (!instance.type.props) {
7359      instance.props = attrs;
7360    } else {
7361      instance.props = props;
7362    }
7363  }
7364  instance.attrs = attrs;
7365}
7366function isInHmrContext(instance) {
7367  while (instance) {
7368    if (instance.type.__hmrId) return true;
7369    instance = instance.parent;
7370  }
7371}
7372function updateProps(instance, rawProps, rawPrevProps, optimized) {
7373  const {
7374    props,
7375    attrs,
7376    vnode: { patchFlag }
7377  } = instance;
7378  const rawCurrentProps = reactivity_esm_bundler_toRaw(props);
7379  const [options] = instance.propsOptions;
7380  let hasAttrsChanged = false;
7381  if (
7382    // always force full diff in dev
7383    // - #1942 if hmr is enabled with sfc component
7384    // - vite#872 non-sfc component used by sfc component
7385     true && (optimized || patchFlag > 0) && !(patchFlag & 16)
7386  ) {
7387    if (patchFlag & 8) {
7388      const propsToUpdate = instance.vnode.dynamicProps;
7389      for (let i = 0; i < propsToUpdate.length; i++) {
7390        let key = propsToUpdate[i];
7391        if (isEmitListener(instance.emitsOptions, key)) {
7392          continue;
7393        }
7394        const value = rawProps[key];
7395        if (options) {
7396          if (hasOwn(attrs, key)) {
7397            if (value !== attrs[key]) {
7398              attrs[key] = value;
7399              hasAttrsChanged = true;
7400            }
7401          } else {
7402            const camelizedKey = shared_esm_bundler_camelize(key);
7403            props[camelizedKey] = resolvePropValue(
7404              options,
7405              rawCurrentProps,
7406              camelizedKey,
7407              value,
7408              instance,
7409              false
7410            );
7411          }
7412        } else {
7413          if (value !== attrs[key]) {
7414            attrs[key] = value;
7415            hasAttrsChanged = true;
7416          }
7417        }
7418      }
7419    }
7420  } else {
7421    if (setFullProps(instance, rawProps, props, attrs)) {
7422      hasAttrsChanged = true;
7423    }
7424    let kebabKey;
7425    for (const key in rawCurrentProps) {
7426      if (!rawProps || // for camelCase
7427      !hasOwn(rawProps, key) && // it's possible the original props was passed in as kebab-case
7428      // and converted to camelCase (#955)
7429      ((kebabKey = hyphenate(key)) === key || !hasOwn(rawProps, kebabKey))) {
7430        if (options) {
vendor: 4,956 bytes, lines 7431-7592
7431          if (rawPrevProps && // for camelCase
7432          (rawPrevProps[key] !== void 0 || // for kebab-case
7433          rawPrevProps[kebabKey] !== void 0)) {
7434            props[key] = resolvePropValue(
7435              options,
7436              rawCurrentProps,
7437              key,
7438              void 0,
7439              instance,
7440              true
7441            );
7442          }
7443        } else {
7444          delete props[key];
7445        }
7446      }
7447    }
7448    if (attrs !== rawCurrentProps) {
7449      for (const key in attrs) {
7450        if (!rawProps || !hasOwn(rawProps, key) && true) {
7451          delete attrs[key];
7452          hasAttrsChanged = true;
7453        }
7454      }
7455    }
7456  }
7457  if (hasAttrsChanged) {
7458    trigger(instance.attrs, "set", "");
7459  }
7460  if (false) // removed by dead control flow
7461{}
7462}
7463function setFullProps(instance, rawProps, props, attrs) {
7464  const [options, needCastKeys] = instance.propsOptions;
7465  let hasAttrsChanged = false;
7466  let rawCastValues;
7467  if (rawProps) {
7468    for (let key in rawProps) {
7469      if (isReservedProp(key)) {
7470        continue;
7471      }
7472      const value = rawProps[key];
7473      let camelKey;
7474      if (options && hasOwn(options, camelKey = shared_esm_bundler_camelize(key))) {
7475        if (!needCastKeys || !needCastKeys.includes(camelKey)) {
7476          props[camelKey] = value;
7477        } else {
7478          (rawCastValues || (rawCastValues = {}))[camelKey] = value;
7479        }
7480      } else if (!isEmitListener(instance.emitsOptions, key)) {
7481        if (!(key in attrs) || value !== attrs[key]) {
7482          attrs[key] = value;
7483          hasAttrsChanged = true;
7484        }
7485      }
7486    }
7487  }
7488  if (needCastKeys) {
7489    const rawCurrentProps = reactivity_esm_bundler_toRaw(props);
7490    const castValues = rawCastValues || EMPTY_OBJ;
7491    for (let i = 0; i < needCastKeys.length; i++) {
7492      const key = needCastKeys[i];
7493      props[key] = resolvePropValue(
7494        options,
7495        rawCurrentProps,
7496        key,
7497        castValues[key],
7498        instance,
7499        !hasOwn(castValues, key)
7500      );
7501    }
7502  }
7503  return hasAttrsChanged;
7504}
7505function resolvePropValue(options, props, key, value, instance, isAbsent) {
7506  const opt = options[key];
7507  if (opt != null) {
7508    const hasDefault = hasOwn(opt, "default");
7509    if (hasDefault && value === void 0) {
7510      const defaultValue = opt.default;
7511      if (opt.type !== Function && !opt.skipFactory && shared_esm_bundler_isFunction(defaultValue)) {
7512        const { propsDefaults } = instance;
7513        if (key in propsDefaults) {
7514          value = propsDefaults[key];
7515        } else {
7516          const reset = setCurrentInstance(instance);
7517          value = propsDefaults[key] = defaultValue.call(
7518            null,
7519            props
7520          );
7521          reset();
7522        }
7523      } else {
7524        value = defaultValue;
7525      }
7526      if (instance.ce) {
7527        instance.ce._setProp(key, value);
7528      }
7529    }
7530    if (opt[0 /* shouldCast */]) {
7531      if (isAbsent && !hasDefault) {
7532        value = false;
7533      } else if (opt[1 /* shouldCastTrue */] && (value === "" || value === hyphenate(key))) {
7534        value = true;
7535      }
7536    }
7537  }
7538  return value;
7539}
7540const mixinPropsCache = /* @__PURE__ */ new WeakMap();
7541function normalizePropsOptions(comp, appContext, asMixin = false) {
7542  const cache = __VUE_OPTIONS_API__ && asMixin ? mixinPropsCache : appContext.propsCache;
7543  const cached = cache.get(comp);
7544  if (cached) {
7545    return cached;
7546  }
7547  const raw = comp.props;
7548  const normalized = {};
7549  const needCastKeys = [];
7550  let hasExtends = false;
7551  if (__VUE_OPTIONS_API__ && !shared_esm_bundler_isFunction(comp)) {
7552    const extendProps = (raw2) => {
7553      hasExtends = true;
7554      const [props, keys] = normalizePropsOptions(raw2, appContext, true);
7555      shared_esm_bundler_extend(normalized, props);
7556      if (keys) needCastKeys.push(...keys);
7557    };
7558    if (!asMixin && appContext.mixins.length) {
7559      appContext.mixins.forEach(extendProps);
7560    }
7561    if (comp.extends) {
7562      extendProps(comp.extends);
7563    }
7564    if (comp.mixins) {
7565      comp.mixins.forEach(extendProps);
7566    }
7567  }
7568  if (!raw && !hasExtends) {
7569    if (shared_esm_bundler_isObject(comp)) {
7570      cache.set(comp, EMPTY_ARR);
7571    }
7572    return EMPTY_ARR;
7573  }
7574  if (shared_esm_bundler_isArray(raw)) {
7575    for (let i = 0; i < raw.length; i++) {
7576      if (false) // removed by dead control flow
7577{}
7578      const normalizedKey = shared_esm_bundler_camelize(raw[i]);
7579      if (validatePropName(normalizedKey)) {
7580        normalized[normalizedKey] = EMPTY_OBJ;
7581      }
7582    }
7583  } else if (raw) {
7584    if (false) // removed by dead control flow
7585{}
7586    for (const key in raw) {
7587      const normalizedKey = shared_esm_bundler_camelize(key);
7588      if (validatePropName(normalizedKey)) {
7589        const opt = raw[key];
7590        const prop = normalized[normalizedKey] = shared_esm_bundler_isArray(opt) || shared_esm_bundler_isFunction(opt) ? { type: opt } : shared_esm_bundler_extend({}, opt);
7591        const propType = prop.type;
7592        let shouldCast = false;
vendor: 4,775 bytes, lines 7593-7745
7593        let shouldCastTrue = true;
7594        if (shared_esm_bundler_isArray(propType)) {
7595          for (let index = 0; index < propType.length; ++index) {
7596            const type = propType[index];
7597            const typeName = shared_esm_bundler_isFunction(type) && type.name;
7598            if (typeName === "Boolean") {
7599              shouldCast = true;
7600              break;
7601            } else if (typeName === "String") {
7602              shouldCastTrue = false;
7603            }
7604          }
7605        } else {
7606          shouldCast = shared_esm_bundler_isFunction(propType) && propType.name === "Boolean";
7607        }
7608        prop[0 /* shouldCast */] = shouldCast;
7609        prop[1 /* shouldCastTrue */] = shouldCastTrue;
7610        if (shouldCast || hasOwn(prop, "default")) {
7611          needCastKeys.push(normalizedKey);
7612        }
7613      }
7614    }
7615  }
7616  const res = [normalized, needCastKeys];
7617  if (shared_esm_bundler_isObject(comp)) {
7618    cache.set(comp, res);
7619  }
7620  return res;
7621}
7622function validatePropName(key) {
7623  if (key[0] !== "$" && !isReservedProp(key)) {
7624    return true;
7625  } else if (false) // removed by dead control flow
7626{}
7627  return false;
7628}
7629function getType(ctor) {
7630  if (ctor === null) {
7631    return "null";
7632  }
7633  if (typeof ctor === "function") {
7634    return ctor.name || "";
7635  } else if (typeof ctor === "object") {
7636    const name = ctor.constructor && ctor.constructor.name;
7637    return name || "";
7638  }
7639  return "";
7640}
7641function validateProps(rawProps, props, instance) {
7642  const resolvedValues = toRaw(props);
7643  const options = instance.propsOptions[0];
7644  const camelizePropsKey = Object.keys(rawProps).map((key) => camelize(key));
7645  for (const key in options) {
7646    let opt = options[key];
7647    if (opt == null) continue;
7648    validateProp(
7649      key,
7650      resolvedValues[key],
7651      opt,
7652       false ? 0 : resolvedValues,
7653      !camelizePropsKey.includes(key)
7654    );
7655  }
7656}
7657function validateProp(name, value, prop, props, isAbsent) {
7658  const { type, required, validator, skipCheck } = prop;
7659  if (required && isAbsent) {
7660    warn$1('Missing required prop: "' + name + '"');
7661    return;
7662  }
7663  if (value == null && !required) {
7664    return;
7665  }
7666  if (type != null && type !== true && !skipCheck) {
7667    let isValid = false;
7668    const types = isArray(type) ? type : [type];
7669    const expectedTypes = [];
7670    for (let i = 0; i < types.length && !isValid; i++) {
7671      const { valid, expectedType } = assertType(value, types[i]);
7672      expectedTypes.push(expectedType || "");
7673      isValid = valid;
7674    }
7675    if (!isValid) {
7676      warn$1(getInvalidTypeMessage(name, value, expectedTypes));
7677      return;
7678    }
7679  }
7680  if (validator && !validator(value, props)) {
7681    warn$1('Invalid prop: custom validator check failed for prop "' + name + '".');
7682  }
7683}
7684const isSimpleType = /* @__PURE__ */ (/* unused pure expression or super */ null && (makeMap(
7685  "String,Number,Boolean,Function,Symbol,BigInt"
7686)));
7687function assertType(value, type) {
7688  let valid;
7689  const expectedType = getType(type);
7690  if (expectedType === "null") {
7691    valid = value === null;
7692  } else if (isSimpleType(expectedType)) {
7693    const t = typeof value;
7694    valid = t === expectedType.toLowerCase();
7695    if (!valid && t === "object") {
7696      valid = value instanceof type;
7697    }
7698  } else if (expectedType === "Object") {
7699    valid = isObject(value);
7700  } else if (expectedType === "Array") {
7701    valid = isArray(value);
7702  } else {
7703    valid = value instanceof type;
7704  }
7705  return {
7706    valid,
7707    expectedType
7708  };
7709}
7710function getInvalidTypeMessage(name, value, expectedTypes) {
7711  if (expectedTypes.length === 0) {
7712    return `Prop type [] for prop "${name}" won't match anything. Did you mean to use type Array instead?`;
7713  }
7714  let message = `Invalid prop: type check failed for prop "${name}". Expected ${expectedTypes.map(capitalize).join(" | ")}`;
7715  const expectedType = expectedTypes[0];
7716  const receivedType = toRawType(value);
7717  const expectedValue = styleValue(value, expectedType);
7718  const receivedValue = styleValue(value, receivedType);
7719  if (expectedTypes.length === 1 && isExplicable(expectedType) && !isBoolean(expectedType, receivedType)) {
7720    message += ` with value ${expectedValue}`;
7721  }
7722  message += `, got ${receivedType} `;
7723  if (isExplicable(receivedType)) {
7724    message += `with value ${receivedValue}.`;
7725  }
7726  return message;
7727}
7728function styleValue(value, type) {
7729  if (type === "String") {
7730    return `"${value}"`;
7731  } else if (type === "Number") {
7732    return `${Number(value)}`;
7733  } else {
7734    return `${value}`;
7735  }
7736}
7737function isExplicable(type) {
7738  const explicitTypes = ["string", "number", "boolean"];
7739  return explicitTypes.some((elem) => type.toLowerCase() === elem);
7740}
7741function isBoolean(...args) {
7742  return args.some((elem) => elem.toLowerCase() === "boolean");
7743}
7744
7745const isInternalKey = (key) =>
vendor: 4,106 bytes, lines 7745-7880
7745 key === "_" || key === "_ctx" || key === "$stable";
7746const normalizeSlotValue = (value) => shared_esm_bundler_isArray(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
7747const normalizeSlot = (key, rawSlot, ctx) => {
7748  if (rawSlot._n) {
7749    return rawSlot;
7750  }
7751  const normalized = withCtx((...args) => {
7752    if (false) // removed by dead control flow
7753{}
7754    return normalizeSlotValue(rawSlot(...args));
7755  }, ctx);
7756  normalized._c = false;
7757  return normalized;
7758};
7759const normalizeObjectSlots = (rawSlots, slots, instance) => {
7760  const ctx = rawSlots._ctx;
7761  for (const key in rawSlots) {
7762    if (isInternalKey(key)) continue;
7763    const value = rawSlots[key];
7764    if (shared_esm_bundler_isFunction(value)) {
7765      slots[key] = normalizeSlot(key, value, ctx);
7766    } else if (value != null) {
7767      if (false) // removed by dead control flow
7768{}
7769      const normalized = normalizeSlotValue(value);
7770      slots[key] = () => normalized;
7771    }
7772  }
7773};
7774const normalizeVNodeSlots = (instance, children) => {
7775  if (false) // removed by dead control flow
7776{}
7777  const normalized = normalizeSlotValue(children);
7778  instance.slots.default = () => normalized;
7779};
7780const assignSlots = (slots, children, optimized) => {
7781  for (const key in children) {
7782    if (optimized || !isInternalKey(key)) {
7783      slots[key] = children[key];
7784    }
7785  }
7786};
7787const initSlots = (instance, children, optimized) => {
7788  const slots = instance.slots = createInternalObject();
7789  if (instance.vnode.shapeFlag & 32) {
7790    const type = children._;
7791    if (type) {
7792      assignSlots(slots, children, optimized);
7793      if (optimized) {
7794        def(slots, "_", type, true);
7795      }
7796    } else {
7797      normalizeObjectSlots(children, slots);
7798    }
7799  } else if (children) {
7800    normalizeVNodeSlots(instance, children);
7801  }
7802};
7803const updateSlots = (instance, children, optimized) => {
7804  const { vnode, slots } = instance;
7805  let needDeletionCheck = true;
7806  let deletionComparisonTarget = EMPTY_OBJ;
7807  if (vnode.shapeFlag & 32) {
7808    const type = children._;
7809    if (type) {
7810      if (false) // removed by dead control flow
7811{} else if (optimized && type === 1) {
7812        needDeletionCheck = false;
7813      } else {
7814        assignSlots(slots, children, optimized);
7815      }
7816    } else {
7817      needDeletionCheck = !children.$stable;
7818      normalizeObjectSlots(children, slots);
7819    }
7820    deletionComparisonTarget = children;
7821  } else if (children) {
7822    normalizeVNodeSlots(instance, children);
7823    deletionComparisonTarget = { default: 1 };
7824  }
7825  if (needDeletionCheck) {
7826    for (const key in slots) {
7827      if (!isInternalKey(key) && deletionComparisonTarget[key] == null) {
7828        delete slots[key];
7829      }
7830    }
7831  }
7832};
7833
7834let supported;
7835let perf;
7836function startMeasure(instance, type) {
7837  if (instance.appContext.config.performance && isSupported()) {
7838    perf.mark(`vue-${type}-${instance.uid}`);
7839  }
7840  if ( false || __VUE_PROD_DEVTOOLS__) {
7841    devtoolsPerfStart(instance, type, isSupported() ? perf.now() : Date.now());
7842  }
7843}
7844function endMeasure(instance, type) {
7845  if (instance.appContext.config.performance && isSupported()) {
7846    const startTag = `vue-${type}-${instance.uid}`;
7847    const endTag = startTag + `:end`;
7848    const measureName = `<${formatComponentName(instance, instance.type)}> ${type}`;
7849    perf.mark(endTag);
7850    perf.measure(measureName, startTag, endTag);
7851    perf.clearMeasures(measureName);
7852    perf.clearMarks(startTag);
7853    perf.clearMarks(endTag);
7854  }
7855  if ( false || __VUE_PROD_DEVTOOLS__) {
7856    devtoolsPerfEnd(instance, type, isSupported() ? perf.now() : Date.now());
7857  }
7858}
7859function isSupported() {
7860  if (supported !== void 0) {
7861    return supported;
7862  }
7863  if (typeof window !== "undefined" && window.performance) {
7864    supported = true;
7865    perf = window.performance;
7866  } else {
7867    supported = false;
7868  }
7869  return supported;
7870}
7871
7872function initFeatureFlags() {
7873  const needWarn = [];
7874  if (typeof __VUE_OPTIONS_API__ !== "boolean") {
7875     false && 0;
7876    getGlobalThis().__VUE_OPTIONS_API__ = true;
7877  }
7878  if (typeof __VUE_PROD_DEVTOOLS__ !== "boolean") {
7879     false && 0;
7880    getGlobalThis().__VUE_PROD_DEVTOOLS__ = false;
7881  }
7882  if (typeof __VUE_PROD_HYDRATION_MISMATCH_DETAILS__ !== "boolean") {
7883     false && 0;
7884    getGlobalThis().__VUE_PROD_HYDRATION_MISMATCH_DETAILS__ = false;
7885  }
7886  if (false) // removed by dead control flow
7887{}
7888}
7889
7890const queuePostRenderEffect = queueEffectWithSuspense ;
7891function createRenderer(options) {
7892  return baseCreateRenderer(options);
7893}
7894function createHydrationRenderer(options) {
7895  return baseCreateRenderer(options, createHydrationFunctions);
7896}
7897function baseCreateRenderer(options, createHydrationFns) {
7898  {
7899    initFeatureFlags();
7900  }
7901  const target = getGlobalThis();
7902  target.__VUE__ = true;
7903  if ( false || __VUE_PROD_DEVTOOLS__) {
7904    setDevtoolsHook$1(target.__VUE_DEVTOOLS_GLOBAL_HOOK__, target);
7905  }
7906  const {
7907    insert: hostInsert,
7908    remove: hostRemove,
7909    patchProp: hostPatchProp,
7910    createElement: hostCreateElement,
7911    createText: hostCreateText,
7912    createComment: hostCreateComment,
7913    setText: hostSetText,
7914    setElementText: hostSetElementText,
7915    parentNode: hostParentNode,
7916    nextSibling: hostNextSibling,
7917    setScopeId: hostSetScopeId = shared_esm_bundler_NOOP,
7918    insertStaticContent: hostInsertStaticContent
7919  } = options;
7920  const patch = (n1, n2, container, anchor = null, parentComponent = null, parentSuspense = null, namespace = void 0, slotScopeIds = null, optimized =  false ? 0 : !!n2.dynamicChildren) => {
7921    if (n1 === n2) {
7922      return;
7923    }
7924    if (n1 && !isSameVNodeType(n1, n2)) {
7925      anchor = getNextHostNode(n1);
7926      unmount(n1, parentComponent, parentSuspense, true);
7927      n1 = null;
7928    }
7929    if (n2.patchFlag === -2) {
7930      optimized = false;
7931      n2.dynamicChildren = null;
7932    }
7933    const { type, ref, shapeFlag } = n2;
7934    switch (type) {
7935      case Text:
7936        processText(n1, n2, container, anchor);
7937        break;
7938      case Comment:
7939        processCommentNode(n1, n2, container, anchor);
7940        break;
7941      case Static:
7942        if (n1 == null) {
7943          mountStaticNode(n2, container, anchor, namespace);
7944        } else if (false) // removed by dead control flow
7945{}
7946        break;
7947      case Fragment:
7948        processFragment(
7949          n1,
7950          n2,
7951          container,
7952          anchor,
7953          parentComponent,
7954          parentSuspense,
7955          namespace,
7956          slotScopeIds,
7957          optimized
7958        );
7959        break;
7960      default:
7961        if (shapeFlag & 1) {
7962          processElement(
7963            n1,
7964            n2,
7965            container,
7966            anchor,
7967            parentComponent,
7968            parentSuspense,
7969            namespace,
7970            slotScopeIds,
7971            optimized
7972          );
7973        } else if (shapeFlag & 6) {
7974          processComponent(
7975            n1,
7976            n2,
7977            container,
7978            anchor,
7979            parentComponent,
7980            parentSuspense,
7981            namespace,
7982            slotScopeIds,
7983            optimized
7984          );
7985        } else if (shapeFlag & 64) {
7986          type.process(
7987            n1,
7988            n2,
7989            container,
7990            anchor,
7991            parentComponent,
7992            parentSuspense,
7993            namespace,
7994            slotScopeIds,
7995            optimized,
7996            internals
7997          );
7998        } else if (shapeFlag & 128) {
7999          type.process(
8000            n1,
8001            n2,
8002            container,
8003            anchor,
8004            parentComponent,
8005            parentSuspense,
8006            namespace,
8007            slotScopeIds,
8008            optimized,
8009            internals
8010          );
8011        } else if (false) // removed by dead control flow
8012{}
8013    }
8014    if (ref != null && parentComponent) {
8015      setRef(ref, n1 && n1.ref, parentSuspense, n2 || n1, !n2);
8016    } else if (ref == null && n1 && n1.ref != null) {
8017      setRef(n1.ref, null, parentSuspense, n1, true);
8018    }
8019  };
8020  const processText = (n1, n2, container, anchor) => {
8021    if (n1 == null) {
8022      hostInsert(
8023        n2.el = hostCreateText(n2.children),
8024        container,
8025        anchor
8026      );
8027    } else {
8028      const el = n2.el = n1.el;
8029      if (n2.children !== n1.children) {
8030        hostSetText(el, n2.children);
8031      }
8032    }
8033  };
8034  const processCommentNode = (n1, n2, container, anchor) => {
8035    if (n1 == null) {
8036      hostInsert(
8037        n2.el = hostCreateComment(n2.children || ""),
8038        container,
8039        anchor
8040      );
8041    } else {
8042      n2.el = n1.el;
8043    }
8044  };
vendor: 4,581 bytes, lines 8045-8201
8045  const mountStaticNode = (n2, container, anchor, namespace) => {
8046    [n2.el, n2.anchor] = hostInsertStaticContent(
8047      n2.children,
8048      container,
8049      anchor,
8050      namespace,
8051      n2.el,
8052      n2.anchor
8053    );
8054  };
8055  const patchStaticNode = (n1, n2, container, namespace) => {
8056    if (n2.children !== n1.children) {
8057      const anchor = hostNextSibling(n1.anchor);
8058      removeStaticNode(n1);
8059      [n2.el, n2.anchor] = hostInsertStaticContent(
8060        n2.children,
8061        container,
8062        anchor,
8063        namespace
8064      );
8065    } else {
8066      n2.el = n1.el;
8067      n2.anchor = n1.anchor;
8068    }
8069  };
8070  const moveStaticNode = ({ el, anchor }, container, nextSibling) => {
8071    let next;
8072    while (el && el !== anchor) {
8073      next = hostNextSibling(el);
8074      hostInsert(el, container, nextSibling);
8075      el = next;
8076    }
8077    hostInsert(anchor, container, nextSibling);
8078  };
8079  const removeStaticNode = ({ el, anchor }) => {
8080    let next;
8081    while (el && el !== anchor) {
8082      next = hostNextSibling(el);
8083      hostRemove(el);
8084      el = next;
8085    }
8086    hostRemove(anchor);
8087  };
8088  const processElement = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
8089    if (n2.type === "svg") {
8090      namespace = "svg";
8091    } else if (n2.type === "math") {
8092      namespace = "mathml";
8093    }
8094    if (n1 == null) {
8095      mountElement(
8096        n2,
8097        container,
8098        anchor,
8099        parentComponent,
8100        parentSuspense,
8101        namespace,
8102        slotScopeIds,
8103        optimized
8104      );
8105    } else {
8106      const customElement = !!(n1.el && n1.el._isVueCE) ? n1.el : null;
8107      try {
8108        if (customElement) {
8109          customElement._beginPatch();
8110        }
8111        patchElement(
8112          n1,
8113          n2,
8114          parentComponent,
8115          parentSuspense,
8116          namespace,
8117          slotScopeIds,
8118          optimized
8119        );
8120      } finally {
8121        if (customElement) {
8122          customElement._endPatch();
8123        }
8124      }
8125    }
8126  };
8127  const mountElement = (vnode, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
8128    let el;
8129    let vnodeHook;
8130    const { props, shapeFlag, transition, dirs } = vnode;
8131    el = vnode.el = hostCreateElement(
8132      vnode.type,
8133      namespace,
8134      props && props.is,
8135      props
8136    );
8137    if (shapeFlag & 8) {
8138      hostSetElementText(el, vnode.children);
8139    } else if (shapeFlag & 16) {
8140      mountChildren(
8141        vnode.children,
8142        el,
8143        null,
8144        parentComponent,
8145        parentSuspense,
8146        resolveChildrenNamespace(vnode, namespace),
8147        slotScopeIds,
8148        optimized
8149      );
8150    }
8151    if (dirs) {
8152      invokeDirectiveHook(vnode, null, parentComponent, "created");
8153    }
8154    setScopeId(el, vnode, vnode.scopeId, slotScopeIds, parentComponent);
8155    if (props) {
8156      for (const key in props) {
8157        if (key !== "value" && !isReservedProp(key)) {
8158          hostPatchProp(el, key, null, props[key], namespace, parentComponent);
8159        }
8160      }
8161      if ("value" in props) {
8162        hostPatchProp(el, "value", null, props.value, namespace);
8163      }
8164      if (vnodeHook = props.onVnodeBeforeMount) {
8165        invokeVNodeHook(vnodeHook, parentComponent, vnode);
8166      }
8167    }
8168    if ( false || __VUE_PROD_DEVTOOLS__) {
8169      def(el, "__vnode", vnode, true);
8170      def(el, "__vueParentComponent", parentComponent, true);
8171    }
8172    if (dirs) {
8173      invokeDirectiveHook(vnode, null, parentComponent, "beforeMount");
8174    }
8175    const needCallTransitionHooks = needTransition(parentSuspense, transition);
8176    if (needCallTransitionHooks) {
8177      transition.beforeEnter(el);
8178    }
8179    hostInsert(el, container, anchor);
8180    if ((vnodeHook = props && props.onVnodeMounted) || needCallTransitionHooks || dirs) {
8181      queuePostRenderEffect(() => {
8182        vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
8183        needCallTransitionHooks && transition.enter(el);
8184        dirs && invokeDirectiveHook(vnode, null, parentComponent, "mounted");
8185      }, parentSuspense);
8186    }
8187  };
8188  const setScopeId = (el, vnode, scopeId, slotScopeIds, parentComponent) => {
8189    if (scopeId) {
8190      hostSetScopeId(el, scopeId);
8191    }
8192    if (slotScopeIds) {
8193      for (let i = 0; i < slotScopeIds.length; i++) {
8194        hostSetScopeId(el, slotScopeIds[i]);
8195      }
8196    }
8197    if (parentComponent) {
8198      let subTree = parentComponent.subTree;
8199      if (false) // removed by dead control flow
8200{}
8201      if (vnode === subTree || isSuspense(subTree.type) && (subTree.ssContent === vnode || subTree.ss
vendor: 5,073 bytes, lines 8201-8347
8201Fallback === vnode)) {
8202        const parentVNode = parentComponent.vnode;
8203        setScopeId(
8204          el,
8205          parentVNode,
8206          parentVNode.scopeId,
8207          parentVNode.slotScopeIds,
8208          parentComponent.parent
8209        );
8210      }
8211    }
8212  };
8213  const mountChildren = (children, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, start = 0) => {
8214    for (let i = start; i < children.length; i++) {
8215      const child = children[i] = optimized ? cloneIfMounted(children[i]) : normalizeVNode(children[i]);
8216      patch(
8217        null,
8218        child,
8219        container,
8220        anchor,
8221        parentComponent,
8222        parentSuspense,
8223        namespace,
8224        slotScopeIds,
8225        optimized
8226      );
8227    }
8228  };
8229  const patchElement = (n1, n2, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
8230    const el = n2.el = n1.el;
8231    if ( false || __VUE_PROD_DEVTOOLS__) {
8232      el.__vnode = n2;
8233    }
8234    let { patchFlag, dynamicChildren, dirs } = n2;
8235    patchFlag |= n1.patchFlag & 16;
8236    const oldProps = n1.props || EMPTY_OBJ;
8237    const newProps = n2.props || EMPTY_OBJ;
8238    let vnodeHook;
8239    parentComponent && toggleRecurse(parentComponent, false);
8240    if (vnodeHook = newProps.onVnodeBeforeUpdate) {
8241      invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
8242    }
8243    if (dirs) {
8244      invokeDirectiveHook(n2, n1, parentComponent, "beforeUpdate");
8245    }
8246    parentComponent && toggleRecurse(parentComponent, true);
8247    if (false) // removed by dead control flow
8248{}
8249    if (oldProps.innerHTML && newProps.innerHTML == null || oldProps.textContent && newProps.textContent == null) {
8250      hostSetElementText(el, "");
8251    }
8252    if (dynamicChildren) {
8253      patchBlockChildren(
8254        n1.dynamicChildren,
8255        dynamicChildren,
8256        el,
8257        parentComponent,
8258        parentSuspense,
8259        resolveChildrenNamespace(n2, namespace),
8260        slotScopeIds
8261      );
8262      if (false) // removed by dead control flow
8263{}
8264    } else if (!optimized) {
8265      patchChildren(
8266        n1,
8267        n2,
8268        el,
8269        null,
8270        parentComponent,
8271        parentSuspense,
8272        resolveChildrenNamespace(n2, namespace),
8273        slotScopeIds,
8274        false
8275      );
8276    }
8277    if (patchFlag > 0) {
8278      if (patchFlag & 16) {
8279        patchProps(el, oldProps, newProps, parentComponent, namespace);
8280      } else {
8281        if (patchFlag & 2) {
8282          if (oldProps.class !== newProps.class) {
8283            hostPatchProp(el, "class", null, newProps.class, namespace);
8284          }
8285        }
8286        if (patchFlag & 4) {
8287          hostPatchProp(el, "style", oldProps.style, newProps.style, namespace);
8288        }
8289        if (patchFlag & 8) {
8290          const propsToUpdate = n2.dynamicProps;
8291          for (let i = 0; i < propsToUpdate.length; i++) {
8292            const key = propsToUpdate[i];
8293            const prev = oldProps[key];
8294            const next = newProps[key];
8295            if (next !== prev || key === "value") {
8296              hostPatchProp(el, key, prev, next, namespace, parentComponent);
8297            }
8298          }
8299        }
8300      }
8301      if (patchFlag & 1) {
8302        if (n1.children !== n2.children) {
8303          hostSetElementText(el, n2.children);
8304        }
8305      }
8306    } else if (!optimized && dynamicChildren == null) {
8307      patchProps(el, oldProps, newProps, parentComponent, namespace);
8308    }
8309    if ((vnodeHook = newProps.onVnodeUpdated) || dirs) {
8310      queuePostRenderEffect(() => {
8311        vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
8312        dirs && invokeDirectiveHook(n2, n1, parentComponent, "updated");
8313      }, parentSuspense);
8314    }
8315  };
8316  const patchBlockChildren = (oldChildren, newChildren, fallbackContainer, parentComponent, parentSuspense, namespace, slotScopeIds) => {
8317    for (let i = 0; i < newChildren.length; i++) {
8318      const oldVNode = oldChildren[i];
8319      const newVNode = newChildren[i];
8320      const container = (
8321        // oldVNode may be an errored async setup() component inside Suspense
8322        // which will not have a mounted element
8323        oldVNode.el && // - In the case of a Fragment, we need to provide the actual parent
8324        // of the Fragment itself so it can move its children.
8325        (oldVNode.type === Fragment || // - In the case of different nodes, there is going to be a replacement
8326        // which also requires the correct parent container
8327        !isSameVNodeType(oldVNode, newVNode) || // - In the case of a component, it could contain anything.
8328        oldVNode.shapeFlag & (6 | 64 | 128)) ? hostParentNode(oldVNode.el) : (
8329          // In other cases, the parent container is not actually used so we
8330          // just pass the block element here to avoid a DOM parentNode call.
8331          fallbackContainer
8332        )
8333      );
8334      patch(
8335        oldVNode,
8336        newVNode,
8337        container,
8338        null,
8339        parentComponent,
8340        parentSuspense,
8341        namespace,
8342        slotScopeIds,
8343        true
8344      );
8345    }
8346  };
8347  const patchProps = (el, oldProps, newProps, parentComponent, namespace) 
8347=> {
8348    if (oldProps !== newProps) {
8349      if (oldProps !== EMPTY_OBJ) {
8350        for (const key in oldProps) {
8351          if (!isReservedProp(key) && !(key in newProps)) {
8352            hostPatchProp(
8353              el,
8354              key,
8355              oldProps[key],
8356              null,
8357              namespace,
8358              parentComponent
8359            );
8360          }
8361        }
8362      }
8363      for (const key in newProps) {
8364        if (isReservedProp(key)) continue;
8365        const next = newProps[key];
8366        const prev = oldProps[key];
8367        if (next !== prev && key !== "value") {
8368          hostPatchProp(el, key, prev, next, namespace, parentComponent);
8369        }
8370      }
8371      if ("value" in newProps) {
8372        hostPatchProp(el, "value", oldProps.value, newProps.value, namespace);
8373      }
8374    }
8375  };
8376  const processFragment = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
8377    const fragmentStartAnchor = n2.el = n1 ? n1.el : hostCreateText("");
8378    const fragmentEndAnchor = n2.anchor = n1 ? n1.anchor : hostCreateText("");
8379    let { patchFlag, dynamicChildren, slotScopeIds: fragmentSlotScopeIds } = n2;
8380    if (false) // removed by dead control flow
8381{}
8382    if (fragmentSlotScopeIds) {
8383      slotScopeIds = slotScopeIds ? slotScopeIds.concat(fragmentSlotScopeIds) : fragmentSlotScopeIds;
8384    }
8385    if (n1 == null) {
8386      hostInsert(fragmentStartAnchor, container, anchor);
8387      hostInsert(fragmentEndAnchor, container, anchor);
8388      mountChildren(
8389        // #10007
8390        // such fragment like `<></>` will be compiled into
8391        // a fragment which doesn't have a children.
8392        // In this case fallback to an empty array
8393        n2.children || [],
8394        container,
8395        fragmentEndAnchor,
8396        parentComponent,
8397        parentSuspense,
8398        namespace,
8399        slotScopeIds,
8400        optimized
8401      );
8402    } else {
8403      if (patchFlag > 0 && patchFlag & 64 && dynamicChildren && // #2715 the previous fragment could've been a BAILed one as a result
8404      // of renderSlot() with no valid children
8405      n1.dynamicChildren) {
8406        patchBlockChildren(
8407          n1.dynamicChildren,
8408          dynamicChildren,
8409          container,
8410          parentComponent,
8411          parentSuspense,
8412          namespace,
8413          slotScopeIds
8414        );
8415        if (false) // removed by dead control flow
8416{} else if (
8417          // #2080 if the stable fragment has a key, it's a <template v-for> that may
8418          //  get moved around. Make sure all root level vnodes inherit el.
8419          // #2134 or if it's a component root, it may also get moved around
8420          // as the component is being moved.
8421          n2.key != null || parentComponent && n2 === parentComponent.subTree
8422        ) {
8423          traverseStaticChildren(
8424            n1,
8425            n2,
8426            true
8427            /* shallow */
8428          );
8429        }
8430      } else {
8431        patchChildren(
8432          n1,
8433          n2,
8434          container,
8435          fragmentEndAnchor,
8436          parentComponent,
8437          parentSuspense,
8438          namespace,
8439          slotScopeIds,
8440          optimized
8441        );
8442      }
8443    }
8444  };
8445  const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
8446    n2.slotScopeIds = slotScopeIds;
8447    if (n1 == null) {
8448      if (n2.shapeFlag & 512) {
8449        parentComponent.ctx.activate(
8450          n2,
8451          container,
8452          anchor,
8453          namespace,
8454          optimized
8455        );
8456      } else {
8457        mountComponent(
8458          n2,
8459          container,
8460          anchor,
8461          parentComponent,
8462          parentSuspense,
8463          namespace,
8464          optimized
8465        );
8466      }
8467    } else {
8468      updateComponent(n1, n2, optimized);
8469    }
8470  };
8471  const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, namespace, optimized) => {
8472    const instance = (initialVNode.component = createComponentInstance(
8473      initialVNode,
8474      parentComponent,
8475      parentSuspense
8476    ));
8477    if (false) // removed by dead control flow
8478{}
8479    if (false) // removed by dead control flow
8480{}
8481    if (isKeepAlive(initialVNode)) {
8482      instance.ctx.renderer = internals;
8483    }
8484    {
8485      if (false) // removed by dead control flow
8486{}
8487      setupComponent(instance, false, optimized);
8488      if (false) // removed by dead control flow
8489{}
8490    }
8491    if (false) // removed by dead control flow
8492{}
8493    if (instance.asyncDep) {
8494      parentSuspense && parentSuspense.registerDep(instance, setupRenderEffect, optimized);
8495      if (!initialVNode.el) {
8496        const placeholder = instance.subTree = createVNode(Comment);
8497        processCommentNode(null, placeholder, container, anchor);
8498        initialVNode.placeholder = placeholder.el;
8499      }
8500    } else {
8501      setupRenderEffect(
8502        instance,
8503        initialVNode,
8504        container,
8505        anchor,
8506        parentSuspense,
8507        namespace,
8508        optimized
8509      );
8510    }
8511    if (false) // removed by dead control flow
8512{}
8513  };
8514  const updateComponent = (n1, n2, optimized) => {
8515    const instance = n2.component = n1.component;
8516    if (shouldUpdateComponent(n1, n2, optimized)) {
8517      if (instance.asyncDep && !instance.asyncResolved) {
8518        if (false) // removed by dead control flow
8519{}
8520        updateComponentPreRender(instance, n2, optimized);
8521        if (false) // removed by dead control flow
8522{}
8523        return;
8524      } else {
8525        instance.next = n2;
vendor: 11,013 bytes, lines 8526-8913
8526        instance.update();
8527      }
8528    } else {
8529      n2.el = n1.el;
8530      instance.vnode = n2;
8531    }
8532  };
8533  const setupRenderEffect = (instance, initialVNode, container, anchor, parentSuspense, namespace, optimized) => {
8534    const componentUpdateFn = () => {
8535      if (!instance.isMounted) {
8536        let vnodeHook;
8537        const { el, props } = initialVNode;
8538        const { bm, m, parent, root, type } = instance;
8539        const isAsyncWrapperVNode = isAsyncWrapper(initialVNode);
8540        toggleRecurse(instance, false);
8541        if (bm) {
8542          invokeArrayFns(bm);
8543        }
8544        if (!isAsyncWrapperVNode && (vnodeHook = props && props.onVnodeBeforeMount)) {
8545          invokeVNodeHook(vnodeHook, parent, initialVNode);
8546        }
8547        toggleRecurse(instance, true);
8548        if (el && hydrateNode) {
8549          const hydrateSubTree = () => {
8550            if (false) // removed by dead control flow
8551{}
8552            instance.subTree = renderComponentRoot(instance);
8553            if (false) // removed by dead control flow
8554{}
8555            if (false) // removed by dead control flow
8556{}
8557            hydrateNode(
8558              el,
8559              instance.subTree,
8560              instance,
8561              parentSuspense,
8562              null
8563            );
8564            if (false) // removed by dead control flow
8565{}
8566          };
8567          if (isAsyncWrapperVNode && type.__asyncHydrate) {
8568            type.__asyncHydrate(
8569              el,
8570              instance,
8571              hydrateSubTree
8572            );
8573          } else {
8574            hydrateSubTree();
8575          }
8576        } else {
8577          if (root.ce && // @ts-expect-error _def is private
8578          root.ce._def.shadowRoot !== false) {
8579            root.ce._injectChildStyle(type);
8580          }
8581          if (false) // removed by dead control flow
8582{}
8583          const subTree = instance.subTree = renderComponentRoot(instance);
8584          if (false) // removed by dead control flow
8585{}
8586          if (false) // removed by dead control flow
8587{}
8588          patch(
8589            null,
8590            subTree,
8591            container,
8592            anchor,
8593            instance,
8594            parentSuspense,
8595            namespace
8596          );
8597          if (false) // removed by dead control flow
8598{}
8599          initialVNode.el = subTree.el;
8600        }
8601        if (m) {
8602          queuePostRenderEffect(m, parentSuspense);
8603        }
8604        if (!isAsyncWrapperVNode && (vnodeHook = props && props.onVnodeMounted)) {
8605          const scopedInitialVNode = initialVNode;
8606          queuePostRenderEffect(
8607            () => invokeVNodeHook(vnodeHook, parent, scopedInitialVNode),
8608            parentSuspense
8609          );
8610        }
8611        if (initialVNode.shapeFlag & 256 || parent && isAsyncWrapper(parent.vnode) && parent.vnode.shapeFlag & 256) {
8612          instance.a && queuePostRenderEffect(instance.a, parentSuspense);
8613        }
8614        instance.isMounted = true;
8615        if ( false || __VUE_PROD_DEVTOOLS__) {
8616          devtoolsComponentAdded(instance);
8617        }
8618        initialVNode = container = anchor = null;
8619      } else {
8620        let { next, bu, u, parent, vnode } = instance;
8621        {
8622          const nonHydratedAsyncRoot = locateNonHydratedAsyncRoot(instance);
8623          if (nonHydratedAsyncRoot) {
8624            if (next) {
8625              next.el = vnode.el;
8626              updateComponentPreRender(instance, next, optimized);
8627            }
8628            nonHydratedAsyncRoot.asyncDep.then(() => {
8629              if (!instance.isUnmounted) {
8630                componentUpdateFn();
8631              }
8632            });
8633            return;
8634          }
8635        }
8636        let originNext = next;
8637        let vnodeHook;
8638        if (false) // removed by dead control flow
8639{}
8640        toggleRecurse(instance, false);
8641        if (next) {
8642          next.el = vnode.el;
8643          updateComponentPreRender(instance, next, optimized);
8644        } else {
8645          next = vnode;
8646        }
8647        if (bu) {
8648          invokeArrayFns(bu);
8649        }
8650        if (vnodeHook = next.props && next.props.onVnodeBeforeUpdate) {
8651          invokeVNodeHook(vnodeHook, parent, next, vnode);
8652        }
8653        toggleRecurse(instance, true);
8654        if (false) // removed by dead control flow
8655{}
8656        const nextTree = renderComponentRoot(instance);
8657        if (false) // removed by dead control flow
8658{}
8659        const prevTree = instance.subTree;
8660        instance.subTree = nextTree;
8661        if (false) // removed by dead control flow
8662{}
8663        patch(
8664          prevTree,
8665          nextTree,
8666          // parent may have changed if it's in a teleport
8667          hostParentNode(prevTree.el),
8668          // anchor may have changed if it's in a fragment
8669          getNextHostNode(prevTree),
8670          instance,
8671          parentSuspense,
8672          namespace
8673        );
8674        if (false) // removed by dead control flow
8675{}
8676        next.el = nextTree.el;
8677        if (originNext === null) {
8678          updateHOCHostEl(instance, nextTree.el);
8679        }
8680        if (u) {
8681          queuePostRenderEffect(u, parentSuspense);
8682        }
8683        if (vnodeHook = next.props && next.props.onVnodeUpdated) {
8684          queuePostRenderEffect(
8685            () => invokeVNodeHook(vnodeHook, parent, next, vnode),
8686            parentSuspense
8687          );
8688        }
8689        if ( false || __VUE_PROD_DEVTOOLS__) {
8690          devtoolsComponentUpdated(instance);
8691        }
8692        if (false) // removed by dead control flow
8693{}
8694      }
8695    };
8696    instance.scope.on();
8697    const effect = instance.effect = new ReactiveEffect(componentUpdateFn);
8698    instance.scope.off();
8699    const update = instance.update = effect.run.bind(effect);
8700    const job = instance.job = effect.runIfDirty.bind(effect);
8701    job.i = instance;
8702    job.id = instance.uid;
8703    effect.scheduler = () => queueJob(job);
8704    toggleRecurse(instance, true);
8705    if (false) // removed by dead control flow
8706{}
8707    update();
8708  };
8709  const updateComponentPreRender = (instance, nextVNode, optimized) => {
8710    nextVNode.component = instance;
8711    const prevProps = instance.vnode.props;
8712    instance.vnode = nextVNode;
8713    instance.next = null;
8714    updateProps(instance, nextVNode.props, prevProps, optimized);
8715    updateSlots(instance, nextVNode.children, optimized);
8716    pauseTracking();
8717    flushPreFlushCbs(instance);
8718    resetTracking();
8719  };
8720  const patchChildren = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized = false) => {
8721    const c1 = n1 && n1.children;
8722    const prevShapeFlag = n1 ? n1.shapeFlag : 0;
8723    const c2 = n2.children;
8724    const { patchFlag, shapeFlag } = n2;
8725    if (patchFlag > 0) {
8726      if (patchFlag & 128) {
8727        patchKeyedChildren(
8728          c1,
8729          c2,
8730          container,
8731          anchor,
8732          parentComponent,
8733          parentSuspense,
8734          namespace,
8735          slotScopeIds,
8736          optimized
8737        );
8738        return;
8739      } else if (patchFlag & 256) {
8740        patchUnkeyedChildren(
8741          c1,
8742          c2,
8743          container,
8744          anchor,
8745          parentComponent,
8746          parentSuspense,
8747          namespace,
8748          slotScopeIds,
8749          optimized
8750        );
8751        return;
8752      }
8753    }
8754    if (shapeFlag & 8) {
8755      if (prevShapeFlag & 16) {
8756        unmountChildren(c1, parentComponent, parentSuspense);
8757      }
8758      if (c2 !== c1) {
8759        hostSetElementText(container, c2);
8760      }
8761    } else {
8762      if (prevShapeFlag & 16) {
8763        if (shapeFlag & 16) {
8764          patchKeyedChildren(
8765            c1,
8766            c2,
8767            container,
8768            anchor,
8769            parentComponent,
8770            parentSuspense,
8771            namespace,
8772            slotScopeIds,
8773            optimized
8774          );
8775        } else {
8776          unmountChildren(c1, parentComponent, parentSuspense, true);
8777        }
8778      } else {
8779        if (prevShapeFlag & 8) {
8780          hostSetElementText(container, "");
8781        }
8782        if (shapeFlag & 16) {
8783          mountChildren(
8784            c2,
8785            container,
8786            anchor,
8787            parentComponent,
8788            parentSuspense,
8789            namespace,
8790            slotScopeIds,
8791            optimized
8792          );
8793        }
8794      }
8795    }
8796  };
8797  const patchUnkeyedChildren = (c1, c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
8798    c1 = c1 || EMPTY_ARR;
8799    c2 = c2 || EMPTY_ARR;
8800    const oldLength = c1.length;
8801    const newLength = c2.length;
8802    const commonLength = Math.min(oldLength, newLength);
8803    let i;
8804    for (i = 0; i < commonLength; i++) {
8805      const nextChild = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
8806      patch(
8807        c1[i],
8808        nextChild,
8809        container,
8810        null,
8811        parentComponent,
8812        parentSuspense,
8813        namespace,
8814        slotScopeIds,
8815        optimized
8816      );
8817    }
8818    if (oldLength > newLength) {
8819      unmountChildren(
8820        c1,
8821        parentComponent,
8822        parentSuspense,
8823        true,
8824        false,
8825        commonLength
8826      );
8827    } else {
8828      mountChildren(
8829        c2,
8830        container,
8831        anchor,
8832        parentComponent,
8833        parentSuspense,
8834        namespace,
8835        slotScopeIds,
8836        optimized,
8837        commonLength
8838      );
8839    }
8840  };
8841  const patchKeyedChildren = (c1, c2, container, parentAnchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
8842    let i = 0;
8843    const l2 = c2.length;
8844    let e1 = c1.length - 1;
8845    let e2 = l2 - 1;
8846    while (i <= e1 && i <= e2) {
8847      const n1 = c1[i];
8848      const n2 = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
8849      if (isSameVNodeType(n1, n2)) {
8850        patch(
8851          n1,
8852          n2,
8853          container,
8854          null,
8855          parentComponent,
8856          parentSuspense,
8857          namespace,
8858          slotScopeIds,
8859          optimized
8860        );
8861      } else {
8862        break;
8863      }
8864      i++;
8865    }
8866    while (i <= e1 && i <= e2) {
8867      const n1 = c1[e1];
8868      const n2 = c2[e2] = optimized ? cloneIfMounted(c2[e2]) : normalizeVNode(c2[e2]);
8869      if (isSameVNodeType(n1, n2)) {
8870        patch(
8871          n1,
8872          n2,
8873          container,
8874          null,
8875          parentComponent,
8876          parentSuspense,
8877          namespace,
8878          slotScopeIds,
8879          optimized
8880        );
8881      } else {
8882        break;
8883      }
8884      e1--;
8885      e2--;
8886    }
8887    if (i > e1) {
8888      if (i <= e2) {
8889        const nextPos = e2 + 1;
8890        const anchor = nextPos < l2 ? c2[nextPos].el : parentAnchor;
8891        while (i <= e2) {
8892          patch(
8893            null,
8894            c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]),
8895            container,
8896            anchor,
8897            parentComponent,
8898            parentSuspense,
8899            namespace,
8900            slotScopeIds,
8901            optimized
8902          );
8903          i++;
8904        }
8905      }
8906    } else if (i > e2) {
8907      while (i <= e1) {
8908        unmount(c1[i], parentComponent, parentSuspense, true);
8909        i++;
8910      }
8911    } else {
8912      const s1 = i;
8913      const s2 = i;
vendor: 4,962 bytes, lines 8914-9078
8914      const keyToNewIndexMap = /* @__PURE__ */ new Map();
8915      for (i = s2; i <= e2; i++) {
8916        const nextChild = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
8917        if (nextChild.key != null) {
8918          if (false) // removed by dead control flow
8919{}
8920          keyToNewIndexMap.set(nextChild.key, i);
8921        }
8922      }
8923      let j;
8924      let patched = 0;
8925      const toBePatched = e2 - s2 + 1;
8926      let moved = false;
8927      let maxNewIndexSoFar = 0;
8928      const newIndexToOldIndexMap = new Array(toBePatched);
8929      for (i = 0; i < toBePatched; i++) newIndexToOldIndexMap[i] = 0;
8930      for (i = s1; i <= e1; i++) {
8931        const prevChild = c1[i];
8932        if (patched >= toBePatched) {
8933          unmount(prevChild, parentComponent, parentSuspense, true);
8934          continue;
8935        }
8936        let newIndex;
8937        if (prevChild.key != null) {
8938          newIndex = keyToNewIndexMap.get(prevChild.key);
8939        } else {
8940          for (j = s2; j <= e2; j++) {
8941            if (newIndexToOldIndexMap[j - s2] === 0 && isSameVNodeType(prevChild, c2[j])) {
8942              newIndex = j;
8943              break;
8944            }
8945          }
8946        }
8947        if (newIndex === void 0) {
8948          unmount(prevChild, parentComponent, parentSuspense, true);
8949        } else {
8950          newIndexToOldIndexMap[newIndex - s2] = i + 1;
8951          if (newIndex >= maxNewIndexSoFar) {
8952            maxNewIndexSoFar = newIndex;
8953          } else {
8954            moved = true;
8955          }
8956          patch(
8957            prevChild,
8958            c2[newIndex],
8959            container,
8960            null,
8961            parentComponent,
8962            parentSuspense,
8963            namespace,
8964            slotScopeIds,
8965            optimized
8966          );
8967          patched++;
8968        }
8969      }
8970      const increasingNewIndexSequence = moved ? getSequence(newIndexToOldIndexMap) : EMPTY_ARR;
8971      j = increasingNewIndexSequence.length - 1;
8972      for (i = toBePatched - 1; i >= 0; i--) {
8973        const nextIndex = s2 + i;
8974        const nextChild = c2[nextIndex];
8975        const anchorVNode = c2[nextIndex + 1];
8976        const anchor = nextIndex + 1 < l2 ? (
8977          // #13559, fallback to el placeholder for unresolved async component
8978          anchorVNode.el || anchorVNode.placeholder
8979        ) : parentAnchor;
8980        if (newIndexToOldIndexMap[i] === 0) {
8981          patch(
8982            null,
8983            nextChild,
8984            container,
8985            anchor,
8986            parentComponent,
8987            parentSuspense,
8988            namespace,
8989            slotScopeIds,
8990            optimized
8991          );
8992        } else if (moved) {
8993          if (j < 0 || i !== increasingNewIndexSequence[j]) {
8994            move(nextChild, container, anchor, 2);
8995          } else {
8996            j--;
8997          }
8998        }
8999      }
9000    }
9001  };
9002  const move = (vnode, container, anchor, moveType, parentSuspense = null) => {
9003    const { el, type, transition, children, shapeFlag } = vnode;
9004    if (shapeFlag & 6) {
9005      move(vnode.component.subTree, container, anchor, moveType);
9006      return;
9007    }
9008    if (shapeFlag & 128) {
9009      vnode.suspense.move(container, anchor, moveType);
9010      return;
9011    }
9012    if (shapeFlag & 64) {
9013      type.move(vnode, container, anchor, internals);
9014      return;
9015    }
9016    if (type === Fragment) {
9017      hostInsert(el, container, anchor);
9018      for (let i = 0; i < children.length; i++) {
9019        move(children[i], container, anchor, moveType);
9020      }
9021      hostInsert(vnode.anchor, container, anchor);
9022      return;
9023    }
9024    if (type === Static) {
9025      moveStaticNode(vnode, container, anchor);
9026      return;
9027    }
9028    const needTransition2 = moveType !== 2 && shapeFlag & 1 && transition;
9029    if (needTransition2) {
9030      if (moveType === 0) {
9031        transition.beforeEnter(el);
9032        hostInsert(el, container, anchor);
9033        queuePostRenderEffect(() => transition.enter(el), parentSuspense);
9034      } else {
9035        const { leave, delayLeave, afterLeave } = transition;
9036        const remove2 = () => {
9037          if (vnode.ctx.isUnmounted) {
9038            hostRemove(el);
9039          } else {
9040            hostInsert(el, container, anchor);
9041          }
9042        };
9043        const performLeave = () => {
9044          if (el._isLeaving) {
9045            el[leaveCbKey](
9046              true
9047              /* cancelled */
9048            );
9049          }
9050          leave(el, () => {
9051            remove2();
9052            afterLeave && afterLeave();
9053          });
9054        };
9055        if (delayLeave) {
9056          delayLeave(el, remove2, performLeave);
9057        } else {
9058          performLeave();
9059        }
9060      }
9061    } else {
9062      hostInsert(el, container, anchor);
9063    }
9064  };
9065  const unmount = (vnode, parentComponent, parentSuspense, doRemove = false, optimized = false) => {
9066    const {
9067      type,
9068      props,
9069      ref,
9070      children,
9071      dynamicChildren,
9072      shapeFlag,
9073      patchFlag,
9074      dirs,
9075      cacheIndex
9076    } = vnode;
9077    if (patchFlag === -2) {
9078      optimized = false;
vendor: 4,650 bytes, lines 9079-9224
9079    }
9080    if (ref != null) {
9081      pauseTracking();
9082      setRef(ref, null, parentSuspense, vnode, true);
9083      resetTracking();
9084    }
9085    if (cacheIndex != null) {
9086      parentComponent.renderCache[cacheIndex] = void 0;
9087    }
9088    if (shapeFlag & 256) {
9089      parentComponent.ctx.deactivate(vnode);
9090      return;
9091    }
9092    const shouldInvokeDirs = shapeFlag & 1 && dirs;
9093    const shouldInvokeVnodeHook = !isAsyncWrapper(vnode);
9094    let vnodeHook;
9095    if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeBeforeUnmount)) {
9096      invokeVNodeHook(vnodeHook, parentComponent, vnode);
9097    }
9098    if (shapeFlag & 6) {
9099      unmountComponent(vnode.component, parentSuspense, doRemove);
9100    } else {
9101      if (shapeFlag & 128) {
9102        vnode.suspense.unmount(parentSuspense, doRemove);
9103        return;
9104      }
9105      if (shouldInvokeDirs) {
9106        invokeDirectiveHook(vnode, null, parentComponent, "beforeUnmount");
9107      }
9108      if (shapeFlag & 64) {
9109        vnode.type.remove(
9110          vnode,
9111          parentComponent,
9112          parentSuspense,
9113          internals,
9114          doRemove
9115        );
9116      } else if (dynamicChildren && // #5154
9117      // when v-once is used inside a block, setBlockTracking(-1) marks the
9118      // parent block with hasOnce: true
9119      // so that it doesn't take the fast path during unmount - otherwise
9120      // components nested in v-once are never unmounted.
9121      !dynamicChildren.hasOnce && // #1153: fast path should not be taken for non-stable (v-for) fragments
9122      (type !== Fragment || patchFlag > 0 && patchFlag & 64)) {
9123        unmountChildren(
9124          dynamicChildren,
9125          parentComponent,
9126          parentSuspense,
9127          false,
9128          true
9129        );
9130      } else if (type === Fragment && patchFlag & (128 | 256) || !optimized && shapeFlag & 16) {
9131        unmountChildren(children, parentComponent, parentSuspense);
9132      }
9133      if (doRemove) {
9134        remove(vnode);
9135      }
9136    }
9137    if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeUnmounted) || shouldInvokeDirs) {
9138      queuePostRenderEffect(() => {
9139        vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
9140        shouldInvokeDirs && invokeDirectiveHook(vnode, null, parentComponent, "unmounted");
9141      }, parentSuspense);
9142    }
9143  };
9144  const remove = (vnode) => {
9145    const { type, el, anchor, transition } = vnode;
9146    if (type === Fragment) {
9147      if (false) // removed by dead control flow
9148{} else {
9149        removeFragment(el, anchor);
9150      }
9151      return;
9152    }
9153    if (type === Static) {
9154      removeStaticNode(vnode);
9155      return;
9156    }
9157    const performRemove = () => {
9158      hostRemove(el);
9159      if (transition && !transition.persisted && transition.afterLeave) {
9160        transition.afterLeave();
9161      }
9162    };
9163    if (vnode.shapeFlag & 1 && transition && !transition.persisted) {
9164      const { leave, delayLeave } = transition;
9165      const performLeave = () => leave(el, performRemove);
9166      if (delayLeave) {
9167        delayLeave(vnode.el, performRemove, performLeave);
9168      } else {
9169        performLeave();
9170      }
9171    } else {
9172      performRemove();
9173    }
9174  };
9175  const removeFragment = (cur, end) => {
9176    let next;
9177    while (cur !== end) {
9178      next = hostNextSibling(cur);
9179      hostRemove(cur);
9180      cur = next;
9181    }
9182    hostRemove(end);
9183  };
9184  const unmountComponent = (instance, parentSuspense, doRemove) => {
9185    if (false) // removed by dead control flow
9186{}
9187    const { bum, scope, job, subTree, um, m, a } = instance;
9188    invalidateMount(m);
9189    invalidateMount(a);
9190    if (bum) {
9191      invokeArrayFns(bum);
9192    }
9193    scope.stop();
9194    if (job) {
9195      job.flags |= 8;
9196      unmount(subTree, instance, parentSuspense, doRemove);
9197    }
9198    if (um) {
9199      queuePostRenderEffect(um, parentSuspense);
9200    }
9201    queuePostRenderEffect(() => {
9202      instance.isUnmounted = true;
9203    }, parentSuspense);
9204    if ( false || __VUE_PROD_DEVTOOLS__) {
9205      devtoolsComponentRemoved(instance);
9206    }
9207  };
9208  const unmountChildren = (children, parentComponent, parentSuspense, doRemove = false, optimized = false, start = 0) => {
9209    for (let i = start; i < children.length; i++) {
9210      unmount(children[i], parentComponent, parentSuspense, doRemove, optimized);
9211    }
9212  };
9213  const getNextHostNode = (vnode) => {
9214    if (vnode.shapeFlag & 6) {
9215      return getNextHostNode(vnode.component.subTree);
9216    }
9217    if (vnode.shapeFlag & 128) {
9218      return vnode.suspense.next();
9219    }
9220    const el = hostNextSibling(vnode.anchor || vnode.el);
9221    const teleportEnd = el && el[TeleportEndKey];
9222    return teleportEnd ? hostNextSibling(teleportEnd) : el;
9223  };
9224  let isFlushing = false;
vendor: 3,523 bytes, lines 9225-9365
9225  const render = (vnode, container, namespace) => {
9226    if (vnode == null) {
9227      if (container._vnode) {
9228        unmount(container._vnode, null, null, true);
9229      }
9230    } else {
9231      patch(
9232        container._vnode || null,
9233        vnode,
9234        container,
9235        null,
9236        null,
9237        null,
9238        namespace
9239      );
9240    }
9241    container._vnode = vnode;
9242    if (!isFlushing) {
9243      isFlushing = true;
9244      flushPreFlushCbs();
9245      flushPostFlushCbs();
9246      isFlushing = false;
9247    }
9248  };
9249  const internals = {
9250    p: patch,
9251    um: unmount,
9252    m: move,
9253    r: remove,
9254    mt: mountComponent,
9255    mc: mountChildren,
9256    pc: patchChildren,
9257    pbc: patchBlockChildren,
9258    n: getNextHostNode,
9259    o: options
9260  };
9261  let hydrate;
9262  let hydrateNode;
9263  if (createHydrationFns) {
9264    [hydrate, hydrateNode] = createHydrationFns(
9265      internals
9266    );
9267  }
9268  return {
9269    render,
9270    hydrate,
9271    createApp: createAppAPI(render, hydrate)
9272  };
9273}
9274function resolveChildrenNamespace({ type, props }, currentNamespace) {
9275  return currentNamespace === "svg" && type === "foreignObject" || currentNamespace === "mathml" && type === "annotation-xml" && props && props.encoding && props.encoding.includes("html") ? void 0 : currentNamespace;
9276}
9277function toggleRecurse({ effect, job }, allowed) {
9278  if (allowed) {
9279    effect.flags |= 32;
9280    job.flags |= 4;
9281  } else {
9282    effect.flags &= -33;
9283    job.flags &= -5;
9284  }
9285}
9286function needTransition(parentSuspense, transition) {
9287  return (!parentSuspense || parentSuspense && !parentSuspense.pendingBranch) && transition && !transition.persisted;
9288}
9289function traverseStaticChildren(n1, n2, shallow = false) {
9290  const ch1 = n1.children;
9291  const ch2 = n2.children;
9292  if (shared_esm_bundler_isArray(ch1) && shared_esm_bundler_isArray(ch2)) {
9293    for (let i = 0; i < ch1.length; i++) {
9294      const c1 = ch1[i];
9295      let c2 = ch2[i];
9296      if (c2.shapeFlag & 1 && !c2.dynamicChildren) {
9297        if (c2.patchFlag <= 0 || c2.patchFlag === 32) {
9298          c2 = ch2[i] = cloneIfMounted(ch2[i]);
9299          c2.el = c1.el;
9300        }
9301        if (!shallow && c2.patchFlag !== -2)
9302          traverseStaticChildren(c1, c2);
9303      }
9304      if (c2.type === Text && // avoid cached text nodes retaining detached dom nodes
9305      c2.patchFlag !== -1) {
9306        c2.el = c1.el;
9307      }
9308      if (c2.type === Comment && !c2.el) {
9309        c2.el = c1.el;
9310      }
9311      if (false) // removed by dead control flow
9312{}
9313    }
9314  }
9315}
9316function getSequence(arr) {
9317  const p = arr.slice();
9318  const result = [0];
9319  let i, j, u, v, c;
9320  const len = arr.length;
9321  for (i = 0; i < len; i++) {
9322    const arrI = arr[i];
9323    if (arrI !== 0) {
9324      j = result[result.length - 1];
9325      if (arr[j] < arrI) {
9326        p[i] = j;
9327        result.push(i);
9328        continue;
9329      }
9330      u = 0;
9331      v = result.length - 1;
9332      while (u < v) {
9333        c = u + v >> 1;
9334        if (arr[result[c]] < arrI) {
9335          u = c + 1;
9336        } else {
9337          v = c;
9338        }
9339      }
9340      if (arrI < arr[result[u]]) {
9341        if (u > 0) {
9342          p[i] = result[u - 1];
9343        }
9344        result[u] = i;
9345      }
9346    }
9347  }
9348  u = result.length;
9349  v = result[u - 1];
9350  while (u-- > 0) {
9351    result[u] = v;
9352    v = p[v];
9353  }
9354  return result;
9355}
9356function locateNonHydratedAsyncRoot(instance) {
9357  const subComponent = instance.subTree.component;
9358  if (subComponent) {
9359    if (subComponent.asyncDep && !subComponent.asyncResolved) {
9360      return subComponent;
9361    } else {
9362      return locateNonHydratedAsyncRoot(subComponent);
9363    }
9364  }
9365}
vendor: 3,786 bytes, lines 9366-9508
9366function invalidateMount(hooks) {
9367  if (hooks) {
9368    for (let i = 0; i < hooks.length; i++)
9369      hooks[i].flags |= 8;
9370  }
9371}
9372
9373const isSuspense = (type) => type.__isSuspense;
9374let suspenseId = 0;
9375const SuspenseImpl = {
9376  name: "Suspense",
9377  // In order to make Suspense tree-shakable, we need to avoid importing it
9378  // directly in the renderer. The renderer checks for the __isSuspense flag
9379  // on a vnode's type and calls the `process` method, passing in renderer
9380  // internals.
9381  __isSuspense: true,
9382  process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals) {
9383    if (n1 == null) {
9384      mountSuspense(
9385        n2,
9386        container,
9387        anchor,
9388        parentComponent,
9389        parentSuspense,
9390        namespace,
9391        slotScopeIds,
9392        optimized,
9393        rendererInternals
9394      );
9395    } else {
9396      if (parentSuspense && parentSuspense.deps > 0 && !n1.suspense.isInFallback) {
9397        n2.suspense = n1.suspense;
9398        n2.suspense.vnode = n2;
9399        n2.el = n1.el;
9400        return;
9401      }
9402      patchSuspense(
9403        n1,
9404        n2,
9405        container,
9406        anchor,
9407        parentComponent,
9408        namespace,
9409        slotScopeIds,
9410        optimized,
9411        rendererInternals
9412      );
9413    }
9414  },
9415  hydrate: hydrateSuspense,
9416  normalize: normalizeSuspenseChildren
9417};
9418const Suspense = SuspenseImpl ;
9419function triggerEvent(vnode, name) {
9420  const eventListener = vnode.props && vnode.props[name];
9421  if (shared_esm_bundler_isFunction(eventListener)) {
9422    eventListener();
9423  }
9424}
9425function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals) {
9426  const {
9427    p: patch,
9428    o: { createElement }
9429  } = rendererInternals;
9430  const hiddenContainer = createElement("div");
9431  const suspense = vnode.suspense = createSuspenseBoundary(
9432    vnode,
9433    parentSuspense,
9434    parentComponent,
9435    container,
9436    hiddenContainer,
9437    anchor,
9438    namespace,
9439    slotScopeIds,
9440    optimized,
9441    rendererInternals
9442  );
9443  patch(
9444    null,
9445    suspense.pendingBranch = vnode.ssContent,
9446    hiddenContainer,
9447    null,
9448    parentComponent,
9449    suspense,
9450    namespace,
9451    slotScopeIds
9452  );
9453  if (suspense.deps > 0) {
9454    triggerEvent(vnode, "onPending");
9455    triggerEvent(vnode, "onFallback");
9456    patch(
9457      null,
9458      vnode.ssFallback,
9459      container,
9460      anchor,
9461      parentComponent,
9462      null,
9463      // fallback tree will not have suspense context
9464      namespace,
9465      slotScopeIds
9466    );
9467    setActiveBranch(suspense, vnode.ssFallback);
9468  } else {
9469    suspense.resolve(false, true);
9470  }
9471}
9472function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) {
9473  const suspense = n2.suspense = n1.suspense;
9474  suspense.vnode = n2;
9475  n2.el = n1.el;
9476  const newBranch = n2.ssContent;
9477  const newFallback = n2.ssFallback;
9478  const { activeBranch, pendingBranch, isInFallback, isHydrating } = suspense;
9479  if (pendingBranch) {
9480    suspense.pendingBranch = newBranch;
9481    if (isSameVNodeType(pendingBranch, newBranch)) {
9482      patch(
9483        pendingBranch,
9484        newBranch,
9485        suspense.hiddenContainer,
9486        null,
9487        parentComponent,
9488        suspense,
9489        namespace,
9490        slotScopeIds,
9491        optimized
9492      );
9493      if (suspense.deps <= 0) {
9494        suspense.resolve();
9495      } else if (isInFallback) {
9496        if (!isHydrating) {
9497          patch(
9498            activeBranch,
9499            newFallback,
9500            container,
9501            anchor,
9502            parentComponent,
9503            null,
9504            // fallback tree will not have suspense context
9505            namespace,
9506            slotScopeIds,
9507            optimized
9508          );
vendor: 5,698 bytes, lines 9509-9717
9509          setActiveBranch(suspense, newFallback);
9510        }
9511      }
9512    } else {
9513      suspense.pendingId = suspenseId++;
9514      if (isHydrating) {
9515        suspense.isHydrating = false;
9516        suspense.activeBranch = pendingBranch;
9517      } else {
9518        unmount(pendingBranch, parentComponent, suspense);
9519      }
9520      suspense.deps = 0;
9521      suspense.effects.length = 0;
9522      suspense.hiddenContainer = createElement("div");
9523      if (isInFallback) {
9524        patch(
9525          null,
9526          newBranch,
9527          suspense.hiddenContainer,
9528          null,
9529          parentComponent,
9530          suspense,
9531          namespace,
9532          slotScopeIds,
9533          optimized
9534        );
9535        if (suspense.deps <= 0) {
9536          suspense.resolve();
9537        } else {
9538          patch(
9539            activeBranch,
9540            newFallback,
9541            container,
9542            anchor,
9543            parentComponent,
9544            null,
9545            // fallback tree will not have suspense context
9546            namespace,
9547            slotScopeIds,
9548            optimized
9549          );
9550          setActiveBranch(suspense, newFallback);
9551        }
9552      } else if (activeBranch && isSameVNodeType(activeBranch, newBranch)) {
9553        patch(
9554          activeBranch,
9555          newBranch,
9556          container,
9557          anchor,
9558          parentComponent,
9559          suspense,
9560          namespace,
9561          slotScopeIds,
9562          optimized
9563        );
9564        suspense.resolve(true);
9565      } else {
9566        patch(
9567          null,
9568          newBranch,
9569          suspense.hiddenContainer,
9570          null,
9571          parentComponent,
9572          suspense,
9573          namespace,
9574          slotScopeIds,
9575          optimized
9576        );
9577        if (suspense.deps <= 0) {
9578          suspense.resolve();
9579        }
9580      }
9581    }
9582  } else {
9583    if (activeBranch && isSameVNodeType(activeBranch, newBranch)) {
9584      patch(
9585        activeBranch,
9586        newBranch,
9587        container,
9588        anchor,
9589        parentComponent,
9590        suspense,
9591        namespace,
9592        slotScopeIds,
9593        optimized
9594      );
9595      setActiveBranch(suspense, newBranch);
9596    } else {
9597      triggerEvent(n2, "onPending");
9598      suspense.pendingBranch = newBranch;
9599      if (newBranch.shapeFlag & 512) {
9600        suspense.pendingId = newBranch.component.suspenseId;
9601      } else {
9602        suspense.pendingId = suspenseId++;
9603      }
9604      patch(
9605        null,
9606        newBranch,
9607        suspense.hiddenContainer,
9608        null,
9609        parentComponent,
9610        suspense,
9611        namespace,
9612        slotScopeIds,
9613        optimized
9614      );
9615      if (suspense.deps <= 0) {
9616        suspense.resolve();
9617      } else {
9618        const { timeout, pendingId } = suspense;
9619        if (timeout > 0) {
9620          setTimeout(() => {
9621            if (suspense.pendingId === pendingId) {
9622              suspense.fallback(newFallback);
9623            }
9624          }, timeout);
9625        } else if (timeout === 0) {
9626          suspense.fallback(newFallback);
9627        }
9628      }
9629    }
9630  }
9631}
9632let hasWarned = false;
9633function createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, namespace, slotScopeIds, optimized, rendererInternals, isHydrating = false) {
9634  if (false) // removed by dead control flow
9635{}
9636  const {
9637    p: patch,
9638    m: move,
9639    um: unmount,
9640    n: next,
9641    o: { parentNode, remove }
9642  } = rendererInternals;
9643  let parentSuspenseId;
9644  const isSuspensible = isVNodeSuspensible(vnode);
9645  if (isSuspensible) {
9646    if (parentSuspense && parentSuspense.pendingBranch) {
9647      parentSuspenseId = parentSuspense.pendingId;
9648      parentSuspense.deps++;
9649    }
9650  }
9651  const timeout = vnode.props ? toNumber(vnode.props.timeout) : void 0;
9652  if (false) // removed by dead control flow
9653{}
9654  const initialAnchor = anchor;
9655  const suspense = {
9656    vnode,
9657    parent: parentSuspense,
9658    parentComponent,
9659    namespace,
9660    container,
9661    hiddenContainer,
9662    deps: 0,
9663    pendingId: suspenseId++,
9664    timeout: typeof timeout === "number" ? timeout : -1,
9665    activeBranch: null,
9666    pendingBranch: null,
9667    isInFallback: !isHydrating,
9668    isHydrating,
9669    isUnmounted: false,
9670    effects: [],
9671    resolve(resume = false, sync = false) {
9672      if (false) // removed by dead control flow
9673{}
9674      const {
9675        vnode: vnode2,
9676        activeBranch,
9677        pendingBranch,
9678        pendingId,
9679        effects,
9680        parentComponent: parentComponent2,
9681        container: container2,
9682        isInFallback
9683      } = suspense;
9684      let delayEnter = false;
9685      if (suspense.isHydrating) {
9686        suspense.isHydrating = false;
9687      } else if (!resume) {
9688        delayEnter = activeBranch && pendingBranch.transition && pendingBranch.transition.mode === "out-in";
9689        if (delayEnter) {
9690          activeBranch.transition.afterLeave = () => {
9691            if (pendingId === suspense.pendingId) {
9692              move(
9693                pendingBranch,
9694                container2,
9695                anchor === initialAnchor ? next(activeBranch) : anchor,
9696                0
9697              );
9698              queuePostFlushCb(effects);
9699              if (isInFallback && vnode2.ssFallback) {
9700                vnode2.ssFallback.el = null;
9701              }
9702            }
9703          };
9704        }
9705        if (activeBranch) {
9706          if (parentNode(activeBranch.el) === container2) {
9707            anchor = next(activeBranch);
9708          }
9709          unmount(activeBranch, parentComponent2, suspense, true);
9710          if (!delayEnter && isInFallback && vnode2.ssFallback) {
9711            queuePostRenderEffect(() => vnode2.ssFallback.el = null, suspense);
9712          }
9713        }
9714        if (!delayEnter) {
9715          move(pendingBranch, container2, anchor, 0);
9716        }
9717      }
9718      setActiveBranch(suspense, pendingBranch);
9719      suspense.pendingBranch = null;
9720      suspense.isInFallback = false;
9721      let parent = suspense.parent;
9722      let hasUnresolvedAncestor = false;
9723      while (parent) {
9724        if (parent.pendingBranch) {
9725          parent.effects.push(...effects);
9726          hasUnresolvedAncestor = true;
9727          break;
9728        }
9729        parent = parent.parent;
9730      }
9731      if (!hasUnresolvedAncestor && !delayEnter) {
9732        queuePostFlushCb(effects);
9733      }
9734      suspense.effects = [];
9735      if (isSuspensible) {
9736        if (parentSuspense && parentSuspense.pendingBranch && parentSuspenseId === parentSuspense.pendingId) {
9737          parentSuspense.deps--;
9738          if (parentSuspense.deps === 0 && !sync) {
9739            parentSuspense.resolve();
9740          }
9741        }
9742      }
9743      triggerEvent(vnode2, "onResolve");
9744    },
9745    fallback(fallbackVNode) {
9746      if (!suspense.pendingBranch) {
9747        return;
9748      }
9749      const { vnode: vnode2, activeBranch, parentComponent: parentComponent2, container: container2, namespace: namespace2 } = suspense;
9750      triggerEvent(vnode2, "onFallback");
9751      const anchor2 = next(activeBranch);
9752      const mountFallback = () => {
9753        if (!suspense.isInFallback) {
9754          return;
9755        }
9756        patch(
9757          null,
9758          fallbackVNode,
9759          container2,
9760          anchor2,
9761          parentComponent2,
9762          null,
9763          // fallback tree will not have suspense context
9764          namespace2,
9765          slotScopeIds,
9766          optimized
9767        );
9768        setActiveBranch(suspense, fallbackVNode);
9769      };
9770      const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
9771      if (delayEnter) {
9772        activeBranch.transition.afterLeave = mountFallback;
9773      }
9774      suspense.isInFallback = true;
9775      unmount(
9776        activeBranch,
9777        parentComponent2,
9778        null,
9779        // no suspense so unmount hooks fire now
9780        true
9781        // shouldRemove
9782      );
9783      if (!delayEnter) {
9784        mountFallback();
9785      }
9786    },
vendor: 16,148 bytes, lines 9787-10305
9787    move(container2, anchor2, type) {
9788      suspense.activeBranch && move(suspense.activeBranch, container2, anchor2, type);
9789      suspense.container = container2;
9790    },
9791    next() {
9792      return suspense.activeBranch && next(suspense.activeBranch);
9793    },
9794    registerDep(instance, setupRenderEffect, optimized2) {
9795      const isInPendingSuspense = !!suspense.pendingBranch;
9796      if (isInPendingSuspense) {
9797        suspense.deps++;
9798      }
9799      const hydratedEl = instance.vnode.el;
9800      instance.asyncDep.catch((err) => {
9801        handleError(err, instance, 0);
9802      }).then((asyncSetupResult) => {
9803        if (instance.isUnmounted || suspense.isUnmounted || suspense.pendingId !== instance.suspenseId) {
9804          return;
9805        }
9806        instance.asyncResolved = true;
9807        const { vnode: vnode2 } = instance;
9808        if (false) // removed by dead control flow
9809{}
9810        handleSetupResult(instance, asyncSetupResult, false);
9811        if (hydratedEl) {
9812          vnode2.el = hydratedEl;
9813        }
9814        const placeholder = !hydratedEl && instance.subTree.el;
9815        setupRenderEffect(
9816          instance,
9817          vnode2,
9818          // component may have been moved before resolve.
9819          // if this is not a hydration, instance.subTree will be the comment
9820          // placeholder.
9821          parentNode(hydratedEl || instance.subTree.el),
9822          // anchor will not be used if this is hydration, so only need to
9823          // consider the comment placeholder case.
9824          hydratedEl ? null : next(instance.subTree),
9825          suspense,
9826          namespace,
9827          optimized2
9828        );
9829        if (placeholder) {
9830          vnode2.placeholder = null;
9831          remove(placeholder);
9832        }
9833        updateHOCHostEl(instance, vnode2.el);
9834        if (false) // removed by dead control flow
9835{}
9836        if (isInPendingSuspense && --suspense.deps === 0) {
9837          suspense.resolve();
9838        }
9839      });
9840    },
9841    unmount(parentSuspense2, doRemove) {
9842      suspense.isUnmounted = true;
9843      if (suspense.activeBranch) {
9844        unmount(
9845          suspense.activeBranch,
9846          parentComponent,
9847          parentSuspense2,
9848          doRemove
9849        );
9850      }
9851      if (suspense.pendingBranch) {
9852        unmount(
9853          suspense.pendingBranch,
9854          parentComponent,
9855          parentSuspense2,
9856          doRemove
9857        );
9858      }
9859    }
9860  };
9861  return suspense;
9862}
9863function hydrateSuspense(node, vnode, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals, hydrateNode) {
9864  const suspense = vnode.suspense = createSuspenseBoundary(
9865    vnode,
9866    parentSuspense,
9867    parentComponent,
9868    node.parentNode,
9869    // eslint-disable-next-line no-restricted-globals
9870    document.createElement("div"),
9871    null,
9872    namespace,
9873    slotScopeIds,
9874    optimized,
9875    rendererInternals,
9876    true
9877  );
9878  const result = hydrateNode(
9879    node,
9880    suspense.pendingBranch = vnode.ssContent,
9881    parentComponent,
9882    suspense,
9883    slotScopeIds,
9884    optimized
9885  );
9886  if (suspense.deps === 0) {
9887    suspense.resolve(false, true);
9888  }
9889  return result;
9890}
9891function normalizeSuspenseChildren(vnode) {
9892  const { shapeFlag, children } = vnode;
9893  const isSlotChildren = shapeFlag & 32;
9894  vnode.ssContent = normalizeSuspenseSlot(
9895    isSlotChildren ? children.default : children
9896  );
9897  vnode.ssFallback = isSlotChildren ? normalizeSuspenseSlot(children.fallback) : createVNode(Comment);
9898}
9899function normalizeSuspenseSlot(s) {
9900  let block;
9901  if (shared_esm_bundler_isFunction(s)) {
9902    const trackBlock = isBlockTreeEnabled && s._c;
9903    if (trackBlock) {
9904      s._d = false;
9905      openBlock();
9906    }
9907    s = s();
9908    if (trackBlock) {
9909      s._d = true;
9910      block = currentBlock;
9911      closeBlock();
9912    }
9913  }
9914  if (shared_esm_bundler_isArray(s)) {
9915    const singleChild = filterSingleRoot(s);
9916    if (false) // removed by dead control flow
9917{}
9918    s = singleChild;
9919  }
9920  s = normalizeVNode(s);
9921  if (block && !s.dynamicChildren) {
9922    s.dynamicChildren = block.filter((c) => c !== s);
9923  }
9924  return s;
9925}
9926function queueEffectWithSuspense(fn, suspense) {
9927  if (suspense && suspense.pendingBranch) {
9928    if (shared_esm_bundler_isArray(fn)) {
9929      suspense.effects.push(...fn);
9930    } else {
9931      suspense.effects.push(fn);
9932    }
9933  } else {
9934    queuePostFlushCb(fn);
9935  }
9936}
9937function setActiveBranch(suspense, branch) {
9938  suspense.activeBranch = branch;
9939  const { vnode, parentComponent } = suspense;
9940  let el = branch.el;
9941  while (!el && branch.component) {
9942    branch = branch.component.subTree;
9943    el = branch.el;
9944  }
9945  vnode.el = el;
9946  if (parentComponent && parentComponent.subTree === vnode) {
9947    parentComponent.vnode.el = el;
9948    updateHOCHostEl(parentComponent, el);
9949  }
9950}
9951function isVNodeSuspensible(vnode) {
9952  const suspensible = vnode.props && vnode.props.suspensible;
9953  return suspensible != null && suspensible !== false;
9954}
9955
9956const Fragment = Symbol.for("v-fgt");
9957const Text = Symbol.for("v-txt");
9958const Comment = Symbol.for("v-cmt");
9959const Static = Symbol.for("v-stc");
9960const blockStack = [];
9961let currentBlock = null;
9962function openBlock(disableTracking = false) {
9963  blockStack.push(currentBlock = disableTracking ? null : []);
9964}
9965function closeBlock() {
9966  blockStack.pop();
9967  currentBlock = blockStack[blockStack.length - 1] || null;
9968}
9969let isBlockTreeEnabled = 1;
9970function setBlockTracking(value, inVOnce = false) {
9971  isBlockTreeEnabled += value;
9972  if (value < 0 && currentBlock && inVOnce) {
9973    currentBlock.hasOnce = true;
9974  }
9975}
9976function setupBlock(vnode) {
9977  vnode.dynamicChildren = isBlockTreeEnabled > 0 ? currentBlock || EMPTY_ARR : null;
9978  closeBlock();
9979  if (isBlockTreeEnabled > 0 && currentBlock) {
9980    currentBlock.push(vnode);
9981  }
9982  return vnode;
9983}
9984function createElementBlock(type, props, children, patchFlag, dynamicProps, shapeFlag) {
9985  return setupBlock(
9986    createBaseVNode(
9987      type,
9988      props,
9989      children,
9990      patchFlag,
9991      dynamicProps,
9992      shapeFlag,
9993      true
9994    )
9995  );
9996}
9997function createBlock(type, props, children, patchFlag, dynamicProps) {
9998  return setupBlock(
9999    createVNode(
10000      type,
10001      props,
10002      children,
10003      patchFlag,
10004      dynamicProps,
10005      true
10006    )
10007  );
10008}
10009function isVNode(value) {
10010  return value ? value.__v_isVNode === true : false;
10011}
10012function isSameVNodeType(n1, n2) {
10013  if (false) // removed by dead control flow
10014{}
10015  return n1.type === n2.type && n1.key === n2.key;
10016}
10017let vnodeArgsTransformer;
10018function transformVNodeArgs(transformer) {
10019  vnodeArgsTransformer = transformer;
10020}
10021const createVNodeWithArgsTransform = (...args) => {
10022  return _createVNode(
10023    ...vnodeArgsTransformer ? vnodeArgsTransformer(args, currentRenderingInstance) : args
10024  );
10025};
10026const normalizeKey = ({ key }) => key != null ? key : null;
10027const normalizeRef = ({
10028  ref,
10029  ref_key,
10030  ref_for
10031}) => {
10032  if (typeof ref === "number") {
10033    ref = "" + ref;
10034  }
10035  return ref != null ? shared_esm_bundler_isString(ref) || reactivity_esm_bundler_isRef(ref) || shared_esm_bundler_isFunction(ref) ? { i: currentRenderingInstance, r: ref, k: ref_key, f: !!ref_for } : ref : null;
10036};
10037function createBaseVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, shapeFlag = type === Fragment ? 0 : 1, isBlockNode = false, needFullChildrenNormalization = false) {
10038  const vnode = {
10039    __v_isVNode: true,
10040    __v_skip: true,
10041    type,
10042    props,
10043    key: props && normalizeKey(props),
10044    ref: props && normalizeRef(props),
10045    scopeId: currentScopeId,
10046    slotScopeIds: null,
10047    children,
10048    component: null,
10049    suspense: null,
10050    ssContent: null,
10051    ssFallback: null,
10052    dirs: null,
10053    transition: null,
10054    el: null,
10055    anchor: null,
10056    target: null,
10057    targetStart: null,
10058    targetAnchor: null,
10059    staticCount: 0,
10060    shapeFlag,
10061    patchFlag,
10062    dynamicProps,
10063    dynamicChildren: null,
10064    appContext: null,
10065    ctx: currentRenderingInstance
10066  };
10067  if (needFullChildrenNormalization) {
10068    normalizeChildren(vnode, children);
10069    if (shapeFlag & 128) {
10070      type.normalize(vnode);
10071    }
10072  } else if (children) {
10073    vnode.shapeFlag |= shared_esm_bundler_isString(children) ? 8 : 16;
10074  }
10075  if (false) // removed by dead control flow
10076{}
10077  if (isBlockTreeEnabled > 0 && // avoid a block node from tracking itself
10078  !isBlockNode && // has current parent block
10079  currentBlock && // presence of a patch flag indicates this node needs patching on updates.
10080  // component nodes also should always be patched, because even if the
10081  // component doesn't need to update, it needs to persist the instance on to
10082  // the next vnode so that it can be properly unmounted later.
10083  (vnode.patchFlag > 0 || shapeFlag & 6) && // the EVENTS flag is only for hydration and if it is the only flag, the
10084  // vnode should not be considered dynamic due to handler caching.
10085  vnode.patchFlag !== 32) {
10086    currentBlock.push(vnode);
10087  }
10088  return vnode;
10089}
10090const createVNode =  false ? 0 : _createVNode;
10091function _createVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, isBlockNode = false) {
10092  if (!type || type === NULL_DYNAMIC_COMPONENT) {
10093    if (false) // removed by dead control flow
10094{}
10095    type = Comment;
10096  }
10097  if (isVNode(type)) {
10098    const cloned = cloneVNode(
10099      type,
10100      props,
10101      true
10102      /* mergeRef: true */
10103    );
10104    if (children) {
10105      normalizeChildren(cloned, children);
10106    }
10107    if (isBlockTreeEnabled > 0 && !isBlockNode && currentBlock) {
10108      if (cloned.shapeFlag & 6) {
10109        currentBlock[currentBlock.indexOf(type)] = cloned;
10110      } else {
10111        currentBlock.push(cloned);
10112      }
10113    }
10114    cloned.patchFlag = -2;
10115    return cloned;
10116  }
10117  if (isClassComponent(type)) {
10118    type = type.__vccOpts;
10119  }
10120  if (props) {
10121    props = guardReactiveProps(props);
10122    let { class: klass, style } = props;
10123    if (klass && !shared_esm_bundler_isString(klass)) {
10124      props.class = normalizeClass(klass);
10125    }
10126    if (shared_esm_bundler_isObject(style)) {
10127      if (isProxy(style) && !shared_esm_bundler_isArray(style)) {
10128        style = shared_esm_bundler_extend({}, style);
10129      }
10130      props.style = normalizeStyle(style);
10131    }
10132  }
10133  const shapeFlag = shared_esm_bundler_isString(type) ? 1 : isSuspense(type) ? 128 : isTeleport(type) ? 64 : shared_esm_bundler_isObject(type) ? 4 : shared_esm_bundler_isFunction(type) ? 2 : 0;
10134  if (false) // removed by dead control flow
10135{}
10136  return createBaseVNode(
10137    type,
10138    props,
10139    children,
10140    patchFlag,
10141    dynamicProps,
10142    shapeFlag,
10143    isBlockNode,
10144    true
10145  );
10146}
10147function guardReactiveProps(props) {
10148  if (!props) return null;
10149  return isProxy(props) || isInternalObject(props) ? shared_esm_bundler_extend({}, props) : props;
10150}
10151function cloneVNode(vnode, extraProps, mergeRef = false, cloneTransition = false) {
10152  const { props, ref, patchFlag, children, transition } = vnode;
10153  const mergedProps = extraProps ? mergeProps(props || {}, extraProps) : props;
10154  const cloned = {
10155    __v_isVNode: true,
10156    __v_skip: true,
10157    type: vnode.type,
10158    props: mergedProps,
10159    key: mergedProps && normalizeKey(mergedProps),
10160    ref: extraProps && extraProps.ref ? (
10161      // #2078 in the case of <component :is="vnode" ref="extra"/>
10162      // if the vnode itself already has a ref, cloneVNode will need to merge
10163      // the refs so the single vnode can be set on multiple refs
10164      mergeRef && ref ? shared_esm_bundler_isArray(ref) ? ref.concat(normalizeRef(extraProps)) : [ref, normalizeRef(extraProps)] : normalizeRef(extraProps)
10165    ) : ref,
10166    scopeId: vnode.scopeId,
10167    slotScopeIds: vnode.slotScopeIds,
10168    children:  false ? 0 : children,
10169    target: vnode.target,
10170    targetStart: vnode.targetStart,
10171    targetAnchor: vnode.targetAnchor,
10172    staticCount: vnode.staticCount,
10173    shapeFlag: vnode.shapeFlag,
10174    // if the vnode is cloned with extra props, we can no longer assume its
10175    // existing patch flag to be reliable and need to add the FULL_PROPS flag.
10176    // note: preserve flag for fragments since they use the flag for children
10177    // fast paths only.
10178    patchFlag: extraProps && vnode.type !== Fragment ? patchFlag === -1 ? 16 : patchFlag | 16 : patchFlag,
10179    dynamicProps: vnode.dynamicProps,
10180    dynamicChildren: vnode.dynamicChildren,
10181    appContext: vnode.appContext,
10182    dirs: vnode.dirs,
10183    transition,
10184    // These should technically only be non-null on mounted VNodes. However,
10185    // they *should* be copied for kept-alive vnodes. So we just always copy
10186    // them since them being non-null during a mount doesn't affect the logic as
10187    // they will simply be overwritten.
10188    component: vnode.component,
10189    suspense: vnode.suspense,
10190    ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),
10191    ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),
10192    placeholder: vnode.placeholder,
10193    el: vnode.el,
10194    anchor: vnode.anchor,
10195    ctx: vnode.ctx,
10196    ce: vnode.ce
10197  };
10198  if (transition && cloneTransition) {
10199    setTransitionHooks(
10200      cloned,
10201      transition.clone(cloned)
10202    );
10203  }
10204  return cloned;
10205}
10206function deepCloneVNode(vnode) {
10207  const cloned = cloneVNode(vnode);
10208  if (isArray(vnode.children)) {
10209    cloned.children = vnode.children.map(deepCloneVNode);
10210  }
10211  return cloned;
10212}
10213function createTextVNode(text = " ", flag = 0) {
10214  return createVNode(Text, null, text, flag);
10215}
10216function createStaticVNode(content, numberOfNodes) {
10217  const vnode = createVNode(Static, null, content);
10218  vnode.staticCount = numberOfNodes;
10219  return vnode;
10220}
10221function createCommentVNode(text = "", asBlock = false) {
10222  return asBlock ? (openBlock(), createBlock(Comment, null, text)) : createVNode(Comment, null, text);
10223}
10224function normalizeVNode(child) {
10225  if (child == null || typeof child === "boolean") {
10226    return createVNode(Comment);
10227  } else if (shared_esm_bundler_isArray(child)) {
10228    return createVNode(
10229      Fragment,
10230      null,
10231      // #3666, avoid reference pollution when reusing vnode
10232      child.slice()
10233    );
10234  } else if (isVNode(child)) {
10235    return cloneIfMounted(child);
10236  } else {
10237    return createVNode(Text, null, String(child));
10238  }
10239}
10240function cloneIfMounted(child) {
10241  return child.el === null && child.patchFlag !== -1 || child.memo ? child : cloneVNode(child);
10242}
10243function normalizeChildren(vnode, children) {
10244  let type = 0;
10245  const { shapeFlag } = vnode;
10246  if (children == null) {
10247    children = null;
10248  } else if (shared_esm_bundler_isArray(children)) {
10249    type = 16;
10250  } else if (typeof children === "object") {
10251    if (shapeFlag & (1 | 64)) {
10252      const slot = children.default;
10253      if (slot) {
10254        slot._c && (slot._d = false);
10255        normalizeChildren(vnode, slot());
10256        slot._c && (slot._d = true);
10257      }
10258      return;
10259    } else {
10260      type = 32;
10261      const slotFlag = children._;
10262      if (!slotFlag && !isInternalObject(children)) {
10263        children._ctx = currentRenderingInstance;
10264      } else if (slotFlag === 3 && currentRenderingInstance) {
10265        if (currentRenderingInstance.slots._ === 1) {
10266          children._ = 1;
10267        } else {
10268          children._ = 2;
10269          vnode.patchFlag |= 1024;
10270        }
10271      }
10272    }
10273  } else if (shared_esm_bundler_isFunction(children)) {
10274    children = { default: children, _ctx: currentRenderingInstance };
10275    type = 32;
10276  } else {
10277    children = String(children);
10278    if (shapeFlag & 64) {
10279      type = 16;
10280      children = [createTextVNode(children)];
10281    } else {
10282      type = 8;
10283    }
10284  }
10285  vnode.children = children;
10286  vnode.shapeFlag |= type;
10287}
10288function mergeProps(...args) {
10289  const ret = {};
10290  for (let i = 0; i < args.length; i++) {
10291    const toMerge = args[i];
10292    for (const key in toMerge) {
10293      if (key === "class") {
10294        if (ret.class !== toMerge.class) {
10295          ret.class = normalizeClass([ret.class, toMerge.class]);
10296        }
10297      } else if (key === "style") {
10298        ret.style = normalizeStyle([ret.style, toMerge.style]);
10299      } else if (isOn(key)) {
10300        const existing = ret[key];
10301        const incoming = toMerge[key];
10302        if (incoming && existing !== incoming && !(shared_esm_bundler_isArray(existing) && existing.includes(incoming))) {
10303          ret[key] = existing ? [].concat(existing, incoming) : incoming;
10304        }
10305      } else if (key !== "") {
vendor: 14,977 bytes, lines 10306-10833
10306        ret[key] = toMerge[key];
10307      }
10308    }
10309  }
10310  return ret;
10311}
10312function invokeVNodeHook(hook, instance, vnode, prevVNode = null) {
10313  callWithAsyncErrorHandling(hook, instance, 7, [
10314    vnode,
10315    prevVNode
10316  ]);
10317}
10318
10319const emptyAppContext = createAppContext();
10320let uid = 0;
10321function createComponentInstance(vnode, parent, suspense) {
10322  const type = vnode.type;
10323  const appContext = (parent ? parent.appContext : vnode.appContext) || emptyAppContext;
10324  const instance = {
10325    uid: uid++,
10326    vnode,
10327    type,
10328    parent,
10329    appContext,
10330    root: null,
10331    // to be immediately set
10332    next: null,
10333    subTree: null,
10334    // will be set synchronously right after creation
10335    effect: null,
10336    update: null,
10337    // will be set synchronously right after creation
10338    job: null,
10339    scope: new EffectScope(
10340      true
10341      /* detached */
10342    ),
10343    render: null,
10344    proxy: null,
10345    exposed: null,
10346    exposeProxy: null,
10347    withProxy: null,
10348    provides: parent ? parent.provides : Object.create(appContext.provides),
10349    ids: parent ? parent.ids : ["", 0, 0],
10350    accessCache: null,
10351    renderCache: [],
10352    // local resolved assets
10353    components: null,
10354    directives: null,
10355    // resolved props and emits options
10356    propsOptions: normalizePropsOptions(type, appContext),
10357    emitsOptions: normalizeEmitsOptions(type, appContext),
10358    // emit
10359    emit: null,
10360    // to be set immediately
10361    emitted: null,
10362    // props default value
10363    propsDefaults: EMPTY_OBJ,
10364    // inheritAttrs
10365    inheritAttrs: type.inheritAttrs,
10366    // state
10367    ctx: EMPTY_OBJ,
10368    data: EMPTY_OBJ,
10369    props: EMPTY_OBJ,
10370    attrs: EMPTY_OBJ,
10371    slots: EMPTY_OBJ,
10372    refs: EMPTY_OBJ,
10373    setupState: EMPTY_OBJ,
10374    setupContext: null,
10375    // suspense related
10376    suspense,
10377    suspenseId: suspense ? suspense.pendingId : 0,
10378    asyncDep: null,
10379    asyncResolved: false,
10380    // lifecycle hooks
10381    // not using enums here because it results in computed properties
10382    isMounted: false,
10383    isUnmounted: false,
10384    isDeactivated: false,
10385    bc: null,
10386    c: null,
10387    bm: null,
10388    m: null,
10389    bu: null,
10390    u: null,
10391    um: null,
10392    bum: null,
10393    da: null,
10394    a: null,
10395    rtg: null,
10396    rtc: null,
10397    ec: null,
10398    sp: null
10399  };
10400  if (false) // removed by dead control flow
10401{} else {
10402    instance.ctx = { _: instance };
10403  }
10404  instance.root = parent ? parent.root : instance;
10405  instance.emit = emit.bind(null, instance);
10406  if (vnode.ce) {
10407    vnode.ce(instance);
10408  }
10409  return instance;
10410}
10411let currentInstance = null;
10412const getCurrentInstance = () => currentInstance || currentRenderingInstance;
10413let internalSetCurrentInstance;
10414let setInSSRSetupState;
10415{
10416  const g = getGlobalThis();
10417  const registerGlobalSetter = (key, setter) => {
10418    let setters;
10419    if (!(setters = g[key])) setters = g[key] = [];
10420    setters.push(setter);
10421    return (v) => {
10422      if (setters.length > 1) setters.forEach((set) => set(v));
10423      else setters[0](v);
10424    };
10425  };
10426  internalSetCurrentInstance = registerGlobalSetter(
10427    `__VUE_INSTANCE_SETTERS__`,
10428    (v) => currentInstance = v
10429  );
10430  setInSSRSetupState = registerGlobalSetter(
10431    `__VUE_SSR_SETTERS__`,
10432    (v) => isInSSRComponentSetup = v
10433  );
10434}
10435const setCurrentInstance = (instance) => {
10436  const prev = currentInstance;
10437  internalSetCurrentInstance(instance);
10438  instance.scope.on();
10439  return () => {
10440    instance.scope.off();
10441    internalSetCurrentInstance(prev);
10442  };
10443};
10444const unsetCurrentInstance = () => {
10445  currentInstance && currentInstance.scope.off();
10446  internalSetCurrentInstance(null);
10447};
10448const isBuiltInTag = /* @__PURE__ */ (/* unused pure expression or super */ null && (makeMap("slot,component")));
10449function validateComponentName(name, { isNativeTag }) {
10450  if (isBuiltInTag(name) || isNativeTag(name)) {
10451    warn$1(
10452      "Do not use built-in or reserved HTML elements as component id: " + name
10453    );
10454  }
10455}
10456function isStatefulComponent(instance) {
10457  return instance.vnode.shapeFlag & 4;
10458}
10459let isInSSRComponentSetup = false;
10460function setupComponent(instance, isSSR = false, optimized = false) {
10461  isSSR && setInSSRSetupState(isSSR);
10462  const { props, children } = instance.vnode;
10463  const isStateful = isStatefulComponent(instance);
10464  initProps(instance, props, isStateful, isSSR);
10465  initSlots(instance, children, optimized || isSSR);
10466  const setupResult = isStateful ? setupStatefulComponent(instance, isSSR) : void 0;
10467  isSSR && setInSSRSetupState(false);
10468  return setupResult;
10469}
10470function setupStatefulComponent(instance, isSSR) {
10471  const Component = instance.type;
10472  if (false) // removed by dead control flow
10473{}
10474  instance.accessCache = /* @__PURE__ */ Object.create(null);
10475  instance.proxy = new Proxy(instance.ctx, PublicInstanceProxyHandlers);
10476  if (false) // removed by dead control flow
10477{}
10478  const { setup } = Component;
10479  if (setup) {
10480    pauseTracking();
10481    const setupContext = instance.setupContext = setup.length > 1 ? createSetupContext(instance) : null;
10482    const reset = setCurrentInstance(instance);
10483    const setupResult = callWithErrorHandling(
10484      setup,
10485      instance,
10486      0,
10487      [
10488         false ? 0 : instance.props,
10489        setupContext
10490      ]
10491    );
10492    const isAsyncSetup = isPromise(setupResult);
10493    resetTracking();
10494    reset();
10495    if ((isAsyncSetup || instance.sp) && !isAsyncWrapper(instance)) {
10496      markAsyncBoundary(instance);
10497    }
10498    if (isAsyncSetup) {
10499      setupResult.then(unsetCurrentInstance, unsetCurrentInstance);
10500      if (isSSR) {
10501        return setupResult.then((resolvedResult) => {
10502          handleSetupResult(instance, resolvedResult, isSSR);
10503        }).catch((e) => {
10504          handleError(e, instance, 0);
10505        });
10506      } else {
10507        instance.asyncDep = setupResult;
10508        if (false) // removed by dead control flow
10509{}
10510      }
10511    } else {
10512      handleSetupResult(instance, setupResult, isSSR);
10513    }
10514  } else {
10515    finishComponentSetup(instance, isSSR);
10516  }
10517}
10518function handleSetupResult(instance, setupResult, isSSR) {
10519  if (shared_esm_bundler_isFunction(setupResult)) {
10520    if (instance.type.__ssrInlineRender) {
10521      instance.ssrRender = setupResult;
10522    } else {
10523      instance.render = setupResult;
10524    }
10525  } else if (shared_esm_bundler_isObject(setupResult)) {
10526    if (false) // removed by dead control flow
10527{}
10528    if ( false || __VUE_PROD_DEVTOOLS__) {
10529      instance.devtoolsRawSetupState = setupResult;
10530    }
10531    instance.setupState = proxyRefs(setupResult);
10532    if (false) // removed by dead control flow
10533{}
10534  } else if (false) // removed by dead control flow
10535{}
10536  finishComponentSetup(instance, isSSR);
10537}
10538let compile;
10539let installWithProxy;
10540function registerRuntimeCompiler(_compile) {
10541  compile = _compile;
10542  installWithProxy = (i) => {
10543    if (i.render._rc) {
10544      i.withProxy = new Proxy(i.ctx, RuntimeCompiledPublicInstanceProxyHandlers);
10545    }
10546  };
10547}
10548const runtime_core_esm_bundler_isRuntimeOnly = () => !compile;
10549function finishComponentSetup(instance, isSSR, skipOptions) {
10550  const Component = instance.type;
10551  if (!instance.render) {
10552    if (!isSSR && compile && !Component.render) {
10553      const template = Component.template || __VUE_OPTIONS_API__ && resolveMergedOptions(instance).template;
10554      if (template) {
10555        if (false) // removed by dead control flow
10556{}
10557        const { isCustomElement, compilerOptions } = instance.appContext.config;
10558        const { delimiters, compilerOptions: componentCompilerOptions } = Component;
10559        const finalCompilerOptions = shared_esm_bundler_extend(
10560          shared_esm_bundler_extend(
10561            {
10562              isCustomElement,
10563              delimiters
10564            },
10565            compilerOptions
10566          ),
10567          componentCompilerOptions
10568        );
10569        Component.render = compile(template, finalCompilerOptions);
10570        if (false) // removed by dead control flow
10571{}
10572      }
10573    }
10574    instance.render = Component.render || shared_esm_bundler_NOOP;
10575    if (installWithProxy) {
10576      installWithProxy(instance);
10577    }
10578  }
10579  if (__VUE_OPTIONS_API__ && true) {
10580    const reset = setCurrentInstance(instance);
10581    pauseTracking();
10582    try {
10583      applyOptions(instance);
10584    } finally {
10585      resetTracking();
10586      reset();
10587    }
10588  }
10589  if (false) // removed by dead control flow
10590{}
10591}
10592const attrsProxyHandlers =  false ? 0 : {
10593  get(target, key) {
10594    reactivity_esm_bundler_track(target, "get", "");
10595    return target[key];
10596  }
10597};
10598function getSlotsProxy(instance) {
10599  return new Proxy(instance.slots, {
10600    get(target, key) {
10601      track(instance, "get", "$slots");
10602      return target[key];
10603    }
10604  });
10605}
10606function createSetupContext(instance) {
10607  const expose = (exposed) => {
10608    if (false) // removed by dead control flow
10609{}
10610    instance.exposed = exposed || {};
10611  };
10612  if (false) // removed by dead control flow
10613{} else {
10614    return {
10615      attrs: new Proxy(instance.attrs, attrsProxyHandlers),
10616      slots: instance.slots,
10617      emit: instance.emit,
10618      expose
10619    };
10620  }
10621}
10622function getComponentPublicInstance(instance) {
10623  if (instance.exposed) {
10624    return instance.exposeProxy || (instance.exposeProxy = new Proxy(proxyRefs(markRaw(instance.exposed)), {
10625      get(target, key) {
10626        if (key in target) {
10627          return target[key];
10628        } else if (key in publicPropertiesMap) {
10629          return publicPropertiesMap[key](instance);
10630        }
10631      },
10632      has(target, key) {
10633        return key in target || key in publicPropertiesMap;
10634      }
10635    }));
10636  } else {
10637    return instance.proxy;
10638  }
10639}
10640const classifyRE = /(?:^|[-_])\w/g;
10641const classify = (str) => str.replace(classifyRE, (c) => c.toUpperCase()).replace(/[-_]/g, "");
10642function getComponentName(Component, includeInferred = true) {
10643  return shared_esm_bundler_isFunction(Component) ? Component.displayName || Component.name : Component.name || includeInferred && Component.__name;
10644}
10645function formatComponentName(instance, Component, isRoot = false) {
10646  let name = getComponentName(Component);
10647  if (!name && Component.__file) {
10648    const match = Component.__file.match(/([^/\\]+)\.\w+$/);
10649    if (match) {
10650      name = match[1];
10651    }
10652  }
10653  if (!name && instance) {
10654    const inferFromRegistry = (registry) => {
10655      for (const key in registry) {
10656        if (registry[key] === Component) {
10657          return key;
10658        }
10659      }
10660    };
10661    name = inferFromRegistry(instance.components) || instance.parent && inferFromRegistry(
10662      instance.parent.type.components
10663    ) || inferFromRegistry(instance.appContext.components);
10664  }
10665  return name ? classify(name) : isRoot ? `App` : `Anonymous`;
10666}
10667function isClassComponent(value) {
10668  return shared_esm_bundler_isFunction(value) && "__vccOpts" in value;
10669}
10670
10671const runtime_core_esm_bundler_computed = (getterOrOptions, debugOptions) => {
10672  const c = computed(getterOrOptions, debugOptions, isInSSRComponentSetup);
10673  if (false) // removed by dead control flow
10674{}
10675  return c;
10676};
10677
10678function h(type, propsOrChildren, children) {
10679  try {
10680    setBlockTracking(-1);
10681    const l = arguments.length;
10682    if (l === 2) {
10683      if (shared_esm_bundler_isObject(propsOrChildren) && !shared_esm_bundler_isArray(propsOrChildren)) {
10684        if (isVNode(propsOrChildren)) {
10685          return createVNode(type, null, [propsOrChildren]);
10686        }
10687        return createVNode(type, propsOrChildren);
10688      } else {
10689        return createVNode(type, null, propsOrChildren);
10690      }
10691    } else {
10692      if (l > 3) {
10693        children = Array.prototype.slice.call(arguments, 2);
10694      } else if (l === 3 && isVNode(children)) {
10695        children = [children];
10696      }
10697      return createVNode(type, propsOrChildren, children);
10698    }
10699  } finally {
10700    setBlockTracking(1);
10701  }
10702}
10703
10704function runtime_core_esm_bundler_initCustomFormatter() {
10705  if (true) {
10706    return;
10707  }
10708  // removed by dead control flow
10709
10710  // removed by dead control flow
10711
10712  // removed by dead control flow
10713
10714  // removed by dead control flow
10715
10716  // removed by dead control flow
10717
10718  function formatInstance(instance) {
10719    const blocks = [];
10720    if (instance.type.props && instance.props) {
10721      blocks.push(createInstanceBlock("props", reactivity_esm_bundler_toRaw(instance.props)));
10722    }
10723    if (instance.setupState !== EMPTY_OBJ) {
10724      blocks.push(createInstanceBlock("setup", instance.setupState));
10725    }
10726    if (instance.data !== EMPTY_OBJ) {
10727      blocks.push(createInstanceBlock("data", reactivity_esm_bundler_toRaw(instance.data)));
10728    }
10729    const computed = extractKeys(instance, "computed");
10730    if (computed) {
10731      blocks.push(createInstanceBlock("computed", computed));
10732    }
10733    const injected = extractKeys(instance, "inject");
10734    if (injected) {
10735      blocks.push(createInstanceBlock("injected", injected));
10736    }
10737    blocks.push([
10738      "div",
10739      {},
10740      [
10741        "span",
10742        {
10743          style: keywordStyle.style + ";opacity:0.66"
10744        },
10745        "$ (internal): "
10746      ],
10747      ["object", { object: instance }]
10748    ]);
10749    return blocks;
10750  }
10751  function createInstanceBlock(type, target) {
10752    target = shared_esm_bundler_extend({}, target);
10753    if (!Object.keys(target).length) {
10754      return ["span", {}];
10755    }
10756    return [
10757      "div",
10758      { style: "line-height:1.25em;margin-bottom:0.6em" },
10759      [
10760        "div",
10761        {
10762          style: "color:#476582"
10763        },
10764        type
10765      ],
10766      [
10767        "div",
10768        {
10769          style: "padding-left:1.25em"
10770        },
10771        ...Object.keys(target).map((key) => {
10772          return [
10773            "div",
10774            {},
10775            ["span", keywordStyle, key + ": "],
10776            formatValue(target[key], false)
10777          ];
10778        })
10779      ]
10780    ];
10781  }
10782  function formatValue(v, asRaw = true) {
10783    if (typeof v === "number") {
10784      return ["span", numberStyle, v];
10785    } else if (typeof v === "string") {
10786      return ["span", stringStyle, JSON.stringify(v)];
10787    } else if (typeof v === "boolean") {
10788      return ["span", keywordStyle, v];
10789    } else if (shared_esm_bundler_isObject(v)) {
10790      return ["object", { object: asRaw ? reactivity_esm_bundler_toRaw(v) : v }];
10791    } else {
10792      return ["span", stringStyle, String(v)];
10793    }
10794  }
10795  function extractKeys(instance, type) {
10796    const Comp = instance.type;
10797    if (shared_esm_bundler_isFunction(Comp)) {
10798      return;
10799    }
10800    const extracted = {};
10801    for (const key in instance.ctx) {
10802      if (isKeyOfType(Comp, key, type)) {
10803        extracted[key] = instance.ctx[key];
10804      }
10805    }
10806    return extracted;
10807  }
10808  function isKeyOfType(Comp, key, type) {
10809    const opts = Comp[type];
10810    if (shared_esm_bundler_isArray(opts) && opts.includes(key) || shared_esm_bundler_isObject(opts) && key in opts) {
10811      return true;
10812    }
10813    if (Comp.extends && isKeyOfType(Comp.extends, key, type)) {
10814      return true;
10815    }
10816    if (Comp.mixins && Comp.mixins.some((m) => isKeyOfType(m, key, type))) {
10817      return true;
10818    }
10819  }
10820  function genRefFlag(v) {
10821    if (isShallow(v)) {
10822      return `ShallowRef`;
10823    }
10824    if (v.effect) {
10825      return `ComputedRef`;
10826    }
10827    return `Ref`;
10828  }
10829  // removed by dead control flow
10830
10831}
10832
10833function withMemo(memo, render, cache, index) {
10834  const cached = cache[index];
10835  if (cached && isMemoSame(cached, memo)) {
10836    return cached;
10837  }
10838  const ret = render();
10839  ret.memo = memo.slice();
10840  ret.cacheIndex = index;
10841  return cache[index] = ret;
10842}
10843function isMemoSame(cached, memo) {
10844  const prev = cached.memo;
10845  if (prev.length != memo.length) {
10846    return false;
10847  }
10848  for (let i = 0; i < prev.length; i++) {
10849    if (hasChanged(prev[i], memo[i])) {
10850      return false;
10851    }
10852  }
10853  if (isBlockTreeEnabled > 0 && currentBlock) {
10854    currentBlock.push(cached);
10855  }
10856  return true;
10857}
10858
10859const version = "3.5.25";
10860const runtime_core_esm_bundler_warn =  false ? 0 : shared_esm_bundler_NOOP;
10861const ErrorTypeStrings = ErrorTypeStrings$1 ;
10862const devtools =  true ? devtools$1 : 0;
10863const setDevtoolsHook =  true ? setDevtoolsHook$1 : 0;
10864const _ssrUtils = {
10865  createComponentInstance,
10866  setupComponent,
10867  renderComponentRoot,
10868  setCurrentRenderingInstance,
10869  isVNode: isVNode,
10870  normalizeVNode,
10871  getComponentPublicInstance,
10872  ensureValidVNode,
10873  pushWarningContext,
10874  popWarningContext
10875};
10876const ssrUtils = _ssrUtils ;
10877const resolveFilter = null;
10878const compatUtils = null;
10879const DeprecationTypes = null;
10880
10881
10882
10883;// ./node_modules/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js
10884/**
10885* @vue/runtime-dom v3.5.25
10886* (c) 2018-present Yuxi (Evan) You and Vue contributors
10887* @license MIT
vendor: 5,497 bytes, lines 10888-11062
10888**/
10889
10890
10891
10892
10893let policy = void 0;
10894const tt = typeof window !== "undefined" && window.trustedTypes;
10895if (tt) {
10896  try {
10897    policy = /* @__PURE__ */ tt.createPolicy("vue", {
10898      createHTML: (val) => val
10899    });
10900  } catch (e) {
10901     false && 0;
10902  }
10903}
10904const unsafeToTrustedHTML = policy ? (val) => policy.createHTML(val) : (val) => val;
10905const svgNS = "http://www.w3.org/2000/svg";
10906const mathmlNS = "http://www.w3.org/1998/Math/MathML";
10907const doc = typeof document !== "undefined" ? document : null;
10908const templateContainer = doc && /* @__PURE__ */ doc.createElement("template");
10909const nodeOps = {
10910  insert: (child, parent, anchor) => {
10911    parent.insertBefore(child, anchor || null);
10912  },
10913  remove: (child) => {
10914    const parent = child.parentNode;
10915    if (parent) {
10916      parent.removeChild(child);
10917    }
10918  },
10919  createElement: (tag, namespace, is, props) => {
10920    const el = namespace === "svg" ? doc.createElementNS(svgNS, tag) : namespace === "mathml" ? doc.createElementNS(mathmlNS, tag) : is ? doc.createElement(tag, { is }) : doc.createElement(tag);
10921    if (tag === "select" && props && props.multiple != null) {
10922      el.setAttribute("multiple", props.multiple);
10923    }
10924    return el;
10925  },
10926  createText: (text) => doc.createTextNode(text),
10927  createComment: (text) => doc.createComment(text),
10928  setText: (node, text) => {
10929    node.nodeValue = text;
10930  },
10931  setElementText: (el, text) => {
10932    el.textContent = text;
10933  },
10934  parentNode: (node) => node.parentNode,
10935  nextSibling: (node) => node.nextSibling,
10936  querySelector: (selector) => doc.querySelector(selector),
10937  setScopeId(el, id) {
10938    el.setAttribute(id, "");
10939  },
10940  // __UNSAFE__
10941  // Reason: innerHTML.
10942  // Static content here can only come from compiled templates.
10943  // As long as the user only uses trusted templates, this is safe.
10944  insertStaticContent(content, parent, anchor, namespace, start, end) {
10945    const before = anchor ? anchor.previousSibling : parent.lastChild;
10946    if (start && (start === end || start.nextSibling)) {
10947      while (true) {
10948        parent.insertBefore(start.cloneNode(true), anchor);
10949        if (start === end || !(start = start.nextSibling)) break;
10950      }
10951    } else {
10952      templateContainer.innerHTML = unsafeToTrustedHTML(
10953        namespace === "svg" ? `<svg>${content}</svg>` : namespace === "mathml" ? `<math>${content}</math>` : content
10954      );
10955      const template = templateContainer.content;
10956      if (namespace === "svg" || namespace === "mathml") {
10957        const wrapper = template.firstChild;
10958        while (wrapper.firstChild) {
10959          template.appendChild(wrapper.firstChild);
10960        }
10961        template.removeChild(wrapper);
10962      }
10963      parent.insertBefore(template, anchor);
10964    }
10965    return [
10966      // first
10967      before ? before.nextSibling : parent.firstChild,
10968      // last
10969      anchor ? anchor.previousSibling : parent.lastChild
10970    ];
10971  }
10972};
10973
10974const TRANSITION = "transition";
10975const ANIMATION = "animation";
10976const vtcKey = Symbol("_vtc");
10977const DOMTransitionPropsValidators = {
10978  name: String,
10979  type: String,
10980  css: {
10981    type: Boolean,
10982    default: true
10983  },
10984  duration: [String, Number, Object],
10985  enterFromClass: String,
10986  enterActiveClass: String,
10987  enterToClass: String,
10988  appearFromClass: String,
10989  appearActiveClass: String,
10990  appearToClass: String,
10991  leaveFromClass: String,
10992  leaveActiveClass: String,
10993  leaveToClass: String
10994};
10995const TransitionPropsValidators = /* @__PURE__ */ shared_esm_bundler_extend(
10996  {},
10997  BaseTransitionPropsValidators,
10998  DOMTransitionPropsValidators
10999);
11000const decorate$1 = (t) => {
11001  t.displayName = "Transition";
11002  t.props = TransitionPropsValidators;
11003  return t;
11004};
11005const Transition = /* @__PURE__ */ decorate$1(
11006  (props, { slots }) => h(BaseTransition, resolveTransitionProps(props), slots)
11007);
11008const runtime_dom_esm_bundler_callHook = (hook, args = []) => {
11009  if (shared_esm_bundler_isArray(hook)) {
11010    hook.forEach((h2) => h2(...args));
11011  } else if (hook) {
11012    hook(...args);
11013  }
11014};
11015const hasExplicitCallback = (hook) => {
11016  return hook ? shared_esm_bundler_isArray(hook) ? hook.some((h2) => h2.length > 1) : hook.length > 1 : false;
11017};
11018function resolveTransitionProps(rawProps) {
11019  const baseProps = {};
11020  for (const key in rawProps) {
11021    if (!(key in DOMTransitionPropsValidators)) {
11022      baseProps[key] = rawProps[key];
11023    }
11024  }
11025  if (rawProps.css === false) {
11026    return baseProps;
11027  }
11028  const {
11029    name = "v",
11030    type,
11031    duration,
11032    enterFromClass = `${name}-enter-from`,
11033    enterActiveClass = `${name}-enter-active`,
11034    enterToClass = `${name}-enter-to`,
11035    appearFromClass = enterFromClass,
11036    appearActiveClass = enterActiveClass,
11037    appearToClass = enterToClass,
11038    leaveFromClass = `${name}-leave-from`,
11039    leaveActiveClass = `${name}-leave-active`,
11040    leaveToClass = `${name}-leave-to`
11041  } = rawProps;
11042  const durations = normalizeDuration(duration);
11043  const enterDuration = durations && durations[0];
11044  const leaveDuration = durations && durations[1];
11045  const {
11046    onBeforeEnter,
11047    onEnter,
11048    onEnterCancelled,
11049    onLeave,
11050    onLeaveCancelled,
11051    onBeforeAppear = onBeforeEnter,
11052    onAppear = onEnter,
11053    onAppearCancelled = onEnterCancelled
11054  } = baseProps;
11055  const finishEnter = (el, isAppear, done, isCancelled) => {
11056    el._enterCancelled = isCancelled;
11057    removeTransitionClass(el, isAppear ? appearToClass : enterToClass);
11058    removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);
11059    done && done();
11060  };
11061  const finishLeave = (el, done) => {
11062    el._isLeaving = false;
vendor: 13,752 bytes, lines 11063-11530
11063    removeTransitionClass(el, leaveFromClass);
11064    removeTransitionClass(el, leaveToClass);
11065    removeTransitionClass(el, leaveActiveClass);
11066    done && done();
11067  };
11068  const makeEnterHook = (isAppear) => {
11069    return (el, done) => {
11070      const hook = isAppear ? onAppear : onEnter;
11071      const resolve = () => finishEnter(el, isAppear, done);
11072      runtime_dom_esm_bundler_callHook(hook, [el, resolve]);
11073      nextFrame(() => {
11074        removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass);
11075        addTransitionClass(el, isAppear ? appearToClass : enterToClass);
11076        if (!hasExplicitCallback(hook)) {
11077          whenTransitionEnds(el, type, enterDuration, resolve);
11078        }
11079      });
11080    };
11081  };
11082  return shared_esm_bundler_extend(baseProps, {
11083    onBeforeEnter(el) {
11084      runtime_dom_esm_bundler_callHook(onBeforeEnter, [el]);
11085      addTransitionClass(el, enterFromClass);
11086      addTransitionClass(el, enterActiveClass);
11087    },
11088    onBeforeAppear(el) {
11089      runtime_dom_esm_bundler_callHook(onBeforeAppear, [el]);
11090      addTransitionClass(el, appearFromClass);
11091      addTransitionClass(el, appearActiveClass);
11092    },
11093    onEnter: makeEnterHook(false),
11094    onAppear: makeEnterHook(true),
11095    onLeave(el, done) {
11096      el._isLeaving = true;
11097      const resolve = () => finishLeave(el, done);
11098      addTransitionClass(el, leaveFromClass);
11099      if (!el._enterCancelled) {
11100        forceReflow(el);
11101        addTransitionClass(el, leaveActiveClass);
11102      } else {
11103        addTransitionClass(el, leaveActiveClass);
11104        forceReflow(el);
11105      }
11106      nextFrame(() => {
11107        if (!el._isLeaving) {
11108          return;
11109        }
11110        removeTransitionClass(el, leaveFromClass);
11111        addTransitionClass(el, leaveToClass);
11112        if (!hasExplicitCallback(onLeave)) {
11113          whenTransitionEnds(el, type, leaveDuration, resolve);
11114        }
11115      });
11116      runtime_dom_esm_bundler_callHook(onLeave, [el, resolve]);
11117    },
11118    onEnterCancelled(el) {
11119      finishEnter(el, false, void 0, true);
11120      runtime_dom_esm_bundler_callHook(onEnterCancelled, [el]);
11121    },
11122    onAppearCancelled(el) {
11123      finishEnter(el, true, void 0, true);
11124      runtime_dom_esm_bundler_callHook(onAppearCancelled, [el]);
11125    },
11126    onLeaveCancelled(el) {
11127      finishLeave(el);
11128      runtime_dom_esm_bundler_callHook(onLeaveCancelled, [el]);
11129    }
11130  });
11131}
11132function normalizeDuration(duration) {
11133  if (duration == null) {
11134    return null;
11135  } else if (shared_esm_bundler_isObject(duration)) {
11136    return [NumberOf(duration.enter), NumberOf(duration.leave)];
11137  } else {
11138    const n = NumberOf(duration);
11139    return [n, n];
11140  }
11141}
11142function NumberOf(val) {
11143  const res = toNumber(val);
11144  if (false) // removed by dead control flow
11145{}
11146  return res;
11147}
11148function addTransitionClass(el, cls) {
11149  cls.split(/\s+/).forEach((c) => c && el.classList.add(c));
11150  (el[vtcKey] || (el[vtcKey] = /* @__PURE__ */ new Set())).add(cls);
11151}
11152function removeTransitionClass(el, cls) {
11153  cls.split(/\s+/).forEach((c) => c && el.classList.remove(c));
11154  const _vtc = el[vtcKey];
11155  if (_vtc) {
11156    _vtc.delete(cls);
11157    if (!_vtc.size) {
11158      el[vtcKey] = void 0;
11159    }
11160  }
11161}
11162function nextFrame(cb) {
11163  requestAnimationFrame(() => {
11164    requestAnimationFrame(cb);
11165  });
11166}
11167let endId = 0;
11168function whenTransitionEnds(el, expectedType, explicitTimeout, resolve) {
11169  const id = el._endId = ++endId;
11170  const resolveIfNotStale = () => {
11171    if (id === el._endId) {
11172      resolve();
11173    }
11174  };
11175  if (explicitTimeout != null) {
11176    return setTimeout(resolveIfNotStale, explicitTimeout);
11177  }
11178  const { type, timeout, propCount } = getTransitionInfo(el, expectedType);
11179  if (!type) {
11180    return resolve();
11181  }
11182  const endEvent = type + "end";
11183  let ended = 0;
11184  const end = () => {
11185    el.removeEventListener(endEvent, onEnd);
11186    resolveIfNotStale();
11187  };
11188  const onEnd = (e) => {
11189    if (e.target === el && ++ended >= propCount) {
11190      end();
11191    }
11192  };
11193  setTimeout(() => {
11194    if (ended < propCount) {
11195      end();
11196    }
11197  }, timeout + 1);
11198  el.addEventListener(endEvent, onEnd);
11199}
11200function getTransitionInfo(el, expectedType) {
11201  const styles = window.getComputedStyle(el);
11202  const getStyleProperties = (key) => (styles[key] || "").split(", ");
11203  const transitionDelays = getStyleProperties(`${TRANSITION}Delay`);
11204  const transitionDurations = getStyleProperties(`${TRANSITION}Duration`);
11205  const transitionTimeout = getTimeout(transitionDelays, transitionDurations);
11206  const animationDelays = getStyleProperties(`${ANIMATION}Delay`);
11207  const animationDurations = getStyleProperties(`${ANIMATION}Duration`);
11208  const animationTimeout = getTimeout(animationDelays, animationDurations);
11209  let type = null;
11210  let timeout = 0;
11211  let propCount = 0;
11212  if (expectedType === TRANSITION) {
11213    if (transitionTimeout > 0) {
11214      type = TRANSITION;
11215      timeout = transitionTimeout;
11216      propCount = transitionDurations.length;
11217    }
11218  } else if (expectedType === ANIMATION) {
11219    if (animationTimeout > 0) {
11220      type = ANIMATION;
11221      timeout = animationTimeout;
11222      propCount = animationDurations.length;
11223    }
11224  } else {
11225    timeout = Math.max(transitionTimeout, animationTimeout);
11226    type = timeout > 0 ? transitionTimeout > animationTimeout ? TRANSITION : ANIMATION : null;
11227    propCount = type ? type === TRANSITION ? transitionDurations.length : animationDurations.length : 0;
11228  }
11229  const hasTransform = type === TRANSITION && /\b(?:transform|all)(?:,|$)/.test(
11230    getStyleProperties(`${TRANSITION}Property`).toString()
11231  );
11232  return {
11233    type,
11234    timeout,
11235    propCount,
11236    hasTransform
11237  };
11238}
11239function getTimeout(delays, durations) {
11240  while (delays.length < durations.length) {
11241    delays = delays.concat(delays);
11242  }
11243  return Math.max(...durations.map((d, i) => toMs(d) + toMs(delays[i])));
11244}
11245function toMs(s) {
11246  if (s === "auto") return 0;
11247  return Number(s.slice(0, -1).replace(",", ".")) * 1e3;
11248}
11249function forceReflow(el) {
11250  const targetDocument = el ? el.ownerDocument : document;
11251  return targetDocument.body.offsetHeight;
11252}
11253
11254function patchClass(el, value, isSVG) {
11255  const transitionClasses = el[vtcKey];
11256  if (transitionClasses) {
11257    value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(" ");
11258  }
11259  if (value == null) {
11260    el.removeAttribute("class");
11261  } else if (isSVG) {
11262    el.setAttribute("class", value);
11263  } else {
11264    el.className = value;
11265  }
11266}
11267
11268const vShowOriginalDisplay = Symbol("_vod");
11269const vShowHidden = Symbol("_vsh");
11270const vShow = {
11271  // used for prop mismatch check during hydration
11272  name: "show",
11273  beforeMount(el, { value }, { transition }) {
11274    el[vShowOriginalDisplay] = el.style.display === "none" ? "" : el.style.display;
11275    if (transition && value) {
11276      transition.beforeEnter(el);
11277    } else {
11278      setDisplay(el, value);
11279    }
11280  },
11281  mounted(el, { value }, { transition }) {
11282    if (transition && value) {
11283      transition.enter(el);
11284    }
11285  },
11286  updated(el, { value, oldValue }, { transition }) {
11287    if (!value === !oldValue) return;
11288    if (transition) {
11289      if (value) {
11290        transition.beforeEnter(el);
11291        setDisplay(el, true);
11292        transition.enter(el);
11293      } else {
11294        transition.leave(el, () => {
11295          setDisplay(el, false);
11296        });
11297      }
11298    } else {
11299      setDisplay(el, value);
11300    }
11301  },
11302  beforeUnmount(el, { value }) {
11303    setDisplay(el, value);
11304  }
11305};
11306function setDisplay(el, value) {
11307  el.style.display = value ? el[vShowOriginalDisplay] : "none";
11308  el[vShowHidden] = !value;
11309}
11310function initVShowForSSR() {
11311  vShow.getSSRProps = ({ value }) => {
11312    if (!value) {
11313      return { style: { display: "none" } };
11314    }
11315  };
11316}
11317
11318const CSS_VAR_TEXT = Symbol( false ? 0 : "");
11319function useCssVars(getter) {
11320  const instance = getCurrentInstance();
11321  if (!instance) {
11322     false && 0;
11323    return;
11324  }
11325  const updateTeleports = instance.ut = (vars = getter(instance.proxy)) => {
11326    Array.from(
11327      document.querySelectorAll(`[data-v-owner="${instance.uid}"]`)
11328    ).forEach((node) => setVarsOnNode(node, vars));
11329  };
11330  if (false) // removed by dead control flow
11331{}
11332  const setVars = () => {
11333    const vars = getter(instance.proxy);
11334    if (instance.ce) {
11335      setVarsOnNode(instance.ce, vars);
11336    } else {
11337      setVarsOnVNode(instance.subTree, vars);
11338    }
11339    updateTeleports(vars);
11340  };
11341  onBeforeUpdate(() => {
11342    queuePostFlushCb(setVars);
11343  });
11344  onMounted(() => {
11345    runtime_core_esm_bundler_watch(setVars, shared_esm_bundler_NOOP, { flush: "post" });
11346    const ob = new MutationObserver(setVars);
11347    ob.observe(instance.subTree.el.parentNode, { childList: true });
11348    onUnmounted(() => ob.disconnect());
11349  });
11350}
11351function setVarsOnVNode(vnode, vars) {
11352  if (vnode.shapeFlag & 128) {
11353    const suspense = vnode.suspense;
11354    vnode = suspense.activeBranch;
11355    if (suspense.pendingBranch && !suspense.isHydrating) {
11356      suspense.effects.push(() => {
11357        setVarsOnVNode(suspense.activeBranch, vars);
11358      });
11359    }
11360  }
11361  while (vnode.component) {
11362    vnode = vnode.component.subTree;
11363  }
11364  if (vnode.shapeFlag & 1 && vnode.el) {
11365    setVarsOnNode(vnode.el, vars);
11366  } else if (vnode.type === Fragment) {
11367    vnode.children.forEach((c) => setVarsOnVNode(c, vars));
11368  } else if (vnode.type === Static) {
11369    let { el, anchor } = vnode;
11370    while (el) {
11371      setVarsOnNode(el, vars);
11372      if (el === anchor) break;
11373      el = el.nextSibling;
11374    }
11375  }
11376}
11377function setVarsOnNode(el, vars) {
11378  if (el.nodeType === 1) {
11379    const style = el.style;
11380    let cssText = "";
11381    for (const key in vars) {
11382      const value = normalizeCssVarValue(vars[key]);
11383      style.setProperty(`--${key}`, value);
11384      cssText += `--${key}: ${value};`;
11385    }
11386    style[CSS_VAR_TEXT] = cssText;
11387  }
11388}
11389
11390const displayRE = /(?:^|;)\s*display\s*:/;
11391function patchStyle(el, prev, next) {
11392  const style = el.style;
11393  const isCssString = shared_esm_bundler_isString(next);
11394  let hasControlledDisplay = false;
11395  if (next && !isCssString) {
11396    if (prev) {
11397      if (!shared_esm_bundler_isString(prev)) {
11398        for (const key in prev) {
11399          if (next[key] == null) {
11400            setStyle(style, key, "");
11401          }
11402        }
11403      } else {
11404        for (const prevStyle of prev.split(";")) {
11405          const key = prevStyle.slice(0, prevStyle.indexOf(":")).trim();
11406          if (next[key] == null) {
11407            setStyle(style, key, "");
11408          }
11409        }
11410      }
11411    }
11412    for (const key in next) {
11413      if (key === "display") {
11414        hasControlledDisplay = true;
11415      }
11416      setStyle(style, key, next[key]);
11417    }
11418  } else {
11419    if (isCssString) {
11420      if (prev !== next) {
11421        const cssVarText = style[CSS_VAR_TEXT];
11422        if (cssVarText) {
11423          next += ";" + cssVarText;
11424        }
11425        style.cssText = next;
11426        hasControlledDisplay = displayRE.test(next);
11427      }
11428    } else if (prev) {
11429      el.removeAttribute("style");
11430    }
11431  }
11432  if (vShowOriginalDisplay in el) {
11433    el[vShowOriginalDisplay] = hasControlledDisplay ? style.display : "";
11434    if (el[vShowHidden]) {
11435      style.display = "none";
11436    }
11437  }
11438}
11439const semicolonRE = /[^\\];\s*$/;
11440const importantRE = /\s*!important$/;
11441function setStyle(style, name, val) {
11442  if (shared_esm_bundler_isArray(val)) {
11443    val.forEach((v) => setStyle(style, name, v));
11444  } else {
11445    if (val == null) val = "";
11446    if (false) // removed by dead control flow
11447{}
11448    if (name.startsWith("--")) {
11449      style.setProperty(name, val);
11450    } else {
11451      const prefixed = autoPrefix(style, name);
11452      if (importantRE.test(val)) {
11453        style.setProperty(
11454          hyphenate(prefixed),
11455          val.replace(importantRE, ""),
11456          "important"
11457        );
11458      } else {
11459        style[prefixed] = val;
11460      }
11461    }
11462  }
11463}
11464const prefixes = ["Webkit", "Moz", "ms"];
11465const prefixCache = {};
11466function autoPrefix(style, rawName) {
11467  const cached = prefixCache[rawName];
11468  if (cached) {
11469    return cached;
11470  }
11471  let name = shared_esm_bundler_camelize(rawName);
11472  if (name !== "filter" && name in style) {
11473    return prefixCache[rawName] = name;
11474  }
11475  name = shared_esm_bundler_capitalize(name);
11476  for (let i = 0; i < prefixes.length; i++) {
11477    const prefixed = prefixes[i] + name;
11478    if (prefixed in style) {
11479      return prefixCache[rawName] = prefixed;
11480    }
11481  }
11482  return rawName;
11483}
11484
11485const xlinkNS = "http://www.w3.org/1999/xlink";
11486function patchAttr(el, key, value, isSVG, instance, isBoolean = isSpecialBooleanAttr(key)) {
11487  if (isSVG && key.startsWith("xlink:")) {
11488    if (value == null) {
11489      el.removeAttributeNS(xlinkNS, key.slice(6, key.length));
11490    } else {
11491      el.setAttributeNS(xlinkNS, key, value);
11492    }
11493  } else {
11494    if (value == null || isBoolean && !includeBooleanAttr(value)) {
11495      el.removeAttribute(key);
11496    } else {
11497      el.setAttribute(
11498        key,
11499        isBoolean ? "" : isSymbol(value) ? String(value) : value
11500      );
11501    }
11502  }
11503}
11504
11505function patchDOMProp(el, key, value, parentComponent, attrName) {
11506  if (key === "innerHTML" || key === "textContent") {
11507    if (value != null) {
11508      el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
11509    }
11510    return;
11511  }
11512  const tag = el.tagName;
11513  if (key === "value" && tag !== "PROGRESS" && // custom elements may use _value internally
11514  !tag.includes("-")) {
11515    const oldValue = tag === "OPTION" ? el.getAttribute("value") || "" : el.value;
11516    const newValue = value == null ? (
11517      // #11647: value should be set as empty string for null and undefined,
11518      // but <input type="checkbox"> should be set as 'on'.
11519      el.type === "checkbox" ? "on" : ""
11520    ) : String(value);
11521    if (oldValue !== newValue || !("_value" in el)) {
11522      el.value = newValue;
11523    }
11524    if (value == null) {
11525      el.removeAttribute(key);
11526    }
11527    el._value = value;
11528    return;
11529  }
11530  let needRemove = false;
vendor: 1,053 bytes, lines 11531-11565
11531  if (value === "" || value == null) {
11532    const type = typeof el[key];
11533    if (type === "boolean") {
11534      value = includeBooleanAttr(value);
11535    } else if (value == null && type === "string") {
11536      value = "";
11537      needRemove = true;
11538    } else if (type === "number") {
11539      value = 0;
11540      needRemove = true;
11541    }
11542  }
11543  try {
11544    el[key] = value;
11545  } catch (e) {
11546    if (false) // removed by dead control flow
11547{}
11548  }
11549  needRemove && el.removeAttribute(attrName || key);
11550}
11551
11552function addEventListener(el, event, handler, options) {
11553  el.addEventListener(event, handler, options);
11554}
11555function removeEventListener(el, event, handler, options) {
11556  el.removeEventListener(event, handler, options);
11557}
11558const veiKey = Symbol("_vei");
11559function patchEvent(el, rawName, prevValue, nextValue, instance = null) {
11560  const invokers = el[veiKey] || (el[veiKey] = {});
11561  const existingInvoker = invokers[rawName];
11562  if (nextValue && existingInvoker) {
11563    existingInvoker.value =  false ? 0 : nextValue;
11564  } else {
11565    const [name, options] = parseName(rawName);
vendor: 2,022 bytes, lines 11566-11638
11566    if (nextValue) {
11567      const invoker = invokers[rawName] = createInvoker(
11568         false ? 0 : nextValue,
11569        instance
11570      );
11571      addEventListener(el, name, invoker, options);
11572    } else if (existingInvoker) {
11573      removeEventListener(el, name, existingInvoker, options);
11574      invokers[rawName] = void 0;
11575    }
11576  }
11577}
11578const optionsModifierRE = /(?:Once|Passive|Capture)$/;
11579function parseName(name) {
11580  let options;
11581  if (optionsModifierRE.test(name)) {
11582    options = {};
11583    let m;
11584    while (m = name.match(optionsModifierRE)) {
11585      name = name.slice(0, name.length - m[0].length);
11586      options[m[0].toLowerCase()] = true;
11587    }
11588  }
11589  const event = name[2] === ":" ? name.slice(3) : hyphenate(name.slice(2));
11590  return [event, options];
11591}
11592let cachedNow = 0;
11593const p = /* @__PURE__ */ Promise.resolve();
11594const getNow = () => cachedNow || (p.then(() => cachedNow = 0), cachedNow = Date.now());
11595function createInvoker(initialValue, instance) {
11596  const invoker = (e) => {
11597    if (!e._vts) {
11598      e._vts = Date.now();
11599    } else if (e._vts <= invoker.attached) {
11600      return;
11601    }
11602    callWithAsyncErrorHandling(
11603      patchStopImmediatePropagation(e, invoker.value),
11604      instance,
11605      5,
11606      [e]
11607    );
11608  };
11609  invoker.value = initialValue;
11610  invoker.attached = getNow();
11611  return invoker;
11612}
11613function sanitizeEventValue(value, propName) {
11614  if (isFunction(value) || isArray(value)) {
11615    return value;
11616  }
11617  warn(
11618    `Wrong type passed as event handler to ${propName} - did you forget @ or : in front of your prop?
11619Expected function or array of functions, received type ${typeof value}.`
11620  );
11621  return NOOP;
11622}
11623function patchStopImmediatePropagation(e, value) {
11624  if (shared_esm_bundler_isArray(value)) {
11625    const originalStop = e.stopImmediatePropagation;
11626    e.stopImmediatePropagation = () => {
11627      originalStop.call(e);
11628      e._stopped = true;
11629    };
11630    return value.map(
11631      (fn) => (e2) => !e2._stopped && fn && fn(e2)
11632    );
11633  } else {
11634    return value;
11635  }
11636}
11637
11638const isNativeOn = (key) =>
vendor: 5,215 bytes, lines 11638-11810
11638 key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && // lowercase letter
11639key.charCodeAt(2) > 96 && key.charCodeAt(2) < 123;
11640const patchProp = (el, key, prevValue, nextValue, namespace, parentComponent) => {
11641  const isSVG = namespace === "svg";
11642  if (key === "class") {
11643    patchClass(el, nextValue, isSVG);
11644  } else if (key === "style") {
11645    patchStyle(el, prevValue, nextValue);
11646  } else if (isOn(key)) {
11647    if (!isModelListener(key)) {
11648      patchEvent(el, key, prevValue, nextValue, parentComponent);
11649    }
11650  } else if (key[0] === "." ? (key = key.slice(1), true) : key[0] === "^" ? (key = key.slice(1), false) : shouldSetAsProp(el, key, nextValue, isSVG)) {
11651    patchDOMProp(el, key, nextValue);
11652    if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) {
11653      patchAttr(el, key, nextValue, isSVG, parentComponent, key !== "value");
11654    }
11655  } else if (
11656    // #11081 force set props for possible async custom element
11657    el._isVueCE && (/[A-Z]/.test(key) || !shared_esm_bundler_isString(nextValue))
11658  ) {
11659    patchDOMProp(el, shared_esm_bundler_camelize(key), nextValue, parentComponent, key);
11660  } else {
11661    if (key === "true-value") {
11662      el._trueValue = nextValue;
11663    } else if (key === "false-value") {
11664      el._falseValue = nextValue;
11665    }
11666    patchAttr(el, key, nextValue, isSVG);
11667  }
11668};
11669function shouldSetAsProp(el, key, value, isSVG) {
11670  if (isSVG) {
11671    if (key === "innerHTML" || key === "textContent") {
11672      return true;
11673    }
11674    if (key in el && isNativeOn(key) && shared_esm_bundler_isFunction(value)) {
11675      return true;
11676    }
11677    return false;
11678  }
11679  if (key === "spellcheck" || key === "draggable" || key === "translate" || key === "autocorrect") {
11680    return false;
11681  }
11682  if (key === "sandbox" && el.tagName === "IFRAME") {
11683    return false;
11684  }
11685  if (key === "form") {
11686    return false;
11687  }
11688  if (key === "list" && el.tagName === "INPUT") {
11689    return false;
11690  }
11691  if (key === "type" && el.tagName === "TEXTAREA") {
11692    return false;
11693  }
11694  if (key === "width" || key === "height") {
11695    const tag = el.tagName;
11696    if (tag === "IMG" || tag === "VIDEO" || tag === "CANVAS" || tag === "SOURCE") {
11697      return false;
11698    }
11699  }
11700  if (isNativeOn(key) && shared_esm_bundler_isString(value)) {
11701    return false;
11702  }
11703  return key in el;
11704}
11705
11706const REMOVAL = {};
11707// @__NO_SIDE_EFFECTS__
11708function defineCustomElement(options, extraOptions, _createApp) {
11709  let Comp = defineComponent(options, extraOptions);
11710  if (isPlainObject(Comp)) Comp = shared_esm_bundler_extend({}, Comp, extraOptions);
11711  class VueCustomElement extends VueElement {
11712    constructor(initialProps) {
11713      super(Comp, initialProps, _createApp);
11714    }
11715  }
11716  VueCustomElement.def = Comp;
11717  return VueCustomElement;
11718}
11719const defineSSRCustomElement = (/* @__NO_SIDE_EFFECTS__ */ (options, extraOptions) => {
11720  return /* @__PURE__ */ defineCustomElement(options, extraOptions, createSSRApp);
11721});
11722const BaseClass = typeof HTMLElement !== "undefined" ? HTMLElement : class {
11723};
11724class VueElement extends BaseClass {
11725  constructor(_def, _props = {}, _createApp = createApp) {
11726    super();
11727    this._def = _def;
11728    this._props = _props;
11729    this._createApp = _createApp;
11730    this._isVueCE = true;
11731    /**
11732     * @internal
11733     */
11734    this._instance = null;
11735    /**
11736     * @internal
11737     */
11738    this._app = null;
11739    /**
11740     * @internal
11741     */
11742    this._nonce = this._def.nonce;
11743    this._connected = false;
11744    this._resolved = false;
11745    this._patching = false;
11746    this._dirty = false;
11747    this._numberProps = null;
11748    this._styleChildren = /* @__PURE__ */ new WeakSet();
11749    this._ob = null;
11750    if (this.shadowRoot && _createApp !== createApp) {
11751      this._root = this.shadowRoot;
11752    } else {
11753      if (false) // removed by dead control flow
11754{}
11755      if (_def.shadowRoot !== false) {
11756        this.attachShadow(
11757          shared_esm_bundler_extend({}, _def.shadowRootOptions, {
11758            mode: "open"
11759          })
11760        );
11761        this._root = this.shadowRoot;
11762      } else {
11763        this._root = this;
11764      }
11765    }
11766  }
11767  connectedCallback() {
11768    if (!this.isConnected) return;
11769    if (!this.shadowRoot && !this._resolved) {
11770      this._parseSlots();
11771    }
11772    this._connected = true;
11773    let parent = this;
11774    while (parent = parent && (parent.parentNode || parent.host)) {
11775      if (parent instanceof VueElement) {
11776        this._parent = parent;
11777        break;
11778      }
11779    }
11780    if (!this._instance) {
11781      if (this._resolved) {
11782        this._mount(this._def);
11783      } else {
11784        if (parent && parent._pendingResolve) {
11785          this._pendingResolve = parent._pendingResolve.then(() => {
11786            this._pendingResolve = void 0;
11787            this._resolveDef();
11788          });
11789        } else {
11790          this._resolveDef();
11791        }
11792      }
11793    }
11794  }
11795  _setParent(parent = this._parent) {
11796    if (parent) {
11797      this._instance.parent = parent._instance;
11798      this._inheritParentContext(parent);
11799    }
11800  }
11801  _inheritParentContext(parent = this._parent) {
11802    if (parent && this._app) {
11803      Object.setPrototypeOf(
11804        this._app._context.provides,
11805        parent._instance.provides
11806      );
11807    }
11808  }
11809  disconnectedCallback() {
11810    this._connected = false;
vendor: 6,352 bytes, lines 11811-12019
11811    nextTick(() => {
11812      if (!this._connected) {
11813        if (this._ob) {
11814          this._ob.disconnect();
11815          this._ob = null;
11816        }
11817        this._app && this._app.unmount();
11818        if (this._instance) this._instance.ce = void 0;
11819        this._app = this._instance = null;
11820        if (this._teleportTargets) {
11821          this._teleportTargets.clear();
11822          this._teleportTargets = void 0;
11823        }
11824      }
11825    });
11826  }
11827  _processMutations(mutations) {
11828    for (const m of mutations) {
11829      this._setAttr(m.attributeName);
11830    }
11831  }
11832  /**
11833   * resolve inner component definition (handle possible async component)
11834   */
11835  _resolveDef() {
11836    if (this._pendingResolve) {
11837      return;
11838    }
11839    for (let i = 0; i < this.attributes.length; i++) {
11840      this._setAttr(this.attributes[i].name);
11841    }
11842    this._ob = new MutationObserver(this._processMutations.bind(this));
11843    this._ob.observe(this, { attributes: true });
11844    const resolve = (def, isAsync = false) => {
11845      this._resolved = true;
11846      this._pendingResolve = void 0;
11847      const { props, styles } = def;
11848      let numberProps;
11849      if (props && !shared_esm_bundler_isArray(props)) {
11850        for (const key in props) {
11851          const opt = props[key];
11852          if (opt === Number || opt && opt.type === Number) {
11853            if (key in this._props) {
11854              this._props[key] = toNumber(this._props[key]);
11855            }
11856            (numberProps || (numberProps = /* @__PURE__ */ Object.create(null)))[shared_esm_bundler_camelize(key)] = true;
11857          }
11858        }
11859      }
11860      this._numberProps = numberProps;
11861      this._resolveProps(def);
11862      if (this.shadowRoot) {
11863        this._applyStyles(styles);
11864      } else if (false) // removed by dead control flow
11865{}
11866      this._mount(def);
11867    };
11868    const asyncDef = this._def.__asyncLoader;
11869    if (asyncDef) {
11870      this._pendingResolve = asyncDef().then((def) => {
11871        def.configureApp = this._def.configureApp;
11872        resolve(this._def = def, true);
11873      });
11874    } else {
11875      resolve(this._def);
11876    }
11877  }
11878  _mount(def) {
11879    if (( false || __VUE_PROD_DEVTOOLS__) && !def.name) {
11880      def.name = "VueElement";
11881    }
11882    this._app = this._createApp(def);
11883    this._inheritParentContext();
11884    if (def.configureApp) {
11885      def.configureApp(this._app);
11886    }
11887    this._app._ceVNode = this._createVNode();
11888    this._app.mount(this._root);
11889    const exposed = this._instance && this._instance.exposed;
11890    if (!exposed) return;
11891    for (const key in exposed) {
11892      if (!hasOwn(this, key)) {
11893        Object.defineProperty(this, key, {
11894          // unwrap ref to be consistent with public instance behavior
11895          get: () => unref(exposed[key])
11896        });
11897      } else if (false) // removed by dead control flow
11898{}
11899    }
11900  }
11901  _resolveProps(def) {
11902    const { props } = def;
11903    const declaredPropKeys = shared_esm_bundler_isArray(props) ? props : Object.keys(props || {});
11904    for (const key of Object.keys(this)) {
11905      if (key[0] !== "_" && declaredPropKeys.includes(key)) {
11906        this._setProp(key, this[key]);
11907      }
11908    }
11909    for (const key of declaredPropKeys.map(shared_esm_bundler_camelize)) {
11910      Object.defineProperty(this, key, {
11911        get() {
11912          return this._getProp(key);
11913        },
11914        set(val) {
11915          this._setProp(key, val, true, !this._patching);
11916        }
11917      });
11918    }
11919  }
11920  _setAttr(key) {
11921    if (key.startsWith("data-v-")) return;
11922    const has = this.hasAttribute(key);
11923    let value = has ? this.getAttribute(key) : REMOVAL;
11924    const camelKey = shared_esm_bundler_camelize(key);
11925    if (has && this._numberProps && this._numberProps[camelKey]) {
11926      value = toNumber(value);
11927    }
11928    this._setProp(camelKey, value, false, true);
11929  }
11930  /**
11931   * @internal
11932   */
11933  _getProp(key) {
11934    return this._props[key];
11935  }
11936  /**
11937   * @internal
11938   */
11939  _setProp(key, val, shouldReflect = true, shouldUpdate = false) {
11940    if (val !== this._props[key]) {
11941      this._dirty = true;
11942      if (val === REMOVAL) {
11943        delete this._props[key];
11944      } else {
11945        this._props[key] = val;
11946        if (key === "key" && this._app) {
11947          this._app._ceVNode.key = val;
11948        }
11949      }
11950      if (shouldUpdate && this._instance) {
11951        this._update();
11952      }
11953      if (shouldReflect) {
11954        const ob = this._ob;
11955        if (ob) {
11956          this._processMutations(ob.takeRecords());
11957          ob.disconnect();
11958        }
11959        if (val === true) {
11960          this.setAttribute(hyphenate(key), "");
11961        } else if (typeof val === "string" || typeof val === "number") {
11962          this.setAttribute(hyphenate(key), val + "");
11963        } else if (!val) {
11964          this.removeAttribute(hyphenate(key));
11965        }
11966        ob && ob.observe(this, { attributes: true });
11967      }
11968    }
11969  }
11970  _update() {
11971    const vnode = this._createVNode();
11972    if (this._app) vnode.appContext = this._app._context;
11973    render(vnode, this._root);
11974  }
11975  _createVNode() {
11976    const baseProps = {};
11977    if (!this.shadowRoot) {
11978      baseProps.onVnodeMounted = baseProps.onVnodeUpdated = this._renderSlots.bind(this);
11979    }
11980    const vnode = createVNode(this._def, shared_esm_bundler_extend(baseProps, this._props));
11981    if (!this._instance) {
11982      vnode.ce = (instance) => {
11983        this._instance = instance;
11984        instance.ce = this;
11985        instance.isCE = true;
11986        if (false) // removed by dead control flow
11987{}
11988        const dispatch = (event, args) => {
11989          this.dispatchEvent(
11990            new CustomEvent(
11991              event,
11992              isPlainObject(args[0]) ? shared_esm_bundler_extend({ detail: args }, args[0]) : { detail: args }
11993            )
11994          );
11995        };
11996        instance.emit = (event, ...args) => {
11997          dispatch(event, args);
11998          if (hyphenate(event) !== event) {
11999            dispatch(hyphenate(event), args);
12000          }
12001        };
12002        this._setParent();
12003      };
12004    }
12005    return vnode;
12006  }
12007  _applyStyles(styles, owner) {
12008    if (!styles) return;
12009    if (owner) {
12010      if (owner === this._def || this._styleChildren.has(owner)) {
12011        return;
12012      }
12013      this._styleChildren.add(owner);
12014    }
12015    const nonce = this._nonce;
12016    for (let i = styles.length - 1; i >= 0; i--) {
12017      const s = document.createElement("style");
12018      if (nonce) s.setAttribute("nonce", nonce);
12019      s.textContent = styles[i];
12020      this.shadowRoot.prepend(s);
12021      if (false) // removed by dead control flow
12022{}
12023    }
12024  }
12025  /**
12026   * Only called when shadowRoot is false
12027   */
12028  _parseSlots() {
12029    const slots = this._slots = {};
12030    let n;
12031    while (n = this.firstChild) {
12032      const slotName = n.nodeType === 1 && n.getAttribute("slot") || "default";
12033      (slots[slotName] || (slots[slotName] = [])).push(n);
12034      this.removeChild(n);
12035    }
12036  }
12037  /**
12038   * Only called when shadowRoot is false
12039   */
12040  _renderSlots() {
12041    const outlets = this._getSlots();
12042    const scopeId = this._instance.type.__scopeId;
12043    for (let i = 0; i < outlets.length; i++) {
12044      const o = outlets[i];
12045      const slotName = o.getAttribute("name") || "default";
12046      const content = this._slots[slotName];
12047      const parent = o.parentNode;
12048      if (content) {
12049        for (const n of content) {
12050          if (scopeId && n.nodeType === 1) {
12051            const id = scopeId + "-s";
12052            const walker = document.createTreeWalker(n, 1);
12053            n.setAttribute(id, "");
12054            let child;
12055            while (child = walker.nextNode()) {
12056              child.setAttribute(id, "");
12057            }
12058          }
12059          parent.insertBefore(n, o);
12060        }
12061      } else {
12062        while (o.firstChild) parent.insertBefore(o.firstChild, o);
12063      }
12064      parent.removeChild(o);
12065    }
12066  }
12067  /**
12068   * @internal
12069   */
12070  _getSlots() {
12071    const roots = [this];
12072    if (this._teleportTargets) {
12073      roots.push(...this._teleportTargets);
12074    }
12075    const slots = /* @__PURE__ */ new Set();
12076    for (const root of roots) {
12077      const found = root.querySelectorAll("slot");
12078      for (let i = 0; i < found.length; i++) {
12079        slots.add(found[i]);
12080      }
12081    }
12082    return Array.from(slots);
12083  }
12084  /**
12085   * @internal
12086   */
12087  _injectChildStyle(comp) {
12088    this._applyStyles(comp.styles, comp);
12089  }
12090  /**
12091   * @internal
12092   */
12093  _beginPatch() {
12094    this._patching = true;
12095    this._dirty = false;
12096  }
12097  /**
12098   * @internal
12099   */
12100  _endPatch() {
12101    this._patching = false;
12102    if (this._dirty && this._instance) {
12103      this._update();
12104    }
12105  }
12106  /**
12107   * @internal
12108   */
12109  _removeChildStyle(comp) {
12110    if (false) // removed by dead control flow
12111{}
12112  }
12113}
12114function useHost(caller) {
12115  const instance = getCurrentInstance();
12116  const el = instance && instance.ce;
12117  if (el) {
12118    return el;
12119  } else if (false) // removed by dead control flow
12120{}
12121  return null;
12122}
12123function useShadowRoot() {
12124  const el =  false ? 0 : useHost();
12125  return el && el.shadowRoot;
12126}
12127
12128function useCssModule(name = "$style") {
12129  {
12130    const instance = getCurrentInstance();
12131    if (!instance) {
12132       false && 0;
12133      return EMPTY_OBJ;
12134    }
12135    const modules = instance.type.__cssModules;
12136    if (!modules) {
12137       false && 0;
12138      return EMPTY_OBJ;
12139    }
12140    const mod = modules[name];
12141    if (!mod) {
12142       false && 0;
12143      return EMPTY_OBJ;
12144    }
12145    return mod;
12146  }
12147}
12148
12149const positionMap = /* @__PURE__ */ new WeakMap();
12150const newPositionMap = /* @__PURE__ */ new WeakMap();
12151const moveCbKey = Symbol("_moveCb");
12152const runtime_dom_esm_bundler_enterCbKey = Symbol("_enterCb");
12153const decorate = (t) => {
12154  delete t.props.mode;
12155  return t;
12156};
12157const TransitionGroupImpl = /* @__PURE__ */ decorate({
12158  name: "TransitionGroup",
12159  props: /* @__PURE__ */ shared_esm_bundler_extend({}, TransitionPropsValidators, {
12160    tag: String,
12161    moveClass: String
12162  }),
12163  setup(props, { slots }) {
12164    const instance = getCurrentInstance();
12165    const state = useTransitionState();
12166    let prevChildren;
12167    let children;
12168    onUpdated(() => {
12169      if (!prevChildren.length) {
12170        return;
12171      }
12172      const moveClass = props.moveClass || `${props.name || "v"}-move`;
12173      if (!hasCSSTransform(
12174        prevChildren[0].el,
12175        instance.vnode.el,
12176        moveClass
12177      )) {
12178        prevChildren = [];
12179        return;
12180      }
12181      prevChildren.forEach(callPendingCbs);
12182      prevChildren.forEach(recordPosition);
12183      const movedChildren = prevChildren.filter(applyTranslation);
12184      forceReflow(instance.vnode.el);
12185      movedChildren.forEach((c) => {
12186        const el = c.el;
12187        const style = el.style;
12188        addTransitionClass(el, moveClass);
12189        style.transform = style.webkitTransform = style.transitionDuration = "";
12190        const cb = el[moveCbKey] = (e) => {
12191          if (e && e.target !== el) {
12192            return;
12193          }
12194          if (!e || e.propertyName.endsWith("transform")) {
12195            el.removeEventListener("transitionend", cb);
12196            el[moveCbKey] = null;
12197            removeTransitionClass(el, moveClass);
12198          }
12199        };
12200        el.addEventListener("transitionend", cb);
12201      });
12202      prevChildren = [];
12203    });
12204    return () => {
12205      const rawProps = reactivity_esm_bundler_toRaw(props);
12206      const cssTransitionProps = resolveTransitionProps(rawProps);
12207      let tag = rawProps.tag || Fragment;
12208      prevChildren = [];
12209      if (children) {
12210        for (let i = 0; i < children.length; i++) {
12211          const child = children[i];
12212          if (child.el && child.el instanceof Element) {
12213            prevChildren.push(child);
12214            setTransitionHooks(
12215              child,
12216              resolveTransitionHooks(
12217                child,
12218                cssTransitionProps,
12219                state,
12220                instance
12221              )
12222            );
12223            positionMap.set(child, {
12224              left: child.el.offsetLeft,
12225              top: child.el.offsetTop
12226            });
12227          }
12228        }
12229      }
12230      children = slots.default ? getTransitionRawChildren(slots.default()) : [];
12231      for (let i = 0; i < children.length; i++) {
12232        const child = children[i];
12233        if (child.key != null) {
12234          setTransitionHooks(
12235            child,
12236            resolveTransitionHooks(child, cssTransitionProps, state, instance)
12237          );
12238        } else if (false) // removed by dead control flow
12239{}
12240      }
12241      return createVNode(tag, null, children);
12242    };
12243  }
12244});
12245const TransitionGroup = TransitionGroupImpl;
12246function callPendingCbs(c) {
12247  const el = c.el;
12248  if (el[moveCbKey]) {
12249    el[moveCbKey]();
12250  }
12251  if (el[runtime_dom_esm_bundler_enterCbKey]) {
12252    el[runtime_dom_esm_bundler_enterCbKey]();
12253  }
12254}
12255function recordPosition(c) {
12256  newPositionMap.set(c, {
12257    left: c.el.offsetLeft,
12258    top: c.el.offsetTop
12259  });
12260}
12261function applyTranslation(c) {
12262  const oldPos = positionMap.get(c);
12263  const newPos = newPositionMap.get(c);
12264  const dx = oldPos.left - newPos.left;
12265  const dy = oldPos.top - newPos.top;
12266  if (dx || dy) {
12267    const s = c.el.style;
12268    s.transform = s.webkitTransform = `translate(${dx}px,${dy}px)`;
12269    s.transitionDuration = "0s";
12270    return c;
12271  }
12272}
12273function hasCSSTransform(el, root, moveClass) {
12274  const clone = el.cloneNode();
12275  const _vtc = el[vtcKey];
12276  if (_vtc) {
vendor: 14,623 bytes, lines 12277-12739
12277    _vtc.forEach((cls) => {
12278      cls.split(/\s+/).forEach((c) => c && clone.classList.remove(c));
12279    });
12280  }
12281  moveClass.split(/\s+/).forEach((c) => c && clone.classList.add(c));
12282  clone.style.display = "none";
12283  const container = root.nodeType === 1 ? root : root.parentNode;
12284  container.appendChild(clone);
12285  const { hasTransform } = getTransitionInfo(clone);
12286  container.removeChild(clone);
12287  return hasTransform;
12288}
12289
12290const getModelAssigner = (vnode) => {
12291  const fn = vnode.props["onUpdate:modelValue"] || false;
12292  return shared_esm_bundler_isArray(fn) ? (value) => invokeArrayFns(fn, value) : fn;
12293};
12294function onCompositionStart(e) {
12295  e.target.composing = true;
12296}
12297function onCompositionEnd(e) {
12298  const target = e.target;
12299  if (target.composing) {
12300    target.composing = false;
12301    target.dispatchEvent(new Event("input"));
12302  }
12303}
12304const assignKey = Symbol("_assign");
12305function castValue(value, trim, number) {
12306  if (trim) value = value.trim();
12307  if (number) value = looseToNumber(value);
12308  return value;
12309}
12310const vModelText = {
12311  created(el, { modifiers: { lazy, trim, number } }, vnode) {
12312    el[assignKey] = getModelAssigner(vnode);
12313    const castToNumber = number || vnode.props && vnode.props.type === "number";
12314    addEventListener(el, lazy ? "change" : "input", (e) => {
12315      if (e.target.composing) return;
12316      el[assignKey](castValue(el.value, trim, castToNumber));
12317    });
12318    if (trim || castToNumber) {
12319      addEventListener(el, "change", () => {
12320        el.value = castValue(el.value, trim, castToNumber);
12321      });
12322    }
12323    if (!lazy) {
12324      addEventListener(el, "compositionstart", onCompositionStart);
12325      addEventListener(el, "compositionend", onCompositionEnd);
12326      addEventListener(el, "change", onCompositionEnd);
12327    }
12328  },
12329  // set value on mounted so it's after min/max for type="range"
12330  mounted(el, { value }) {
12331    el.value = value == null ? "" : value;
12332  },
12333  beforeUpdate(el, { value, oldValue, modifiers: { lazy, trim, number } }, vnode) {
12334    el[assignKey] = getModelAssigner(vnode);
12335    if (el.composing) return;
12336    const elValue = (number || el.type === "number") && !/^0\d/.test(el.value) ? looseToNumber(el.value) : el.value;
12337    const newValue = value == null ? "" : value;
12338    if (elValue === newValue) {
12339      return;
12340    }
12341    if (document.activeElement === el && el.type !== "range") {
12342      if (lazy && value === oldValue) {
12343        return;
12344      }
12345      if (trim && el.value.trim() === newValue) {
12346        return;
12347      }
12348    }
12349    el.value = newValue;
12350  }
12351};
12352const vModelCheckbox = {
12353  // #4096 array checkboxes need to be deep traversed
12354  deep: true,
12355  created(el, _, vnode) {
12356    el[assignKey] = getModelAssigner(vnode);
12357    addEventListener(el, "change", () => {
12358      const modelValue = el._modelValue;
12359      const elementValue = getValue(el);
12360      const checked = el.checked;
12361      const assign = el[assignKey];
12362      if (shared_esm_bundler_isArray(modelValue)) {
12363        const index = looseIndexOf(modelValue, elementValue);
12364        const found = index !== -1;
12365        if (checked && !found) {
12366          assign(modelValue.concat(elementValue));
12367        } else if (!checked && found) {
12368          const filtered = [...modelValue];
12369          filtered.splice(index, 1);
12370          assign(filtered);
12371        }
12372      } else if (isSet(modelValue)) {
12373        const cloned = new Set(modelValue);
12374        if (checked) {
12375          cloned.add(elementValue);
12376        } else {
12377          cloned.delete(elementValue);
12378        }
12379        assign(cloned);
12380      } else {
12381        assign(getCheckboxValue(el, checked));
12382      }
12383    });
12384  },
12385  // set initial checked on mount to wait for true-value/false-value
12386  mounted: setChecked,
12387  beforeUpdate(el, binding, vnode) {
12388    el[assignKey] = getModelAssigner(vnode);
12389    setChecked(el, binding, vnode);
12390  }
12391};
12392function setChecked(el, { value, oldValue }, vnode) {
12393  el._modelValue = value;
12394  let checked;
12395  if (shared_esm_bundler_isArray(value)) {
12396    checked = looseIndexOf(value, vnode.props.value) > -1;
12397  } else if (isSet(value)) {
12398    checked = value.has(vnode.props.value);
12399  } else {
12400    if (value === oldValue) return;
12401    checked = looseEqual(value, getCheckboxValue(el, true));
12402  }
12403  if (el.checked !== checked) {
12404    el.checked = checked;
12405  }
12406}
12407const vModelRadio = {
12408  created(el, { value }, vnode) {
12409    el.checked = looseEqual(value, vnode.props.value);
12410    el[assignKey] = getModelAssigner(vnode);
12411    addEventListener(el, "change", () => {
12412      el[assignKey](getValue(el));
12413    });
12414  },
12415  beforeUpdate(el, { value, oldValue }, vnode) {
12416    el[assignKey] = getModelAssigner(vnode);
12417    if (value !== oldValue) {
12418      el.checked = looseEqual(value, vnode.props.value);
12419    }
12420  }
12421};
12422const vModelSelect = {
12423  // <select multiple> value need to be deep traversed
12424  deep: true,
12425  created(el, { value, modifiers: { number } }, vnode) {
12426    const isSetModel = isSet(value);
12427    addEventListener(el, "change", () => {
12428      const selectedVal = Array.prototype.filter.call(el.options, (o) => o.selected).map(
12429        (o) => number ? looseToNumber(getValue(o)) : getValue(o)
12430      );
12431      el[assignKey](
12432        el.multiple ? isSetModel ? new Set(selectedVal) : selectedVal : selectedVal[0]
12433      );
12434      el._assigning = true;
12435      nextTick(() => {
12436        el._assigning = false;
12437      });
12438    });
12439    el[assignKey] = getModelAssigner(vnode);
12440  },
12441  // set value in mounted & updated because <select> relies on its children
12442  // <option>s.
12443  mounted(el, { value }) {
12444    setSelected(el, value);
12445  },
12446  beforeUpdate(el, _binding, vnode) {
12447    el[assignKey] = getModelAssigner(vnode);
12448  },
12449  updated(el, { value }) {
12450    if (!el._assigning) {
12451      setSelected(el, value);
12452    }
12453  }
12454};
12455function setSelected(el, value) {
12456  const isMultiple = el.multiple;
12457  const isArrayValue = shared_esm_bundler_isArray(value);
12458  if (isMultiple && !isArrayValue && !isSet(value)) {
12459     false && 0;
12460    return;
12461  }
12462  for (let i = 0, l = el.options.length; i < l; i++) {
12463    const option = el.options[i];
12464    const optionValue = getValue(option);
12465    if (isMultiple) {
12466      if (isArrayValue) {
12467        const optionType = typeof optionValue;
12468        if (optionType === "string" || optionType === "number") {
12469          option.selected = value.some((v) => String(v) === String(optionValue));
12470        } else {
12471          option.selected = looseIndexOf(value, optionValue) > -1;
12472        }
12473      } else {
12474        option.selected = value.has(optionValue);
12475      }
12476    } else if (looseEqual(getValue(option), value)) {
12477      if (el.selectedIndex !== i) el.selectedIndex = i;
12478      return;
12479    }
12480  }
12481  if (!isMultiple && el.selectedIndex !== -1) {
12482    el.selectedIndex = -1;
12483  }
12484}
12485function getValue(el) {
12486  return "_value" in el ? el._value : el.value;
12487}
12488function getCheckboxValue(el, checked) {
12489  const key = checked ? "_trueValue" : "_falseValue";
12490  return key in el ? el[key] : checked;
12491}
12492const vModelDynamic = {
12493  created(el, binding, vnode) {
12494    callModelHook(el, binding, vnode, null, "created");
12495  },
12496  mounted(el, binding, vnode) {
12497    callModelHook(el, binding, vnode, null, "mounted");
12498  },
12499  beforeUpdate(el, binding, vnode, prevVNode) {
12500    callModelHook(el, binding, vnode, prevVNode, "beforeUpdate");
12501  },
12502  updated(el, binding, vnode, prevVNode) {
12503    callModelHook(el, binding, vnode, prevVNode, "updated");
12504  }
12505};
12506function resolveDynamicModel(tagName, type) {
12507  switch (tagName) {
12508    case "SELECT":
12509      return vModelSelect;
12510    case "TEXTAREA":
12511      return vModelText;
12512    default:
12513      switch (type) {
12514        case "checkbox":
12515          return vModelCheckbox;
12516        case "radio":
12517          return vModelRadio;
12518        default:
12519          return vModelText;
12520      }
12521  }
12522}
12523function callModelHook(el, binding, vnode, prevVNode, hook) {
12524  const modelToUse = resolveDynamicModel(
12525    el.tagName,
12526    vnode.props && vnode.props.type
12527  );
12528  const fn = modelToUse[hook];
12529  fn && fn(el, binding, vnode, prevVNode);
12530}
12531function initVModelForSSR() {
12532  vModelText.getSSRProps = ({ value }) => ({ value });
12533  vModelRadio.getSSRProps = ({ value }, vnode) => {
12534    if (vnode.props && looseEqual(vnode.props.value, value)) {
12535      return { checked: true };
12536    }
12537  };
12538  vModelCheckbox.getSSRProps = ({ value }, vnode) => {
12539    if (shared_esm_bundler_isArray(value)) {
12540      if (vnode.props && looseIndexOf(value, vnode.props.value) > -1) {
12541        return { checked: true };
12542      }
12543    } else if (isSet(value)) {
12544      if (vnode.props && value.has(vnode.props.value)) {
12545        return { checked: true };
12546      }
12547    } else if (value) {
12548      return { checked: true };
12549    }
12550  };
12551  vModelDynamic.getSSRProps = (binding, vnode) => {
12552    if (typeof vnode.type !== "string") {
12553      return;
12554    }
12555    const modelToUse = resolveDynamicModel(
12556      // resolveDynamicModel expects an uppercase tag name, but vnode.type is lowercase
12557      vnode.type.toUpperCase(),
12558      vnode.props && vnode.props.type
12559    );
12560    if (modelToUse.getSSRProps) {
12561      return modelToUse.getSSRProps(binding, vnode);
12562    }
12563  };
12564}
12565
12566const systemModifiers = ["ctrl", "shift", "alt", "meta"];
12567const modifierGuards = {
12568  stop: (e) => e.stopPropagation(),
12569  prevent: (e) => e.preventDefault(),
12570  self: (e) => e.target !== e.currentTarget,
12571  ctrl: (e) => !e.ctrlKey,
12572  shift: (e) => !e.shiftKey,
12573  alt: (e) => !e.altKey,
12574  meta: (e) => !e.metaKey,
12575  left: (e) => "button" in e && e.button !== 0,
12576  middle: (e) => "button" in e && e.button !== 1,
12577  right: (e) => "button" in e && e.button !== 2,
12578  exact: (e, modifiers) => systemModifiers.some((m) => e[`${m}Key`] && !modifiers.includes(m))
12579};
12580const withModifiers = (fn, modifiers) => {
12581  const cache = fn._withMods || (fn._withMods = {});
12582  const cacheKey = modifiers.join(".");
12583  return cache[cacheKey] || (cache[cacheKey] = ((event, ...args) => {
12584    for (let i = 0; i < modifiers.length; i++) {
12585      const guard = modifierGuards[modifiers[i]];
12586      if (guard && guard(event, modifiers)) return;
12587    }
12588    return fn(event, ...args);
12589  }));
12590};
12591const keyNames = {
12592  esc: "escape",
12593  space: " ",
12594  up: "arrow-up",
12595  left: "arrow-left",
12596  right: "arrow-right",
12597  down: "arrow-down",
12598  delete: "backspace"
12599};
12600const withKeys = (fn, modifiers) => {
12601  const cache = fn._withKeys || (fn._withKeys = {});
12602  const cacheKey = modifiers.join(".");
12603  return cache[cacheKey] || (cache[cacheKey] = ((event) => {
12604    if (!("key" in event)) {
12605      return;
12606    }
12607    const eventKey = hyphenate(event.key);
12608    if (modifiers.some(
12609      (k) => k === eventKey || keyNames[k] === eventKey
12610    )) {
12611      return fn(event);
12612    }
12613  }));
12614};
12615
12616const rendererOptions = /* @__PURE__ */ shared_esm_bundler_extend({ patchProp }, nodeOps);
12617let renderer;
12618let enabledHydration = false;
12619function ensureRenderer() {
12620  return renderer || (renderer = createRenderer(rendererOptions));
12621}
12622function ensureHydrationRenderer() {
12623  renderer = enabledHydration ? renderer : createHydrationRenderer(rendererOptions);
12624  enabledHydration = true;
12625  return renderer;
12626}
12627const render = ((...args) => {
12628  ensureRenderer().render(...args);
12629});
12630const hydrate = ((...args) => {
12631  ensureHydrationRenderer().hydrate(...args);
12632});
12633const createApp = ((...args) => {
12634  const app = ensureRenderer().createApp(...args);
12635  if (false) // removed by dead control flow
12636{}
12637  const { mount } = app;
12638  app.mount = (containerOrSelector) => {
12639    const container = normalizeContainer(containerOrSelector);
12640    if (!container) return;
12641    const component = app._component;
12642    if (!shared_esm_bundler_isFunction(component) && !component.render && !component.template) {
12643      component.template = container.innerHTML;
12644    }
12645    if (container.nodeType === 1) {
12646      container.textContent = "";
12647    }
12648    const proxy = mount(container, false, resolveRootNamespace(container));
12649    if (container instanceof Element) {
12650      container.removeAttribute("v-cloak");
12651      container.setAttribute("data-v-app", "");
12652    }
12653    return proxy;
12654  };
12655  return app;
12656});
12657const createSSRApp = ((...args) => {
12658  const app = ensureHydrationRenderer().createApp(...args);
12659  if (false) // removed by dead control flow
12660{}
12661  const { mount } = app;
12662  app.mount = (containerOrSelector) => {
12663    const container = normalizeContainer(containerOrSelector);
12664    if (container) {
12665      return mount(container, true, resolveRootNamespace(container));
12666    }
12667  };
12668  return app;
12669});
12670function resolveRootNamespace(container) {
12671  if (container instanceof SVGElement) {
12672    return "svg";
12673  }
12674  if (typeof MathMLElement === "function" && container instanceof MathMLElement) {
12675    return "mathml";
12676  }
12677}
12678function injectNativeTagCheck(app) {
12679  Object.defineProperty(app.config, "isNativeTag", {
12680    value: (tag) => isHTMLTag(tag) || isSVGTag(tag) || isMathMLTag(tag),
12681    writable: false
12682  });
12683}
12684function injectCompilerOptionsCheck(app) {
12685  if (isRuntimeOnly()) {
12686    const isCustomElement = app.config.isCustomElement;
12687    Object.defineProperty(app.config, "isCustomElement", {
12688      get() {
12689        return isCustomElement;
12690      },
12691      set() {
12692        warn(
12693          `The \`isCustomElement\` config option is deprecated. Use \`compilerOptions.isCustomElement\` instead.`
12694        );
12695      }
12696    });
12697    const compilerOptions = app.config.compilerOptions;
12698    const msg = `The \`compilerOptions\` config option is only respected when using a build of Vue.js that includes the runtime compiler (aka "full build"). Since you are using the runtime-only build, \`compilerOptions\` must be passed to \`@vue/compiler-dom\` in the build setup instead.
12699- For vue-loader: pass it via vue-loader's \`compilerOptions\` loader option.
12700- For vue-cli: see https://cli.vuejs.org/guide/webpack.html#modifying-options-of-a-loader
12701- For vite: pass it via @vitejs/plugin-vue options. See https://github.com/vitejs/vite-plugin-vue/tree/main/packages/plugin-vue#example-for-passing-options-to-vuecompiler-sfc`;
12702    Object.defineProperty(app.config, "compilerOptions", {
12703      get() {
12704        warn(msg);
12705        return compilerOptions;
12706      },
12707      set() {
12708        warn(msg);
12709      }
12710    });
12711  }
12712}
12713function normalizeContainer(container) {
12714  if (shared_esm_bundler_isString(container)) {
12715    const res = document.querySelector(container);
12716    if (false) // removed by dead control flow
12717{}
12718    return res;
12719  }
12720  if (false) // removed by dead control flow
12721{}
12722  return container;
12723}
12724let ssrDirectiveInitialized = false;
12725const initDirectivesForSSR = () => {
12726  if (!ssrDirectiveInitialized) {
12727    ssrDirectiveInitialized = true;
12728    initVModelForSSR();
12729    initVShowForSSR();
12730  }
12731} ;
12732
12733
12734
12735;// ./node_modules/@vue/compiler-core/dist/compiler-core.esm-bundler.js
12736/**
12737* @vue/compiler-core v3.5.25
12738* (c) 2018-present Yuxi (Evan) You and Vue contributors
12739* @license MIT
12740**/
12741
12742
12743
12744const FRAGMENT = Symbol( false ? 0 : ``);
12745const TELEPORT = Symbol( false ? 0 : ``);
12746const SUSPENSE = Symbol( false ? 0 : ``);
12747const KEEP_ALIVE = Symbol( false ? 0 : ``);
12748const BASE_TRANSITION = Symbol(
12749   false ? 0 : ``
12750);
12751const OPEN_BLOCK = Symbol( false ? 0 : ``);
12752const CREATE_BLOCK = Symbol( false ? 0 : ``);
12753const CREATE_ELEMENT_BLOCK = Symbol(
12754   false ? 0 : ``
12755);
12756const CREATE_VNODE = Symbol( false ? 0 : ``);
12757const CREATE_ELEMENT_VNODE = Symbol(
12758   false ? 0 : ``
12759);
12760const CREATE_COMMENT = Symbol(
12761   false ? 0 : ``
12762);
12763const CREATE_TEXT = Symbol(
12764   false ? 0 : ``
12765);
12766const CREATE_STATIC = Symbol(
12767   false ? 0 : ``
12768);
12769const RESOLVE_COMPONENT = Symbol(
12770   false ? 0 : ``
12771);
12772const RESOLVE_DYNAMIC_COMPONENT = Symbol(
12773   false ? 0 : ``
12774);
12775const RESOLVE_DIRECTIVE = Symbol(
12776   false ? 0 : ``
12777);
12778const RESOLVE_FILTER = Symbol(
12779   false ? 0 : ``
12780);
12781const WITH_DIRECTIVES = Symbol(
12782   false ? 0 : ``
12783);
12784const RENDER_LIST = Symbol( false ? 0 : ``);
12785const RENDER_SLOT = Symbol( false ? 0 : ``);
12786const CREATE_SLOTS = Symbol( false ? 0 : ``);
12787const TO_DISPLAY_STRING = Symbol(
12788   false ? 0 : ``
12789);
12790const MERGE_PROPS = Symbol( false ? 0 : ``);
12791const NORMALIZE_CLASS = Symbol(
12792   false ? 0 : ``
12793);
12794const NORMALIZE_STYLE = Symbol(
12795   false ? 0 : ``
12796);
12797const NORMALIZE_PROPS = Symbol(
12798   false ? 0 : ``
12799);
12800const GUARD_REACTIVE_PROPS = Symbol(
12801   false ? 0 : ``
12802);
12803const TO_HANDLERS = Symbol( false ? 0 : ``);
12804const CAMELIZE = Symbol( false ? 0 : ``);
12805const CAPITALIZE = Symbol( false ? 0 : ``);
12806const TO_HANDLER_KEY = Symbol(
12807   false ? 0 : ``
12808);
12809const SET_BLOCK_TRACKING = Symbol(
12810   false ? 0 : ``
12811);
12812const PUSH_SCOPE_ID = Symbol( false ? 0 : ``);
12813const POP_SCOPE_ID = Symbol( false ? 0 : ``);
12814const WITH_CTX = Symbol( false ? 0 : ``);
12815const UNREF = Symbol( false ? 0 : ``);
12816const IS_REF = Symbol( false ? 0 : ``);
12817const WITH_MEMO = Symbol( false ? 0 : ``);
12818const IS_MEMO_SAME = Symbol( false ? 0 : ``);
12819const helperNameMap = {
12820  [FRAGMENT]: `Fragment`,
12821  [TELEPORT]: `Teleport`,
12822  [SUSPENSE]: `Suspense`,
12823  [KEEP_ALIVE]: `KeepAlive`,
12824  [BASE_TRANSITION]: `BaseTransition`,
12825  [OPEN_BLOCK]: `openBlock`,
12826  [CREATE_BLOCK]: `createBlock`,
12827  [CREATE_ELEMENT_BLOCK]: `createElementBlock`,
12828  [CREATE_VNODE]: `createVNode`,
12829  [CREATE_ELEMENT_VNODE]: `createElementVNode`,
12830  [CREATE_COMMENT]: `createCommentVNode`,
12831  [CREATE_TEXT]: `createTextVNode`,
12832  [CREATE_STATIC]: `createStaticVNode`,
12833  [RESOLVE_COMPONENT]: `resolveComponent`,
12834  [RESOLVE_DYNAMIC_COMPONENT]: `resolveDynamicComponent`,
12835  [RESOLVE_DIRECTIVE]: `resolveDirective`,
12836  [RESOLVE_FILTER]: `resolveFilter`,
12837  [WITH_DIRECTIVES]: `withDirectives`,
12838  [RENDER_LIST]: `renderList`,
12839  [RENDER_SLOT]: `renderSlot`,
12840  [CREATE_SLOTS]: `createSlots`,
12841  [TO_DISPLAY_STRING]: `toDisplayString`,
12842  [MERGE_PROPS]: `mergeProps`,
12843  [NORMALIZE_CLASS]: `normalizeClass`,
12844  [NORMALIZE_STYLE]: `normalizeStyle`,
12845  [NORMALIZE_PROPS]: `normalizeProps`,
12846  [GUARD_REACTIVE_PROPS]: `guardReactiveProps`,
12847  [TO_HANDLERS]: `toHandlers`,
12848  [CAMELIZE]: `camelize`,
12849  [CAPITALIZE]: `capitalize`,
12850  [TO_HANDLER_KEY]: `toHandlerKey`,
12851  [SET_BLOCK_TRACKING]: `setBlockTracking`,
12852  [PUSH_SCOPE_ID]: `pushScopeId`,
12853  [POP_SCOPE_ID]: `popScopeId`,
12854  [WITH_CTX]: `withCtx`,
12855  [UNREF]: `unref`,
12856  [IS_REF]: `isRef`,
12857  [WITH_MEMO]: `withMemo`,
12858  [IS_MEMO_SAME]: `isMemoSame`
12859};
12860function registerRuntimeHelpers(helpers) {
12861  Object.getOwnPropertySymbols(helpers).forEach((s) => {
12862    helperNameMap[s] = helpers[s];
12863  });
12864}
12865
12866const Namespaces = {
12867  "HTML": 0,
12868  "0": "HTML",
12869  "SVG": 1,
12870  "1": "SVG",
12871  "MATH_ML": 2,
12872  "2": "MATH_ML"
12873};
12874const NodeTypes = {
12875  "ROOT": 0,
12876  "0": "ROOT",
12877  "ELEMENT": 1,
12878  "1": "ELEMENT",
12879  "TEXT": 2,
12880  "2": "TEXT",
12881  "COMMENT": 3,
12882  "3": "COMMENT",
12883  "SIMPLE_EXPRESSION": 4,
12884  "4": "SIMPLE_EXPRESSION",
12885  "INTERPOLATION": 5,
12886  "5": "INTERPOLATION",
12887  "ATTRIBUTE": 6,
12888  "6": "ATTRIBUTE",
12889  "DIRECTIVE": 7,
12890  "7": "DIRECTIVE",
12891  "COMPOUND_EXPRESSION": 8,
12892  "8": "COMPOUND_EXPRESSION",
12893  "IF": 9,
12894  "9": "IF",
12895  "IF_BRANCH": 10,
12896  "10": "IF_BRANCH",
12897  "FOR": 11,
12898  "11": "FOR",
12899  "TEXT_CALL": 12,
12900  "12": "TEXT_CALL",
12901  "VNODE_CALL": 13,
12902  "13": "VNODE_CALL",
12903  "JS_CALL_EXPRESSION": 14,
12904  "14": "JS_CALL_EXPRESSION",
12905  "JS_OBJECT_EXPRESSION": 15,
12906  "15": "JS_OBJECT_EXPRESSION",
12907  "JS_PROPERTY": 16,
12908  "16": "JS_PROPERTY",
12909  "JS_ARRAY_EXPRESSION": 17,
12910  "17": "JS_ARRAY_EXPRESSION",
12911  "JS_FUNCTION_EXPRESSION": 18,
12912  "18": "JS_FUNCTION_EXPRESSION",
12913  "JS_CONDITIONAL_EXPRESSION": 19,
12914  "19": "JS_CONDITIONAL_EXPRESSION",
12915  "JS_CACHE_EXPRESSION": 20,
12916  "20": "JS_CACHE_EXPRESSION",
12917  "JS_BLOCK_STATEMENT": 21,
12918  "21": "JS_BLOCK_STATEMENT",
12919  "JS_TEMPLATE_LITERAL": 22,
12920  "22": "JS_TEMPLATE_LITERAL",
12921  "JS_IF_STATEMENT": 23,
12922  "23": "JS_IF_STATEMENT",
12923  "JS_ASSIGNMENT_EXPRESSION": 24,
12924  "24": "JS_ASSIGNMENT_EXPRESSION",
12925  "JS_SEQUENCE_EXPRESSION": 25,
12926  "25": "JS_SEQUENCE_EXPRESSION",
12927  "JS_RETURN_STATEMENT": 26,
12928  "26": "JS_RETURN_STATEMENT"
12929};
12930const ElementTypes = {
12931  "ELEMENT": 0,
12932  "0": "ELEMENT",
12933  "COMPONENT": 1,
12934  "1": "COMPONENT",
12935  "SLOT": 2,
12936  "2": "SLOT",
12937  "TEMPLATE": 3,
12938  "3": "TEMPLATE"
vendor: 3,497 bytes, lines 12939-13118
12939};
12940const ConstantTypes = {
12941  "NOT_CONSTANT": 0,
12942  "0": "NOT_CONSTANT",
12943  "CAN_SKIP_PATCH": 1,
12944  "1": "CAN_SKIP_PATCH",
12945  "CAN_CACHE": 2,
12946  "2": "CAN_CACHE",
12947  "CAN_STRINGIFY": 3,
12948  "3": "CAN_STRINGIFY"
12949};
12950const locStub = {
12951  start: { line: 1, column: 1, offset: 0 },
12952  end: { line: 1, column: 1, offset: 0 },
12953  source: ""
12954};
12955function createRoot(children, source = "") {
12956  return {
12957    type: 0,
12958    source,
12959    children,
12960    helpers: /* @__PURE__ */ new Set(),
12961    components: [],
12962    directives: [],
12963    hoists: [],
12964    imports: [],
12965    cached: [],
12966    temps: 0,
12967    codegenNode: void 0,
12968    loc: locStub
12969  };
12970}
12971function createVNodeCall(context, tag, props, children, patchFlag, dynamicProps, directives, isBlock = false, disableTracking = false, isComponent = false, loc = locStub) {
12972  if (context) {
12973    if (isBlock) {
12974      context.helper(OPEN_BLOCK);
12975      context.helper(getVNodeBlockHelper(context.inSSR, isComponent));
12976    } else {
12977      context.helper(getVNodeHelper(context.inSSR, isComponent));
12978    }
12979    if (directives) {
12980      context.helper(WITH_DIRECTIVES);
12981    }
12982  }
12983  return {
12984    type: 13,
12985    tag,
12986    props,
12987    children,
12988    patchFlag,
12989    dynamicProps,
12990    directives,
12991    isBlock,
12992    disableTracking,
12993    isComponent,
12994    loc
12995  };
12996}
12997function createArrayExpression(elements, loc = locStub) {
12998  return {
12999    type: 17,
13000    loc,
13001    elements
13002  };
13003}
13004function createObjectExpression(properties, loc = locStub) {
13005  return {
13006    type: 15,
13007    loc,
13008    properties
13009  };
13010}
13011function createObjectProperty(key, value) {
13012  return {
13013    type: 16,
13014    loc: locStub,
13015    key: shared_esm_bundler_isString(key) ? createSimpleExpression(key, true) : key,
13016    value
13017  };
13018}
13019function createSimpleExpression(content, isStatic = false, loc = locStub, constType = 0) {
13020  return {
13021    type: 4,
13022    loc,
13023    content,
13024    isStatic,
13025    constType: isStatic ? 3 : constType
13026  };
13027}
13028function createInterpolation(content, loc) {
13029  return {
13030    type: 5,
13031    loc,
13032    content: isString(content) ? createSimpleExpression(content, false, loc) : content
13033  };
13034}
13035function createCompoundExpression(children, loc = locStub) {
13036  return {
13037    type: 8,
13038    loc,
13039    children
13040  };
13041}
13042function createCallExpression(callee, args = [], loc = locStub) {
13043  return {
13044    type: 14,
13045    loc,
13046    callee,
13047    arguments: args
13048  };
13049}
13050function createFunctionExpression(params, returns = void 0, newline = false, isSlot = false, loc = locStub) {
13051  return {
13052    type: 18,
13053    params,
13054    returns,
13055    newline,
13056    isSlot,
13057    loc
13058  };
13059}
13060function createConditionalExpression(test, consequent, alternate, newline = true) {
13061  return {
13062    type: 19,
13063    test,
13064    consequent,
13065    alternate,
13066    newline,
13067    loc: locStub
13068  };
13069}
13070function createCacheExpression(index, value, needPauseTracking = false, inVOnce = false) {
13071  return {
13072    type: 20,
13073    index,
13074    value,
13075    needPauseTracking,
13076    inVOnce,
13077    needArraySpread: false,
13078    loc: locStub
13079  };
13080}
13081function createBlockStatement(body) {
13082  return {
13083    type: 21,
13084    body,
13085    loc: locStub
13086  };
13087}
13088function createTemplateLiteral(elements) {
13089  return {
13090    type: 22,
13091    elements,
13092    loc: locStub
13093  };
13094}
13095function createIfStatement(test, consequent, alternate) {
13096  return {
13097    type: 23,
13098    test,
13099    consequent,
13100    alternate,
13101    loc: locStub
13102  };
13103}
13104function createAssignmentExpression(left, right) {
13105  return {
13106    type: 24,
13107    left,
13108    right,
13109    loc: locStub
13110  };
13111}
13112function createSequenceExpression(expressions) {
13113  return {
13114    type: 25,
13115    expressions,
13116    loc: locStub
13117  };
13118}
vendor: 16,076 bytes, lines 13119-13669
13119function createReturnStatement(returns) {
13120  return {
13121    type: 26,
13122    returns,
13123    loc: locStub
13124  };
13125}
13126function getVNodeHelper(ssr, isComponent) {
13127  return ssr || isComponent ? CREATE_VNODE : CREATE_ELEMENT_VNODE;
13128}
13129function getVNodeBlockHelper(ssr, isComponent) {
13130  return ssr || isComponent ? CREATE_BLOCK : CREATE_ELEMENT_BLOCK;
13131}
13132function convertToBlock(node, { helper, removeHelper, inSSR }) {
13133  if (!node.isBlock) {
13134    node.isBlock = true;
13135    removeHelper(getVNodeHelper(inSSR, node.isComponent));
13136    helper(OPEN_BLOCK);
13137    helper(getVNodeBlockHelper(inSSR, node.isComponent));
13138  }
13139}
13140
13141const defaultDelimitersOpen = new Uint8Array([123, 123]);
13142const defaultDelimitersClose = new Uint8Array([125, 125]);
13143function isTagStartChar(c) {
13144  return c >= 97 && c <= 122 || c >= 65 && c <= 90;
13145}
13146function isWhitespace(c) {
13147  return c === 32 || c === 10 || c === 9 || c === 12 || c === 13;
13148}
13149function isEndOfTagSection(c) {
13150  return c === 47 || c === 62 || isWhitespace(c);
13151}
13152function toCharCodes(str) {
13153  const ret = new Uint8Array(str.length);
13154  for (let i = 0; i < str.length; i++) {
13155    ret[i] = str.charCodeAt(i);
13156  }
13157  return ret;
13158}
13159const Sequences = {
13160  Cdata: new Uint8Array([67, 68, 65, 84, 65, 91]),
13161  // CDATA[
13162  CdataEnd: new Uint8Array([93, 93, 62]),
13163  // ]]>
13164  CommentEnd: new Uint8Array([45, 45, 62]),
13165  // `-->`
13166  ScriptEnd: new Uint8Array([60, 47, 115, 99, 114, 105, 112, 116]),
13167  // `<\/script`
13168  StyleEnd: new Uint8Array([60, 47, 115, 116, 121, 108, 101]),
13169  // `</style`
13170  TitleEnd: new Uint8Array([60, 47, 116, 105, 116, 108, 101]),
13171  // `</title`
13172  TextareaEnd: new Uint8Array([
13173    60,
13174    47,
13175    116,
13176    101,
13177    120,
13178    116,
13179    97,
13180    114,
13181    101,
13182    97
13183  ])
13184  // `</textarea
13185};
13186class Tokenizer {
13187  constructor(stack, cbs) {
13188    this.stack = stack;
13189    this.cbs = cbs;
13190    /** The current state the tokenizer is in. */
13191    this.state = 1;
13192    /** The read buffer. */
13193    this.buffer = "";
13194    /** The beginning of the section that is currently being read. */
13195    this.sectionStart = 0;
13196    /** The index within the buffer that we are currently looking at. */
13197    this.index = 0;
13198    /** The start of the last entity. */
13199    this.entityStart = 0;
13200    /** Some behavior, eg. when decoding entities, is done while we are in another state. This keeps track of the other state type. */
13201    this.baseState = 1;
13202    /** For special parsing behavior inside of script and style tags. */
13203    this.inRCDATA = false;
13204    /** For disabling RCDATA tags handling */
13205    this.inXML = false;
13206    /** For disabling interpolation parsing in v-pre */
13207    this.inVPre = false;
13208    /** Record newline positions for fast line / column calculation */
13209    this.newlines = [];
13210    this.mode = 0;
13211    this.delimiterOpen = defaultDelimitersOpen;
13212    this.delimiterClose = defaultDelimitersClose;
13213    this.delimiterIndex = -1;
13214    this.currentSequence = void 0;
13215    this.sequenceIndex = 0;
13216  }
13217  get inSFCRoot() {
13218    return this.mode === 2 && this.stack.length === 0;
13219  }
13220  reset() {
13221    this.state = 1;
13222    this.mode = 0;
13223    this.buffer = "";
13224    this.sectionStart = 0;
13225    this.index = 0;
13226    this.baseState = 1;
13227    this.inRCDATA = false;
13228    this.currentSequence = void 0;
13229    this.newlines.length = 0;
13230    this.delimiterOpen = defaultDelimitersOpen;
13231    this.delimiterClose = defaultDelimitersClose;
13232  }
13233  /**
13234   * Generate Position object with line / column information using recorded
13235   * newline positions. We know the index is always going to be an already
13236   * processed index, so all the newlines up to this index should have been
13237   * recorded.
13238   */
13239  getPos(index) {
13240    let line = 1;
13241    let column = index + 1;
13242    for (let i = this.newlines.length - 1; i >= 0; i--) {
13243      const newlineIndex = this.newlines[i];
13244      if (index > newlineIndex) {
13245        line = i + 2;
13246        column = index - newlineIndex;
13247        break;
13248      }
13249    }
13250    return {
13251      column,
13252      line,
13253      offset: index
13254    };
13255  }
13256  peek() {
13257    return this.buffer.charCodeAt(this.index + 1);
13258  }
13259  stateText(c) {
13260    if (c === 60) {
13261      if (this.index > this.sectionStart) {
13262        this.cbs.ontext(this.sectionStart, this.index);
13263      }
13264      this.state = 5;
13265      this.sectionStart = this.index;
13266    } else if (!this.inVPre && c === this.delimiterOpen[0]) {
13267      this.state = 2;
13268      this.delimiterIndex = 0;
13269      this.stateInterpolationOpen(c);
13270    }
13271  }
13272  stateInterpolationOpen(c) {
13273    if (c === this.delimiterOpen[this.delimiterIndex]) {
13274      if (this.delimiterIndex === this.delimiterOpen.length - 1) {
13275        const start = this.index + 1 - this.delimiterOpen.length;
13276        if (start > this.sectionStart) {
13277          this.cbs.ontext(this.sectionStart, start);
13278        }
13279        this.state = 3;
13280        this.sectionStart = start;
13281      } else {
13282        this.delimiterIndex++;
13283      }
13284    } else if (this.inRCDATA) {
13285      this.state = 32;
13286      this.stateInRCDATA(c);
13287    } else {
13288      this.state = 1;
13289      this.stateText(c);
13290    }
13291  }
13292  stateInterpolation(c) {
13293    if (c === this.delimiterClose[0]) {
13294      this.state = 4;
13295      this.delimiterIndex = 0;
13296      this.stateInterpolationClose(c);
13297    }
13298  }
13299  stateInterpolationClose(c) {
13300    if (c === this.delimiterClose[this.delimiterIndex]) {
13301      if (this.delimiterIndex === this.delimiterClose.length - 1) {
13302        this.cbs.oninterpolation(this.sectionStart, this.index + 1);
13303        if (this.inRCDATA) {
13304          this.state = 32;
13305        } else {
13306          this.state = 1;
13307        }
13308        this.sectionStart = this.index + 1;
13309      } else {
13310        this.delimiterIndex++;
13311      }
13312    } else {
13313      this.state = 3;
13314      this.stateInterpolation(c);
13315    }
13316  }
13317  stateSpecialStartSequence(c) {
13318    const isEnd = this.sequenceIndex === this.currentSequence.length;
13319    const isMatch = isEnd ? (
13320      // If we are at the end of the sequence, make sure the tag name has ended
13321      isEndOfTagSection(c)
13322    ) : (
13323      // Otherwise, do a case-insensitive comparison
13324      (c | 32) === this.currentSequence[this.sequenceIndex]
13325    );
13326    if (!isMatch) {
13327      this.inRCDATA = false;
13328    } else if (!isEnd) {
13329      this.sequenceIndex++;
13330      return;
13331    }
13332    this.sequenceIndex = 0;
13333    this.state = 6;
13334    this.stateInTagName(c);
13335  }
13336  /** Look for an end tag. For <title> and <textarea>, also decode entities. */
13337  stateInRCDATA(c) {
13338    if (this.sequenceIndex === this.currentSequence.length) {
13339      if (c === 62 || isWhitespace(c)) {
13340        const endOfText = this.index - this.currentSequence.length;
13341        if (this.sectionStart < endOfText) {
13342          const actualIndex = this.index;
13343          this.index = endOfText;
13344          this.cbs.ontext(this.sectionStart, endOfText);
13345          this.index = actualIndex;
13346        }
13347        this.sectionStart = endOfText + 2;
13348        this.stateInClosingTagName(c);
13349        this.inRCDATA = false;
13350        return;
13351      }
13352      this.sequenceIndex = 0;
13353    }
13354    if ((c | 32) === this.currentSequence[this.sequenceIndex]) {
13355      this.sequenceIndex += 1;
13356    } else if (this.sequenceIndex === 0) {
13357      if (this.currentSequence === Sequences.TitleEnd || this.currentSequence === Sequences.TextareaEnd && !this.inSFCRoot) {
13358        if (!this.inVPre && c === this.delimiterOpen[0]) {
13359          this.state = 2;
13360          this.delimiterIndex = 0;
13361          this.stateInterpolationOpen(c);
13362        }
13363      } else if (this.fastForwardTo(60)) {
13364        this.sequenceIndex = 1;
13365      }
13366    } else {
13367      this.sequenceIndex = Number(c === 60);
13368    }
13369  }
13370  stateCDATASequence(c) {
13371    if (c === Sequences.Cdata[this.sequenceIndex]) {
13372      if (++this.sequenceIndex === Sequences.Cdata.length) {
13373        this.state = 28;
13374        this.currentSequence = Sequences.CdataEnd;
13375        this.sequenceIndex = 0;
13376        this.sectionStart = this.index + 1;
13377      }
13378    } else {
13379      this.sequenceIndex = 0;
13380      this.state = 23;
13381      this.stateInDeclaration(c);
13382    }
13383  }
13384  /**
13385   * When we wait for one specific character, we can speed things up
13386   * by skipping through the buffer until we find it.
13387   *
13388   * @returns Whether the character was found.
13389   */
13390  fastForwardTo(c) {
13391    while (++this.index < this.buffer.length) {
13392      const cc = this.buffer.charCodeAt(this.index);
13393      if (cc === 10) {
13394        this.newlines.push(this.index);
13395      }
13396      if (cc === c) {
13397        return true;
13398      }
13399    }
13400    this.index = this.buffer.length - 1;
13401    return false;
13402  }
13403  /**
13404   * Comments and CDATA end with `-->` and `]]>`.
13405   *
13406   * Their common qualities are:
13407   * - Their end sequences have a distinct character they start with.
13408   * - That character is then repeated, so we have to check multiple repeats.
13409   * - All characters but the start character of the sequence can be skipped.
13410   */
13411  stateInCommentLike(c) {
13412    if (c === this.currentSequence[this.sequenceIndex]) {
13413      if (++this.sequenceIndex === this.currentSequence.length) {
13414        if (this.currentSequence === Sequences.CdataEnd) {
13415          this.cbs.oncdata(this.sectionStart, this.index - 2);
13416        } else {
13417          this.cbs.oncomment(this.sectionStart, this.index - 2);
13418        }
13419        this.sequenceIndex = 0;
13420        this.sectionStart = this.index + 1;
13421        this.state = 1;
13422      }
13423    } else if (this.sequenceIndex === 0) {
13424      if (this.fastForwardTo(this.currentSequence[0])) {
13425        this.sequenceIndex = 1;
13426      }
13427    } else if (c !== this.currentSequence[this.sequenceIndex - 1]) {
13428      this.sequenceIndex = 0;
13429    }
13430  }
13431  startSpecial(sequence, offset) {
13432    this.enterRCDATA(sequence, offset);
13433    this.state = 31;
13434  }
13435  enterRCDATA(sequence, offset) {
13436    this.inRCDATA = true;
13437    this.currentSequence = sequence;
13438    this.sequenceIndex = offset;
13439  }
13440  stateBeforeTagName(c) {
13441    if (c === 33) {
13442      this.state = 22;
13443      this.sectionStart = this.index + 1;
13444    } else if (c === 63) {
13445      this.state = 24;
13446      this.sectionStart = this.index + 1;
13447    } else if (isTagStartChar(c)) {
13448      this.sectionStart = this.index;
13449      if (this.mode === 0) {
13450        this.state = 6;
13451      } else if (this.inSFCRoot) {
13452        this.state = 34;
13453      } else if (!this.inXML) {
13454        if (c === 116) {
13455          this.state = 30;
13456        } else {
13457          this.state = c === 115 ? 29 : 6;
13458        }
13459      } else {
13460        this.state = 6;
13461      }
13462    } else if (c === 47) {
13463      this.state = 8;
13464    } else {
13465      this.state = 1;
13466      this.stateText(c);
13467    }
13468  }
13469  stateInTagName(c) {
13470    if (isEndOfTagSection(c)) {
13471      this.handleTagName(c);
13472    }
13473  }
13474  stateInSFCRootTagName(c) {
13475    if (isEndOfTagSection(c)) {
13476      const tag = this.buffer.slice(this.sectionStart, this.index);
13477      if (tag !== "template") {
13478        this.enterRCDATA(toCharCodes(`</` + tag), 0);
13479      }
13480      this.handleTagName(c);
13481    }
13482  }
13483  handleTagName(c) {
13484    this.cbs.onopentagname(this.sectionStart, this.index);
13485    this.sectionStart = -1;
13486    this.state = 11;
13487    this.stateBeforeAttrName(c);
13488  }
13489  stateBeforeClosingTagName(c) {
13490    if (isWhitespace(c)) ; else if (c === 62) {
13491      if (false) // removed by dead control flow
13492{}
13493      this.state = 1;
13494      this.sectionStart = this.index + 1;
13495    } else {
13496      this.state = isTagStartChar(c) ? 9 : 27;
13497      this.sectionStart = this.index;
13498    }
13499  }
13500  stateInClosingTagName(c) {
13501    if (c === 62 || isWhitespace(c)) {
13502      this.cbs.onclosetag(this.sectionStart, this.index);
13503      this.sectionStart = -1;
13504      this.state = 10;
13505      this.stateAfterClosingTagName(c);
13506    }
13507  }
13508  stateAfterClosingTagName(c) {
13509    if (c === 62) {
13510      this.state = 1;
13511      this.sectionStart = this.index + 1;
13512    }
13513  }
13514  stateBeforeAttrName(c) {
13515    if (c === 62) {
13516      this.cbs.onopentagend(this.index);
13517      if (this.inRCDATA) {
13518        this.state = 32;
13519      } else {
13520        this.state = 1;
13521      }
13522      this.sectionStart = this.index + 1;
13523    } else if (c === 47) {
13524      this.state = 7;
13525      if (false) // removed by dead control flow
13526{}
13527    } else if (c === 60 && this.peek() === 47) {
13528      this.cbs.onopentagend(this.index);
13529      this.state = 5;
13530      this.sectionStart = this.index;
13531    } else if (!isWhitespace(c)) {
13532      if (false) // removed by dead control flow
13533{}
13534      this.handleAttrStart(c);
13535    }
13536  }
13537  handleAttrStart(c) {
13538    if (c === 118 && this.peek() === 45) {
13539      this.state = 13;
13540      this.sectionStart = this.index;
13541    } else if (c === 46 || c === 58 || c === 64 || c === 35) {
13542      this.cbs.ondirname(this.index, this.index + 1);
13543      this.state = 14;
13544      this.sectionStart = this.index + 1;
13545    } else {
13546      this.state = 12;
13547      this.sectionStart = this.index;
13548    }
13549  }
13550  stateInSelfClosingTag(c) {
13551    if (c === 62) {
13552      this.cbs.onselfclosingtag(this.index);
13553      this.state = 1;
13554      this.sectionStart = this.index + 1;
13555      this.inRCDATA = false;
13556    } else if (!isWhitespace(c)) {
13557      this.state = 11;
13558      this.stateBeforeAttrName(c);
13559    }
13560  }
13561  stateInAttrName(c) {
13562    if (c === 61 || isEndOfTagSection(c)) {
13563      this.cbs.onattribname(this.sectionStart, this.index);
13564      this.handleAttrNameEnd(c);
13565    } else if (false) // removed by dead control flow
13566{}
13567  }
13568  stateInDirName(c) {
13569    if (c === 61 || isEndOfTagSection(c)) {
13570      this.cbs.ondirname(this.sectionStart, this.index);
13571      this.handleAttrNameEnd(c);
13572    } else if (c === 58) {
13573      this.cbs.ondirname(this.sectionStart, this.index);
13574      this.state = 14;
13575      this.sectionStart = this.index + 1;
13576    } else if (c === 46) {
13577      this.cbs.ondirname(this.sectionStart, this.index);
13578      this.state = 16;
13579      this.sectionStart = this.index + 1;
13580    }
13581  }
13582  stateInDirArg(c) {
13583    if (c === 61 || isEndOfTagSection(c)) {
13584      this.cbs.ondirarg(this.sectionStart, this.index);
13585      this.handleAttrNameEnd(c);
13586    } else if (c === 91) {
13587      this.state = 15;
13588    } else if (c === 46) {
13589      this.cbs.ondirarg(this.sectionStart, this.index);
13590      this.state = 16;
13591      this.sectionStart = this.index + 1;
13592    }
13593  }
13594  stateInDynamicDirArg(c) {
13595    if (c === 93) {
13596      this.state = 14;
13597    } else if (c === 61 || isEndOfTagSection(c)) {
13598      this.cbs.ondirarg(this.sectionStart, this.index + 1);
13599      this.handleAttrNameEnd(c);
13600      if (false) // removed by dead control flow
13601{}
13602    }
13603  }
13604  stateInDirModifier(c) {
13605    if (c === 61 || isEndOfTagSection(c)) {
13606      this.cbs.ondirmodifier(this.sectionStart, this.index);
13607      this.handleAttrNameEnd(c);
13608    } else if (c === 46) {
13609      this.cbs.ondirmodifier(this.sectionStart, this.index);
13610      this.sectionStart = this.index + 1;
13611    }
13612  }
13613  handleAttrNameEnd(c) {
13614    this.sectionStart = this.index;
13615    this.state = 17;
13616    this.cbs.onattribnameend(this.index);
13617    this.stateAfterAttrName(c);
13618  }
13619  stateAfterAttrName(c) {
13620    if (c === 61) {
13621      this.state = 18;
13622    } else if (c === 47 || c === 62) {
13623      this.cbs.onattribend(0, this.sectionStart);
13624      this.sectionStart = -1;
13625      this.state = 11;
13626      this.stateBeforeAttrName(c);
13627    } else if (!isWhitespace(c)) {
13628      this.cbs.onattribend(0, this.sectionStart);
13629      this.handleAttrStart(c);
13630    }
13631  }
13632  stateBeforeAttrValue(c) {
13633    if (c === 34) {
13634      this.state = 19;
13635      this.sectionStart = this.index + 1;
13636    } else if (c === 39) {
13637      this.state = 20;
13638      this.sectionStart = this.index + 1;
13639    } else if (!isWhitespace(c)) {
13640      this.sectionStart = this.index;
13641      this.state = 21;
13642      this.stateInAttrValueNoQuotes(c);
13643    }
13644  }
13645  handleInAttrValue(c, quote) {
13646    if (c === quote || this.fastForwardTo(quote)) {
13647      this.cbs.onattribdata(this.sectionStart, this.index);
13648      this.sectionStart = -1;
13649      this.cbs.onattribend(
13650        quote === 34 ? 3 : 2,
13651        this.index + 1
13652      );
13653      this.state = 11;
13654    }
13655  }
13656  stateInAttrValueDoubleQuotes(c) {
13657    this.handleInAttrValue(c, 34);
13658  }
13659  stateInAttrValueSingleQuotes(c) {
13660    this.handleInAttrValue(c, 39);
13661  }
13662  stateInAttrValueNoQuotes(c) {
13663    if (isWhitespace(c) || c === 62) {
13664      this.cbs.onattribdata(this.sectionStart, this.index);
13665      this.sectionStart = -1;
13666      this.cbs.onattribend(1, this.index);
13667      this.state = 11;
13668      this.stateBeforeAttrName(c);
13669    } else if ( false
vendor: 7,519 bytes, lines 13669-13947
13669 || c === 39 || c === 60 || c === 61 || c === 96) {
13670      this.cbs.onerr(
13671        18,
13672        this.index
13673      );
13674    } else ;
13675  }
13676  stateBeforeDeclaration(c) {
13677    if (c === 91) {
13678      this.state = 26;
13679      this.sequenceIndex = 0;
13680    } else {
13681      this.state = c === 45 ? 25 : 23;
13682    }
13683  }
13684  stateInDeclaration(c) {
13685    if (c === 62 || this.fastForwardTo(62)) {
13686      this.state = 1;
13687      this.sectionStart = this.index + 1;
13688    }
13689  }
13690  stateInProcessingInstruction(c) {
13691    if (c === 62 || this.fastForwardTo(62)) {
13692      this.cbs.onprocessinginstruction(this.sectionStart, this.index);
13693      this.state = 1;
13694      this.sectionStart = this.index + 1;
13695    }
13696  }
13697  stateBeforeComment(c) {
13698    if (c === 45) {
13699      this.state = 28;
13700      this.currentSequence = Sequences.CommentEnd;
13701      this.sequenceIndex = 2;
13702      this.sectionStart = this.index + 1;
13703    } else {
13704      this.state = 23;
13705    }
13706  }
13707  stateInSpecialComment(c) {
13708    if (c === 62 || this.fastForwardTo(62)) {
13709      this.cbs.oncomment(this.sectionStart, this.index);
13710      this.state = 1;
13711      this.sectionStart = this.index + 1;
13712    }
13713  }
13714  stateBeforeSpecialS(c) {
13715    if (c === Sequences.ScriptEnd[3]) {
13716      this.startSpecial(Sequences.ScriptEnd, 4);
13717    } else if (c === Sequences.StyleEnd[3]) {
13718      this.startSpecial(Sequences.StyleEnd, 4);
13719    } else {
13720      this.state = 6;
13721      this.stateInTagName(c);
13722    }
13723  }
13724  stateBeforeSpecialT(c) {
13725    if (c === Sequences.TitleEnd[3]) {
13726      this.startSpecial(Sequences.TitleEnd, 4);
13727    } else if (c === Sequences.TextareaEnd[3]) {
13728      this.startSpecial(Sequences.TextareaEnd, 4);
13729    } else {
13730      this.state = 6;
13731      this.stateInTagName(c);
13732    }
13733  }
13734  startEntity() {
13735  }
13736  stateInEntity() {
13737  }
13738  /**
13739   * Iterates through the buffer, calling the function corresponding to the current state.
13740   *
13741   * States that are more likely to be hit are higher up, as a performance improvement.
13742   */
13743  parse(input) {
13744    this.buffer = input;
13745    while (this.index < this.buffer.length) {
13746      const c = this.buffer.charCodeAt(this.index);
13747      if (c === 10 && this.state !== 33) {
13748        this.newlines.push(this.index);
13749      }
13750      switch (this.state) {
13751        case 1: {
13752          this.stateText(c);
13753          break;
13754        }
13755        case 2: {
13756          this.stateInterpolationOpen(c);
13757          break;
13758        }
13759        case 3: {
13760          this.stateInterpolation(c);
13761          break;
13762        }
13763        case 4: {
13764          this.stateInterpolationClose(c);
13765          break;
13766        }
13767        case 31: {
13768          this.stateSpecialStartSequence(c);
13769          break;
13770        }
13771        case 32: {
13772          this.stateInRCDATA(c);
13773          break;
13774        }
13775        case 26: {
13776          this.stateCDATASequence(c);
13777          break;
13778        }
13779        case 19: {
13780          this.stateInAttrValueDoubleQuotes(c);
13781          break;
13782        }
13783        case 12: {
13784          this.stateInAttrName(c);
13785          break;
13786        }
13787        case 13: {
13788          this.stateInDirName(c);
13789          break;
13790        }
13791        case 14: {
13792          this.stateInDirArg(c);
13793          break;
13794        }
13795        case 15: {
13796          this.stateInDynamicDirArg(c);
13797          break;
13798        }
13799        case 16: {
13800          this.stateInDirModifier(c);
13801          break;
13802        }
13803        case 28: {
13804          this.stateInCommentLike(c);
13805          break;
13806        }
13807        case 27: {
13808          this.stateInSpecialComment(c);
13809          break;
13810        }
13811        case 11: {
13812          this.stateBeforeAttrName(c);
13813          break;
13814        }
13815        case 6: {
13816          this.stateInTagName(c);
13817          break;
13818        }
13819        case 34: {
13820          this.stateInSFCRootTagName(c);
13821          break;
13822        }
13823        case 9: {
13824          this.stateInClosingTagName(c);
13825          break;
13826        }
13827        case 5: {
13828          this.stateBeforeTagName(c);
13829          break;
13830        }
13831        case 17: {
13832          this.stateAfterAttrName(c);
13833          break;
13834        }
13835        case 20: {
13836          this.stateInAttrValueSingleQuotes(c);
13837          break;
13838        }
13839        case 18: {
13840          this.stateBeforeAttrValue(c);
13841          break;
13842        }
13843        case 8: {
13844          this.stateBeforeClosingTagName(c);
13845          break;
13846        }
13847        case 10: {
13848          this.stateAfterClosingTagName(c);
13849          break;
13850        }
13851        case 29: {
13852          this.stateBeforeSpecialS(c);
13853          break;
13854        }
13855        case 30: {
13856          this.stateBeforeSpecialT(c);
13857          break;
13858        }
13859        case 21: {
13860          this.stateInAttrValueNoQuotes(c);
13861          break;
13862        }
13863        case 7: {
13864          this.stateInSelfClosingTag(c);
13865          break;
13866        }
13867        case 23: {
13868          this.stateInDeclaration(c);
13869          break;
13870        }
13871        case 22: {
13872          this.stateBeforeDeclaration(c);
13873          break;
13874        }
13875        case 25: {
13876          this.stateBeforeComment(c);
13877          break;
13878        }
13879        case 24: {
13880          this.stateInProcessingInstruction(c);
13881          break;
13882        }
13883        case 33: {
13884          this.stateInEntity();
13885          break;
13886        }
13887      }
13888      this.index++;
13889    }
13890    this.cleanup();
13891    this.finish();
13892  }
13893  /**
13894   * Remove data that has already been consumed from the buffer.
13895   */
13896  cleanup() {
13897    if (this.sectionStart !== this.index) {
13898      if (this.state === 1 || this.state === 32 && this.sequenceIndex === 0) {
13899        this.cbs.ontext(this.sectionStart, this.index);
13900        this.sectionStart = this.index;
13901      } else if (this.state === 19 || this.state === 20 || this.state === 21) {
13902        this.cbs.onattribdata(this.sectionStart, this.index);
13903        this.sectionStart = this.index;
13904      }
13905    }
13906  }
13907  finish() {
13908    this.handleTrailingData();
13909    this.cbs.onend();
13910  }
13911  /** Handle any trailing data. */
13912  handleTrailingData() {
13913    const endIndex = this.buffer.length;
13914    if (this.sectionStart >= endIndex) {
13915      return;
13916    }
13917    if (this.state === 28) {
13918      if (this.currentSequence === Sequences.CdataEnd) {
13919        this.cbs.oncdata(this.sectionStart, endIndex);
13920      } else {
13921        this.cbs.oncomment(this.sectionStart, endIndex);
13922      }
13923    } else if (this.state === 6 || this.state === 11 || this.state === 18 || this.state === 17 || this.state === 12 || this.state === 13 || this.state === 14 || this.state === 15 || this.state === 16 || this.state === 20 || this.state === 19 || this.state === 21 || this.state === 9) ; else {
13924      this.cbs.ontext(this.sectionStart, endIndex);
13925    }
13926  }
13927  emitCodePoint(cp, consumed) {
13928  }
13929}
13930
13931const CompilerDeprecationTypes = {
13932  "COMPILER_IS_ON_ELEMENT": "COMPILER_IS_ON_ELEMENT",
13933  "COMPILER_V_BIND_SYNC": "COMPILER_V_BIND_SYNC",
13934  "COMPILER_V_BIND_OBJECT_ORDER": "COMPILER_V_BIND_OBJECT_ORDER",
13935  "COMPILER_V_ON_NATIVE": "COMPILER_V_ON_NATIVE",
13936  "COMPILER_V_IF_V_FOR_PRECEDENCE": "COMPILER_V_IF_V_FOR_PRECEDENCE",
13937  "COMPILER_NATIVE_TEMPLATE": "COMPILER_NATIVE_TEMPLATE",
13938  "COMPILER_INLINE_TEMPLATE": "COMPILER_INLINE_TEMPLATE",
13939  "COMPILER_FILTERS": "COMPILER_FILTERS"
13940};
13941const deprecationData = {
13942  ["COMPILER_IS_ON_ELEMENT"]: {
13943    message: `Platform-native elements with "is" prop will no longer be treated as components in Vue 3 unless the "is" value is explicitly prefixed with "vue:".`,
13944    link: `https://v3-migration.vuejs.org/breaking-changes/custom-elements-interop.html`
13945  },
13946  ["COMPILER_V_BIND_SYNC"]: {
13947    message: (key) => `.sync modifier for v-bind has been removed. Use v-model with argument instead. \`v-bind:${key}.sync\` should be changed to \`v-model:${key}\`.`,
vendor: 2,296 bytes, lines 13948-13989
13948    link: `https://v3-migration.vuejs.org/breaking-changes/v-model.html`
13949  },
13950  ["COMPILER_V_BIND_OBJECT_ORDER"]: {
13951    message: `v-bind="obj" usage is now order sensitive and behaves like JavaScript object spread: it will now overwrite an existing non-mergeable attribute that appears before v-bind in the case of conflict. To retain 2.x behavior, move v-bind to make it the first attribute. You can also suppress this warning if the usage is intended.`,
13952    link: `https://v3-migration.vuejs.org/breaking-changes/v-bind.html`
13953  },
13954  ["COMPILER_V_ON_NATIVE"]: {
13955    message: `.native modifier for v-on has been removed as is no longer necessary.`,
13956    link: `https://v3-migration.vuejs.org/breaking-changes/v-on-native-modifier-removed.html`
13957  },
13958  ["COMPILER_V_IF_V_FOR_PRECEDENCE"]: {
13959    message: `v-if / v-for precedence when used on the same element has changed in Vue 3: v-if now takes higher precedence and will no longer have access to v-for scope variables. It is best to avoid the ambiguity with <template> tags or use a computed property that filters v-for data source.`,
13960    link: `https://v3-migration.vuejs.org/breaking-changes/v-if-v-for.html`
13961  },
13962  ["COMPILER_NATIVE_TEMPLATE"]: {
13963    message: `<template> with no special directives will render as a native template element instead of its inner content in Vue 3.`
13964  },
13965  ["COMPILER_INLINE_TEMPLATE"]: {
13966    message: `"inline-template" has been removed in Vue 3.`,
13967    link: `https://v3-migration.vuejs.org/breaking-changes/inline-template-attribute.html`
13968  },
13969  ["COMPILER_FILTERS"]: {
13970    message: `filters have been removed in Vue 3. The "|" symbol will be treated as native JavaScript bitwise OR operator. Use method calls or computed properties instead.`,
13971    link: `https://v3-migration.vuejs.org/breaking-changes/filters.html`
13972  }
13973};
13974function getCompatValue(key, { compatConfig }) {
13975  const value = compatConfig && compatConfig[key];
13976  if (key === "MODE") {
13977    return value || 3;
13978  } else {
13979    return value;
13980  }
13981}
13982function isCompatEnabled(key, context) {
13983  const mode = getCompatValue("MODE", context);
13984  const value = getCompatValue(key, context);
13985  return mode === 3 ? value === true : value !== false;
13986}
13987function checkCompatEnabled(key, context, loc, ...args) {
13988  const enabled = isCompatEnabled(key, context);
13989  if (
13989false) // removed by dead control flow
13990{}
13991  return enabled;
13992}
13993function warnDeprecation(key, context, loc, ...args) {
13994  const val = getCompatValue(key, context);
13995  if (val === "suppress-warning") {
13996    return;
13997  }
13998  const { message, link } = deprecationData[key];
13999  const msg = `(deprecation ${key}) ${typeof message === "function" ? message(...args) : message}${link ? `
14000  Details: ${link}` : ``}`;
14001  const err = new SyntaxError(msg);
14002  err.code = key;
14003  if (loc) err.loc = loc;
14004  context.onWarn(err);
14005}
14006
14007function defaultOnError(error) {
14008  throw error;
14009}
14010function defaultOnWarn(msg) {
14011   false && 0;
14012}
14013function createCompilerError(code, loc, messages, additionalMessage) {
14014  const msg =  false ? 0 : `https://vuejs.org/error-reference/#compiler-${code}`;
14015  const error = new SyntaxError(String(msg));
14016  error.code = code;
14017  error.loc = loc;
14018  return error;
14019}
14020const compiler_core_esm_bundler_ErrorCodes = {
14021  "ABRUPT_CLOSING_OF_EMPTY_COMMENT": 0,
14022  "0": "ABRUPT_CLOSING_OF_EMPTY_COMMENT",
14023  "CDATA_IN_HTML_CONTENT": 1,
14024  "1": "CDATA_IN_HTML_CONTENT",
14025  "DUPLICATE_ATTRIBUTE": 2,
14026  "2": "DUPLICATE_ATTRIBUTE",
14027  "END_TAG_WITH_ATTRIBUTES": 3,
14028  "3": "END_TAG_WITH_ATTRIBUTES",
14029  "END_TAG_WITH_TRAILING_SOLIDUS": 4,
14030  "4": "END_TAG_WITH_TRAILING_SOLIDUS",
14031  "EOF_BEFORE_TAG_NAME": 5,
14032  "5": "EOF_BEFORE_TAG_NAME",
14033  "EOF_IN_CDATA": 6,
14034  "6": "EOF_IN_CDATA",
14035  "EOF_IN_COMMENT": 7,
14036  "7": "EOF_IN_COMMENT",
14037  "EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT": 8,
14038  "8": "EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT",
14039  "EOF_IN_TAG": 9,
14040  "9": "EOF_IN_TAG",
14041  "INCORRECTLY_CLOSED_COMMENT": 10,
14042  "10": "INCORRECTLY_CLOSED_COMMENT",
14043  "INCORRECTLY_OPENED_COMMENT": 11,
14044  "11": "INCORRECTLY_OPENED_COMMENT",
14045  "INVALID_FIRST_CHARACTER_OF_TAG_NAME": 12,
14046  "12": "INVALID_FIRST_CHARACTER_OF_TAG_NAME",
14047  "MISSING_ATTRIBUTE_VALUE": 13,
14048  "13": "MISSING_ATTRIBUTE_VALUE",
14049  "MISSING_END_TAG_NAME": 14,
14050  "14": "MISSING_END_TAG_NAME",
14051  "MISSING_WHITESPACE_BETWEEN_ATTRIBUTES": 15,
14052  "15": "MISSING_WHITESPACE_BETWEEN_ATTRIBUTES",
14053  "NESTED_COMMENT": 16,
14054  "16": "NESTED_COMMENT",
14055  "UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME": 17,
14056  "17": "UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME",
14057  "UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE": 18,
14058  "18": "UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE",
14059  "UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME": 19,
14060  "19": "UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME",
14061  "UNEXPECTED_NULL_CHARACTER": 20,
14062  "20": "UNEXPECTED_NULL_CHARACTER",
14063  "UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME": 21,
14064  "21": "UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME",
14065  "UNEXPECTED_SOLIDUS_IN_TAG": 22,
14066  "22": "UNEXPECTED_SOLIDUS_IN_TAG",
14067  "X_INVALID_END_TAG": 23,
14068  "23": "X_INVALID_END_TAG",
14069  "X_MISSING_END_TAG": 24,
14070  "24": "X_MISSING_END_TAG",
14071  "X_MISSING_INTERPOLATION_END": 25,
14072  "25": "X_MISSING_INTERPOLATION_END",
14073  "X_MISSING_DIRECTIVE_NAME": 26,
14074  "26": "X_MISSING_DIRECTIVE_NAME",
14075  "X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END": 27,
14076  "27": "X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END",
14077  "X_V_IF_NO_EXPRESSION": 28,
14078  "28": "X_V_IF_NO_EXPRESSION",
14079  "X_V_IF_SAME_KEY": 29,
14080  "29": "X_V_IF_SAME_KEY",
14081  "X_V_ELSE_NO_ADJACENT_IF": 30,
14082  "30": "X_V_ELSE_NO_ADJACENT_IF",
14083  "X_V_FOR_NO_EXPRESSION": 31,
14084  "31": "X_V_FOR_NO_EXPRESSION",
14085  "X_V_FOR_MALFORMED_EXPRESSION": 32,
14086  "32": "X_V_FOR_MALFORMED_EXPRESSION",
14087  "X_V_FOR_TEMPLATE_KEY_PLACEMENT": 33,
14088  "33": "X_V_FOR_TEMPLATE_KEY_PLACEMENT",
14089  "X_V_BIND_NO_EXPRESSION": 34,
14090  "34": "X_V_BIND_NO_EXPRESSION",
14091  "X_V_ON_NO_EXPRESSION": 35,
14092  "35": "X_V_ON_NO_EXPRESSION",
14093  "X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET": 36,
14094  "36": "X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET",
14095  "X_V_SLOT_MIXED_SLOT_USAGE": 37,
14096  "37": "X_V_SLOT_MIXED_SLOT_USAGE",
14097  "X_V_SLOT_DUPLICATE_SLOT_NAMES": 38,
14098  "38": "X_V_SLOT_DUPLICATE_SLOT_NAMES",
14099  "X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN": 39,
14100  "39": "X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN",
14101  "X_V_SLOT_MISPLACED": 40,
14102  "40": "X_V_SLOT_MISPLACED",
14103  "X_V_MODEL_NO_EXPRESSION": 41,
14104  "41": "X_V_MODEL_NO_EXPRESSION",
14105  "X_V_MODEL_MALFORMED_EXPRESSION": 42,
14106  "42": "X_V_MODEL_MALFORMED_EXPRESSION",
14107  "X_V_MODEL_ON_SCOPE_VARIABLE": 43,
14108  "43": "X_V_MODEL_ON_SCOPE_VARIABLE",
14109  "X_V_MODEL_ON_PROPS": 44,
14110  "44": "X_V_MODEL_ON_PROPS",
14111  "X_INVALID_EXPRESSION": 45,
14112  "45": "X_INVALID_EXPRESSION",
14113  "X_KEEP_ALIVE_INVALID_CHILDREN": 46,
14114  "46": "X_KEEP_ALIVE_INVALID_CHILDREN",
14115  "X_PREFIX_ID_NOT_SUPPORTED": 47,
14116  "47": "X_PREFIX_ID_NOT_SUPPORTED",
14117  "X_MODULE_MODE_NOT_SUPPORTED": 48,
14118  "48": "X_MODULE_MODE_NOT_SUPPORTED",
14119  "X_CACHE_HANDLER_NOT_SUPPORTED": 49,
14120  "49": "X_CACHE_HANDLER_NOT_SUPPORTED",
14121  "X_SCOPE_ID_NOT_SUPPORTED": 50,
14122  "50": "X_SCOPE_ID_NOT_SUPPORTED",
14123  "X_VNODE_HOOKS": 51,
14124  "51": "X_VNODE_HOOKS",
14125  "X_V_BIND_INVALID_SAME_NAME_ARGUMENT": 52,
14126  "52": "X_V_BIND_INVALID_SAME_NAME_ARGUMENT",
14127  "__EXTEND_POINT__": 53,
14128  "53": "__EXTEND_POINT__"
14129};
14130const errorMessages = {
14131  // parse errors
14132  [0]: "Illegal comment.",
14133  [1]: "CDATA section is allowed only in XML context.",
14134  [2]: "Duplicate attribute.",
14135  [3]: "End tag cannot have attributes.",
14136  [4]: "Illegal '/' in tags.",
14137  [5]: "Unexpected EOF in tag.",
14138  [6]: "Unexpected EOF in CDATA section.",
14139  [7]: "Unexpected EOF in comment.",
14140  [8]: "Unexpected EOF in script.",
14141  [9]: "Unexpected EOF in tag.",
14142  [10]: "Incorrectly closed comment.",
14143  [11]: "Incorrectly opened comment.",
14144  [12]: "Illegal tag name. Use '&lt;' to print '<'.",
14145  [13]: "Attribute value was expected.",
14146  [14]: "End tag name was expected.",
14147  [15]: "Whitespace was expected.",
14148  [16]: "Unexpected '<!--' in comment.",
14149  [17]: `Attribute name cannot contain U+0022 ("), U+0027 ('), and U+003C (<).`,
14150  [18]: "Unquoted attribute value cannot contain U+0022 (\"), U+0027 ('), U+003C (<), U+003D (=), and U+0060 (`).",
14151  [19]: "Attribute name cannot start with '='.",
14152  [21]: "'<?' is allowed only in XML context.",
14153  [20]: `Unexpected null character.`,
14154  [22]: "Illegal '/' in tags.",
14155  // Vue-specific parse errors
14156  [23]: "Invalid end tag.",
14157  [24]: "Element is missing end tag.",
14158  [25]: "Interpolation end sign was not found.",
14159  [27]: "End bracket for dynamic directive argument was not found. Note that dynamic directive argument cannot contain spaces.",
14160  [26]: "Legal directive name was expected.",
14161  // transform errors
14162  [28]: `v-if/v-else-if is missing expression.`,
14163  [29]: `v-if/else branches must use unique keys.`,
14164  [30]: `v-else/v-else-if has no adjacent v-if or v-else-if.`,
14165  [31]: `v-for is missing expression.`,
14166  [32]: `v-for has invalid expression.`,
14167  [33]: `<template v-for> key should be placed on the <template> tag.`,
14168  [34]: `v-bind is missing expression.`,
14169  [52]: `v-bind with same-name shorthand only allows static argument.`,
14170  [35]: `v-on is missing expression.`,
14171  [36]: `Unexpected custom directive on <slot> outlet.`,
14172  [37]: `Mixed v-slot usage on both the component and nested <template>. When there are multiple named slots, all slots should use <template> syntax to avoid scope ambiguity.`,
14173  [38]: `Duplicate slot names found. `,
14174  [39]: `Extraneous children found when component already has explicitly named default slot. These children will be ignored.`,
14175  [40]: `v-slot can only be used on components or <template> tags.`,
14176  [41]: `v-model is missing expression.`,
14177  [42]: `v-model value must be a valid JavaScript member expression.`,
14178  [43]: `v-model cannot be used on v-for or v-slot scope variables because they are not writable.`,
14179  [44]: `v-model cannot be used on a prop, because local prop bindings are not writable.
14180Use a v-bind binding combined with a v-on listener that emits update:x event instead.`,
14181  [45]: `Error parsing JavaScript expression: `,
14182  [46]: `<KeepAlive> expects exactly one child component.`,
14183  [51]: `@vnode-* hooks in templates are no longer supported. Use the vue: prefix instead. For example, @vnode-mounted should be changed to @vue:mounted. @vnode-* hooks support has been removed in 3.4.`,
14184  // generic errors
14185  [47]: `"prefixIdentifiers" option is not supported in this build of compiler.`,
14186  [48]: `ES module mode is not supported in this build of compiler.`,
14187  [49]: `"cacheHandlers" option is only supported when the "prefixIdentifiers" option is enabled.`,
14188  [50]: `"scopeId" option is only supported in module mode.`,
14189  // just to fulfill types
14190  [53]: ``
14191};
14192
14193function walkIdentifiers(root, onIdentifier, includeAll = false, parentStack = [], knownIds = /* @__PURE__ */ Object.create(null)) {
14194  {
14195    return;
14196  }
14197}
14198function isReferencedIdentifier(id, parent, parentStack) {
14199  {
14200    return false;
vendor: 5,769 bytes, lines 14201-14386
14201  }
14202}
14203function isInDestructureAssignment(parent, parentStack) {
14204  if (parent && (parent.type === "ObjectProperty" || parent.type === "ArrayPattern")) {
14205    let i = parentStack.length;
14206    while (i--) {
14207      const p = parentStack[i];
14208      if (p.type === "AssignmentExpression") {
14209        return true;
14210      } else if (p.type !== "ObjectProperty" && !p.type.endsWith("Pattern")) {
14211        break;
14212      }
14213    }
14214  }
14215  return false;
14216}
14217function isInNewExpression(parentStack) {
14218  let i = parentStack.length;
14219  while (i--) {
14220    const p = parentStack[i];
14221    if (p.type === "NewExpression") {
14222      return true;
14223    } else if (p.type !== "MemberExpression") {
14224      break;
14225    }
14226  }
14227  return false;
14228}
14229function walkFunctionParams(node, onIdent) {
14230  for (const p of node.params) {
14231    for (const id of extractIdentifiers(p)) {
14232      onIdent(id);
14233    }
14234  }
14235}
14236function walkBlockDeclarations(block, onIdent) {
14237  const body = block.type === "SwitchCase" ? block.consequent : block.body;
14238  for (const stmt of body) {
14239    if (stmt.type === "VariableDeclaration") {
14240      if (stmt.declare) continue;
14241      for (const decl of stmt.declarations) {
14242        for (const id of extractIdentifiers(decl.id)) {
14243          onIdent(id);
14244        }
14245      }
14246    } else if (stmt.type === "FunctionDeclaration" || stmt.type === "ClassDeclaration") {
14247      if (stmt.declare || !stmt.id) continue;
14248      onIdent(stmt.id);
14249    } else if (isForStatement(stmt)) {
14250      walkForStatement(stmt, true, onIdent);
14251    } else if (stmt.type === "SwitchStatement") {
14252      walkSwitchStatement(stmt, true, onIdent);
14253    }
14254  }
14255}
14256function isForStatement(stmt) {
14257  return stmt.type === "ForOfStatement" || stmt.type === "ForInStatement" || stmt.type === "ForStatement";
14258}
14259function walkForStatement(stmt, isVar, onIdent) {
14260  const variable = stmt.type === "ForStatement" ? stmt.init : stmt.left;
14261  if (variable && variable.type === "VariableDeclaration" && (variable.kind === "var" ? isVar : !isVar)) {
14262    for (const decl of variable.declarations) {
14263      for (const id of extractIdentifiers(decl.id)) {
14264        onIdent(id);
14265      }
14266    }
14267  }
14268}
14269function walkSwitchStatement(stmt, isVar, onIdent) {
14270  for (const cs of stmt.cases) {
14271    for (const stmt2 of cs.consequent) {
14272      if (stmt2.type === "VariableDeclaration" && (stmt2.kind === "var" ? isVar : !isVar)) {
14273        for (const decl of stmt2.declarations) {
14274          for (const id of extractIdentifiers(decl.id)) {
14275            onIdent(id);
14276          }
14277        }
14278      }
14279    }
14280    walkBlockDeclarations(cs, onIdent);
14281  }
14282}
14283function extractIdentifiers(param, nodes = []) {
14284  switch (param.type) {
14285    case "Identifier":
14286      nodes.push(param);
14287      break;
14288    case "MemberExpression":
14289      let object = param;
14290      while (object.type === "MemberExpression") {
14291        object = object.object;
14292      }
14293      nodes.push(object);
14294      break;
14295    case "ObjectPattern":
14296      for (const prop of param.properties) {
14297        if (prop.type === "RestElement") {
14298          extractIdentifiers(prop.argument, nodes);
14299        } else {
14300          extractIdentifiers(prop.value, nodes);
14301        }
14302      }
14303      break;
14304    case "ArrayPattern":
14305      param.elements.forEach((element) => {
14306        if (element) extractIdentifiers(element, nodes);
14307      });
14308      break;
14309    case "RestElement":
14310      extractIdentifiers(param.argument, nodes);
14311      break;
14312    case "AssignmentPattern":
14313      extractIdentifiers(param.left, nodes);
14314      break;
14315  }
14316  return nodes;
14317}
14318const isFunctionType = (node) => {
14319  return /Function(?:Expression|Declaration)$|Method$/.test(node.type);
14320};
14321const isStaticProperty = (node) => node && (node.type === "ObjectProperty" || node.type === "ObjectMethod") && !node.computed;
14322const isStaticPropertyKey = (node, parent) => isStaticProperty(parent) && parent.key === node;
14323const TS_NODE_TYPES = (/* unused pure expression or super */ null && ([
14324  "TSAsExpression",
14325  // foo as number
14326  "TSTypeAssertion",
14327  // (<number>foo)
14328  "TSNonNullExpression",
14329  // foo!
14330  "TSInstantiationExpression",
14331  // foo<string>
14332  "TSSatisfiesExpression"
14333  // foo satisfies T
14334]));
14335function unwrapTSNode(node) {
14336  if (TS_NODE_TYPES.includes(node.type)) {
14337    return unwrapTSNode(node.expression);
14338  } else {
14339    return node;
14340  }
14341}
14342
14343const isStaticExp = (p) => p.type === 4 && p.isStatic;
14344function isCoreComponent(tag) {
14345  switch (tag) {
14346    case "Teleport":
14347    case "teleport":
14348      return TELEPORT;
14349    case "Suspense":
14350    case "suspense":
14351      return SUSPENSE;
14352    case "KeepAlive":
14353    case "keep-alive":
14354      return KEEP_ALIVE;
14355    case "BaseTransition":
14356    case "base-transition":
14357      return BASE_TRANSITION;
14358  }
14359}
14360const nonIdentifierRE = /^$|^\d|[^\$\w\xA0-\uFFFF]/;
14361const isSimpleIdentifier = (name) => !nonIdentifierRE.test(name);
14362const validFirstIdentCharRE = /[A-Za-z_$\xA0-\uFFFF]/;
14363const validIdentCharRE = /[\.\?\w$\xA0-\uFFFF]/;
14364const whitespaceRE = /\s+[.[]\s*|\s*[.[]\s+/g;
14365const getExpSource = (exp) => exp.type === 4 ? exp.content : exp.loc.source;
14366const isMemberExpressionBrowser = (exp) => {
14367  const path = getExpSource(exp).trim().replace(whitespaceRE, (s) => s.trim());
14368  let state = 0 /* inMemberExp */;
14369  let stateStack = [];
14370  let currentOpenBracketCount = 0;
14371  let currentOpenParensCount = 0;
14372  let currentStringType = null;
14373  for (let i = 0; i < path.length; i++) {
14374    const char = path.charAt(i);
14375    switch (state) {
14376      case 0 /* inMemberExp */:
14377        if (char === "[") {
14378          stateStack.push(state);
14379          state = 1 /* inBrackets */;
14380          currentOpenBracketCount++;
14381        } else if (char === "(") {
14382          stateStack.push(state);
14383          state = 2 /* inParens */;
14384          currentOpenParensCount++;
14385        } else if (!(i === 0 ? validFirstIdentCharRE : validIdentCharRE).test(char)) {
14386          return false;
vendor: 2,622 bytes, lines 14387-14466
14387        }
14388        break;
14389      case 1 /* inBrackets */:
14390        if (char === `'` || char === `"` || char === "`") {
14391          stateStack.push(state);
14392          state = 3 /* inString */;
14393          currentStringType = char;
14394        } else if (char === `[`) {
14395          currentOpenBracketCount++;
14396        } else if (char === `]`) {
14397          if (!--currentOpenBracketCount) {
14398            state = stateStack.pop();
14399          }
14400        }
14401        break;
14402      case 2 /* inParens */:
14403        if (char === `'` || char === `"` || char === "`") {
14404          stateStack.push(state);
14405          state = 3 /* inString */;
14406          currentStringType = char;
14407        } else if (char === `(`) {
14408          currentOpenParensCount++;
14409        } else if (char === `)`) {
14410          if (i === path.length - 1) {
14411            return false;
14412          }
14413          if (!--currentOpenParensCount) {
14414            state = stateStack.pop();
14415          }
14416        }
14417        break;
14418      case 3 /* inString */:
14419        if (char === currentStringType) {
14420          state = stateStack.pop();
14421          currentStringType = null;
14422        }
14423        break;
14424    }
14425  }
14426  return !currentOpenBracketCount && !currentOpenParensCount;
14427};
14428const isMemberExpressionNode = (/* unused pure expression or super */ null && (NOOP)) ;
14429const isMemberExpression = isMemberExpressionBrowser ;
14430const fnExpRE = /^\s*(?:async\s*)?(?:\([^)]*?\)|[\w$_]+)\s*(?::[^=]+)?=>|^\s*(?:async\s+)?function(?:\s+[\w$]+)?\s*\(/;
14431const isFnExpressionBrowser = (exp) => fnExpRE.test(getExpSource(exp));
14432const isFnExpressionNode = (/* unused pure expression or super */ null && (NOOP)) ;
14433const isFnExpression = isFnExpressionBrowser ;
14434function advancePositionWithClone(pos, source, numberOfCharacters = source.length) {
14435  return advancePositionWithMutation(
14436    {
14437      offset: pos.offset,
14438      line: pos.line,
14439      column: pos.column
14440    },
14441    source,
14442    numberOfCharacters
14443  );
14444}
14445function advancePositionWithMutation(pos, source, numberOfCharacters = source.length) {
14446  let linesCount = 0;
14447  let lastNewLinePos = -1;
14448  for (let i = 0; i < numberOfCharacters; i++) {
14449    if (source.charCodeAt(i) === 10) {
14450      linesCount++;
14451      lastNewLinePos = i;
14452    }
14453  }
14454  pos.offset += numberOfCharacters;
14455  pos.line += linesCount;
14456  pos.column = lastNewLinePos === -1 ? pos.column + numberOfCharacters : numberOfCharacters - lastNewLinePos;
14457  return pos;
14458}
14459function assert(condition, msg) {
14460  if (!condition) {
14461    throw new Error(msg || `unexpected compiler condition`);
14462  }
14463}
14464function findDir(node, name, allowEmpty = false) {
14465  for (let i = 0; i < node.props.length; i++) {
14466    const p = node.props[i];
vendor: 3,604 bytes, lines 14467-14583
14467    if (p.type === 7 && (allowEmpty || p.exp) && (shared_esm_bundler_isString(name) ? p.name === name : name.test(p.name))) {
14468      return p;
14469    }
14470  }
14471}
14472function findProp(node, name, dynamicOnly = false, allowEmpty = false) {
14473  for (let i = 0; i < node.props.length; i++) {
14474    const p = node.props[i];
14475    if (p.type === 6) {
14476      if (dynamicOnly) continue;
14477      if (p.name === name && (p.value || allowEmpty)) {
14478        return p;
14479      }
14480    } else if (p.name === "bind" && (p.exp || allowEmpty) && isStaticArgOf(p.arg, name)) {
14481      return p;
14482    }
14483  }
14484}
14485function isStaticArgOf(arg, name) {
14486  return !!(arg && isStaticExp(arg) && arg.content === name);
14487}
14488function hasDynamicKeyVBind(node) {
14489  return node.props.some(
14490    (p) => p.type === 7 && p.name === "bind" && (!p.arg || // v-bind="obj"
14491    p.arg.type !== 4 || // v-bind:[_ctx.foo]
14492    !p.arg.isStatic)
14493    // v-bind:[foo]
14494  );
14495}
14496function isText$1(node) {
14497  return node.type === 5 || node.type === 2;
14498}
14499function isVPre(p) {
14500  return p.type === 7 && p.name === "pre";
14501}
14502function isVSlot(p) {
14503  return p.type === 7 && p.name === "slot";
14504}
14505function isTemplateNode(node) {
14506  return node.type === 1 && node.tagType === 3;
14507}
14508function isSlotOutlet(node) {
14509  return node.type === 1 && node.tagType === 2;
14510}
14511const propsHelperSet = /* @__PURE__ */ new Set([NORMALIZE_PROPS, GUARD_REACTIVE_PROPS]);
14512function getUnnormalizedProps(props, callPath = []) {
14513  if (props && !shared_esm_bundler_isString(props) && props.type === 14) {
14514    const callee = props.callee;
14515    if (!shared_esm_bundler_isString(callee) && propsHelperSet.has(callee)) {
14516      return getUnnormalizedProps(
14517        props.arguments[0],
14518        callPath.concat(props)
14519      );
14520    }
14521  }
14522  return [props, callPath];
14523}
14524function injectProp(node, prop, context) {
14525  let propsWithInjection;
14526  let props = node.type === 13 ? node.props : node.arguments[2];
14527  let callPath = [];
14528  let parentCall;
14529  if (props && !shared_esm_bundler_isString(props) && props.type === 14) {
14530    const ret = getUnnormalizedProps(props);
14531    props = ret[0];
14532    callPath = ret[1];
14533    parentCall = callPath[callPath.length - 1];
14534  }
14535  if (props == null || shared_esm_bundler_isString(props)) {
14536    propsWithInjection = createObjectExpression([prop]);
14537  } else if (props.type === 14) {
14538    const first = props.arguments[0];
14539    if (!shared_esm_bundler_isString(first) && first.type === 15) {
14540      if (!hasProp(prop, first)) {
14541        first.properties.unshift(prop);
14542      }
14543    } else {
14544      if (props.callee === TO_HANDLERS) {
14545        propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [
14546          createObjectExpression([prop]),
14547          props
14548        ]);
14549      } else {
14550        props.arguments.unshift(createObjectExpression([prop]));
14551      }
14552    }
14553    !propsWithInjection && (propsWithInjection = props);
14554  } else if (props.type === 15) {
14555    if (!hasProp(prop, props)) {
14556      props.properties.unshift(prop);
14557    }
14558    propsWithInjection = props;
14559  } else {
14560    propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [
14561      createObjectExpression([prop]),
14562      props
14563    ]);
14564    if (parentCall && parentCall.callee === GUARD_REACTIVE_PROPS) {
14565      parentCall = callPath[callPath.length - 2];
14566    }
14567  }
14568  if (node.type === 13) {
14569    if (parentCall) {
14570      parentCall.arguments[0] = propsWithInjection;
14571    } else {
14572      node.props = propsWithInjection;
14573    }
14574  } else {
14575    if (parentCall) {
14576      parentCall.arguments[0] = propsWithInjection;
14577    } else {
14578      node.arguments[2] = propsWithInjection;
14579    }
14580  }
14581}
14582function hasProp(prop, props) {
14583  let result = false;
vendor: 17,113 bytes, lines 14584-15154
14584  if (prop.key.type === 4) {
14585    const propKeyName = prop.key.content;
14586    result = props.properties.some(
14587      (p) => p.key.type === 4 && p.key.content === propKeyName
14588    );
14589  }
14590  return result;
14591}
14592function toValidAssetId(name, type) {
14593  return `_${type}_${name.replace(/[^\w]/g, (searchValue, replaceValue) => {
14594    return searchValue === "-" ? "_" : name.charCodeAt(replaceValue).toString();
14595  })}`;
14596}
14597function hasScopeRef(node, ids) {
14598  if (!node || Object.keys(ids).length === 0) {
14599    return false;
14600  }
14601  switch (node.type) {
14602    case 1:
14603      for (let i = 0; i < node.props.length; i++) {
14604        const p = node.props[i];
14605        if (p.type === 7 && (hasScopeRef(p.arg, ids) || hasScopeRef(p.exp, ids))) {
14606          return true;
14607        }
14608      }
14609      return node.children.some((c) => hasScopeRef(c, ids));
14610    case 11:
14611      if (hasScopeRef(node.source, ids)) {
14612        return true;
14613      }
14614      return node.children.some((c) => hasScopeRef(c, ids));
14615    case 9:
14616      return node.branches.some((b) => hasScopeRef(b, ids));
14617    case 10:
14618      if (hasScopeRef(node.condition, ids)) {
14619        return true;
14620      }
14621      return node.children.some((c) => hasScopeRef(c, ids));
14622    case 4:
14623      return !node.isStatic && isSimpleIdentifier(node.content) && !!ids[node.content];
14624    case 8:
14625      return node.children.some((c) => isObject(c) && hasScopeRef(c, ids));
14626    case 5:
14627    case 12:
14628      return hasScopeRef(node.content, ids);
14629    case 2:
14630    case 3:
14631    case 20:
14632      return false;
14633    default:
14634      if (false) // removed by dead control flow
14635{}
14636      return false;
14637  }
14638}
14639function getMemoedVNodeCall(node) {
14640  if (node.type === 14 && node.callee === WITH_MEMO) {
14641    return node.arguments[1].returns;
14642  } else {
14643    return node;
14644  }
14645}
14646const forAliasRE = /([\s\S]*?)\s+(?:in|of)\s+(\S[\s\S]*)/;
14647function isAllWhitespace(str) {
14648  for (let i = 0; i < str.length; i++) {
14649    if (!isWhitespace(str.charCodeAt(i))) {
14650      return false;
14651    }
14652  }
14653  return true;
14654}
14655function isWhitespaceText(node) {
14656  return node.type === 2 && isAllWhitespace(node.content) || node.type === 12 && isWhitespaceText(node.content);
14657}
14658function compiler_core_esm_bundler_isCommentOrWhitespace(node) {
14659  return node.type === 3 || isWhitespaceText(node);
14660}
14661
14662const defaultParserOptions = {
14663  parseMode: "base",
14664  ns: 0,
14665  delimiters: [`{{`, `}}`],
14666  getNamespace: () => 0,
14667  isVoidTag: NO,
14668  isPreTag: NO,
14669  isIgnoreNewlineTag: NO,
14670  isCustomElement: NO,
14671  onError: defaultOnError,
14672  onWarn: defaultOnWarn,
14673  comments: !!("production" !== "production"),
14674  prefixIdentifiers: false
14675};
14676let currentOptions = defaultParserOptions;
14677let currentRoot = null;
14678let currentInput = "";
14679let currentOpenTag = null;
14680let currentProp = null;
14681let currentAttrValue = "";
14682let currentAttrStartIndex = -1;
14683let currentAttrEndIndex = -1;
14684let inPre = 0;
14685let inVPre = false;
14686let currentVPreBoundary = null;
14687const compiler_core_esm_bundler_stack = [];
14688const tokenizer = new Tokenizer(compiler_core_esm_bundler_stack, {
14689  onerr: emitError,
14690  ontext(start, end) {
14691    onText(getSlice(start, end), start, end);
14692  },
14693  ontextentity(char, start, end) {
14694    onText(char, start, end);
14695  },
14696  oninterpolation(start, end) {
14697    if (inVPre) {
14698      return onText(getSlice(start, end), start, end);
14699    }
14700    let innerStart = start + tokenizer.delimiterOpen.length;
14701    let innerEnd = end - tokenizer.delimiterClose.length;
14702    while (isWhitespace(currentInput.charCodeAt(innerStart))) {
14703      innerStart++;
14704    }
14705    while (isWhitespace(currentInput.charCodeAt(innerEnd - 1))) {
14706      innerEnd--;
14707    }
14708    let exp = getSlice(innerStart, innerEnd);
14709    if (exp.includes("&")) {
14710      {
14711        exp = currentOptions.decodeEntities(exp, false);
14712      }
14713    }
14714    addNode({
14715      type: 5,
14716      content: createExp(exp, false, getLoc(innerStart, innerEnd)),
14717      loc: getLoc(start, end)
14718    });
14719  },
14720  onopentagname(start, end) {
14721    const name = getSlice(start, end);
14722    currentOpenTag = {
14723      type: 1,
14724      tag: name,
14725      ns: currentOptions.getNamespace(name, compiler_core_esm_bundler_stack[0], currentOptions.ns),
14726      tagType: 0,
14727      // will be refined on tag close
14728      props: [],
14729      children: [],
14730      loc: getLoc(start - 1, end),
14731      codegenNode: void 0
14732    };
14733  },
14734  onopentagend(end) {
14735    endOpenTag(end);
14736  },
14737  onclosetag(start, end) {
14738    const name = getSlice(start, end);
14739    if (!currentOptions.isVoidTag(name)) {
14740      let found = false;
14741      for (let i = 0; i < compiler_core_esm_bundler_stack.length; i++) {
14742        const e = compiler_core_esm_bundler_stack[i];
14743        if (e.tag.toLowerCase() === name.toLowerCase()) {
14744          found = true;
14745          if (i > 0) {
14746            emitError(24, compiler_core_esm_bundler_stack[0].loc.start.offset);
14747          }
14748          for (let j = 0; j <= i; j++) {
14749            const el = compiler_core_esm_bundler_stack.shift();
14750            onCloseTag(el, end, j < i);
14751          }
14752          break;
14753        }
14754      }
14755      if (!found) {
14756        emitError(23, backTrack(start, 60));
14757      }
14758    }
14759  },
14760  onselfclosingtag(end) {
14761    const name = currentOpenTag.tag;
14762    currentOpenTag.isSelfClosing = true;
14763    endOpenTag(end);
14764    if (compiler_core_esm_bundler_stack[0] && compiler_core_esm_bundler_stack[0].tag === name) {
14765      onCloseTag(compiler_core_esm_bundler_stack.shift(), end);
14766    }
14767  },
14768  onattribname(start, end) {
14769    currentProp = {
14770      type: 6,
14771      name: getSlice(start, end),
14772      nameLoc: getLoc(start, end),
14773      value: void 0,
14774      loc: getLoc(start)
14775    };
14776  },
14777  ondirname(start, end) {
14778    const raw = getSlice(start, end);
14779    const name = raw === "." || raw === ":" ? "bind" : raw === "@" ? "on" : raw === "#" ? "slot" : raw.slice(2);
14780    if (!inVPre && name === "") {
14781      emitError(26, start);
14782    }
14783    if (inVPre || name === "") {
14784      currentProp = {
14785        type: 6,
14786        name: raw,
14787        nameLoc: getLoc(start, end),
14788        value: void 0,
14789        loc: getLoc(start)
14790      };
14791    } else {
14792      currentProp = {
14793        type: 7,
14794        name,
14795        rawName: raw,
14796        exp: void 0,
14797        arg: void 0,
14798        modifiers: raw === "." ? [createSimpleExpression("prop")] : [],
14799        loc: getLoc(start)
14800      };
14801      if (name === "pre") {
14802        inVPre = tokenizer.inVPre = true;
14803        currentVPreBoundary = currentOpenTag;
14804        const props = currentOpenTag.props;
14805        for (let i = 0; i < props.length; i++) {
14806          if (props[i].type === 7) {
14807            props[i] = dirToAttr(props[i]);
14808          }
14809        }
14810      }
14811    }
14812  },
14813  ondirarg(start, end) {
14814    if (start === end) return;
14815    const arg = getSlice(start, end);
14816    if (inVPre && !isVPre(currentProp)) {
14817      currentProp.name += arg;
14818      setLocEnd(currentProp.nameLoc, end);
14819    } else {
14820      const isStatic = arg[0] !== `[`;
14821      currentProp.arg = createExp(
14822        isStatic ? arg : arg.slice(1, -1),
14823        isStatic,
14824        getLoc(start, end),
14825        isStatic ? 3 : 0
14826      );
14827    }
14828  },
14829  ondirmodifier(start, end) {
14830    const mod = getSlice(start, end);
14831    if (inVPre && !isVPre(currentProp)) {
14832      currentProp.name += "." + mod;
14833      setLocEnd(currentProp.nameLoc, end);
14834    } else if (currentProp.name === "slot") {
14835      const arg = currentProp.arg;
14836      if (arg) {
14837        arg.content += "." + mod;
14838        setLocEnd(arg.loc, end);
14839      }
14840    } else {
14841      const exp = createSimpleExpression(mod, true, getLoc(start, end));
14842      currentProp.modifiers.push(exp);
14843    }
14844  },
14845  onattribdata(start, end) {
14846    currentAttrValue += getSlice(start, end);
14847    if (currentAttrStartIndex < 0) currentAttrStartIndex = start;
14848    currentAttrEndIndex = end;
14849  },
14850  onattribentity(char, start, end) {
14851    currentAttrValue += char;
14852    if (currentAttrStartIndex < 0) currentAttrStartIndex = start;
14853    currentAttrEndIndex = end;
14854  },
14855  onattribnameend(end) {
14856    const start = currentProp.loc.start.offset;
14857    const name = getSlice(start, end);
14858    if (currentProp.type === 7) {
14859      currentProp.rawName = name;
14860    }
14861    if (currentOpenTag.props.some(
14862      (p) => (p.type === 7 ? p.rawName : p.name) === name
14863    )) {
14864      emitError(2, start);
14865    }
14866  },
14867  onattribend(quote, end) {
14868    if (currentOpenTag && currentProp) {
14869      setLocEnd(currentProp.loc, end);
14870      if (quote !== 0) {
14871        if (currentAttrValue.includes("&")) {
14872          currentAttrValue = currentOptions.decodeEntities(
14873            currentAttrValue,
14874            true
14875          );
14876        }
14877        if (currentProp.type === 6) {
14878          if (currentProp.name === "class") {
14879            currentAttrValue = condense(currentAttrValue).trim();
14880          }
14881          if (quote === 1 && !currentAttrValue) {
14882            emitError(13, end);
14883          }
14884          currentProp.value = {
14885            type: 2,
14886            content: currentAttrValue,
14887            loc: quote === 1 ? getLoc(currentAttrStartIndex, currentAttrEndIndex) : getLoc(currentAttrStartIndex - 1, currentAttrEndIndex + 1)
14888          };
14889          if (tokenizer.inSFCRoot && currentOpenTag.tag === "template" && currentProp.name === "lang" && currentAttrValue && currentAttrValue !== "html") {
14890            tokenizer.enterRCDATA(toCharCodes(`</template`), 0);
14891          }
14892        } else {
14893          let expParseMode = 0 /* Normal */;
14894          currentProp.exp = createExp(
14895            currentAttrValue,
14896            false,
14897            getLoc(currentAttrStartIndex, currentAttrEndIndex),
14898            0,
14899            expParseMode
14900          );
14901          if (currentProp.name === "for") {
14902            currentProp.forParseResult = parseForExpression(currentProp.exp);
14903          }
14904          let syncIndex = -1;
14905          if (currentProp.name === "bind" && (syncIndex = currentProp.modifiers.findIndex(
14906            (mod) => mod.content === "sync"
14907          )) > -1 && checkCompatEnabled(
14908            "COMPILER_V_BIND_SYNC",
14909            currentOptions,
14910            currentProp.loc,
14911            currentProp.arg.loc.source
14912          )) {
14913            currentProp.name = "model";
14914            currentProp.modifiers.splice(syncIndex, 1);
14915          }
14916        }
14917      }
14918      if (currentProp.type !== 7 || currentProp.name !== "pre") {
14919        currentOpenTag.props.push(currentProp);
14920      }
14921    }
14922    currentAttrValue = "";
14923    currentAttrStartIndex = currentAttrEndIndex = -1;
14924  },
14925  oncomment(start, end) {
14926    if (currentOptions.comments) {
14927      addNode({
14928        type: 3,
14929        content: getSlice(start, end),
14930        loc: getLoc(start - 4, end + 3)
14931      });
14932    }
14933  },
14934  onend() {
14935    const end = currentInput.length;
14936    if (false) // removed by dead control flow
14937{}
14938    for (let index = 0; index < compiler_core_esm_bundler_stack.length; index++) {
14939      onCloseTag(compiler_core_esm_bundler_stack[index], end - 1);
14940      emitError(24, compiler_core_esm_bundler_stack[index].loc.start.offset);
14941    }
14942  },
14943  oncdata(start, end) {
14944    if (compiler_core_esm_bundler_stack[0].ns !== 0) {
14945      onText(getSlice(start, end), start, end);
14946    } else {
14947      emitError(1, start - 9);
14948    }
14949  },
14950  onprocessinginstruction(start) {
14951    if ((compiler_core_esm_bundler_stack[0] ? compiler_core_esm_bundler_stack[0].ns : currentOptions.ns) === 0) {
14952      emitError(
14953        21,
14954        start - 1
14955      );
14956    }
14957  }
14958});
14959const forIteratorRE = /,([^,\}\]]*)(?:,([^,\}\]]*))?$/;
14960const stripParensRE = /^\(|\)$/g;
14961function parseForExpression(input) {
14962  const loc = input.loc;
14963  const exp = input.content;
14964  const inMatch = exp.match(forAliasRE);
14965  if (!inMatch) return;
14966  const [, LHS, RHS] = inMatch;
14967  const createAliasExpression = (content, offset, asParam = false) => {
14968    const start = loc.start.offset + offset;
14969    const end = start + content.length;
14970    return createExp(
14971      content,
14972      false,
14973      getLoc(start, end),
14974      0,
14975      asParam ? 1 /* Params */ : 0 /* Normal */
14976    );
14977  };
14978  const result = {
14979    source: createAliasExpression(RHS.trim(), exp.indexOf(RHS, LHS.length)),
14980    value: void 0,
14981    key: void 0,
14982    index: void 0,
14983    finalized: false
14984  };
14985  let valueContent = LHS.trim().replace(stripParensRE, "").trim();
14986  const trimmedOffset = LHS.indexOf(valueContent);
14987  const iteratorMatch = valueContent.match(forIteratorRE);
14988  if (iteratorMatch) {
14989    valueContent = valueContent.replace(forIteratorRE, "").trim();
14990    const keyContent = iteratorMatch[1].trim();
14991    let keyOffset;
14992    if (keyContent) {
14993      keyOffset = exp.indexOf(keyContent, trimmedOffset + valueContent.length);
14994      result.key = createAliasExpression(keyContent, keyOffset, true);
14995    }
14996    if (iteratorMatch[2]) {
14997      const indexContent = iteratorMatch[2].trim();
14998      if (indexContent) {
14999        result.index = createAliasExpression(
15000          indexContent,
15001          exp.indexOf(
15002            indexContent,
15003            result.key ? keyOffset + keyContent.length : trimmedOffset + valueContent.length
15004          ),
15005          true
15006        );
15007      }
15008    }
15009  }
15010  if (valueContent) {
15011    result.value = createAliasExpression(valueContent, trimmedOffset, true);
15012  }
15013  return result;
15014}
15015function getSlice(start, end) {
15016  return currentInput.slice(start, end);
15017}
15018function endOpenTag(end) {
15019  if (tokenizer.inSFCRoot) {
15020    currentOpenTag.innerLoc = getLoc(end + 1, end + 1);
15021  }
15022  addNode(currentOpenTag);
15023  const { tag, ns } = currentOpenTag;
15024  if (ns === 0 && currentOptions.isPreTag(tag)) {
15025    inPre++;
15026  }
15027  if (currentOptions.isVoidTag(tag)) {
15028    onCloseTag(currentOpenTag, end);
15029  } else {
15030    compiler_core_esm_bundler_stack.unshift(currentOpenTag);
15031    if (ns === 1 || ns === 2) {
15032      tokenizer.inXML = true;
15033    }
15034  }
15035  currentOpenTag = null;
15036}
15037function onText(content, start, end) {
15038  {
15039    const tag = compiler_core_esm_bundler_stack[0] && compiler_core_esm_bundler_stack[0].tag;
15040    if (tag !== "script" && tag !== "style" && content.includes("&")) {
15041      content = currentOptions.decodeEntities(content, false);
15042    }
15043  }
15044  const parent = compiler_core_esm_bundler_stack[0] || currentRoot;
15045  const lastNode = parent.children[parent.children.length - 1];
15046  if (lastNode && lastNode.type === 2) {
15047    lastNode.content += content;
15048    setLocEnd(lastNode.loc, end);
15049  } else {
15050    parent.children.push({
15051      type: 2,
15052      content,
15053      loc: getLoc(start, end)
15054    });
15055  }
15056}
15057function onCloseTag(el, end, isImplied = false) {
15058  if (isImplied) {
15059    setLocEnd(el.loc, backTrack(end, 60));
15060  } else {
15061    setLocEnd(el.loc, lookAhead(end, 62) + 1);
15062  }
15063  if (tokenizer.inSFCRoot) {
15064    if (el.children.length) {
15065      el.innerLoc.end = shared_esm_bundler_extend({}, el.children[el.children.length - 1].loc.end);
15066    } else {
15067      el.innerLoc.end = shared_esm_bundler_extend({}, el.innerLoc.start);
15068    }
15069    el.innerLoc.source = getSlice(
15070      el.innerLoc.start.offset,
15071      el.innerLoc.end.offset
15072    );
15073  }
15074  const { tag, ns, children } = el;
15075  if (!inVPre) {
15076    if (tag === "slot") {
15077      el.tagType = 2;
15078    } else if (isFragmentTemplate(el)) {
15079      el.tagType = 3;
15080    } else if (isComponent(el)) {
15081      el.tagType = 1;
15082    }
15083  }
15084  if (!tokenizer.inRCDATA) {
15085    el.children = condenseWhitespace(children);
15086  }
15087  if (ns === 0 && currentOptions.isIgnoreNewlineTag(tag)) {
15088    const first = children[0];
15089    if (first && first.type === 2) {
15090      first.content = first.content.replace(/^\r?\n/, "");
15091    }
15092  }
15093  if (ns === 0 && currentOptions.isPreTag(tag)) {
15094    inPre--;
15095  }
15096  if (currentVPreBoundary === el) {
15097    inVPre = tokenizer.inVPre = false;
15098    currentVPreBoundary = null;
15099  }
15100  if (tokenizer.inXML && (compiler_core_esm_bundler_stack[0] ? compiler_core_esm_bundler_stack[0].ns : currentOptions.ns) === 0) {
15101    tokenizer.inXML = false;
15102  }
15103  {
15104    const props = el.props;
15105    if (false) // removed by dead control flow
15106{}
15107    if (!tokenizer.inSFCRoot && isCompatEnabled(
15108      "COMPILER_NATIVE_TEMPLATE",
15109      currentOptions
15110    ) && el.tag === "template" && !isFragmentTemplate(el)) {
15111       false && 0;
15112      const parent = compiler_core_esm_bundler_stack[0] || currentRoot;
15113      const index = parent.children.indexOf(el);
15114      parent.children.splice(index, 1, ...el.children);
15115    }
15116    const inlineTemplateProp = props.find(
15117      (p) => p.type === 6 && p.name === "inline-template"
15118    );
15119    if (inlineTemplateProp && checkCompatEnabled(
15120      "COMPILER_INLINE_TEMPLATE",
15121      currentOptions,
15122      inlineTemplateProp.loc
15123    ) && el.children.length) {
15124      inlineTemplateProp.value = {
15125        type: 2,
15126        content: getSlice(
15127          el.children[0].loc.start.offset,
15128          el.children[el.children.length - 1].loc.end.offset
15129        ),
15130        loc: inlineTemplateProp.loc
15131      };
15132    }
15133  }
15134}
15135function lookAhead(index, c) {
15136  let i = index;
15137  while (currentInput.charCodeAt(i) !== c && i < currentInput.length - 1) i++;
15138  return i;
15139}
15140function backTrack(index, c) {
15141  let i = index;
15142  while (currentInput.charCodeAt(i) !== c && i >= 0) i--;
15143  return i;
15144}
15145const specialTemplateDir = /* @__PURE__ */ new Set(["if", "else", "else-if", "for", "slot"]);
15146function isFragmentTemplate({ tag, props }) {
15147  if (tag === "template") {
15148    for (let i = 0; i < props.length; i++) {
15149      if (props[i].type === 7 && specialTemplateDir.has(props[i].name)) {
15150        return true;
15151      }
15152    }
15153  }
15154  return false;
vendor: 4,192 bytes, lines 15155-15302
15155}
15156function isComponent({ tag, props }) {
15157  if (currentOptions.isCustomElement(tag)) {
15158    return false;
15159  }
15160  if (tag === "component" || isUpperCase(tag.charCodeAt(0)) || isCoreComponent(tag) || currentOptions.isBuiltInComponent && currentOptions.isBuiltInComponent(tag) || currentOptions.isNativeTag && !currentOptions.isNativeTag(tag)) {
15161    return true;
15162  }
15163  for (let i = 0; i < props.length; i++) {
15164    const p = props[i];
15165    if (p.type === 6) {
15166      if (p.name === "is" && p.value) {
15167        if (p.value.content.startsWith("vue:")) {
15168          return true;
15169        } else if (checkCompatEnabled(
15170          "COMPILER_IS_ON_ELEMENT",
15171          currentOptions,
15172          p.loc
15173        )) {
15174          return true;
15175        }
15176      }
15177    } else if (// :is on plain element - only treat as component in compat mode
15178    p.name === "bind" && isStaticArgOf(p.arg, "is") && checkCompatEnabled(
15179      "COMPILER_IS_ON_ELEMENT",
15180      currentOptions,
15181      p.loc
15182    )) {
15183      return true;
15184    }
15185  }
15186  return false;
15187}
15188function isUpperCase(c) {
15189  return c > 64 && c < 91;
15190}
15191const windowsNewlineRE = /\r\n/g;
15192function condenseWhitespace(nodes) {
15193  const shouldCondense = currentOptions.whitespace !== "preserve";
15194  let removedWhitespace = false;
15195  for (let i = 0; i < nodes.length; i++) {
15196    const node = nodes[i];
15197    if (node.type === 2) {
15198      if (!inPre) {
15199        if (isAllWhitespace(node.content)) {
15200          const prev = nodes[i - 1] && nodes[i - 1].type;
15201          const next = nodes[i + 1] && nodes[i + 1].type;
15202          if (!prev || !next || shouldCondense && (prev === 3 && (next === 3 || next === 1) || prev === 1 && (next === 3 || next === 1 && hasNewlineChar(node.content)))) {
15203            removedWhitespace = true;
15204            nodes[i] = null;
15205          } else {
15206            node.content = " ";
15207          }
15208        } else if (shouldCondense) {
15209          node.content = condense(node.content);
15210        }
15211      } else {
15212        node.content = node.content.replace(windowsNewlineRE, "\n");
15213      }
15214    }
15215  }
15216  return removedWhitespace ? nodes.filter(Boolean) : nodes;
15217}
15218function hasNewlineChar(str) {
15219  for (let i = 0; i < str.length; i++) {
15220    const c = str.charCodeAt(i);
15221    if (c === 10 || c === 13) {
15222      return true;
15223    }
15224  }
15225  return false;
15226}
15227function condense(str) {
15228  let ret = "";
15229  let prevCharIsWhitespace = false;
15230  for (let i = 0; i < str.length; i++) {
15231    if (isWhitespace(str.charCodeAt(i))) {
15232      if (!prevCharIsWhitespace) {
15233        ret += " ";
15234        prevCharIsWhitespace = true;
15235      }
15236    } else {
15237      ret += str[i];
15238      prevCharIsWhitespace = false;
15239    }
15240  }
15241  return ret;
15242}
15243function addNode(node) {
15244  (compiler_core_esm_bundler_stack[0] || currentRoot).children.push(node);
15245}
15246function getLoc(start, end) {
15247  return {
15248    start: tokenizer.getPos(start),
15249    // @ts-expect-error allow late attachment
15250    end: end == null ? end : tokenizer.getPos(end),
15251    // @ts-expect-error allow late attachment
15252    source: end == null ? end : getSlice(start, end)
15253  };
15254}
15255function cloneLoc(loc) {
15256  return getLoc(loc.start.offset, loc.end.offset);
15257}
15258function setLocEnd(loc, end) {
15259  loc.end = tokenizer.getPos(end);
15260  loc.source = getSlice(loc.start.offset, end);
15261}
15262function dirToAttr(dir) {
15263  const attr = {
15264    type: 6,
15265    name: dir.rawName,
15266    nameLoc: getLoc(
15267      dir.loc.start.offset,
15268      dir.loc.start.offset + dir.rawName.length
15269    ),
15270    value: void 0,
15271    loc: dir.loc
15272  };
15273  if (dir.exp) {
15274    const loc = dir.exp.loc;
15275    if (loc.end.offset < dir.loc.end.offset) {
15276      loc.start.offset--;
15277      loc.start.column--;
15278      loc.end.offset++;
15279      loc.end.column++;
15280    }
15281    attr.value = {
15282      type: 2,
15283      content: dir.exp.content,
15284      loc
15285    };
15286  }
15287  return attr;
15288}
15289function createExp(content, isStatic = false, loc, constType = 0, parseMode = 0 /* Normal */) {
15290  const exp = createSimpleExpression(content, isStatic, loc, constType);
15291  return exp;
15292}
15293function emitError(code, index, message) {
15294  currentOptions.onError(
15295    createCompilerError(code, getLoc(index, index), void 0, message)
15296  );
15297}
15298function compiler_core_esm_bundler_reset() {
15299  tokenizer.reset();
15300  currentOpenTag = null;
15301  currentProp = null;
15302  currentAttrValue = "";
vendor: 5,094 bytes, lines 15303-15440
15303  currentAttrStartIndex = -1;
15304  currentAttrEndIndex = -1;
15305  compiler_core_esm_bundler_stack.length = 0;
15306}
15307function compiler_core_esm_bundler_baseParse(input, options) {
15308  compiler_core_esm_bundler_reset();
15309  currentInput = input;
15310  currentOptions = shared_esm_bundler_extend({}, defaultParserOptions);
15311  if (options) {
15312    let key;
15313    for (key in options) {
15314      if (options[key] != null) {
15315        currentOptions[key] = options[key];
15316      }
15317    }
15318  }
15319  if (false) // removed by dead control flow
15320{}
15321  tokenizer.mode = currentOptions.parseMode === "html" ? 1 : currentOptions.parseMode === "sfc" ? 2 : 0;
15322  tokenizer.inXML = currentOptions.ns === 1 || currentOptions.ns === 2;
15323  const delimiters = options && options.delimiters;
15324  if (delimiters) {
15325    tokenizer.delimiterOpen = toCharCodes(delimiters[0]);
15326    tokenizer.delimiterClose = toCharCodes(delimiters[1]);
15327  }
15328  const root = currentRoot = createRoot([], input);
15329  tokenizer.parse(currentInput);
15330  root.loc = getLoc(0, input.length);
15331  root.children = condenseWhitespace(root.children);
15332  currentRoot = null;
15333  return root;
15334}
15335
15336function cacheStatic(root, context) {
15337  walk(
15338    root,
15339    void 0,
15340    context,
15341    // Root node is unfortunately non-hoistable due to potential parent
15342    // fallthrough attributes.
15343    !!getSingleElementRoot(root)
15344  );
15345}
15346function getSingleElementRoot(root) {
15347  const children = root.children.filter((x) => x.type !== 3);
15348  return children.length === 1 && children[0].type === 1 && !isSlotOutlet(children[0]) ? children[0] : null;
15349}
15350function walk(node, parent, context, doNotHoistNode = false, inFor = false) {
15351  const { children } = node;
15352  const toCache = [];
15353  for (let i = 0; i < children.length; i++) {
15354    const child = children[i];
15355    if (child.type === 1 && child.tagType === 0) {
15356      const constantType = doNotHoistNode ? 0 : getConstantType(child, context);
15357      if (constantType > 0) {
15358        if (constantType >= 2) {
15359          child.codegenNode.patchFlag = -1;
15360          toCache.push(child);
15361          continue;
15362        }
15363      } else {
15364        const codegenNode = child.codegenNode;
15365        if (codegenNode.type === 13) {
15366          const flag = codegenNode.patchFlag;
15367          if ((flag === void 0 || flag === 512 || flag === 1) && getGeneratedPropsConstantType(child, context) >= 2) {
15368            const props = getNodeProps(child);
15369            if (props) {
15370              codegenNode.props = context.hoist(props);
15371            }
15372          }
15373          if (codegenNode.dynamicProps) {
15374            codegenNode.dynamicProps = context.hoist(codegenNode.dynamicProps);
15375          }
15376        }
15377      }
15378    } else if (child.type === 12) {
15379      const constantType = doNotHoistNode ? 0 : getConstantType(child, context);
15380      if (constantType >= 2) {
15381        if (child.codegenNode.type === 14 && child.codegenNode.arguments.length > 0) {
15382          child.codegenNode.arguments.push(
15383            -1 + ( false ? 0 : ``)
15384          );
15385        }
15386        toCache.push(child);
15387        continue;
15388      }
15389    }
15390    if (child.type === 1) {
15391      const isComponent = child.tagType === 1;
15392      if (isComponent) {
15393        context.scopes.vSlot++;
15394      }
15395      walk(child, node, context, false, inFor);
15396      if (isComponent) {
15397        context.scopes.vSlot--;
15398      }
15399    } else if (child.type === 11) {
15400      walk(child, node, context, child.children.length === 1, true);
15401    } else if (child.type === 9) {
15402      for (let i2 = 0; i2 < child.branches.length; i2++) {
15403        walk(
15404          child.branches[i2],
15405          node,
15406          context,
15407          child.branches[i2].children.length === 1,
15408          inFor
15409        );
15410      }
15411    }
15412  }
15413  let cachedAsArray = false;
15414  if (toCache.length === children.length && node.type === 1) {
15415    if (node.tagType === 0 && node.codegenNode && node.codegenNode.type === 13 && shared_esm_bundler_isArray(node.codegenNode.children)) {
15416      node.codegenNode.children = getCacheExpression(
15417        createArrayExpression(node.codegenNode.children)
15418      );
15419      cachedAsArray = true;
15420    } else if (node.tagType === 1 && node.codegenNode && node.codegenNode.type === 13 && node.codegenNode.children && !shared_esm_bundler_isArray(node.codegenNode.children) && node.codegenNode.children.type === 15) {
15421      const slot = getSlotNode(node.codegenNode, "default");
15422      if (slot) {
15423        slot.returns = getCacheExpression(
15424          createArrayExpression(slot.returns)
15425        );
15426        cachedAsArray = true;
15427      }
15428    } else if (node.tagType === 3 && parent && parent.type === 1 && parent.tagType === 1 && parent.codegenNode && parent.codegenNode.type === 13 && parent.codegenNode.children && !shared_esm_bundler_isArray(parent.codegenNode.children) && parent.codegenNode.children.type === 15) {
15429      const slotName = findDir(node, "slot", true);
15430      const slot = slotName && slotName.arg && getSlotNode(parent.codegenNode, slotName.arg);
15431      if (slot) {
15432        slot.returns = getCacheExpression(
15433          createArrayExpression(slot.returns)
15434        );
15435        cachedAsArray = true;
15436      }
15437    }
15438  }
15439  if (!cachedAsArray) {
15440    for (const child of toCache) {
vendor: 4,634 bytes, lines 15441-15593
15441      child.codegenNode = context.cache(child.codegenNode);
15442    }
15443  }
15444  function getCacheExpression(value) {
15445    const exp = context.cache(value);
15446    exp.needArraySpread = true;
15447    return exp;
15448  }
15449  function getSlotNode(node2, name) {
15450    if (node2.children && !shared_esm_bundler_isArray(node2.children) && node2.children.type === 15) {
15451      const slot = node2.children.properties.find(
15452        (p) => p.key === name || p.key.content === name
15453      );
15454      return slot && slot.value;
15455    }
15456  }
15457  if (toCache.length && context.transformHoist) {
15458    context.transformHoist(children, context, node);
15459  }
15460}
15461function getConstantType(node, context) {
15462  const { constantCache } = context;
15463  switch (node.type) {
15464    case 1:
15465      if (node.tagType !== 0) {
15466        return 0;
15467      }
15468      const cached = constantCache.get(node);
15469      if (cached !== void 0) {
15470        return cached;
15471      }
15472      const codegenNode = node.codegenNode;
15473      if (codegenNode.type !== 13) {
15474        return 0;
15475      }
15476      if (codegenNode.isBlock && node.tag !== "svg" && node.tag !== "foreignObject" && node.tag !== "math") {
15477        return 0;
15478      }
15479      if (codegenNode.patchFlag === void 0) {
15480        let returnType2 = 3;
15481        const generatedPropsType = getGeneratedPropsConstantType(node, context);
15482        if (generatedPropsType === 0) {
15483          constantCache.set(node, 0);
15484          return 0;
15485        }
15486        if (generatedPropsType < returnType2) {
15487          returnType2 = generatedPropsType;
15488        }
15489        for (let i = 0; i < node.children.length; i++) {
15490          const childType = getConstantType(node.children[i], context);
15491          if (childType === 0) {
15492            constantCache.set(node, 0);
15493            return 0;
15494          }
15495          if (childType < returnType2) {
15496            returnType2 = childType;
15497          }
15498        }
15499        if (returnType2 > 1) {
15500          for (let i = 0; i < node.props.length; i++) {
15501            const p = node.props[i];
15502            if (p.type === 7 && p.name === "bind" && p.exp) {
15503              const expType = getConstantType(p.exp, context);
15504              if (expType === 0) {
15505                constantCache.set(node, 0);
15506                return 0;
15507              }
15508              if (expType < returnType2) {
15509                returnType2 = expType;
15510              }
15511            }
15512          }
15513        }
15514        if (codegenNode.isBlock) {
15515          for (let i = 0; i < node.props.length; i++) {
15516            const p = node.props[i];
15517            if (p.type === 7) {
15518              constantCache.set(node, 0);
15519              return 0;
15520            }
15521          }
15522          context.removeHelper(OPEN_BLOCK);
15523          context.removeHelper(
15524            getVNodeBlockHelper(context.inSSR, codegenNode.isComponent)
15525          );
15526          codegenNode.isBlock = false;
15527          context.helper(getVNodeHelper(context.inSSR, codegenNode.isComponent));
15528        }
15529        constantCache.set(node, returnType2);
15530        return returnType2;
15531      } else {
15532        constantCache.set(node, 0);
15533        return 0;
15534      }
15535    case 2:
15536    case 3:
15537      return 3;
15538    case 9:
15539    case 11:
15540    case 10:
15541      return 0;
15542    case 5:
15543    case 12:
15544      return getConstantType(node.content, context);
15545    case 4:
15546      return node.constType;
15547    case 8:
15548      let returnType = 3;
15549      for (let i = 0; i < node.children.length; i++) {
15550        const child = node.children[i];
15551        if (shared_esm_bundler_isString(child) || isSymbol(child)) {
15552          continue;
15553        }
15554        const childType = getConstantType(child, context);
15555        if (childType === 0) {
15556          return 0;
15557        } else if (childType < returnType) {
15558          returnType = childType;
15559        }
15560      }
15561      return returnType;
15562    case 20:
15563      return 2;
15564    default:
15565      if (false) // removed by dead control flow
15566{}
15567      return 0;
15568  }
15569}
15570const allowHoistedHelperSet = /* @__PURE__ */ new Set([
15571  NORMALIZE_CLASS,
15572  NORMALIZE_STYLE,
15573  NORMALIZE_PROPS,
15574  GUARD_REACTIVE_PROPS
15575]);
15576function getConstantTypeOfHelperCall(value, context) {
15577  if (value.type === 14 && !shared_esm_bundler_isString(value.callee) && allowHoistedHelperSet.has(value.callee)) {
15578    const arg = value.arguments[0];
15579    if (arg.type === 4) {
15580      return getConstantType(arg, context);
15581    } else if (arg.type === 14) {
15582      return getConstantTypeOfHelperCall(arg, context);
15583    }
15584  }
15585  return 0;
15586}
15587function getGeneratedPropsConstantType(node, context) {
15588  let returnType = 3;
15589  const props = getNodeProps(node);
15590  if (props && props.type === 15) {
15591    const { properties } = props;
15592    for (let i = 0; i < properties.length; i++) {
15593      const { key, value } = properties[i];
vendor: 37,387 bytes, lines 15594-16989
15594      const keyType = getConstantType(key, context);
15595      if (keyType === 0) {
15596        return keyType;
15597      }
15598      if (keyType < returnType) {
15599        returnType = keyType;
15600      }
15601      let valueType;
15602      if (value.type === 4) {
15603        valueType = getConstantType(value, context);
15604      } else if (value.type === 14) {
15605        valueType = getConstantTypeOfHelperCall(value, context);
15606      } else {
15607        valueType = 0;
15608      }
15609      if (valueType === 0) {
15610        return valueType;
15611      }
15612      if (valueType < returnType) {
15613        returnType = valueType;
15614      }
15615    }
15616  }
15617  return returnType;
15618}
15619function getNodeProps(node) {
15620  const codegenNode = node.codegenNode;
15621  if (codegenNode.type === 13) {
15622    return codegenNode.props;
15623  }
15624}
15625
15626function createTransformContext(root, {
15627  filename = "",
15628  prefixIdentifiers = false,
15629  hoistStatic = false,
15630  hmr = false,
15631  cacheHandlers = false,
15632  nodeTransforms = [],
15633  directiveTransforms = {},
15634  transformHoist = null,
15635  isBuiltInComponent = shared_esm_bundler_NOOP,
15636  isCustomElement = shared_esm_bundler_NOOP,
15637  expressionPlugins = [],
15638  scopeId = null,
15639  slotted = true,
15640  ssr = false,
15641  inSSR = false,
15642  ssrCssVars = ``,
15643  bindingMetadata = EMPTY_OBJ,
15644  inline = false,
15645  isTS = false,
15646  onError = defaultOnError,
15647  onWarn = defaultOnWarn,
15648  compatConfig
15649}) {
15650  const nameMatch = filename.replace(/\?.*$/, "").match(/([^/\\]+)\.\w+$/);
15651  const context = {
15652    // options
15653    filename,
15654    selfName: nameMatch && shared_esm_bundler_capitalize(shared_esm_bundler_camelize(nameMatch[1])),
15655    prefixIdentifiers,
15656    hoistStatic,
15657    hmr,
15658    cacheHandlers,
15659    nodeTransforms,
15660    directiveTransforms,
15661    transformHoist,
15662    isBuiltInComponent,
15663    isCustomElement,
15664    expressionPlugins,
15665    scopeId,
15666    slotted,
15667    ssr,
15668    inSSR,
15669    ssrCssVars,
15670    bindingMetadata,
15671    inline,
15672    isTS,
15673    onError,
15674    onWarn,
15675    compatConfig,
15676    // state
15677    root,
15678    helpers: /* @__PURE__ */ new Map(),
15679    components: /* @__PURE__ */ new Set(),
15680    directives: /* @__PURE__ */ new Set(),
15681    hoists: [],
15682    imports: [],
15683    cached: [],
15684    constantCache: /* @__PURE__ */ new WeakMap(),
15685    temps: 0,
15686    identifiers: /* @__PURE__ */ Object.create(null),
15687    scopes: {
15688      vFor: 0,
15689      vSlot: 0,
15690      vPre: 0,
15691      vOnce: 0
15692    },
15693    parent: null,
15694    grandParent: null,
15695    currentNode: root,
15696    childIndex: 0,
15697    inVOnce: false,
15698    // methods
15699    helper(name) {
15700      const count = context.helpers.get(name) || 0;
15701      context.helpers.set(name, count + 1);
15702      return name;
15703    },
15704    removeHelper(name) {
15705      const count = context.helpers.get(name);
15706      if (count) {
15707        const currentCount = count - 1;
15708        if (!currentCount) {
15709          context.helpers.delete(name);
15710        } else {
15711          context.helpers.set(name, currentCount);
15712        }
15713      }
15714    },
15715    helperString(name) {
15716      return `_${helperNameMap[context.helper(name)]}`;
15717    },
15718    replaceNode(node) {
15719      if (false) // removed by dead control flow
15720{}
15721      context.parent.children[context.childIndex] = context.currentNode = node;
15722    },
15723    removeNode(node) {
15724      if (false) // removed by dead control flow
15725{}
15726      const list = context.parent.children;
15727      const removalIndex = node ? list.indexOf(node) : context.currentNode ? context.childIndex : -1;
15728      if (false) // removed by dead control flow
15729{}
15730      if (!node || node === context.currentNode) {
15731        context.currentNode = null;
15732        context.onNodeRemoved();
15733      } else {
15734        if (context.childIndex > removalIndex) {
15735          context.childIndex--;
15736          context.onNodeRemoved();
15737        }
15738      }
15739      context.parent.children.splice(removalIndex, 1);
15740    },
15741    onNodeRemoved: shared_esm_bundler_NOOP,
15742    addIdentifiers(exp) {
15743    },
15744    removeIdentifiers(exp) {
15745    },
15746    hoist(exp) {
15747      if (shared_esm_bundler_isString(exp)) exp = createSimpleExpression(exp);
15748      context.hoists.push(exp);
15749      const identifier = createSimpleExpression(
15750        `_hoisted_${context.hoists.length}`,
15751        false,
15752        exp.loc,
15753        2
15754      );
15755      identifier.hoisted = exp;
15756      return identifier;
15757    },
15758    cache(exp, isVNode = false, inVOnce = false) {
15759      const cacheExp = createCacheExpression(
15760        context.cached.length,
15761        exp,
15762        isVNode,
15763        inVOnce
15764      );
15765      context.cached.push(cacheExp);
15766      return cacheExp;
15767    }
15768  };
15769  {
15770    context.filters = /* @__PURE__ */ new Set();
15771  }
15772  return context;
15773}
15774function transform(root, options) {
15775  const context = createTransformContext(root, options);
15776  traverseNode(root, context);
15777  if (options.hoistStatic) {
15778    cacheStatic(root, context);
15779  }
15780  if (!options.ssr) {
15781    createRootCodegen(root, context);
15782  }
15783  root.helpers = /* @__PURE__ */ new Set([...context.helpers.keys()]);
15784  root.components = [...context.components];
15785  root.directives = [...context.directives];
15786  root.imports = context.imports;
15787  root.hoists = context.hoists;
15788  root.temps = context.temps;
15789  root.cached = context.cached;
15790  root.transformed = true;
15791  {
15792    root.filters = [...context.filters];
15793  }
15794}
15795function createRootCodegen(root, context) {
15796  const { helper } = context;
15797  const { children } = root;
15798  if (children.length === 1) {
15799    const singleElementRootChild = getSingleElementRoot(root);
15800    if (singleElementRootChild && singleElementRootChild.codegenNode) {
15801      const codegenNode = singleElementRootChild.codegenNode;
15802      if (codegenNode.type === 13) {
15803        convertToBlock(codegenNode, context);
15804      }
15805      root.codegenNode = codegenNode;
15806    } else {
15807      root.codegenNode = children[0];
15808    }
15809  } else if (children.length > 1) {
15810    let patchFlag = 64;
15811    if (false) // removed by dead control flow
15812{}
15813    root.codegenNode = createVNodeCall(
15814      context,
15815      helper(FRAGMENT),
15816      void 0,
15817      root.children,
15818      patchFlag,
15819      void 0,
15820      void 0,
15821      true,
15822      void 0,
15823      false
15824    );
15825  } else ;
15826}
15827function traverseChildren(parent, context) {
15828  let i = 0;
15829  const nodeRemoved = () => {
15830    i--;
15831  };
15832  for (; i < parent.children.length; i++) {
15833    const child = parent.children[i];
15834    if (shared_esm_bundler_isString(child)) continue;
15835    context.grandParent = context.parent;
15836    context.parent = parent;
15837    context.childIndex = i;
15838    context.onNodeRemoved = nodeRemoved;
15839    traverseNode(child, context);
15840  }
15841}
15842function traverseNode(node, context) {
15843  context.currentNode = node;
15844  const { nodeTransforms } = context;
15845  const exitFns = [];
15846  for (let i2 = 0; i2 < nodeTransforms.length; i2++) {
15847    const onExit = nodeTransforms[i2](node, context);
15848    if (onExit) {
15849      if (shared_esm_bundler_isArray(onExit)) {
15850        exitFns.push(...onExit);
15851      } else {
15852        exitFns.push(onExit);
15853      }
15854    }
15855    if (!context.currentNode) {
15856      return;
15857    } else {
15858      node = context.currentNode;
15859    }
15860  }
15861  switch (node.type) {
15862    case 3:
15863      if (!context.ssr) {
15864        context.helper(CREATE_COMMENT);
15865      }
15866      break;
15867    case 5:
15868      if (!context.ssr) {
15869        context.helper(TO_DISPLAY_STRING);
15870      }
15871      break;
15872    // for container types, further traverse downwards
15873    case 9:
15874      for (let i2 = 0; i2 < node.branches.length; i2++) {
15875        traverseNode(node.branches[i2], context);
15876      }
15877      break;
15878    case 10:
15879    case 11:
15880    case 1:
15881    case 0:
15882      traverseChildren(node, context);
15883      break;
15884  }
15885  context.currentNode = node;
15886  let i = exitFns.length;
15887  while (i--) {
15888    exitFns[i]();
15889  }
15890}
15891function createStructuralDirectiveTransform(name, fn) {
15892  const matches = shared_esm_bundler_isString(name) ? (n) => n === name : (n) => name.test(n);
15893  return (node, context) => {
15894    if (node.type === 1) {
15895      const { props } = node;
15896      if (node.tagType === 3 && props.some(isVSlot)) {
15897        return;
15898      }
15899      const exitFns = [];
15900      for (let i = 0; i < props.length; i++) {
15901        const prop = props[i];
15902        if (prop.type === 7 && matches(prop.name)) {
15903          props.splice(i, 1);
15904          i--;
15905          const onExit = fn(node, prop, context);
15906          if (onExit) exitFns.push(onExit);
15907        }
15908      }
15909      return exitFns;
15910    }
15911  };
15912}
15913
15914const PURE_ANNOTATION = `/*@__PURE__*/`;
15915const aliasHelper = (s) => `${helperNameMap[s]}: _${helperNameMap[s]}`;
15916function createCodegenContext(ast, {
15917  mode = "function",
15918  prefixIdentifiers = mode === "module",
15919  sourceMap = false,
15920  filename = `template.vue.html`,
15921  scopeId = null,
15922  optimizeImports = false,
15923  runtimeGlobalName = `Vue`,
15924  runtimeModuleName = `vue`,
15925  ssrRuntimeModuleName = "vue/server-renderer",
15926  ssr = false,
15927  isTS = false,
15928  inSSR = false
15929}) {
15930  const context = {
15931    mode,
15932    prefixIdentifiers,
15933    sourceMap,
15934    filename,
15935    scopeId,
15936    optimizeImports,
15937    runtimeGlobalName,
15938    runtimeModuleName,
15939    ssrRuntimeModuleName,
15940    ssr,
15941    isTS,
15942    inSSR,
15943    source: ast.source,
15944    code: ``,
15945    column: 1,
15946    line: 1,
15947    offset: 0,
15948    indentLevel: 0,
15949    pure: false,
15950    map: void 0,
15951    helper(key) {
15952      return `_${helperNameMap[key]}`;
15953    },
15954    push(code, newlineIndex = -2 /* None */, node) {
15955      context.code += code;
15956    },
15957    indent() {
15958      newline(++context.indentLevel);
15959    },
15960    deindent(withoutNewLine = false) {
15961      if (withoutNewLine) {
15962        --context.indentLevel;
15963      } else {
15964        newline(--context.indentLevel);
15965      }
15966    },
15967    newline() {
15968      newline(context.indentLevel);
15969    }
15970  };
15971  function newline(n) {
15972    context.push("\n" + `  `.repeat(n), 0 /* Start */);
15973  }
15974  return context;
15975}
15976function generate(ast, options = {}) {
15977  const context = createCodegenContext(ast, options);
15978  if (options.onContextCreated) options.onContextCreated(context);
15979  const {
15980    mode,
15981    push,
15982    prefixIdentifiers,
15983    indent,
15984    deindent,
15985    newline,
15986    scopeId,
15987    ssr
15988  } = context;
15989  const helpers = Array.from(ast.helpers);
15990  const hasHelpers = helpers.length > 0;
15991  const useWithBlock = !prefixIdentifiers && mode !== "module";
15992  const preambleContext = context;
15993  {
15994    genFunctionPreamble(ast, preambleContext);
15995  }
15996  const functionName = ssr ? `ssrRender` : `render`;
15997  const args = ssr ? ["_ctx", "_push", "_parent", "_attrs"] : ["_ctx", "_cache"];
15998  const signature = args.join(", ");
15999  {
16000    push(`function ${functionName}(${signature}) {`);
16001  }
16002  indent();
16003  if (useWithBlock) {
16004    push(`with (_ctx) {`);
16005    indent();
16006    if (hasHelpers) {
16007      push(
16008        `const { ${helpers.map(aliasHelper).join(", ")} } = _Vue
16009`,
16010        -1 /* End */
16011      );
16012      newline();
16013    }
16014  }
16015  if (ast.components.length) {
16016    genAssets(ast.components, "component", context);
16017    if (ast.directives.length || ast.temps > 0) {
16018      newline();
16019    }
16020  }
16021  if (ast.directives.length) {
16022    genAssets(ast.directives, "directive", context);
16023    if (ast.temps > 0) {
16024      newline();
16025    }
16026  }
16027  if (ast.filters && ast.filters.length) {
16028    newline();
16029    genAssets(ast.filters, "filter", context);
16030    newline();
16031  }
16032  if (ast.temps > 0) {
16033    push(`let `);
16034    for (let i = 0; i < ast.temps; i++) {
16035      push(`${i > 0 ? `, ` : ``}_temp${i}`);
16036    }
16037  }
16038  if (ast.components.length || ast.directives.length || ast.temps) {
16039    push(`
16040`, 0 /* Start */);
16041    newline();
16042  }
16043  if (!ssr) {
16044    push(`return `);
16045  }
16046  if (ast.codegenNode) {
16047    genNode(ast.codegenNode, context);
16048  } else {
16049    push(`null`);
16050  }
16051  if (useWithBlock) {
16052    deindent();
16053    push(`}`);
16054  }
16055  deindent();
16056  push(`}`);
16057  return {
16058    ast,
16059    code: context.code,
16060    preamble: ``,
16061    map: context.map ? context.map.toJSON() : void 0
16062  };
16063}
16064function genFunctionPreamble(ast, context) {
16065  const {
16066    ssr,
16067    prefixIdentifiers,
16068    push,
16069    newline,
16070    runtimeModuleName,
16071    runtimeGlobalName,
16072    ssrRuntimeModuleName
16073  } = context;
16074  const VueBinding = runtimeGlobalName;
16075  const helpers = Array.from(ast.helpers);
16076  if (helpers.length > 0) {
16077    {
16078      push(`const _Vue = ${VueBinding}
16079`, -1 /* End */);
16080      if (ast.hoists.length) {
16081        const staticHelpers = [
16082          CREATE_VNODE,
16083          CREATE_ELEMENT_VNODE,
16084          CREATE_COMMENT,
16085          CREATE_TEXT,
16086          CREATE_STATIC
16087        ].filter((helper) => helpers.includes(helper)).map(aliasHelper).join(", ");
16088        push(`const { ${staticHelpers} } = _Vue
16089`, -1 /* End */);
16090      }
16091    }
16092  }
16093  genHoists(ast.hoists, context);
16094  newline();
16095  push(`return `);
16096}
16097function genAssets(assets, type, { helper, push, newline, isTS }) {
16098  const resolver = helper(
16099    type === "filter" ? RESOLVE_FILTER : type === "component" ? RESOLVE_COMPONENT : RESOLVE_DIRECTIVE
16100  );
16101  for (let i = 0; i < assets.length; i++) {
16102    let id = assets[i];
16103    const maybeSelfReference = id.endsWith("__self");
16104    if (maybeSelfReference) {
16105      id = id.slice(0, -6);
16106    }
16107    push(
16108      `const ${toValidAssetId(id, type)} = ${resolver}(${JSON.stringify(id)}${maybeSelfReference ? `, true` : ``})${isTS ? `!` : ``}`
16109    );
16110    if (i < assets.length - 1) {
16111      newline();
16112    }
16113  }
16114}
16115function genHoists(hoists, context) {
16116  if (!hoists.length) {
16117    return;
16118  }
16119  context.pure = true;
16120  const { push, newline } = context;
16121  newline();
16122  for (let i = 0; i < hoists.length; i++) {
16123    const exp = hoists[i];
16124    if (exp) {
16125      push(`const _hoisted_${i + 1} = `);
16126      genNode(exp, context);
16127      newline();
16128    }
16129  }
16130  context.pure = false;
16131}
16132function isText(n) {
16133  return isString(n) || n.type === 4 || n.type === 2 || n.type === 5 || n.type === 8;
16134}
16135function genNodeListAsArray(nodes, context) {
16136  const multilines = nodes.length > 3 ||  false && 0;
16137  context.push(`[`);
16138  multilines && context.indent();
16139  genNodeList(nodes, context, multilines);
16140  multilines && context.deindent();
16141  context.push(`]`);
16142}
16143function genNodeList(nodes, context, multilines = false, comma = true) {
16144  const { push, newline } = context;
16145  for (let i = 0; i < nodes.length; i++) {
16146    const node = nodes[i];
16147    if (shared_esm_bundler_isString(node)) {
16148      push(node, -3 /* Unknown */);
16149    } else if (shared_esm_bundler_isArray(node)) {
16150      genNodeListAsArray(node, context);
16151    } else {
16152      genNode(node, context);
16153    }
16154    if (i < nodes.length - 1) {
16155      if (multilines) {
16156        comma && push(",");
16157        newline();
16158      } else {
16159        comma && push(", ");
16160      }
16161    }
16162  }
16163}
16164function genNode(node, context) {
16165  if (shared_esm_bundler_isString(node)) {
16166    context.push(node, -3 /* Unknown */);
16167    return;
16168  }
16169  if (isSymbol(node)) {
16170    context.push(context.helper(node));
16171    return;
16172  }
16173  switch (node.type) {
16174    case 1:
16175    case 9:
16176    case 11:
16177       false && 0;
16178      genNode(node.codegenNode, context);
16179      break;
16180    case 2:
16181      genText(node, context);
16182      break;
16183    case 4:
16184      genExpression(node, context);
16185      break;
16186    case 5:
16187      genInterpolation(node, context);
16188      break;
16189    case 12:
16190      genNode(node.codegenNode, context);
16191      break;
16192    case 8:
16193      genCompoundExpression(node, context);
16194      break;
16195    case 3:
16196      genComment(node, context);
16197      break;
16198    case 13:
16199      genVNodeCall(node, context);
16200      break;
16201    case 14:
16202      genCallExpression(node, context);
16203      break;
16204    case 15:
16205      genObjectExpression(node, context);
16206      break;
16207    case 17:
16208      genArrayExpression(node, context);
16209      break;
16210    case 18:
16211      genFunctionExpression(node, context);
16212      break;
16213    case 19:
16214      genConditionalExpression(node, context);
16215      break;
16216    case 20:
16217      genCacheExpression(node, context);
16218      break;
16219    case 21:
16220      genNodeList(node.body, context, true, false);
16221      break;
16222    // SSR only types
16223    case 22:
16224      break;
16225    case 23:
16226      break;
16227    case 24:
16228      break;
16229    case 25:
16230      break;
16231    case 26:
16232      break;
16233    /* v8 ignore start */
16234    case 10:
16235      break;
16236    default:
16237      if (false) // removed by dead control flow
16238{}
16239  }
16240}
16241function genText(node, context) {
16242  context.push(JSON.stringify(node.content), -3 /* Unknown */, node);
16243}
16244function genExpression(node, context) {
16245  const { content, isStatic } = node;
16246  context.push(
16247    isStatic ? JSON.stringify(content) : content,
16248    -3 /* Unknown */,
16249    node
16250  );
16251}
16252function genInterpolation(node, context) {
16253  const { push, helper, pure } = context;
16254  if (pure) push(PURE_ANNOTATION);
16255  push(`${helper(TO_DISPLAY_STRING)}(`);
16256  genNode(node.content, context);
16257  push(`)`);
16258}
16259function genCompoundExpression(node, context) {
16260  for (let i = 0; i < node.children.length; i++) {
16261    const child = node.children[i];
16262    if (shared_esm_bundler_isString(child)) {
16263      context.push(child, -3 /* Unknown */);
16264    } else {
16265      genNode(child, context);
16266    }
16267  }
16268}
16269function genExpressionAsPropertyKey(node, context) {
16270  const { push } = context;
16271  if (node.type === 8) {
16272    push(`[`);
16273    genCompoundExpression(node, context);
16274    push(`]`);
16275  } else if (node.isStatic) {
16276    const text = isSimpleIdentifier(node.content) ? node.content : JSON.stringify(node.content);
16277    push(text, -2 /* None */, node);
16278  } else {
16279    push(`[${node.content}]`, -3 /* Unknown */, node);
16280  }
16281}
16282function genComment(node, context) {
16283  const { push, helper, pure } = context;
16284  if (pure) {
16285    push(PURE_ANNOTATION);
16286  }
16287  push(
16288    `${helper(CREATE_COMMENT)}(${JSON.stringify(node.content)})`,
16289    -3 /* Unknown */,
16290    node
16291  );
16292}
16293function genVNodeCall(node, context) {
16294  const { push, helper, pure } = context;
16295  const {
16296    tag,
16297    props,
16298    children,
16299    patchFlag,
16300    dynamicProps,
16301    directives,
16302    isBlock,
16303    disableTracking,
16304    isComponent
16305  } = node;
16306  let patchFlagString;
16307  if (patchFlag) {
16308    if (false) // removed by dead control flow
16309{} else {
16310      patchFlagString = String(patchFlag);
16311    }
16312  }
16313  if (directives) {
16314    push(helper(WITH_DIRECTIVES) + `(`);
16315  }
16316  if (isBlock) {
16317    push(`(${helper(OPEN_BLOCK)}(${disableTracking ? `true` : ``}), `);
16318  }
16319  if (pure) {
16320    push(PURE_ANNOTATION);
16321  }
16322  const callHelper = isBlock ? getVNodeBlockHelper(context.inSSR, isComponent) : getVNodeHelper(context.inSSR, isComponent);
16323  push(helper(callHelper) + `(`, -2 /* None */, node);
16324  genNodeList(
16325    genNullableArgs([tag, props, children, patchFlagString, dynamicProps]),
16326    context
16327  );
16328  push(`)`);
16329  if (isBlock) {
16330    push(`)`);
16331  }
16332  if (directives) {
16333    push(`, `);
16334    genNode(directives, context);
16335    push(`)`);
16336  }
16337}
16338function genNullableArgs(args) {
16339  let i = args.length;
16340  while (i--) {
16341    if (args[i] != null) break;
16342  }
16343  return args.slice(0, i + 1).map((arg) => arg || `null`);
16344}
16345function genCallExpression(node, context) {
16346  const { push, helper, pure } = context;
16347  const callee = shared_esm_bundler_isString(node.callee) ? node.callee : helper(node.callee);
16348  if (pure) {
16349    push(PURE_ANNOTATION);
16350  }
16351  push(callee + `(`, -2 /* None */, node);
16352  genNodeList(node.arguments, context);
16353  push(`)`);
16354}
16355function genObjectExpression(node, context) {
16356  const { push, indent, deindent, newline } = context;
16357  const { properties } = node;
16358  if (!properties.length) {
16359    push(`{}`, -2 /* None */, node);
16360    return;
16361  }
16362  const multilines = properties.length > 1 ||  false && 0;
16363  push(multilines ? `{` : `{ `);
16364  multilines && indent();
16365  for (let i = 0; i < properties.length; i++) {
16366    const { key, value } = properties[i];
16367    genExpressionAsPropertyKey(key, context);
16368    push(`: `);
16369    genNode(value, context);
16370    if (i < properties.length - 1) {
16371      push(`,`);
16372      newline();
16373    }
16374  }
16375  multilines && deindent();
16376  push(multilines ? `}` : ` }`);
16377}
16378function genArrayExpression(node, context) {
16379  genNodeListAsArray(node.elements, context);
16380}
16381function genFunctionExpression(node, context) {
16382  const { push, indent, deindent } = context;
16383  const { params, returns, body, newline, isSlot } = node;
16384  if (isSlot) {
16385    push(`_${helperNameMap[WITH_CTX]}(`);
16386  }
16387  push(`(`, -2 /* None */, node);
16388  if (shared_esm_bundler_isArray(params)) {
16389    genNodeList(params, context);
16390  } else if (params) {
16391    genNode(params, context);
16392  }
16393  push(`) => `);
16394  if (newline || body) {
16395    push(`{`);
16396    indent();
16397  }
16398  if (returns) {
16399    if (newline) {
16400      push(`return `);
16401    }
16402    if (shared_esm_bundler_isArray(returns)) {
16403      genNodeListAsArray(returns, context);
16404    } else {
16405      genNode(returns, context);
16406    }
16407  } else if (body) {
16408    genNode(body, context);
16409  }
16410  if (newline || body) {
16411    deindent();
16412    push(`}`);
16413  }
16414  if (isSlot) {
16415    if (node.isNonScopedSlot) {
16416      push(`, undefined, true`);
16417    }
16418    push(`)`);
16419  }
16420}
16421function genConditionalExpression(node, context) {
16422  const { test, consequent, alternate, newline: needNewline } = node;
16423  const { push, indent, deindent, newline } = context;
16424  if (test.type === 4) {
16425    const needsParens = !isSimpleIdentifier(test.content);
16426    needsParens && push(`(`);
16427    genExpression(test, context);
16428    needsParens && push(`)`);
16429  } else {
16430    push(`(`);
16431    genNode(test, context);
16432    push(`)`);
16433  }
16434  needNewline && indent();
16435  context.indentLevel++;
16436  needNewline || push(` `);
16437  push(`? `);
16438  genNode(consequent, context);
16439  context.indentLevel--;
16440  needNewline && newline();
16441  needNewline || push(` `);
16442  push(`: `);
16443  const isNested = alternate.type === 19;
16444  if (!isNested) {
16445    context.indentLevel++;
16446  }
16447  genNode(alternate, context);
16448  if (!isNested) {
16449    context.indentLevel--;
16450  }
16451  needNewline && deindent(
16452    true
16453    /* without newline */
16454  );
16455}
16456function genCacheExpression(node, context) {
16457  const { push, helper, indent, deindent, newline } = context;
16458  const { needPauseTracking, needArraySpread } = node;
16459  if (needArraySpread) {
16460    push(`[...(`);
16461  }
16462  push(`_cache[${node.index}] || (`);
16463  if (needPauseTracking) {
16464    indent();
16465    push(`${helper(SET_BLOCK_TRACKING)}(-1`);
16466    if (node.inVOnce) push(`, true`);
16467    push(`),`);
16468    newline();
16469    push(`(`);
16470  }
16471  push(`_cache[${node.index}] = `);
16472  genNode(node.value, context);
16473  if (needPauseTracking) {
16474    push(`).cacheIndex = ${node.index},`);
16475    newline();
16476    push(`${helper(SET_BLOCK_TRACKING)}(1),`);
16477    newline();
16478    push(`_cache[${node.index}]`);
16479    deindent();
16480  }
16481  push(`)`);
16482  if (needArraySpread) {
16483    push(`)]`);
16484  }
16485}
16486
16487const prohibitedKeywordRE = new RegExp(
16488  "\\b" + "arguments,await,break,case,catch,class,const,continue,debugger,default,delete,do,else,export,extends,finally,for,function,if,import,let,new,return,super,switch,throw,try,var,void,while,with,yield".split(",").join("\\b|\\b") + "\\b"
16489);
16490const stripStringRE = /'(?:[^'\\]|\\.)*'|"(?:[^"\\]|\\.)*"|`(?:[^`\\]|\\.)*\$\{|\}(?:[^`\\]|\\.)*`|`(?:[^`\\]|\\.)*`/g;
16491function validateBrowserExpression(node, context, asParams = false, asRawStatements = false) {
16492  const exp = node.content;
16493  if (!exp.trim()) {
16494    return;
16495  }
16496  try {
16497    new Function(
16498      asRawStatements ? ` ${exp} ` : `return ${asParams ? `(${exp}) => {}` : `(${exp})`}`
16499    );
16500  } catch (e) {
16501    let message = e.message;
16502    const keywordMatch = exp.replace(stripStringRE, "").match(prohibitedKeywordRE);
16503    if (keywordMatch) {
16504      message = `avoid using JavaScript keyword as property name: "${keywordMatch[0]}"`;
16505    }
16506    context.onError(
16507      createCompilerError(
16508        45,
16509        node.loc,
16510        void 0,
16511        message
16512      )
16513    );
16514  }
16515}
16516
16517const transformExpression = (node, context) => {
16518  if (node.type === 5) {
16519    node.content = processExpression(
16520      node.content,
16521      context
16522    );
16523  } else if (node.type === 1) {
16524    const memo = findDir(node, "memo");
16525    for (let i = 0; i < node.props.length; i++) {
16526      const dir = node.props[i];
16527      if (dir.type === 7 && dir.name !== "for") {
16528        const exp = dir.exp;
16529        const arg = dir.arg;
16530        if (exp && exp.type === 4 && !(dir.name === "on" && arg) && // key has been processed in transformFor(vMemo + vFor)
16531        !(memo && arg && arg.type === 4 && arg.content === "key")) {
16532          dir.exp = processExpression(
16533            exp,
16534            context,
16535            // slot args must be processed as function params
16536            dir.name === "slot"
16537          );
16538        }
16539        if (arg && arg.type === 4 && !arg.isStatic) {
16540          dir.arg = processExpression(arg, context);
16541        }
16542      }
16543    }
16544  }
16545};
16546function processExpression(node, context, asParams = false, asRawStatements = false, localVars = Object.create(context.identifiers)) {
16547  {
16548    if (false) // removed by dead control flow
16549{}
16550    return node;
16551  }
16552}
16553function stringifyExpression(exp) {
16554  if (isString(exp)) {
16555    return exp;
16556  } else if (exp.type === 4) {
16557    return exp.content;
16558  } else {
16559    return exp.children.map(stringifyExpression).join("");
16560  }
16561}
16562
16563const transformIf = createStructuralDirectiveTransform(
16564  /^(?:if|else|else-if)$/,
16565  (node, dir, context) => {
16566    return processIf(node, dir, context, (ifNode, branch, isRoot) => {
16567      const siblings = context.parent.children;
16568      let i = siblings.indexOf(ifNode);
16569      let key = 0;
16570      while (i-- >= 0) {
16571        const sibling = siblings[i];
16572        if (sibling && sibling.type === 9) {
16573          key += sibling.branches.length;
16574        }
16575      }
16576      return () => {
16577        if (isRoot) {
16578          ifNode.codegenNode = createCodegenNodeForBranch(
16579            branch,
16580            key,
16581            context
16582          );
16583        } else {
16584          const parentCondition = getParentCondition(ifNode.codegenNode);
16585          parentCondition.alternate = createCodegenNodeForBranch(
16586            branch,
16587            key + ifNode.branches.length - 1,
16588            context
16589          );
16590        }
16591      };
16592    });
16593  }
16594);
16595function processIf(node, dir, context, processCodegen) {
16596  if (dir.name !== "else" && (!dir.exp || !dir.exp.content.trim())) {
16597    const loc = dir.exp ? dir.exp.loc : node.loc;
16598    context.onError(
16599      createCompilerError(28, dir.loc)
16600    );
16601    dir.exp = createSimpleExpression(`true`, false, loc);
16602  }
16603  if (false) // removed by dead control flow
16604{}
16605  if (dir.name === "if") {
16606    const branch = createIfBranch(node, dir);
16607    const ifNode = {
16608      type: 9,
16609      loc: cloneLoc(node.loc),
16610      branches: [branch]
16611    };
16612    context.replaceNode(ifNode);
16613    if (processCodegen) {
16614      return processCodegen(ifNode, branch, true);
16615    }
16616  } else {
16617    const siblings = context.parent.children;
16618    const comments = [];
16619    let i = siblings.indexOf(node);
16620    while (i-- >= -1) {
16621      const sibling = siblings[i];
16622      if (sibling && compiler_core_esm_bundler_isCommentOrWhitespace(sibling)) {
16623        context.removeNode(sibling);
16624        if (false) // removed by dead control flow
16625{}
16626        continue;
16627      }
16628      if (sibling && sibling.type === 9) {
16629        if ((dir.name === "else-if" || dir.name === "else") && sibling.branches[sibling.branches.length - 1].condition === void 0) {
16630          context.onError(
16631            createCompilerError(30, node.loc)
16632          );
16633        }
16634        context.removeNode();
16635        const branch = createIfBranch(node, dir);
16636        if (false) // removed by dead control flow
16637{}
16638        if (false) // removed by dead control flow
16639{}
16640        sibling.branches.push(branch);
16641        const onExit = processCodegen && processCodegen(sibling, branch, false);
16642        traverseNode(branch, context);
16643        if (onExit) onExit();
16644        context.currentNode = null;
16645      } else {
16646        context.onError(
16647          createCompilerError(30, node.loc)
16648        );
16649      }
16650      break;
16651    }
16652  }
16653}
16654function createIfBranch(node, dir) {
16655  const isTemplateIf = node.tagType === 3;
16656  return {
16657    type: 10,
16658    loc: node.loc,
16659    condition: dir.name === "else" ? void 0 : dir.exp,
16660    children: isTemplateIf && !findDir(node, "for") ? node.children : [node],
16661    userKey: findProp(node, `key`),
16662    isTemplateIf
16663  };
16664}
16665function createCodegenNodeForBranch(branch, keyIndex, context) {
16666  if (branch.condition) {
16667    return createConditionalExpression(
16668      branch.condition,
16669      createChildrenCodegenNode(branch, keyIndex, context),
16670      // make sure to pass in asBlock: true so that the comment node call
16671      // closes the current block.
16672      createCallExpression(context.helper(CREATE_COMMENT), [
16673         false ? 0 : '""',
16674        "true"
16675      ])
16676    );
16677  } else {
16678    return createChildrenCodegenNode(branch, keyIndex, context);
16679  }
16680}
16681function createChildrenCodegenNode(branch, keyIndex, context) {
16682  const { helper } = context;
16683  const keyProperty = createObjectProperty(
16684    `key`,
16685    createSimpleExpression(
16686      `${keyIndex}`,
16687      false,
16688      locStub,
16689      2
16690    )
16691  );
16692  const { children } = branch;
16693  const firstChild = children[0];
16694  const needFragmentWrapper = children.length !== 1 || firstChild.type !== 1;
16695  if (needFragmentWrapper) {
16696    if (children.length === 1 && firstChild.type === 11) {
16697      const vnodeCall = firstChild.codegenNode;
16698      injectProp(vnodeCall, keyProperty, context);
16699      return vnodeCall;
16700    } else {
16701      let patchFlag = 64;
16702      if (false) // removed by dead control flow
16703{}
16704      return createVNodeCall(
16705        context,
16706        helper(FRAGMENT),
16707        createObjectExpression([keyProperty]),
16708        children,
16709        patchFlag,
16710        void 0,
16711        void 0,
16712        true,
16713        false,
16714        false,
16715        branch.loc
16716      );
16717    }
16718  } else {
16719    const ret = firstChild.codegenNode;
16720    const vnodeCall = getMemoedVNodeCall(ret);
16721    if (vnodeCall.type === 13) {
16722      convertToBlock(vnodeCall, context);
16723    }
16724    injectProp(vnodeCall, keyProperty, context);
16725    return ret;
16726  }
16727}
16728function isSameKey(a, b) {
16729  if (!a || a.type !== b.type) {
16730    return false;
16731  }
16732  if (a.type === 6) {
16733    if (a.value.content !== b.value.content) {
16734      return false;
16735    }
16736  } else {
16737    const exp = a.exp;
16738    const branchExp = b.exp;
16739    if (exp.type !== branchExp.type) {
16740      return false;
16741    }
16742    if (exp.type !== 4 || exp.isStatic !== branchExp.isStatic || exp.content !== branchExp.content) {
16743      return false;
16744    }
16745  }
16746  return true;
16747}
16748function getParentCondition(node) {
16749  while (true) {
16750    if (node.type === 19) {
16751      if (node.alternate.type === 19) {
16752        node = node.alternate;
16753      } else {
16754        return node;
16755      }
16756    } else if (node.type === 20) {
16757      node = node.value;
16758    }
16759  }
16760}
16761
16762const transformFor = createStructuralDirectiveTransform(
16763  "for",
16764  (node, dir, context) => {
16765    const { helper, removeHelper } = context;
16766    return processFor(node, dir, context, (forNode) => {
16767      const renderExp = createCallExpression(helper(RENDER_LIST), [
16768        forNode.source
16769      ]);
16770      const isTemplate = isTemplateNode(node);
16771      const memo = findDir(node, "memo");
16772      const keyProp = findProp(node, `key`, false, true);
16773      keyProp && keyProp.type === 7;
16774      let keyExp = keyProp && (keyProp.type === 6 ? keyProp.value ? createSimpleExpression(keyProp.value.content, true) : void 0 : keyProp.exp);
16775      const keyProperty = keyProp && keyExp ? createObjectProperty(`key`, keyExp) : null;
16776      const isStableFragment = forNode.source.type === 4 && forNode.source.constType > 0;
16777      const fragmentFlag = isStableFragment ? 64 : keyProp ? 128 : 256;
16778      forNode.codegenNode = createVNodeCall(
16779        context,
16780        helper(FRAGMENT),
16781        void 0,
16782        renderExp,
16783        fragmentFlag,
16784        void 0,
16785        void 0,
16786        true,
16787        !isStableFragment,
16788        false,
16789        node.loc
16790      );
16791      return () => {
16792        let childBlock;
16793        const { children } = forNode;
16794        if (false) // removed by dead control flow
16795{}
16796        const needFragmentWrapper = children.length !== 1 || children[0].type !== 1;
16797        const slotOutlet = isSlotOutlet(node) ? node : isTemplate && node.children.length === 1 && isSlotOutlet(node.children[0]) ? node.children[0] : null;
16798        if (slotOutlet) {
16799          childBlock = slotOutlet.codegenNode;
16800          if (isTemplate && keyProperty) {
16801            injectProp(childBlock, keyProperty, context);
16802          }
16803        } else if (needFragmentWrapper) {
16804          childBlock = createVNodeCall(
16805            context,
16806            helper(FRAGMENT),
16807            keyProperty ? createObjectExpression([keyProperty]) : void 0,
16808            node.children,
16809            64,
16810            void 0,
16811            void 0,
16812            true,
16813            void 0,
16814            false
16815          );
16816        } else {
16817          childBlock = children[0].codegenNode;
16818          if (isTemplate && keyProperty) {
16819            injectProp(childBlock, keyProperty, context);
16820          }
16821          if (childBlock.isBlock !== !isStableFragment) {
16822            if (childBlock.isBlock) {
16823              removeHelper(OPEN_BLOCK);
16824              removeHelper(
16825                getVNodeBlockHelper(context.inSSR, childBlock.isComponent)
16826              );
16827            } else {
16828              removeHelper(
16829                getVNodeHelper(context.inSSR, childBlock.isComponent)
16830              );
16831            }
16832          }
16833          childBlock.isBlock = !isStableFragment;
16834          if (childBlock.isBlock) {
16835            helper(OPEN_BLOCK);
16836            helper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));
16837          } else {
16838            helper(getVNodeHelper(context.inSSR, childBlock.isComponent));
16839          }
16840        }
16841        if (memo) {
16842          const loop = createFunctionExpression(
16843            createForLoopParams(forNode.parseResult, [
16844              createSimpleExpression(`_cached`)
16845            ])
16846          );
16847          loop.body = createBlockStatement([
16848            createCompoundExpression([`const _memo = (`, memo.exp, `)`]),
16849            createCompoundExpression([
16850              `if (_cached`,
16851              ...keyExp ? [` && _cached.key === `, keyExp] : [],
16852              ` && ${context.helperString(
16853                IS_MEMO_SAME
16854              )}(_cached, _memo)) return _cached`
16855            ]),
16856            createCompoundExpression([`const _item = `, childBlock]),
16857            createSimpleExpression(`_item.memo = _memo`),
16858            createSimpleExpression(`return _item`)
16859          ]);
16860          renderExp.arguments.push(
16861            loop,
16862            createSimpleExpression(`_cache`),
16863            createSimpleExpression(String(context.cached.length))
16864          );
16865          context.cached.push(null);
16866        } else {
16867          renderExp.arguments.push(
16868            createFunctionExpression(
16869              createForLoopParams(forNode.parseResult),
16870              childBlock,
16871              true
16872            )
16873          );
16874        }
16875      };
16876    });
16877  }
16878);
16879function processFor(node, dir, context, processCodegen) {
16880  if (!dir.exp) {
16881    context.onError(
16882      createCompilerError(31, dir.loc)
16883    );
16884    return;
16885  }
16886  const parseResult = dir.forParseResult;
16887  if (!parseResult) {
16888    context.onError(
16889      createCompilerError(32, dir.loc)
16890    );
16891    return;
16892  }
16893  finalizeForParseResult(parseResult, context);
16894  const { addIdentifiers, removeIdentifiers, scopes } = context;
16895  const { source, value, key, index } = parseResult;
16896  const forNode = {
16897    type: 11,
16898    loc: dir.loc,
16899    source,
16900    valueAlias: value,
16901    keyAlias: key,
16902    objectIndexAlias: index,
16903    parseResult,
16904    children: isTemplateNode(node) ? node.children : [node]
16905  };
16906  context.replaceNode(forNode);
16907  scopes.vFor++;
16908  const onExit = processCodegen && processCodegen(forNode);
16909  return () => {
16910    scopes.vFor--;
16911    if (onExit) onExit();
16912  };
16913}
16914function finalizeForParseResult(result, context) {
16915  if (result.finalized) return;
16916  if (false) // removed by dead control flow
16917{}
16918  result.finalized = true;
16919}
16920function createForLoopParams({ value, key, index }, memoArgs = []) {
16921  return createParamsList([value, key, index, ...memoArgs]);
16922}
16923function createParamsList(args) {
16924  let i = args.length;
16925  while (i--) {
16926    if (args[i]) break;
16927  }
16928  return args.slice(0, i + 1).map((arg, i2) => arg || createSimpleExpression(`_`.repeat(i2 + 1), false));
16929}
16930
16931const defaultFallback = createSimpleExpression(`undefined`, false);
16932const trackSlotScopes = (node, context) => {
16933  if (node.type === 1 && (node.tagType === 1 || node.tagType === 3)) {
16934    const vSlot = findDir(node, "slot");
16935    if (vSlot) {
16936      vSlot.exp;
16937      context.scopes.vSlot++;
16938      return () => {
16939        context.scopes.vSlot--;
16940      };
16941    }
16942  }
16943};
16944const trackVForSlotScopes = (node, context) => {
16945  let vFor;
16946  if (isTemplateNode(node) && node.props.some(isVSlot) && (vFor = findDir(node, "for"))) {
16947    const result = vFor.forParseResult;
16948    if (result) {
16949      finalizeForParseResult(result, context);
16950      const { value, key, index } = result;
16951      const { addIdentifiers, removeIdentifiers } = context;
16952      value && addIdentifiers(value);
16953      key && addIdentifiers(key);
16954      index && addIdentifiers(index);
16955      return () => {
16956        value && removeIdentifiers(value);
16957        key && removeIdentifiers(key);
16958        index && removeIdentifiers(index);
16959      };
16960    }
16961  }
16962};
16963const buildClientSlotFn = (props, _vForExp, children, loc) => createFunctionExpression(
16964  props,
16965  children,
16966  false,
16967  true,
16968  children.length ? children[0].loc : loc
16969);
16970function buildSlots(node, context, buildSlotFn = buildClientSlotFn) {
16971  context.helper(WITH_CTX);
16972  const { children, loc } = node;
16973  const slotsProperties = [];
16974  const dynamicSlots = [];
16975  let hasDynamicSlots = context.scopes.vSlot > 0 || context.scopes.vFor > 0;
16976  const onComponentSlot = findDir(node, "slot", true);
16977  if (onComponentSlot) {
16978    const { arg, exp } = onComponentSlot;
16979    if (arg && !isStaticExp(arg)) {
16980      hasDynamicSlots = true;
16981    }
16982    slotsProperties.push(
16983      createObjectProperty(
16984        arg || createSimpleExpression("default", true),
16985        buildSlotFn(exp, void 0, children, loc)
16986      )
16987    );
16988  }
16989  let hasTemplateSlots = false;
vendor: 4,108 bytes, lines 16990-17122
16990  let hasNamedDefaultSlot = false;
16991  const implicitDefaultChildren = [];
16992  const seenSlotNames = /* @__PURE__ */ new Set();
16993  let conditionalBranchIndex = 0;
16994  for (let i = 0; i < children.length; i++) {
16995    const slotElement = children[i];
16996    let slotDir;
16997    if (!isTemplateNode(slotElement) || !(slotDir = findDir(slotElement, "slot", true))) {
16998      if (slotElement.type !== 3) {
16999        implicitDefaultChildren.push(slotElement);
17000      }
17001      continue;
17002    }
17003    if (onComponentSlot) {
17004      context.onError(
17005        createCompilerError(37, slotDir.loc)
17006      );
17007      break;
17008    }
17009    hasTemplateSlots = true;
17010    const { children: slotChildren, loc: slotLoc } = slotElement;
17011    const {
17012      arg: slotName = createSimpleExpression(`default`, true),
17013      exp: slotProps,
17014      loc: dirLoc
17015    } = slotDir;
17016    let staticSlotName;
17017    if (isStaticExp(slotName)) {
17018      staticSlotName = slotName ? slotName.content : `default`;
17019    } else {
17020      hasDynamicSlots = true;
17021    }
17022    const vFor = findDir(slotElement, "for");
17023    const slotFunction = buildSlotFn(slotProps, vFor, slotChildren, slotLoc);
17024    let vIf;
17025    let vElse;
17026    if (vIf = findDir(slotElement, "if")) {
17027      hasDynamicSlots = true;
17028      dynamicSlots.push(
17029        createConditionalExpression(
17030          vIf.exp,
17031          buildDynamicSlot(slotName, slotFunction, conditionalBranchIndex++),
17032          defaultFallback
17033        )
17034      );
17035    } else if (vElse = findDir(
17036      slotElement,
17037      /^else(?:-if)?$/,
17038      true
17039      /* allowEmpty */
17040    )) {
17041      let j = i;
17042      let prev;
17043      while (j--) {
17044        prev = children[j];
17045        if (!compiler_core_esm_bundler_isCommentOrWhitespace(prev)) {
17046          break;
17047        }
17048      }
17049      if (prev && isTemplateNode(prev) && findDir(prev, /^(?:else-)?if$/)) {
17050        let conditional = dynamicSlots[dynamicSlots.length - 1];
17051        while (conditional.alternate.type === 19) {
17052          conditional = conditional.alternate;
17053        }
17054        conditional.alternate = vElse.exp ? createConditionalExpression(
17055          vElse.exp,
17056          buildDynamicSlot(
17057            slotName,
17058            slotFunction,
17059            conditionalBranchIndex++
17060          ),
17061          defaultFallback
17062        ) : buildDynamicSlot(slotName, slotFunction, conditionalBranchIndex++);
17063      } else {
17064        context.onError(
17065          createCompilerError(30, vElse.loc)
17066        );
17067      }
17068    } else if (vFor) {
17069      hasDynamicSlots = true;
17070      const parseResult = vFor.forParseResult;
17071      if (parseResult) {
17072        finalizeForParseResult(parseResult, context);
17073        dynamicSlots.push(
17074          createCallExpression(context.helper(RENDER_LIST), [
17075            parseResult.source,
17076            createFunctionExpression(
17077              createForLoopParams(parseResult),
17078              buildDynamicSlot(slotName, slotFunction),
17079              true
17080            )
17081          ])
17082        );
17083      } else {
17084        context.onError(
17085          createCompilerError(
17086            32,
17087            vFor.loc
17088          )
17089        );
17090      }
17091    } else {
17092      if (staticSlotName) {
17093        if (seenSlotNames.has(staticSlotName)) {
17094          context.onError(
17095            createCompilerError(
17096              38,
17097              dirLoc
17098            )
17099          );
17100          continue;
17101        }
17102        seenSlotNames.add(staticSlotName);
17103        if (staticSlotName === "default") {
17104          hasNamedDefaultSlot = true;
17105        }
17106      }
17107      slotsProperties.push(createObjectProperty(slotName, slotFunction));
17108    }
17109  }
17110  if (!onComponentSlot) {
17111    const buildDefaultSlotProperty = (props, children2) => {
17112      const fn = buildSlotFn(props, void 0, children2, loc);
17113      if (context.compatConfig) {
17114        fn.isNonScopedSlot = true;
17115      }
17116      return createObjectProperty(`default`, fn);
17117    };
17118    if (!hasTemplateSlots) {
17119      slotsProperties.push(buildDefaultSlotProperty(void 0, children));
17120    } else if (implicitDefaultChildren.length && // #3766
17121    // with whitespace: 'preserve', whitespaces between slots will end up in
17122    // implicitDefaultChildren. Ignore if all implicit children are whitespace
vendor: 4,531 bytes, lines 17122-17260
17122s.
17123    !implicitDefaultChildren.every(isWhitespaceText)) {
17124      if (hasNamedDefaultSlot) {
17125        context.onError(
17126          createCompilerError(
17127            39,
17128            implicitDefaultChildren[0].loc
17129          )
17130        );
17131      } else {
17132        slotsProperties.push(
17133          buildDefaultSlotProperty(void 0, implicitDefaultChildren)
17134        );
17135      }
17136    }
17137  }
17138  const slotFlag = hasDynamicSlots ? 2 : hasForwardedSlots(node.children) ? 3 : 1;
17139  let slots = createObjectExpression(
17140    slotsProperties.concat(
17141      createObjectProperty(
17142        `_`,
17143        // 2 = compiled but dynamic = can skip normalization, but must run diff
17144        // 1 = compiled and static = can skip normalization AND diff as optimized
17145        createSimpleExpression(
17146          slotFlag + ( false ? 0 : ``),
17147          false
17148        )
17149      )
17150    ),
17151    loc
17152  );
17153  if (dynamicSlots.length) {
17154    slots = createCallExpression(context.helper(CREATE_SLOTS), [
17155      slots,
17156      createArrayExpression(dynamicSlots)
17157    ]);
17158  }
17159  return {
17160    slots,
17161    hasDynamicSlots
17162  };
17163}
17164function buildDynamicSlot(name, fn, index) {
17165  const props = [
17166    createObjectProperty(`name`, name),
17167    createObjectProperty(`fn`, fn)
17168  ];
17169  if (index != null) {
17170    props.push(
17171      createObjectProperty(`key`, createSimpleExpression(String(index), true))
17172    );
17173  }
17174  return createObjectExpression(props);
17175}
17176function hasForwardedSlots(children) {
17177  for (let i = 0; i < children.length; i++) {
17178    const child = children[i];
17179    switch (child.type) {
17180      case 1:
17181        if (child.tagType === 2 || hasForwardedSlots(child.children)) {
17182          return true;
17183        }
17184        break;
17185      case 9:
17186        if (hasForwardedSlots(child.branches)) return true;
17187        break;
17188      case 10:
17189      case 11:
17190        if (hasForwardedSlots(child.children)) return true;
17191        break;
17192    }
17193  }
17194  return false;
17195}
17196
17197const directiveImportMap = /* @__PURE__ */ new WeakMap();
17198const transformElement = (node, context) => {
17199  return function postTransformElement() {
17200    node = context.currentNode;
17201    if (!(node.type === 1 && (node.tagType === 0 || node.tagType === 1))) {
17202      return;
17203    }
17204    const { tag, props } = node;
17205    const isComponent = node.tagType === 1;
17206    let vnodeTag = isComponent ? resolveComponentType(node, context) : `"${tag}"`;
17207    const isDynamicComponent = shared_esm_bundler_isObject(vnodeTag) && vnodeTag.callee === RESOLVE_DYNAMIC_COMPONENT;
17208    let vnodeProps;
17209    let vnodeChildren;
17210    let patchFlag = 0;
17211    let vnodeDynamicProps;
17212    let dynamicPropNames;
17213    let vnodeDirectives;
17214    let shouldUseBlock = (
17215      // dynamic component may resolve to plain elements
17216      isDynamicComponent || vnodeTag === TELEPORT || vnodeTag === SUSPENSE || !isComponent && // <svg> and <foreignObject> must be forced into blocks so that block
17217      // updates inside get proper isSVG flag at runtime. (#639, #643)
17218      // This is technically web-specific, but splitting the logic out of core
17219      // leads to too much unnecessary complexity.
17220      (tag === "svg" || tag === "foreignObject" || tag === "math")
17221    );
17222    if (props.length > 0) {
17223      const propsBuildResult = buildProps(
17224        node,
17225        context,
17226        void 0,
17227        isComponent,
17228        isDynamicComponent
17229      );
17230      vnodeProps = propsBuildResult.props;
17231      patchFlag = propsBuildResult.patchFlag;
17232      dynamicPropNames = propsBuildResult.dynamicPropNames;
17233      const directives = propsBuildResult.directives;
17234      vnodeDirectives = directives && directives.length ? createArrayExpression(
17235        directives.map((dir) => buildDirectiveArgs(dir, context))
17236      ) : void 0;
17237      if (propsBuildResult.shouldUseBlock) {
17238        shouldUseBlock = true;
17239      }
17240    }
17241    if (node.children.length > 0) {
17242      if (vnodeTag === KEEP_ALIVE) {
17243        shouldUseBlock = true;
17244        patchFlag |= 1024;
17245        if (false) // removed by dead control flow
17246{}
17247      }
17248      const shouldBuildAsSlots = isComponent && // Teleport is not a real component and has dedicated runtime handling
17249      vnodeTag !== TELEPORT && // explained above.
17250      vnodeTag !== KEEP_ALIVE;
17251      if (shouldBuildAsSlots) {
17252        const { slots, hasDynamicSlots } = buildSlots(node, context);
17253        vnodeChildren = slots;
17254        if (hasDynamicSlots) {
17255          patchFlag |= 1024;
17256        }
17257      } else if (node.children.length === 1 && vnodeTag !== TELEPORT) {
17258        const child = node.children[0];
17259        const type = child.type;
17260        const hasDynamicTextChild = type === 5 || type === 8;
vendor: 6,756 bytes, lines 17261-17486
17261        if (hasDynamicTextChild && getConstantType(child, context) === 0) {
17262          patchFlag |= 1;
17263        }
17264        if (hasDynamicTextChild || type === 2) {
17265          vnodeChildren = child;
17266        } else {
17267          vnodeChildren = node.children;
17268        }
17269      } else {
17270        vnodeChildren = node.children;
17271      }
17272    }
17273    if (dynamicPropNames && dynamicPropNames.length) {
17274      vnodeDynamicProps = stringifyDynamicPropNames(dynamicPropNames);
17275    }
17276    node.codegenNode = createVNodeCall(
17277      context,
17278      vnodeTag,
17279      vnodeProps,
17280      vnodeChildren,
17281      patchFlag === 0 ? void 0 : patchFlag,
17282      vnodeDynamicProps,
17283      vnodeDirectives,
17284      !!shouldUseBlock,
17285      false,
17286      isComponent,
17287      node.loc
17288    );
17289  };
17290};
17291function resolveComponentType(node, context, ssr = false) {
17292  let { tag } = node;
17293  const isExplicitDynamic = isComponentTag(tag);
17294  const isProp = findProp(
17295    node,
17296    "is",
17297    false,
17298    true
17299    /* allow empty */
17300  );
17301  if (isProp) {
17302    if (isExplicitDynamic || isCompatEnabled(
17303      "COMPILER_IS_ON_ELEMENT",
17304      context
17305    )) {
17306      let exp;
17307      if (isProp.type === 6) {
17308        exp = isProp.value && createSimpleExpression(isProp.value.content, true);
17309      } else {
17310        exp = isProp.exp;
17311        if (!exp) {
17312          exp = createSimpleExpression(`is`, false, isProp.arg.loc);
17313        }
17314      }
17315      if (exp) {
17316        return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [
17317          exp
17318        ]);
17319      }
17320    } else if (isProp.type === 6 && isProp.value.content.startsWith("vue:")) {
17321      tag = isProp.value.content.slice(4);
17322    }
17323  }
17324  const builtIn = isCoreComponent(tag) || context.isBuiltInComponent(tag);
17325  if (builtIn) {
17326    if (!ssr) context.helper(builtIn);
17327    return builtIn;
17328  }
17329  context.helper(RESOLVE_COMPONENT);
17330  context.components.add(tag);
17331  return toValidAssetId(tag, `component`);
17332}
17333function buildProps(node, context, props = node.props, isComponent, isDynamicComponent, ssr = false) {
17334  const { tag, loc: elementLoc, children } = node;
17335  let properties = [];
17336  const mergeArgs = [];
17337  const runtimeDirectives = [];
17338  const hasChildren = children.length > 0;
17339  let shouldUseBlock = false;
17340  let patchFlag = 0;
17341  let hasRef = false;
17342  let hasClassBinding = false;
17343  let hasStyleBinding = false;
17344  let hasHydrationEventBinding = false;
17345  let hasDynamicKeys = false;
17346  let hasVnodeHook = false;
17347  const dynamicPropNames = [];
17348  const pushMergeArg = (arg) => {
17349    if (properties.length) {
17350      mergeArgs.push(
17351        createObjectExpression(dedupeProperties(properties), elementLoc)
17352      );
17353      properties = [];
17354    }
17355    if (arg) mergeArgs.push(arg);
17356  };
17357  const pushRefVForMarker = () => {
17358    if (context.scopes.vFor > 0) {
17359      properties.push(
17360        createObjectProperty(
17361          createSimpleExpression("ref_for", true),
17362          createSimpleExpression("true")
17363        )
17364      );
17365    }
17366  };
17367  const analyzePatchFlag = ({ key, value }) => {
17368    if (isStaticExp(key)) {
17369      const name = key.content;
17370      const isEventHandler = isOn(name);
17371      if (isEventHandler && (!isComponent || isDynamicComponent) && // omit the flag for click handlers because hydration gives click
17372      // dedicated fast path.
17373      name.toLowerCase() !== "onclick" && // omit v-model handlers
17374      name !== "onUpdate:modelValue" && // omit onVnodeXXX hooks
17375      !isReservedProp(name)) {
17376        hasHydrationEventBinding = true;
17377      }
17378      if (isEventHandler && isReservedProp(name)) {
17379        hasVnodeHook = true;
17380      }
17381      if (isEventHandler && value.type === 14) {
17382        value = value.arguments[0];
17383      }
17384      if (value.type === 20 || (value.type === 4 || value.type === 8) && getConstantType(value, context) > 0) {
17385        return;
17386      }
17387      if (name === "ref") {
17388        hasRef = true;
17389      } else if (name === "class") {
17390        hasClassBinding = true;
17391      } else if (name === "style") {
17392        hasStyleBinding = true;
17393      } else if (name !== "key" && !dynamicPropNames.includes(name)) {
17394        dynamicPropNames.push(name);
17395      }
17396      if (isComponent && (name === "class" || name === "style") && !dynamicPropNames.includes(name)) {
17397        dynamicPropNames.push(name);
17398      }
17399    } else {
17400      hasDynamicKeys = true;
17401    }
17402  };
17403  for (let i = 0; i < props.length; i++) {
17404    const prop = props[i];
17405    if (prop.type === 6) {
17406      const { loc, name, nameLoc, value } = prop;
17407      let isStatic = true;
17408      if (name === "ref") {
17409        hasRef = true;
17410        pushRefVForMarker();
17411      }
17412      if (name === "is" && (isComponentTag(tag) || value && value.content.startsWith("vue:") || isCompatEnabled(
17413        "COMPILER_IS_ON_ELEMENT",
17414        context
17415      ))) {
17416        continue;
17417      }
17418      properties.push(
17419        createObjectProperty(
17420          createSimpleExpression(name, true, nameLoc),
17421          createSimpleExpression(
17422            value ? value.content : "",
17423            isStatic,
17424            value ? value.loc : loc
17425          )
17426        )
17427      );
17428    } else {
17429      const { name, arg, exp, loc, modifiers } = prop;
17430      const isVBind = name === "bind";
17431      const isVOn = name === "on";
17432      if (name === "slot") {
17433        if (!isComponent) {
17434          context.onError(
17435            createCompilerError(40, loc)
17436          );
17437        }
17438        continue;
17439      }
17440      if (name === "once" || name === "memo") {
17441        continue;
17442      }
17443      if (name === "is" || isVBind && isStaticArgOf(arg, "is") && (isComponentTag(tag) || isCompatEnabled(
17444        "COMPILER_IS_ON_ELEMENT",
17445        context
17446      ))) {
17447        continue;
17448      }
17449      if (isVOn && ssr) {
17450        continue;
17451      }
17452      if (
17453        // #938: elements with dynamic keys should be forced into blocks
17454        isVBind && isStaticArgOf(arg, "key") || // inline before-update hooks need to force block so that it is invoked
17455        // before children
17456        isVOn && hasChildren && isStaticArgOf(arg, "vue:before-update")
17457      ) {
17458        shouldUseBlock = true;
17459      }
17460      if (isVBind && isStaticArgOf(arg, "ref")) {
17461        pushRefVForMarker();
17462      }
17463      if (!arg && (isVBind || isVOn)) {
17464        hasDynamicKeys = true;
17465        if (exp) {
17466          if (isVBind) {
17467            {
17468              pushMergeArg();
17469              if (false) // removed by dead control flow
17470{}
17471              if (isCompatEnabled(
17472                "COMPILER_V_BIND_OBJECT_ORDER",
17473                context
17474              )) {
17475                mergeArgs.unshift(exp);
17476                continue;
17477              }
17478            }
17479            pushRefVForMarker();
17480            pushMergeArg();
17481            mergeArgs.push(exp);
17482          } else {
17483            pushMergeArg({
17484              type: 14,
17485              loc,
17486              callee: context.helper(TO_HANDLERS),
vendor: 12,635 bytes, lines 17487-17928
17487              arguments: isComponent ? [exp] : [exp, `true`]
17488            });
17489          }
17490        } else {
17491          context.onError(
17492            createCompilerError(
17493              isVBind ? 34 : 35,
17494              loc
17495            )
17496          );
17497        }
17498        continue;
17499      }
17500      if (isVBind && modifiers.some((mod) => mod.content === "prop")) {
17501        patchFlag |= 32;
17502      }
17503      const directiveTransform = context.directiveTransforms[name];
17504      if (directiveTransform) {
17505        const { props: props2, needRuntime } = directiveTransform(prop, node, context);
17506        !ssr && props2.forEach(analyzePatchFlag);
17507        if (isVOn && arg && !isStaticExp(arg)) {
17508          pushMergeArg(createObjectExpression(props2, elementLoc));
17509        } else {
17510          properties.push(...props2);
17511        }
17512        if (needRuntime) {
17513          runtimeDirectives.push(prop);
17514          if (isSymbol(needRuntime)) {
17515            directiveImportMap.set(prop, needRuntime);
17516          }
17517        }
17518      } else if (!shared_esm_bundler_isBuiltInDirective(name)) {
17519        runtimeDirectives.push(prop);
17520        if (hasChildren) {
17521          shouldUseBlock = true;
17522        }
17523      }
17524    }
17525  }
17526  let propsExpression = void 0;
17527  if (mergeArgs.length) {
17528    pushMergeArg();
17529    if (mergeArgs.length > 1) {
17530      propsExpression = createCallExpression(
17531        context.helper(MERGE_PROPS),
17532        mergeArgs,
17533        elementLoc
17534      );
17535    } else {
17536      propsExpression = mergeArgs[0];
17537    }
17538  } else if (properties.length) {
17539    propsExpression = createObjectExpression(
17540      dedupeProperties(properties),
17541      elementLoc
17542    );
17543  }
17544  if (hasDynamicKeys) {
17545    patchFlag |= 16;
17546  } else {
17547    if (hasClassBinding && !isComponent) {
17548      patchFlag |= 2;
17549    }
17550    if (hasStyleBinding && !isComponent) {
17551      patchFlag |= 4;
17552    }
17553    if (dynamicPropNames.length) {
17554      patchFlag |= 8;
17555    }
17556    if (hasHydrationEventBinding) {
17557      patchFlag |= 32;
17558    }
17559  }
17560  if (!shouldUseBlock && (patchFlag === 0 || patchFlag === 32) && (hasRef || hasVnodeHook || runtimeDirectives.length > 0)) {
17561    patchFlag |= 512;
17562  }
17563  if (!context.inSSR && propsExpression) {
17564    switch (propsExpression.type) {
17565      case 15:
17566        let classKeyIndex = -1;
17567        let styleKeyIndex = -1;
17568        let hasDynamicKey = false;
17569        for (let i = 0; i < propsExpression.properties.length; i++) {
17570          const key = propsExpression.properties[i].key;
17571          if (isStaticExp(key)) {
17572            if (key.content === "class") {
17573              classKeyIndex = i;
17574            } else if (key.content === "style") {
17575              styleKeyIndex = i;
17576            }
17577          } else if (!key.isHandlerKey) {
17578            hasDynamicKey = true;
17579          }
17580        }
17581        const classProp = propsExpression.properties[classKeyIndex];
17582        const styleProp = propsExpression.properties[styleKeyIndex];
17583        if (!hasDynamicKey) {
17584          if (classProp && !isStaticExp(classProp.value)) {
17585            classProp.value = createCallExpression(
17586              context.helper(NORMALIZE_CLASS),
17587              [classProp.value]
17588            );
17589          }
17590          if (styleProp && // the static style is compiled into an object,
17591          // so use `hasStyleBinding` to ensure that it is a dynamic style binding
17592          (hasStyleBinding || styleProp.value.type === 4 && styleProp.value.content.trim()[0] === `[` || // v-bind:style and style both exist,
17593          // v-bind:style with static literal object
17594          styleProp.value.type === 17)) {
17595            styleProp.value = createCallExpression(
17596              context.helper(NORMALIZE_STYLE),
17597              [styleProp.value]
17598            );
17599          }
17600        } else {
17601          propsExpression = createCallExpression(
17602            context.helper(NORMALIZE_PROPS),
17603            [propsExpression]
17604          );
17605        }
17606        break;
17607      case 14:
17608        break;
17609      default:
17610        propsExpression = createCallExpression(
17611          context.helper(NORMALIZE_PROPS),
17612          [
17613            createCallExpression(context.helper(GUARD_REACTIVE_PROPS), [
17614              propsExpression
17615            ])
17616          ]
17617        );
17618        break;
17619    }
17620  }
17621  return {
17622    props: propsExpression,
17623    directives: runtimeDirectives,
17624    patchFlag,
17625    dynamicPropNames,
17626    shouldUseBlock
17627  };
17628}
17629function dedupeProperties(properties) {
17630  const knownProps = /* @__PURE__ */ new Map();
17631  const deduped = [];
17632  for (let i = 0; i < properties.length; i++) {
17633    const prop = properties[i];
17634    if (prop.key.type === 8 || !prop.key.isStatic) {
17635      deduped.push(prop);
17636      continue;
17637    }
17638    const name = prop.key.content;
17639    const existing = knownProps.get(name);
17640    if (existing) {
17641      if (name === "style" || name === "class" || isOn(name)) {
17642        compiler_core_esm_bundler_mergeAsArray(existing, prop);
17643      }
17644    } else {
17645      knownProps.set(name, prop);
17646      deduped.push(prop);
17647    }
17648  }
17649  return deduped;
17650}
17651function compiler_core_esm_bundler_mergeAsArray(existing, incoming) {
17652  if (existing.value.type === 17) {
17653    existing.value.elements.push(incoming.value);
17654  } else {
17655    existing.value = createArrayExpression(
17656      [existing.value, incoming.value],
17657      existing.loc
17658    );
17659  }
17660}
17661function buildDirectiveArgs(dir, context) {
17662  const dirArgs = [];
17663  const runtime = directiveImportMap.get(dir);
17664  if (runtime) {
17665    dirArgs.push(context.helperString(runtime));
17666  } else {
17667    {
17668      context.helper(RESOLVE_DIRECTIVE);
17669      context.directives.add(dir.name);
17670      dirArgs.push(toValidAssetId(dir.name, `directive`));
17671    }
17672  }
17673  const { loc } = dir;
17674  if (dir.exp) dirArgs.push(dir.exp);
17675  if (dir.arg) {
17676    if (!dir.exp) {
17677      dirArgs.push(`void 0`);
17678    }
17679    dirArgs.push(dir.arg);
17680  }
17681  if (Object.keys(dir.modifiers).length) {
17682    if (!dir.arg) {
17683      if (!dir.exp) {
17684        dirArgs.push(`void 0`);
17685      }
17686      dirArgs.push(`void 0`);
17687    }
17688    const trueExpression = createSimpleExpression(`true`, false, loc);
17689    dirArgs.push(
17690      createObjectExpression(
17691        dir.modifiers.map(
17692          (modifier) => createObjectProperty(modifier, trueExpression)
17693        ),
17694        loc
17695      )
17696    );
17697  }
17698  return createArrayExpression(dirArgs, dir.loc);
17699}
17700function stringifyDynamicPropNames(props) {
17701  let propsNamesString = `[`;
17702  for (let i = 0, l = props.length; i < l; i++) {
17703    propsNamesString += JSON.stringify(props[i]);
17704    if (i < l - 1) propsNamesString += ", ";
17705  }
17706  return propsNamesString + `]`;
17707}
17708function isComponentTag(tag) {
17709  return tag === "component" || tag === "Component";
17710}
17711
17712const transformSlotOutlet = (node, context) => {
17713  if (isSlotOutlet(node)) {
17714    const { children, loc } = node;
17715    const { slotName, slotProps } = processSlotOutlet(node, context);
17716    const slotArgs = [
17717      context.prefixIdentifiers ? `_ctx.$slots` : `$slots`,
17718      slotName,
17719      "{}",
17720      "undefined",
17721      "true"
17722    ];
17723    let expectedLen = 2;
17724    if (slotProps) {
17725      slotArgs[2] = slotProps;
17726      expectedLen = 3;
17727    }
17728    if (children.length) {
17729      slotArgs[3] = createFunctionExpression([], children, false, false, loc);
17730      expectedLen = 4;
17731    }
17732    if (context.scopeId && !context.slotted) {
17733      expectedLen = 5;
17734    }
17735    slotArgs.splice(expectedLen);
17736    node.codegenNode = createCallExpression(
17737      context.helper(RENDER_SLOT),
17738      slotArgs,
17739      loc
17740    );
17741  }
17742};
17743function processSlotOutlet(node, context) {
17744  let slotName = `"default"`;
17745  let slotProps = void 0;
17746  const nonNameProps = [];
17747  for (let i = 0; i < node.props.length; i++) {
17748    const p = node.props[i];
17749    if (p.type === 6) {
17750      if (p.value) {
17751        if (p.name === "name") {
17752          slotName = JSON.stringify(p.value.content);
17753        } else {
17754          p.name = shared_esm_bundler_camelize(p.name);
17755          nonNameProps.push(p);
17756        }
17757      }
17758    } else {
17759      if (p.name === "bind" && isStaticArgOf(p.arg, "name")) {
17760        if (p.exp) {
17761          slotName = p.exp;
17762        } else if (p.arg && p.arg.type === 4) {
17763          const name = shared_esm_bundler_camelize(p.arg.content);
17764          slotName = p.exp = createSimpleExpression(name, false, p.arg.loc);
17765        }
17766      } else {
17767        if (p.name === "bind" && p.arg && isStaticExp(p.arg)) {
17768          p.arg.content = shared_esm_bundler_camelize(p.arg.content);
17769        }
17770        nonNameProps.push(p);
17771      }
17772    }
17773  }
17774  if (nonNameProps.length > 0) {
17775    const { props, directives } = buildProps(
17776      node,
17777      context,
17778      nonNameProps,
17779      false,
17780      false
17781    );
17782    slotProps = props;
17783    if (directives.length) {
17784      context.onError(
17785        createCompilerError(
17786          36,
17787          directives[0].loc
17788        )
17789      );
17790    }
17791  }
17792  return {
17793    slotName,
17794    slotProps
17795  };
17796}
17797
17798const transformOn = (dir, node, context, augmentor) => {
17799  const { loc, modifiers, arg } = dir;
17800  if (!dir.exp && !modifiers.length) {
17801    context.onError(createCompilerError(35, loc));
17802  }
17803  let eventName;
17804  if (arg.type === 4) {
17805    if (arg.isStatic) {
17806      let rawName = arg.content;
17807      if (false) // removed by dead control flow
17808{}
17809      if (rawName.startsWith("vue:")) {
17810        rawName = `vnode-${rawName.slice(4)}`;
17811      }
17812      const eventString = node.tagType !== 0 || rawName.startsWith("vnode") || !/[A-Z]/.test(rawName) ? (
17813        // for non-element and vnode lifecycle event listeners, auto convert
17814        // it to camelCase. See issue #2249
17815        toHandlerKey(shared_esm_bundler_camelize(rawName))
17816      ) : (
17817        // preserve case for plain element listeners that have uppercase
17818        // letters, as these may be custom elements' custom events
17819        `on:${rawName}`
17820      );
17821      eventName = createSimpleExpression(eventString, true, arg.loc);
17822    } else {
17823      eventName = createCompoundExpression([
17824        `${context.helperString(TO_HANDLER_KEY)}(`,
17825        arg,
17826        `)`
17827      ]);
17828    }
17829  } else {
17830    eventName = arg;
17831    eventName.children.unshift(`${context.helperString(TO_HANDLER_KEY)}(`);
17832    eventName.children.push(`)`);
17833  }
17834  let exp = dir.exp;
17835  if (exp && !exp.content.trim()) {
17836    exp = void 0;
17837  }
17838  let shouldCache = context.cacheHandlers && !exp && !context.inVOnce;
17839  if (exp) {
17840    const isMemberExp = isMemberExpression(exp);
17841    const isInlineStatement = !(isMemberExp || isFnExpression(exp));
17842    const hasMultipleStatements = exp.content.includes(`;`);
17843    if (false) // removed by dead control flow
17844{}
17845    if (isInlineStatement || shouldCache && isMemberExp) {
17846      exp = createCompoundExpression([
17847        `${isInlineStatement ? `$event` : `${``}(...args)`} => ${hasMultipleStatements ? `{` : `(`}`,
17848        exp,
17849        hasMultipleStatements ? `}` : `)`
17850      ]);
17851    }
17852  }
17853  let ret = {
17854    props: [
17855      createObjectProperty(
17856        eventName,
17857        exp || createSimpleExpression(`() => {}`, false, loc)
17858      )
17859    ]
17860  };
17861  if (augmentor) {
17862    ret = augmentor(ret);
17863  }
17864  if (shouldCache) {
17865    ret.props[0].value = context.cache(ret.props[0].value);
17866  }
17867  ret.props.forEach((p) => p.key.isHandlerKey = true);
17868  return ret;
17869};
17870
17871const transformBind = (dir, _node, context) => {
17872  const { modifiers, loc } = dir;
17873  const arg = dir.arg;
17874  let { exp } = dir;
17875  if (exp && exp.type === 4 && !exp.content.trim()) {
17876    {
17877      exp = void 0;
17878    }
17879  }
17880  if (arg.type !== 4) {
17881    arg.children.unshift(`(`);
17882    arg.children.push(`) || ""`);
17883  } else if (!arg.isStatic) {
17884    arg.content = arg.content ? `${arg.content} || ""` : `""`;
17885  }
17886  if (modifiers.some((mod) => mod.content === "camel")) {
17887    if (arg.type === 4) {
17888      if (arg.isStatic) {
17889        arg.content = shared_esm_bundler_camelize(arg.content);
17890      } else {
17891        arg.content = `${context.helperString(CAMELIZE)}(${arg.content})`;
17892      }
17893    } else {
17894      arg.children.unshift(`${context.helperString(CAMELIZE)}(`);
17895      arg.children.push(`)`);
17896    }
17897  }
17898  if (!context.inSSR) {
17899    if (modifiers.some((mod) => mod.content === "prop")) {
17900      injectPrefix(arg, ".");
17901    }
17902    if (modifiers.some((mod) => mod.content === "attr")) {
17903      injectPrefix(arg, "^");
17904    }
17905  }
17906  return {
17907    props: [createObjectProperty(arg, exp)]
17908  };
17909};
17910const injectPrefix = (arg, prefix) => {
17911  if (arg.type === 4) {
17912    if (arg.isStatic) {
17913      arg.content = prefix + arg.content;
17914    } else {
17915      arg.content = `\`${prefix}\${${arg.content}}\``;
17916    }
17917  } else {
17918    arg.children.unshift(`'${prefix}' + (`);
17919    arg.children.push(`)`);
17920  }
17921};
17922
17923const transformText = (node, context) => {
17924  if (node.type === 0 || node.type === 1 || node.type === 11 || node.type === 10) {
17925    return () => {
17926      const children = node.children;
17927      let currentContainer = void 0;
17928      let hasText = false;
vendor: 12,631 bytes, lines 17929-18359
17929      for (let i = 0; i < children.length; i++) {
17930        const child = children[i];
17931        if (isText$1(child)) {
17932          hasText = true;
17933          for (let j = i + 1; j < children.length; j++) {
17934            const next = children[j];
17935            if (isText$1(next)) {
17936              if (!currentContainer) {
17937                currentContainer = children[i] = createCompoundExpression(
17938                  [child],
17939                  child.loc
17940                );
17941              }
17942              currentContainer.children.push(` + `, next);
17943              children.splice(j, 1);
17944              j--;
17945            } else {
17946              currentContainer = void 0;
17947              break;
17948            }
17949          }
17950        }
17951      }
17952      if (!hasText || // if this is a plain element with a single text child, leave it
17953      // as-is since the runtime has dedicated fast path for this by directly
17954      // setting textContent of the element.
17955      // for component root it's always normalized anyway.
17956      children.length === 1 && (node.type === 0 || node.type === 1 && node.tagType === 0 && // #3756
17957      // custom directives can potentially add DOM elements arbitrarily,
17958      // we need to avoid setting textContent of the element at runtime
17959      // to avoid accidentally overwriting the DOM elements added
17960      // by the user through custom directives.
17961      !node.props.find(
17962        (p) => p.type === 7 && !context.directiveTransforms[p.name]
17963      ) && // in compat mode, <template> tags with no special directives
17964      // will be rendered as a fragment so its children must be
17965      // converted into vnodes.
17966      !(node.tag === "template"))) {
17967        return;
17968      }
17969      for (let i = 0; i < children.length; i++) {
17970        const child = children[i];
17971        if (isText$1(child) || child.type === 8) {
17972          const callArgs = [];
17973          if (child.type !== 2 || child.content !== " ") {
17974            callArgs.push(child);
17975          }
17976          if (!context.ssr && getConstantType(child, context) === 0) {
17977            callArgs.push(
17978              1 + ( false ? 0 : ``)
17979            );
17980          }
17981          children[i] = {
17982            type: 12,
17983            content: child,
17984            loc: child.loc,
17985            codegenNode: createCallExpression(
17986              context.helper(CREATE_TEXT),
17987              callArgs
17988            )
17989          };
17990        }
17991      }
17992    };
17993  }
17994};
17995
17996const seen$1 = /* @__PURE__ */ new WeakSet();
17997const transformOnce = (node, context) => {
17998  if (node.type === 1 && findDir(node, "once", true)) {
17999    if (seen$1.has(node) || context.inVOnce || context.inSSR) {
18000      return;
18001    }
18002    seen$1.add(node);
18003    context.inVOnce = true;
18004    context.helper(SET_BLOCK_TRACKING);
18005    return () => {
18006      context.inVOnce = false;
18007      const cur = context.currentNode;
18008      if (cur.codegenNode) {
18009        cur.codegenNode = context.cache(
18010          cur.codegenNode,
18011          true,
18012          true
18013        );
18014      }
18015    };
18016  }
18017};
18018
18019const transformModel = (dir, node, context) => {
18020  const { exp, arg } = dir;
18021  if (!exp) {
18022    context.onError(
18023      createCompilerError(41, dir.loc)
18024    );
18025    return createTransformProps();
18026  }
18027  const rawExp = exp.loc.source.trim();
18028  const expString = exp.type === 4 ? exp.content : rawExp;
18029  const bindingType = context.bindingMetadata[rawExp];
18030  if (bindingType === "props" || bindingType === "props-aliased") {
18031    context.onError(createCompilerError(44, exp.loc));
18032    return createTransformProps();
18033  }
18034  if (!expString.trim() || !isMemberExpression(exp) && true) {
18035    context.onError(
18036      createCompilerError(42, exp.loc)
18037    );
18038    return createTransformProps();
18039  }
18040  const propName = arg ? arg : createSimpleExpression("modelValue", true);
18041  const eventName = arg ? isStaticExp(arg) ? `onUpdate:${shared_esm_bundler_camelize(arg.content)}` : createCompoundExpression(['"onUpdate:" + ', arg]) : `onUpdate:modelValue`;
18042  let assignmentExp;
18043  const eventArg = context.isTS ? `($event: any)` : `$event`;
18044  {
18045    assignmentExp = createCompoundExpression([
18046      `${eventArg} => ((`,
18047      exp,
18048      `) = $event)`
18049    ]);
18050  }
18051  const props = [
18052    // modelValue: foo
18053    createObjectProperty(propName, dir.exp),
18054    // "onUpdate:modelValue": $event => (foo = $event)
18055    createObjectProperty(eventName, assignmentExp)
18056  ];
18057  if (dir.modifiers.length && node.tagType === 1) {
18058    const modifiers = dir.modifiers.map((m) => m.content).map((m) => (isSimpleIdentifier(m) ? m : JSON.stringify(m)) + `: true`).join(`, `);
18059    const modifiersKey = arg ? isStaticExp(arg) ? `${arg.content}Modifiers` : createCompoundExpression([arg, ' + "Modifiers"']) : `modelModifiers`;
18060    props.push(
18061      createObjectProperty(
18062        modifiersKey,
18063        createSimpleExpression(
18064          `{ ${modifiers} }`,
18065          false,
18066          dir.loc,
18067          2
18068        )
18069      )
18070    );
18071  }
18072  return createTransformProps(props);
18073};
18074function createTransformProps(props = []) {
18075  return { props };
18076}
18077
18078const validDivisionCharRE = /[\w).+\-_$\]]/;
18079const transformFilter = (node, context) => {
18080  if (!isCompatEnabled("COMPILER_FILTERS", context)) {
18081    return;
18082  }
18083  if (node.type === 5) {
18084    rewriteFilter(node.content, context);
18085  } else if (node.type === 1) {
18086    node.props.forEach((prop) => {
18087      if (prop.type === 7 && prop.name !== "for" && prop.exp) {
18088        rewriteFilter(prop.exp, context);
18089      }
18090    });
18091  }
18092};
18093function rewriteFilter(node, context) {
18094  if (node.type === 4) {
18095    parseFilter(node, context);
18096  } else {
18097    for (let i = 0; i < node.children.length; i++) {
18098      const child = node.children[i];
18099      if (typeof child !== "object") continue;
18100      if (child.type === 4) {
18101        parseFilter(child, context);
18102      } else if (child.type === 8) {
18103        rewriteFilter(node, context);
18104      } else if (child.type === 5) {
18105        rewriteFilter(child.content, context);
18106      }
18107    }
18108  }
18109}
18110function parseFilter(node, context) {
18111  const exp = node.content;
18112  let inSingle = false;
18113  let inDouble = false;
18114  let inTemplateString = false;
18115  let inRegex = false;
18116  let curly = 0;
18117  let square = 0;
18118  let paren = 0;
18119  let lastFilterIndex = 0;
18120  let c, prev, i, expression, filters = [];
18121  for (i = 0; i < exp.length; i++) {
18122    prev = c;
18123    c = exp.charCodeAt(i);
18124    if (inSingle) {
18125      if (c === 39 && prev !== 92) inSingle = false;
18126    } else if (inDouble) {
18127      if (c === 34 && prev !== 92) inDouble = false;
18128    } else if (inTemplateString) {
18129      if (c === 96 && prev !== 92) inTemplateString = false;
18130    } else if (inRegex) {
18131      if (c === 47 && prev !== 92) inRegex = false;
18132    } else if (c === 124 && // pipe
18133    exp.charCodeAt(i + 1) !== 124 && exp.charCodeAt(i - 1) !== 124 && !curly && !square && !paren) {
18134      if (expression === void 0) {
18135        lastFilterIndex = i + 1;
18136        expression = exp.slice(0, i).trim();
18137      } else {
18138        pushFilter();
18139      }
18140    } else {
18141      switch (c) {
18142        case 34:
18143          inDouble = true;
18144          break;
18145        // "
18146        case 39:
18147          inSingle = true;
18148          break;
18149        // '
18150        case 96:
18151          inTemplateString = true;
18152          break;
18153        // `
18154        case 40:
18155          paren++;
18156          break;
18157        // (
18158        case 41:
18159          paren--;
18160          break;
18161        // )
18162        case 91:
18163          square++;
18164          break;
18165        // [
18166        case 93:
18167          square--;
18168          break;
18169        // ]
18170        case 123:
18171          curly++;
18172          break;
18173        // {
18174        case 125:
18175          curly--;
18176          break;
18177      }
18178      if (c === 47) {
18179        let j = i - 1;
18180        let p;
18181        for (; j >= 0; j--) {
18182          p = exp.charAt(j);
18183          if (p !== " ") break;
18184        }
18185        if (!p || !validDivisionCharRE.test(p)) {
18186          inRegex = true;
18187        }
18188      }
18189    }
18190  }
18191  if (expression === void 0) {
18192    expression = exp.slice(0, i).trim();
18193  } else if (lastFilterIndex !== 0) {
18194    pushFilter();
18195  }
18196  function pushFilter() {
18197    filters.push(exp.slice(lastFilterIndex, i).trim());
18198    lastFilterIndex = i + 1;
18199  }
18200  if (filters.length) {
18201     false && 0;
18202    for (i = 0; i < filters.length; i++) {
18203      expression = wrapFilter(expression, filters[i], context);
18204    }
18205    node.content = expression;
18206    node.ast = void 0;
18207  }
18208}
18209function wrapFilter(exp, filter, context) {
18210  context.helper(RESOLVE_FILTER);
18211  const i = filter.indexOf("(");
18212  if (i < 0) {
18213    context.filters.add(filter);
18214    return `${toValidAssetId(filter, "filter")}(${exp})`;
18215  } else {
18216    const name = filter.slice(0, i);
18217    const args = filter.slice(i + 1);
18218    context.filters.add(name);
18219    return `${toValidAssetId(name, "filter")}(${exp}${args !== ")" ? "," + args : args}`;
18220  }
18221}
18222
18223const seen = /* @__PURE__ */ new WeakSet();
18224const transformMemo = (node, context) => {
18225  if (node.type === 1) {
18226    const dir = findDir(node, "memo");
18227    if (!dir || seen.has(node) || context.inSSR) {
18228      return;
18229    }
18230    seen.add(node);
18231    return () => {
18232      const codegenNode = node.codegenNode || context.currentNode.codegenNode;
18233      if (codegenNode && codegenNode.type === 13) {
18234        if (node.tagType !== 1) {
18235          convertToBlock(codegenNode, context);
18236        }
18237        node.codegenNode = createCallExpression(context.helper(WITH_MEMO), [
18238          dir.exp,
18239          createFunctionExpression(void 0, codegenNode),
18240          `_cache`,
18241          String(context.cached.length)
18242        ]);
18243        context.cached.push(null);
18244      }
18245    };
18246  }
18247};
18248
18249const transformVBindShorthand = (node, context) => {
18250  if (node.type === 1) {
18251    for (const prop of node.props) {
18252      if (prop.type === 7 && prop.name === "bind" && (!prop.exp || // #13930 :foo in in-DOM templates will be parsed into :foo="" by browser
18253      prop.exp.type === 4 && !prop.exp.content.trim()) && prop.arg) {
18254        const arg = prop.arg;
18255        if (arg.type !== 4 || !arg.isStatic) {
18256          context.onError(
18257            createCompilerError(
18258              52,
18259              arg.loc
18260            )
18261          );
18262          prop.exp = createSimpleExpression("", true, arg.loc);
18263        } else {
18264          const propName = shared_esm_bundler_camelize(arg.content);
18265          if (validFirstIdentCharRE.test(propName[0]) || // allow hyphen first char for https://github.com/vuejs/language-tools/pull/3424
18266          propName[0] === "-") {
18267            prop.exp = createSimpleExpression(propName, false, arg.loc);
18268          }
18269        }
18270      }
18271    }
18272  }
18273};
18274
18275function getBaseTransformPreset(prefixIdentifiers) {
18276  return [
18277    [
18278      transformVBindShorthand,
18279      transformOnce,
18280      transformIf,
18281      transformMemo,
18282      transformFor,
18283      ...[transformFilter] ,
18284      ... false ? 0 : [],
18285      transformSlotOutlet,
18286      transformElement,
18287      trackSlotScopes,
18288      transformText
18289    ],
18290    {
18291      on: transformOn,
18292      bind: transformBind,
18293      model: transformModel
18294    }
18295  ];
18296}
18297function baseCompile(source, options = {}) {
18298  const onError = options.onError || defaultOnError;
18299  const isModuleMode = options.mode === "module";
18300  {
18301    if (options.prefixIdentifiers === true) {
18302      onError(createCompilerError(47));
18303    } else if (isModuleMode) {
18304      onError(createCompilerError(48));
18305    }
18306  }
18307  const prefixIdentifiers = false;
18308  if (options.cacheHandlers) {
18309    onError(createCompilerError(49));
18310  }
18311  if (options.scopeId && !isModuleMode) {
18312    onError(createCompilerError(50));
18313  }
18314  const resolvedOptions = shared_esm_bundler_extend({}, options, {
18315    prefixIdentifiers
18316  });
18317  const ast = shared_esm_bundler_isString(source) ? compiler_core_esm_bundler_baseParse(source, resolvedOptions) : source;
18318  const [nodeTransforms, directiveTransforms] = getBaseTransformPreset();
18319  transform(
18320    ast,
18321    shared_esm_bundler_extend({}, resolvedOptions, {
18322      nodeTransforms: [
18323        ...nodeTransforms,
18324        ...options.nodeTransforms || []
18325        // user transforms
18326      ],
18327      directiveTransforms: shared_esm_bundler_extend(
18328        {},
18329        directiveTransforms,
18330        options.directiveTransforms || {}
18331        // user transforms
18332      )
18333    })
18334  );
18335  return generate(ast, resolvedOptions);
18336}
18337
18338const BindingTypes = {
18339  "DATA": "data",
18340  "PROPS": "props",
18341  "PROPS_ALIASED": "props-aliased",
18342  "SETUP_LET": "setup-let",
18343  "SETUP_CONST": "setup-const",
18344  "SETUP_REACTIVE_CONST": "setup-reactive-const",
18345  "SETUP_MAYBE_REF": "setup-maybe-ref",
18346  "SETUP_REF": "setup-ref",
18347  "OPTIONS": "options",
18348  "LITERAL_CONST": "literal-const"
18349};
18350
18351const noopDirectiveTransform = () => ({ props: [] });
18352
18353
18354
18355;// ./node_modules/@vue/compiler-dom/dist/compiler-dom.esm-bundler.js
18356/**
18357* @vue/compiler-dom v3.5.25
18358* (c) 2018-present Yuxi (Evan) You and Vue contributors
18359* @license MIT
18360**/
18361
18362
18363
18364
18365const V_MODEL_RADIO = Symbol( false ? 0 : ``);
18366const V_MODEL_CHECKBOX = Symbol(
18367   false ? 0 : ``
18368);
18369const V_MODEL_TEXT = Symbol( false ? 0 : ``);
18370const V_MODEL_SELECT = Symbol(
18371   false ? 0 : ``
18372);
18373const V_MODEL_DYNAMIC = Symbol(
18374   false ? 0 : ``
18375);
18376const V_ON_WITH_MODIFIERS = Symbol(
18377   false ? 0 : ``
18378);
18379const V_ON_WITH_KEYS = Symbol(
18380   false ? 0 : ``
18381);
18382const V_SHOW = Symbol( false ? 0 : ``);
18383const compiler_dom_esm_bundler_TRANSITION = Symbol( false ? 0 : ``);
18384const TRANSITION_GROUP = Symbol(
18385   false ? 0 : ``
18386);
18387registerRuntimeHelpers({
18388  [V_MODEL_RADIO]: `vModelRadio`,
18389  [V_MODEL_CHECKBOX]: `vModelCheckbox`,
18390  [V_MODEL_TEXT]: `vModelText`,
18391  [V_MODEL_SELECT]: `vModelSelect`,
18392  [V_MODEL_DYNAMIC]: `vModelDynamic`,
18393  [V_ON_WITH_MODIFIERS]: `withModifiers`,
18394  [V_ON_WITH_KEYS]: `withKeys`,
18395  [V_SHOW]: `vShow`,
18396  [compiler_dom_esm_bundler_TRANSITION]: `Transition`,
18397  [TRANSITION_GROUP]: `TransitionGroup`
18398});
18399
18400let decoder;
18401function decodeHtmlBrowser(raw, asAttr = false) {
18402  if (!decoder) {
18403    decoder = document.createElement("div");
18404  }
18405  if (asAttr) {
18406    decoder.innerHTML = `<div foo="${raw.replace(/"/g, "&quot;")}">`;
18407    return decoder.children[0].getAttribute("foo");
18408  } else {
18409    decoder.innerHTML = raw;
18410    return decoder.textContent;
18411  }
18412}
18413
18414const parserOptions = {
18415  parseMode: "html",
18416  isVoidTag: isVoidTag,
18417  isNativeTag: (tag) => shared_esm_bundler_isHTMLTag(tag) || shared_esm_bundler_isSVGTag(tag) || shared_esm_bundler_isMathMLTag(tag),
18418  isPreTag: (tag) => tag === "pre",
18419  isIgnoreNewlineTag: (tag) => tag === "pre" || tag === "textarea",
18420  decodeEntities: decodeHtmlBrowser ,
18421  isBuiltInComponent: (tag) => {
18422    if (tag === "Transition" || tag === "transition") {
18423      return compiler_dom_esm_bundler_TRANSITION;
18424    } else if (tag === "TransitionGroup" || tag === "transition-group") {
18425      return TRANSITION_GROUP;
18426    }
18427  },
18428  // https://html.spec.whatwg.org/multipage/parsing.html#tree-construction-dispatcher
18429  getNamespace(tag, parent, rootNamespace) {
18430    let ns = parent ? parent.ns : rootNamespace;
18431    if (parent && ns === 2) {
18432      if (parent.tag === "annotation-xml") {
18433        if (tag === "svg") {
18434          return 1;
18435        }
18436        if (parent.props.some(
18437          (a) => a.type === 6 && a.name === "encoding" && a.value != null && (a.value.content === "text/html" || a.value.content === "application/xhtml+xml")
18438        )) {
18439          ns = 0;
18440        }
18441      } else if (/^m(?:[ions]|text)$/.test(parent.tag) && tag !== "mglyph" && tag !== "malignmark") {
18442        ns = 0;
18443      }
18444    } else if (parent && ns === 1) {
18445      if (parent.tag === "foreignObject" || parent.tag === "desc" || parent.tag === "title") {
18446        ns = 0;
18447      }
18448    }
18449    if (ns === 0) {
18450      if (tag === "svg") {
18451        return 1;
18452      }
18453      if (tag === "math") {
18454        return 2;
18455      }
18456    }
18457    return ns;
18458  }
18459};
18460
18461const transformStyle = (node) => {
18462  if (node.type === 1) {
18463    node.props.forEach((p, i) => {
18464      if (p.type === 6 && p.name === "style" && p.value) {
18465        node.props[i] = {
18466          type: 7,
18467          name: `bind`,
18468          arg: createSimpleExpression(`style`, true, p.loc),
18469          exp: parseInlineCSS(p.value.content, p.loc),
18470          modifiers: [],
18471          loc: p.loc
18472        };
18473      }
18474    });
18475  }
18476};
18477const parseInlineCSS = (cssText, loc) => {
18478  const normalized = parseStringStyle(cssText);
18479  return createSimpleExpression(
18480    JSON.stringify(normalized),
18481    false,
18482    loc,
18483    3
18484  );
18485};
18486
18487function createDOMCompilerError(code, loc) {
18488  return createCompilerError(
18489    code,
18490    loc,
18491     false ? 0 : void 0
18492  );
18493}
18494const DOMErrorCodes = {
18495  "X_V_HTML_NO_EXPRESSION": 53,
18496  "53": "X_V_HTML_NO_EXPRESSION",
18497  "X_V_HTML_WITH_CHILDREN": 54,
18498  "54": "X_V_HTML_WITH_CHILDREN",
18499  "X_V_TEXT_NO_EXPRESSION": 55,
18500  "55": "X_V_TEXT_NO_EXPRESSION",
18501  "X_V_TEXT_WITH_CHILDREN": 56,
18502  "56": "X_V_TEXT_WITH_CHILDREN",
18503  "X_V_MODEL_ON_INVALID_ELEMENT": 57,
18504  "57": "X_V_MODEL_ON_INVALID_ELEMENT",
18505  "X_V_MODEL_ARG_ON_ELEMENT": 58,
18506  "58": "X_V_MODEL_ARG_ON_ELEMENT",
18507  "X_V_MODEL_ON_FILE_INPUT_ELEMENT": 59,
18508  "59": "X_V_MODEL_ON_FILE_INPUT_ELEMENT",
18509  "X_V_MODEL_UNNECESSARY_VALUE": 60,
18510  "60": "X_V_MODEL_UNNECESSARY_VALUE",
18511  "X_V_SHOW_NO_EXPRESSION": 61,
18512  "61": "X_V_SHOW_NO_EXPRESSION",
vendor: 2,693 bytes, lines 18513-18608
18513  "X_TRANSITION_INVALID_CHILDREN": 62,
18514  "62": "X_TRANSITION_INVALID_CHILDREN",
18515  "X_IGNORED_SIDE_EFFECT_TAG": 63,
18516  "63": "X_IGNORED_SIDE_EFFECT_TAG",
18517  "__EXTEND_POINT__": 64,
18518  "64": "__EXTEND_POINT__"
18519};
18520const DOMErrorMessages = {
18521  [53]: `v-html is missing expression.`,
18522  [54]: `v-html will override element children.`,
18523  [55]: `v-text is missing expression.`,
18524  [56]: `v-text will override element children.`,
18525  [57]: `v-model can only be used on <input>, <textarea> and <select> elements.`,
18526  [58]: `v-model argument is not supported on plain elements.`,
18527  [59]: `v-model cannot be used on file inputs since they are read-only. Use a v-on:change listener instead.`,
18528  [60]: `Unnecessary value binding used alongside v-model. It will interfere with v-model's behavior.`,
18529  [61]: `v-show is missing expression.`,
18530  [62]: `<Transition> expects exactly one child element or component.`,
18531  [63]: `Tags with side effect (<script> and <style>) are ignored in client component templates.`
18532};
18533
18534const transformVHtml = (dir, node, context) => {
18535  const { exp, loc } = dir;
18536  if (!exp) {
18537    context.onError(
18538      createDOMCompilerError(53, loc)
18539    );
18540  }
18541  if (node.children.length) {
18542    context.onError(
18543      createDOMCompilerError(54, loc)
18544    );
18545    node.children.length = 0;
18546  }
18547  return {
18548    props: [
18549      createObjectProperty(
18550        createSimpleExpression(`innerHTML`, true, loc),
18551        exp || createSimpleExpression("", true)
18552      )
18553    ]
18554  };
18555};
18556
18557const transformVText = (dir, node, context) => {
18558  const { exp, loc } = dir;
18559  if (!exp) {
18560    context.onError(
18561      createDOMCompilerError(55, loc)
18562    );
18563  }
18564  if (node.children.length) {
18565    context.onError(
18566      createDOMCompilerError(56, loc)
18567    );
18568    node.children.length = 0;
18569  }
18570  return {
18571    props: [
18572      createObjectProperty(
18573        createSimpleExpression(`textContent`, true),
18574        exp ? getConstantType(exp, context) > 0 ? exp : createCallExpression(
18575          context.helperString(TO_DISPLAY_STRING),
18576          [exp],
18577          loc
18578        ) : createSimpleExpression("", true)
18579      )
18580    ]
18581  };
18582};
18583
18584const compiler_dom_esm_bundler_transformModel = (dir, node, context) => {
18585  const baseResult = transformModel(dir, node, context);
18586  if (!baseResult.props.length || node.tagType === 1) {
18587    return baseResult;
18588  }
18589  if (dir.arg) {
18590    context.onError(
18591      createDOMCompilerError(
18592        58,
18593        dir.arg.loc
18594      )
18595    );
18596  }
18597  function checkDuplicatedValue() {
18598    const value = findDir(node, "bind");
18599    if (value && isStaticArgOf(value.arg, "value")) {
18600      context.onError(
18601        createDOMCompilerError(
18602          60,
18603          value.loc
18604        )
18605      );
18606    }
18607  }
18608  const { tag } = node;
vendor: 4,590 bytes, lines 18609-18750
18609  const isCustomElement = context.isCustomElement(tag);
18610  if (tag === "input" || tag === "textarea" || tag === "select" || isCustomElement) {
18611    let directiveToUse = V_MODEL_TEXT;
18612    let isInvalidType = false;
18613    if (tag === "input" || isCustomElement) {
18614      const type = findProp(node, `type`);
18615      if (type) {
18616        if (type.type === 7) {
18617          directiveToUse = V_MODEL_DYNAMIC;
18618        } else if (type.value) {
18619          switch (type.value.content) {
18620            case "radio":
18621              directiveToUse = V_MODEL_RADIO;
18622              break;
18623            case "checkbox":
18624              directiveToUse = V_MODEL_CHECKBOX;
18625              break;
18626            case "file":
18627              isInvalidType = true;
18628              context.onError(
18629                createDOMCompilerError(
18630                  59,
18631                  dir.loc
18632                )
18633              );
18634              break;
18635            default:
18636               false && 0;
18637              break;
18638          }
18639        }
18640      } else if (hasDynamicKeyVBind(node)) {
18641        directiveToUse = V_MODEL_DYNAMIC;
18642      } else {
18643         false && 0;
18644      }
18645    } else if (tag === "select") {
18646      directiveToUse = V_MODEL_SELECT;
18647    } else {
18648       false && 0;
18649    }
18650    if (!isInvalidType) {
18651      baseResult.needRuntime = context.helper(directiveToUse);
18652    }
18653  } else {
18654    context.onError(
18655      createDOMCompilerError(
18656        57,
18657        dir.loc
18658      )
18659    );
18660  }
18661  baseResult.props = baseResult.props.filter(
18662    (p) => !(p.key.type === 4 && p.key.content === "modelValue")
18663  );
18664  return baseResult;
18665};
18666
18667const isEventOptionModifier = /* @__PURE__ */ shared_esm_bundler_makeMap(`passive,once,capture`);
18668const isNonKeyModifier = /* @__PURE__ */ shared_esm_bundler_makeMap(
18669  // event propagation management
18670  `stop,prevent,self,ctrl,shift,alt,meta,exact,middle`
18671);
18672const maybeKeyModifier = /* @__PURE__ */ shared_esm_bundler_makeMap("left,right");
18673const isKeyboardEvent = /* @__PURE__ */ shared_esm_bundler_makeMap(`onkeyup,onkeydown,onkeypress`);
18674const resolveModifiers = (key, modifiers, context, loc) => {
18675  const keyModifiers = [];
18676  const nonKeyModifiers = [];
18677  const eventOptionModifiers = [];
18678  for (let i = 0; i < modifiers.length; i++) {
18679    const modifier = modifiers[i].content;
18680    if (modifier === "native" && checkCompatEnabled(
18681      "COMPILER_V_ON_NATIVE",
18682      context,
18683      loc
18684    )) {
18685      eventOptionModifiers.push(modifier);
18686    } else if (isEventOptionModifier(modifier)) {
18687      eventOptionModifiers.push(modifier);
18688    } else {
18689      if (maybeKeyModifier(modifier)) {
18690        if (isStaticExp(key)) {
18691          if (isKeyboardEvent(key.content.toLowerCase())) {
18692            keyModifiers.push(modifier);
18693          } else {
18694            nonKeyModifiers.push(modifier);
18695          }
18696        } else {
18697          keyModifiers.push(modifier);
18698          nonKeyModifiers.push(modifier);
18699        }
18700      } else {
18701        if (isNonKeyModifier(modifier)) {
18702          nonKeyModifiers.push(modifier);
18703        } else {
18704          keyModifiers.push(modifier);
18705        }
18706      }
18707    }
18708  }
18709  return {
18710    keyModifiers,
18711    nonKeyModifiers,
18712    eventOptionModifiers
18713  };
18714};
18715const transformClick = (key, event) => {
18716  const isStaticClick = isStaticExp(key) && key.content.toLowerCase() === "onclick";
18717  return isStaticClick ? createSimpleExpression(event, true) : key.type !== 4 ? createCompoundExpression([
18718    `(`,
18719    key,
18720    `) === "onClick" ? "${event}" : (`,
18721    key,
18722    `)`
18723  ]) : key;
18724};
18725const compiler_dom_esm_bundler_transformOn = (dir, node, context) => {
18726  return transformOn(dir, node, context, (baseResult) => {
18727    const { modifiers } = dir;
18728    if (!modifiers.length) return baseResult;
18729    let { key, value: handlerExp } = baseResult.props[0];
18730    const { keyModifiers, nonKeyModifiers, eventOptionModifiers } = resolveModifiers(key, modifiers, context, dir.loc);
18731    if (nonKeyModifiers.includes("right")) {
18732      key = transformClick(key, `onContextmenu`);
18733    }
18734    if (nonKeyModifiers.includes("middle")) {
18735      key = transformClick(key, `onMouseup`);
18736    }
18737    if (nonKeyModifiers.length) {
18738      handlerExp = createCallExpression(context.helper(V_ON_WITH_MODIFIERS), [
18739        handlerExp,
18740        JSON.stringify(nonKeyModifiers)
18741      ]);
18742    }
18743    if (keyModifiers.length && // if event name is dynamic, always wrap with keys guard
18744    (!isStaticExp(key) || isKeyboardEvent(key.content.toLowerCase()))) {
18745      handlerExp = createCallExpression(context.helper(V_ON_WITH_KEYS), [
18746        handlerExp,
18747        JSON.stringify(keyModifiers)
18748      ]);
18749    }
18750    if (eventOptionModifiers.length) {
vendor: 7,518 bytes, lines 18751-19046
18751      const modifierPostfix = eventOptionModifiers.map(shared_esm_bundler_capitalize).join("");
18752      key = isStaticExp(key) ? createSimpleExpression(`${key.content}${modifierPostfix}`, true) : createCompoundExpression([`(`, key, `) + "${modifierPostfix}"`]);
18753    }
18754    return {
18755      props: [createObjectProperty(key, handlerExp)]
18756    };
18757  });
18758};
18759
18760const transformShow = (dir, node, context) => {
18761  const { exp, loc } = dir;
18762  if (!exp) {
18763    context.onError(
18764      createDOMCompilerError(61, loc)
18765    );
18766  }
18767  return {
18768    props: [],
18769    needRuntime: context.helper(V_SHOW)
18770  };
18771};
18772
18773const transformTransition = (node, context) => {
18774  if (node.type === 1 && node.tagType === 1) {
18775    const component = context.isBuiltInComponent(node.tag);
18776    if (component === compiler_dom_esm_bundler_TRANSITION) {
18777      return () => {
18778        if (!node.children.length) {
18779          return;
18780        }
18781        if (hasMultipleChildren(node)) {
18782          context.onError(
18783            createDOMCompilerError(
18784              62,
18785              {
18786                start: node.children[0].loc.start,
18787                end: node.children[node.children.length - 1].loc.end,
18788                source: ""
18789              }
18790            )
18791          );
18792        }
18793        const child = node.children[0];
18794        if (child.type === 1) {
18795          for (const p of child.props) {
18796            if (p.type === 7 && p.name === "show") {
18797              node.props.push({
18798                type: 6,
18799                name: "persisted",
18800                nameLoc: node.loc,
18801                value: void 0,
18802                loc: node.loc
18803              });
18804            }
18805          }
18806        }
18807      };
18808    }
18809  }
18810};
18811function hasMultipleChildren(node) {
18812  const children = node.children = node.children.filter(
18813    (c) => !isCommentOrWhitespace(c)
18814  );
18815  const child = children[0];
18816  return children.length !== 1 || child.type === 11 || child.type === 9 && child.branches.some(hasMultipleChildren);
18817}
18818
18819const ignoreSideEffectTags = (node, context) => {
18820  if (node.type === 1 && node.tagType === 0 && (node.tag === "script" || node.tag === "style")) {
18821     false && 0;
18822    context.removeNode();
18823  }
18824};
18825
18826function isValidHTMLNesting(parent, child) {
18827  if (parent === "template") {
18828    return true;
18829  }
18830  if (parent in onlyValidChildren) {
18831    return onlyValidChildren[parent].has(child);
18832  }
18833  if (child in onlyValidParents) {
18834    return onlyValidParents[child].has(parent);
18835  }
18836  if (parent in knownInvalidChildren) {
18837    if (knownInvalidChildren[parent].has(child)) return false;
18838  }
18839  if (child in knownInvalidParents) {
18840    if (knownInvalidParents[child].has(parent)) return false;
18841  }
18842  return true;
18843}
18844const headings = /* @__PURE__ */ new Set(["h1", "h2", "h3", "h4", "h5", "h6"]);
18845const emptySet = /* @__PURE__ */ new Set([]);
18846const onlyValidChildren = {
18847  head: /* @__PURE__ */ new Set([
18848    "base",
18849    "basefront",
18850    "bgsound",
18851    "link",
18852    "meta",
18853    "title",
18854    "noscript",
18855    "noframes",
18856    "style",
18857    "script",
18858    "template"
18859  ]),
18860  optgroup: /* @__PURE__ */ new Set(["option"]),
18861  select: /* @__PURE__ */ new Set(["optgroup", "option", "hr"]),
18862  // table
18863  table: /* @__PURE__ */ new Set(["caption", "colgroup", "tbody", "tfoot", "thead"]),
18864  tr: /* @__PURE__ */ new Set(["td", "th"]),
18865  colgroup: /* @__PURE__ */ new Set(["col"]),
18866  tbody: /* @__PURE__ */ new Set(["tr"]),
18867  thead: /* @__PURE__ */ new Set(["tr"]),
18868  tfoot: /* @__PURE__ */ new Set(["tr"]),
18869  // these elements can not have any children elements
18870  script: emptySet,
18871  iframe: emptySet,
18872  option: emptySet,
18873  textarea: emptySet,
18874  style: emptySet,
18875  title: emptySet
18876};
18877const onlyValidParents = {
18878  // sections
18879  html: emptySet,
18880  body: /* @__PURE__ */ new Set(["html"]),
18881  head: /* @__PURE__ */ new Set(["html"]),
18882  // table
18883  td: /* @__PURE__ */ new Set(["tr"]),
18884  colgroup: /* @__PURE__ */ new Set(["table"]),
18885  caption: /* @__PURE__ */ new Set(["table"]),
18886  tbody: /* @__PURE__ */ new Set(["table"]),
18887  tfoot: /* @__PURE__ */ new Set(["table"]),
18888  col: /* @__PURE__ */ new Set(["colgroup"]),
18889  th: /* @__PURE__ */ new Set(["tr"]),
18890  thead: /* @__PURE__ */ new Set(["table"]),
18891  tr: /* @__PURE__ */ new Set(["tbody", "thead", "tfoot"]),
18892  // data list
18893  dd: /* @__PURE__ */ new Set(["dl", "div"]),
18894  dt: /* @__PURE__ */ new Set(["dl", "div"]),
18895  // other
18896  figcaption: /* @__PURE__ */ new Set(["figure"]),
18897  // li: new Set(["ul", "ol"]),
18898  summary: /* @__PURE__ */ new Set(["details"]),
18899  area: /* @__PURE__ */ new Set(["map"])
18900};
18901const knownInvalidChildren = {
18902  p: /* @__PURE__ */ new Set([
18903    "address",
18904    "article",
18905    "aside",
18906    "blockquote",
18907    "center",
18908    "details",
18909    "dialog",
18910    "dir",
18911    "div",
18912    "dl",
18913    "fieldset",
18914    "figure",
18915    "footer",
18916    "form",
18917    "h1",
18918    "h2",
18919    "h3",
18920    "h4",
18921    "h5",
18922    "h6",
18923    "header",
18924    "hgroup",
18925    "hr",
18926    "li",
18927    "main",
18928    "nav",
18929    "menu",
18930    "ol",
18931    "p",
18932    "pre",
18933    "section",
18934    "table",
18935    "ul"
18936  ]),
18937  svg: /* @__PURE__ */ new Set([
18938    "b",
18939    "blockquote",
18940    "br",
18941    "code",
18942    "dd",
18943    "div",
18944    "dl",
18945    "dt",
18946    "em",
18947    "embed",
18948    "h1",
18949    "h2",
18950    "h3",
18951    "h4",
18952    "h5",
18953    "h6",
18954    "hr",
18955    "i",
18956    "img",
18957    "li",
18958    "menu",
18959    "meta",
18960    "ol",
18961    "p",
18962    "pre",
18963    "ruby",
18964    "s",
18965    "small",
18966    "span",
18967    "strong",
18968    "sub",
18969    "sup",
18970    "table",
18971    "u",
18972    "ul",
18973    "var"
18974  ])
18975};
18976const knownInvalidParents = {
18977  a: /* @__PURE__ */ new Set(["a"]),
18978  button: /* @__PURE__ */ new Set(["button"]),
18979  dd: /* @__PURE__ */ new Set(["dd", "dt"]),
18980  dt: /* @__PURE__ */ new Set(["dd", "dt"]),
18981  form: /* @__PURE__ */ new Set(["form"]),
18982  li: /* @__PURE__ */ new Set(["li"]),
18983  h1: headings,
18984  h2: headings,
18985  h3: headings,
18986  h4: headings,
18987  h5: headings,
18988  h6: headings
18989};
18990
18991const validateHtmlNesting = (node, context) => {
18992  if (node.type === 1 && node.tagType === 0 && context.parent && context.parent.type === 1 && context.parent.tagType === 0 && !isValidHTMLNesting(context.parent.tag, node.tag)) {
18993    const error = new SyntaxError(
18994      `<${node.tag}> cannot be child of <${context.parent.tag}>, according to HTML specifications. This can cause hydration errors or potentially disrupt future functionality.`
18995    );
18996    error.loc = node.loc;
18997    context.onWarn(error);
18998  }
18999};
19000
19001const DOMNodeTransforms = [
19002  transformStyle,
19003  ... false ? 0 : []
19004];
19005const DOMDirectiveTransforms = {
19006  cloak: noopDirectiveTransform,
19007  html: transformVHtml,
19008  text: transformVText,
19009  model: compiler_dom_esm_bundler_transformModel,
19010  // override compiler-core
19011  on: compiler_dom_esm_bundler_transformOn,
19012  // override compiler-core
19013  show: transformShow
19014};
19015function compiler_dom_esm_bundler_compile(src, options = {}) {
19016  return baseCompile(
19017    src,
19018    shared_esm_bundler_extend({}, parserOptions, options, {
19019      nodeTransforms: [
19020        // ignore <script> and <tag>
19021        // this is not put inside DOMNodeTransforms because that list is used
19022        // by compiler-ssr to generate vnode fallback branches
19023        ignoreSideEffectTags,
19024        ...DOMNodeTransforms,
19025        ...options.nodeTransforms || []
19026      ],
19027      directiveTransforms: shared_esm_bundler_extend(
19028        {},
19029        DOMDirectiveTransforms,
19030        options.directiveTransforms || {}
19031      ),
19032      transformHoist: null 
19033    })
19034  );
19035}
19036function parse(template, options = {}) {
19037  return baseParse(template, extend({}, parserOptions, options));
19038}
19039
19040
19041
19042;// ./node_modules/vue/dist/vue.esm-bundler.js
19043/**
19044* vue v3.5.25
19045* (c) 2018-present Yuxi (Evan) You and Vue contributors
19046* @license MIT
19047**/
19048
19049
19050
19051
19052
19053
19054function initDev() {
19055  {
19056    initCustomFormatter();
19057  }
19058}
19059
19060if (false) // removed by dead control flow
19061{}
19062const compileCache = /* @__PURE__ */ Object.create(null);
19063function compileToFunction(template, options) {
19064  if (!shared_esm_bundler_isString(template)) {
19065    if (template.nodeType) {
19066      template = template.innerHTML;
19067    } else {
19068       false && 0;
19069      return shared_esm_bundler_NOOP;
19070    }
19071  }
19072  const key = genCacheKey(template, options);
19073  const cached = compileCache[key];
19074  if (cached) {
19075    return cached;
19076  }
19077  if (template[0] === "#") {
19078    const el = document.querySelector(template);
19079    if (false) // removed by dead control flow
19080{}
19081    template = el ? el.innerHTML : ``;
19082  }
19083  const opts = shared_esm_bundler_extend(
19084    {
19085      hoistStatic: true,
19086      onError:  false ? 0 : void 0,
19087      onWarn:  false ? 0 : shared_esm_bundler_NOOP
19088    },
19089    options
19090  );
19091  if (!opts.isCustomElement && typeof customElements !== "undefined") {
19092    opts.isCustomElement = (tag) => !!customElements.get(tag);
19093  }
19094  const { code } = compiler_dom_esm_bundler_compile(template, opts);
19095  function onError(err, asWarning = false) {
19096    const message = asWarning ? err.message : `Template compilation error: ${err.message}`;
19097    const codeFrame = err.loc && generateCodeFrame(
19098      template,
19099      err.loc.start.offset,
19100      err.loc.end.offset
19101    );
19102    runtime_core_esm_bundler_warn(codeFrame ? `${message}
19103${codeFrame}` : message);
19104  }
19105  const render = new Function("Vue", code)(runtime_dom_esm_bundler_namespaceObject);
19106  render._rc = true;
19107  return compileCache[key] = render;
19108}
19109registerRuntimeCompiler(compileToFunction);
19110
19111
19112
19113
19114/***/ },
19115
19116/***/ 1580
19117(module, __webpack_exports__, __webpack_require__) {
19118
19119"use strict";
19120/* harmony export */ __webpack_require__.d(__webpack_exports__, {
19121/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
19122/* harmony export */ });
19123/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1601);
19124/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
19125/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6314);
19126/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
19127// Imports
19128
19129
19130var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
19131// Module
19132___CSS_LOADER_EXPORT___.push([module.id, `
19133.input-disabled[data-v-4bc9f3ee] {
19134	display: flex;
19135	justify-content: space-between;
19136	align-items: center;
19137}
19138.input-disabled__name[data-v-4bc9f3ee] {
19139	text-decoration: line-through;
19140	opacity: .7;
19141}
19142.input-disabled__name--back-in-stock[data-v-4bc9f3ee] {
19143	text-decoration: none;
19144}
19145.input-disabled__label[data-v-4bc9f3ee] {
19146	font-size: .7em;
19147}
19148.gs_input__fieldset[data-v-4bc9f3ee] {
19149	background-color: #fff;
19150}
19151`, ""]);
19152// Exports
19153/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
19154
19155
19156/***/ },
19157
19158/***/ 1601
19159(module) {
19160
19161"use strict";
19162
19163
19164module.exports = function (i) {
19165  return i[1];
19166};
19167
19168/***/ },
19169
19170/***/ 1858
19171(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
19172
19173"use strict";
19174/* harmony export */ __webpack_require__.d(__webpack_exports__, {
19175/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
19176/* harmony export */ });
19177/* harmony import */ var _Entity__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7249);
19178
19179
19180class DiscountEntity extends _Entity__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A {
19181	constructor() {
19182		super();
19183	}
19184
19185	static createFromAPIData(obj) {
19186		return DiscountEntity.map({
19187            code: 'code',
19188            title: 'title',
19189            type: 'type',
19190            reduction: {
19191                type: {},
19192                properties: {
19193                    amount: 'amount',
19194                    currencyCode: 'currencyCode',
19195                    taxAmount: 'taxAmount',
19196                    taxModel: 'taxModel',
19197                    taxRate: 'taxRate'
19198                }
19199            },
19200            grossReduction: {
19201                type: {},
19202                properties: {
19203                    amount: 'amount',
19204                    currencyCode: 'currencyCode',
19205                    taxAmount: 'taxAmount',
19206                    taxModel: 'taxModel',
19207                    taxRate: 'taxRate'
19208                }
19209            }
19210        },
19211        obj);
19212    }
19213    
19214    static toPaymentPOJO(obj) {
19215		return DiscountEntity.map({
19216            code: 'code',
19217            title: 'title',
19218            type: 'type',
19219            reduction: {
19220                type: {},
19221                properties: {
19222                    amount: 'amount',
19223                    currencyCode: 'currencyCode',
19224                    taxAmount: 'taxAmount',
19225                    taxModel: 'taxModel',
19226                    taxRate: 'taxRate'
19227                }
19228            },
19229            grossReduction: {
19230                type: {},
19231                properties: {
19232                    amount: 'amount',
19233                    currencyCode: 'currencyCode',
19234                    taxAmount: 'taxAmount',
19235                    taxModel: 'taxModel',
19236                    taxRate: 'taxRate'
19237                }
19238            }
19239        },
19240        obj,
19241        true);
19242	}
19243}
19244
19245/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (DiscountEntity);
19246
19247
19248/***/ },
19249
19250/***/ 2051
19251(module) {
19252
19253/**! 
19254 * cookiejs v2.1.3 
19255 * A simple, lightweight JavaScript API for handling browser cookies. 
19256 * 
19257 * Copyright (c) 2023 kenny wong 
19258 * https://github.com/jaywcjlove/cookie.js.git 
19259 * 
19260 * @website: https://jaywcjlove.github.io/cookie.js/
19261 
19262 * Licensed under the MIT license 
19263 */
19264
19265(function (global, factory) {
19266   true ? module.exports = factory() :
19267  0;
19268})(this, (function () { 'use strict';
19269
19270  function getKeys(obj) {
19271    var names = [], name = '';
19272    for (name in obj) {
19273      names.push(name);
19274    }
19275    return names;
19276  }
19277
19278  function isPlainObject(obj) {
19279    obj = JSON.stringify(obj);
19280    if (typeof obj !== 'string') {
19281      return false;
vendor: 5,084 bytes, lines 19282-19430
19282    }
19283    if (!/^\{[\s\S]*\}$/.test(obj)) {
19284      return false;
19285    }
19286    return true;
19287  }
19288
19289  function isArray(value) { return value instanceof Array }
19290  function toArray(value) {
19291    return Array.prototype.slice.call(value);
19292  }
19293  function Cookie(){
19294    if(!(this instanceof Cookie)) {
19295      return new Cookie()
19296    }}
19297  Cookie.prototype = {
19298    get: function(name) {
19299      var nameEQ = name + "=";
19300      var ca = document.cookie.split(';');//把cookie分割成组    
19301      for(var i=0;i < ca.length;i++) {    
19302        var c = ca[i];//取得字符串    
19303        while (c.charAt(0)==' ') {//判断一下字符串有没有前导空格    
19304          c = c.substring(1,c.length);//有的话,从第二位开始取    
19305        }    
19306        //如果含有我们要的name
19307        if (c.indexOf(nameEQ) == 0) {
19308          return decodeURI(c.substring(nameEQ.length,c.length));//解码并截取我们要值    
19309        }    
19310      }
19311      return false;
19312    },
19313    set: function(name, value, options) {
19314      if (isPlainObject(name)) {
19315        for (const k in name) {
19316          this.set(k, name[k], value, options);
19317        }
19318      } else if (typeof name === 'string') {
19319        const opt = isPlainObject(options) ? options : { expires: options },
19320            path = opt.path !== undefined ? `;path=${opt.path};path=/` : ';path=/',
19321            domain = opt.domain ? `;domain=${opt.domain}` : '',
19322            secure = opt.secure ? ';secure' : '';
19323        let expires = opt.expires !== undefined ? opt.expires : '';
19324
19325          //过期时间
19326        if (typeof expires === 'string' && expires !== '') {
19327          expires = new Date(expires);
19328        } else if (typeof expires === 'number') {
19329          expires = new Date(+new Date + 1000 * 60 * 60 * 24 * expires);
19330        } if (expires !== '' && 'toGMTString' in expires) {
19331          expires = `;expires=${expires.toGMTString()}`;
19332        }
19333        const sameSite = opt.sameSite ? `;SameSite=${opt.sameSite}` : '';
19334        document.cookie = `${name}=${encodeURI(value) + expires + path + domain + secure + sameSite}`; // 转码并赋值
19335      }
19336    },
19337    remove: function(names) {
19338      names = isArray(names) ? names : toArray(arguments);
19339      for (var i = 0, l = names.length; i < l; i++) {
19340        this.set(names[i], '', -1);
19341      }
19342      return names;  
19343    },
19344    clear: function(name) {
19345      return name ? this.remove(name) : this.remove(getKeys(this.all()));
19346    },
19347    all: function() {
19348      if (document.cookie === '') return {};
19349      var cookies = document.cookie.split('; '),result = {};
19350      for (var i = 0, l = cookies.length; i < l; i++) {
19351        var item = cookies[i].split('=');
19352        result[decodeURI(item[0])] = decodeURI(item[1]);
19353      }
19354      return result;
19355    }
19356  };
19357
19358  let _Cookie = null;
19359
19360  const cookie = function(name, value, options) {
19361    const argm = arguments;
19362    if (!_Cookie) _Cookie = Cookie();
19363    if (argm.length === 0) return _Cookie.all();
19364    if (argm.length === 1 && name === null) return _Cookie.clear();
19365    if (argm.length === 2 && !value) return _Cookie.clear(name);
19366    if (typeof name == 'string' && !value) return _Cookie.get(name);
19367    if ((typeof name === 'string' && value) || isPlainObject(name)) {
19368      return _Cookie.set(name, value, options);
19369    }
19370  };
19371  for (const a in Cookie.prototype) cookie[a] = Cookie.prototype[a];
19372
19373  return cookie;
19374
19375}));
19376
19377
19378/***/ },
19379
19380/***/ 2124
19381(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
19382
19383"use strict";
19384
19385// EXPORTS
19386__webpack_require__.d(__webpack_exports__, {
19387  y$: () => (/* binding */ createStore),
19388  aH: () => (/* binding */ mapState)
19389});
19390
19391// UNUSED EXPORTS: Store, createLogger, createNamespacedHelpers, default, mapActions, mapGetters, mapMutations, storeKey, useStore
19392
19393// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 6 modules
19394var vue_esm_bundler = __webpack_require__(1425);
19395;// ./node_modules/@vue/devtools-api/lib/esm/env.js
19396function getDevtoolsGlobalHook() {
19397    return getTarget().__VUE_DEVTOOLS_GLOBAL_HOOK__;
19398}
19399function getTarget() {
19400    // @ts-expect-error navigator and windows are not available in all environments
19401    return (typeof navigator !== 'undefined' && typeof window !== 'undefined')
19402        ? window
19403        : typeof globalThis !== 'undefined'
19404            ? globalThis
19405            : {};
19406}
19407const isProxyAvailable = typeof Proxy === 'function';
19408
19409;// ./node_modules/@vue/devtools-api/lib/esm/const.js
19410const HOOK_SETUP = 'devtools-plugin:setup';
19411const HOOK_PLUGIN_SETTINGS_SET = 'plugin:settings:set';
19412
19413;// ./node_modules/@vue/devtools-api/lib/esm/time.js
19414let supported;
19415let perf;
19416function isPerformanceSupported() {
19417    var _a;
19418    if (supported !== undefined) {
19419        return supported;
19420    }
19421    if (typeof window !== 'undefined' && window.performance) {
19422        supported = true;
19423        perf = window.performance;
19424    }
19425    else if (typeof globalThis !== 'undefined' && ((_a = globalThis.perf_hooks) === null || _a === void 0 ? void 0 : _a.performance)) {
19426        supported = true;
19427        perf = globalThis.perf_hooks.performance;
19428    }
19429    else {
19430        supported = false;
vendor: 4,575 bytes, lines 19431-19586
19431    }
19432    return supported;
19433}
19434function now() {
19435    return isPerformanceSupported() ? perf.now() : Date.now();
19436}
19437
19438;// ./node_modules/@vue/devtools-api/lib/esm/proxy.js
19439
19440
19441class ApiProxy {
19442    constructor(plugin, hook) {
19443        this.target = null;
19444        this.targetQueue = [];
19445        this.onQueue = [];
19446        this.plugin = plugin;
19447        this.hook = hook;
19448        const defaultSettings = {};
19449        if (plugin.settings) {
19450            for (const id in plugin.settings) {
19451                const item = plugin.settings[id];
19452                defaultSettings[id] = item.defaultValue;
19453            }
19454        }
19455        const localSettingsSaveId = `__vue-devtools-plugin-settings__${plugin.id}`;
19456        let currentSettings = Object.assign({}, defaultSettings);
19457        try {
19458            const raw = localStorage.getItem(localSettingsSaveId);
19459            const data = JSON.parse(raw);
19460            Object.assign(currentSettings, data);
19461        }
19462        catch (e) {
19463            // noop
19464        }
19465        this.fallbacks = {
19466            getSettings() {
19467                return currentSettings;
19468            },
19469            setSettings(value) {
19470                try {
19471                    localStorage.setItem(localSettingsSaveId, JSON.stringify(value));
19472                }
19473                catch (e) {
19474                    // noop
19475                }
19476                currentSettings = value;
19477            },
19478            now() {
19479                return now();
19480            },
19481        };
19482        if (hook) {
19483            hook.on(HOOK_PLUGIN_SETTINGS_SET, (pluginId, value) => {
19484                if (pluginId === this.plugin.id) {
19485                    this.fallbacks.setSettings(value);
19486                }
19487            });
19488        }
19489        this.proxiedOn = new Proxy({}, {
19490            get: (_target, prop) => {
19491                if (this.target) {
19492                    return this.target.on[prop];
19493                }
19494                else {
19495                    return (...args) => {
19496                        this.onQueue.push({
19497                            method: prop,
19498                            args,
19499                        });
19500                    };
19501                }
19502            },
19503        });
19504        this.proxiedTarget = new Proxy({}, {
19505            get: (_target, prop) => {
19506                if (this.target) {
19507                    return this.target[prop];
19508                }
19509                else if (prop === 'on') {
19510                    return this.proxiedOn;
19511                }
19512                else if (Object.keys(this.fallbacks).includes(prop)) {
19513                    return (...args) => {
19514                        this.targetQueue.push({
19515                            method: prop,
19516                            args,
19517                            resolve: () => { },
19518                        });
19519                        return this.fallbacks[prop](...args);
19520                    };
19521                }
19522                else {
19523                    return (...args) => {
19524                        return new Promise((resolve) => {
19525                            this.targetQueue.push({
19526                                method: prop,
19527                                args,
19528                                resolve,
19529                            });
19530                        });
19531                    };
19532                }
19533            },
19534        });
19535    }
19536    async setRealTarget(target) {
19537        this.target = target;
19538        for (const item of this.onQueue) {
19539            this.target.on[item.method](...item.args);
19540        }
19541        for (const item of this.targetQueue) {
19542            item.resolve(await this.target[item.method](...item.args));
19543        }
19544    }
19545}
19546
19547;// ./node_modules/@vue/devtools-api/lib/esm/index.js
19548
19549
19550
19551
19552
19553
19554function setupDevtoolsPlugin(pluginDescriptor, setupFn) {
19555    const descriptor = pluginDescriptor;
19556    const target = getTarget();
19557    const hook = getDevtoolsGlobalHook();
19558    const enableProxy = isProxyAvailable && descriptor.enableEarlyProxy;
19559    if (hook && (target.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !enableProxy)) {
19560        hook.emit(HOOK_SETUP, pluginDescriptor, setupFn);
19561    }
19562    else {
19563        const proxy = enableProxy ? new ApiProxy(descriptor, hook) : null;
19564        const list = target.__VUE_DEVTOOLS_PLUGINS__ = target.__VUE_DEVTOOLS_PLUGINS__ || [];
19565        list.push({
19566            pluginDescriptor: descriptor,
19567            setupFn,
19568            proxy,
19569        });
19570        if (proxy) {
19571            setupFn(proxy.proxiedTarget);
19572        }
19573    }
19574}
19575
19576;// ./node_modules/vuex/dist/vuex.esm-bundler.js
19577/*!
19578 * vuex v4.1.0
19579 * (c) 2022 Evan You
19580 * @license MIT
19581 */
19582
19583
19584
19585var storeKey = 'store';
19586
vendor: 4,329 bytes, lines 19587-19753
19587function useStore (key) {
19588  if ( key === void 0 ) key = null;
19589
19590  return (0,vue_esm_bundler/* inject */.WQ)(key !== null ? key : storeKey)
19591}
19592
19593/**
19594 * Get the first item that pass the test
19595 * by second argument function
19596 *
19597 * @param {Array} list
19598 * @param {Function} f
19599 * @return {*}
19600 */
19601function find (list, f) {
19602  return list.filter(f)[0]
19603}
19604
19605/**
19606 * Deep copy the given object considering circular structure.
19607 * This function caches all nested objects and its copies.
19608 * If it detects circular structure, use cached copy to avoid infinite loop.
19609 *
19610 * @param {*} obj
19611 * @param {Array<Object>} cache
19612 * @return {*}
19613 */
19614function deepCopy (obj, cache) {
19615  if ( cache === void 0 ) cache = [];
19616
19617  // just return if obj is immutable value
19618  if (obj === null || typeof obj !== 'object') {
19619    return obj
19620  }
19621
19622  // if obj is hit, it is in circular structure
19623  var hit = find(cache, function (c) { return c.original === obj; });
19624  if (hit) {
19625    return hit.copy
19626  }
19627
19628  var copy = Array.isArray(obj) ? [] : {};
19629  // put the copy into cache at first
19630  // because we want to refer it in recursive deepCopy
19631  cache.push({
19632    original: obj,
19633    copy: copy
19634  });
19635
19636  Object.keys(obj).forEach(function (key) {
19637    copy[key] = deepCopy(obj[key], cache);
19638  });
19639
19640  return copy
19641}
19642
19643/**
19644 * forEach for object
19645 */
19646function forEachValue (obj, fn) {
19647  Object.keys(obj).forEach(function (key) { return fn(obj[key], key); });
19648}
19649
19650function isObject (obj) {
19651  return obj !== null && typeof obj === 'object'
19652}
19653
19654function isPromise (val) {
19655  return val && typeof val.then === 'function'
19656}
19657
19658function assert (condition, msg) {
19659  if (!condition) { throw new Error(("[vuex] " + msg)) }
19660}
19661
19662function partial (fn, arg) {
19663  return function () {
19664    return fn(arg)
19665  }
19666}
19667
19668function genericSubscribe (fn, subs, options) {
19669  if (subs.indexOf(fn) < 0) {
19670    options && options.prepend
19671      ? subs.unshift(fn)
19672      : subs.push(fn);
19673  }
19674  return function () {
19675    var i = subs.indexOf(fn);
19676    if (i > -1) {
19677      subs.splice(i, 1);
19678    }
19679  }
19680}
19681
19682function resetStore (store, hot) {
19683  store._actions = Object.create(null);
19684  store._mutations = Object.create(null);
19685  store._wrappedGetters = Object.create(null);
19686  store._modulesNamespaceMap = Object.create(null);
19687  var state = store.state;
19688  // init all modules
19689  installModule(store, state, [], store._modules.root, true);
19690  // reset state
19691  resetStoreState(store, state, hot);
19692}
19693
19694function resetStoreState (store, state, hot) {
19695  var oldState = store._state;
19696  var oldScope = store._scope;
19697
19698  // bind store public getters
19699  store.getters = {};
19700  // reset local getters cache
19701  store._makeLocalGettersCache = Object.create(null);
19702  var wrappedGetters = store._wrappedGetters;
19703  var computedObj = {};
19704  var computedCache = {};
19705
19706  // create a new effect scope and create computed object inside it to avoid
19707  // getters (computed) getting destroyed on component unmount.
19708  var scope = (0,vue_esm_bundler/* effectScope */.uY)(true);
19709
19710  scope.run(function () {
19711    forEachValue(wrappedGetters, function (fn, key) {
19712      // use computed to leverage its lazy-caching mechanism
19713      // direct inline function use will lead to closure preserving oldState.
19714      // using partial to return function with only arguments preserved in closure environment.
19715      computedObj[key] = partial(fn, store);
19716      computedCache[key] = (0,vue_esm_bundler/* computed */.EW)(function () { return computedObj[key](); });
19717      Object.defineProperty(store.getters, key, {
19718        get: function () { return computedCache[key].value; },
19719        enumerable: true // for local getters
19720      });
19721    });
19722  });
19723
19724  store._state = (0,vue_esm_bundler/* reactive */.Kh)({
19725    data: state
19726  });
19727
19728  // register the newly created effect scope to the store so that we can
19729  // dispose the effects when this method runs again in the future.
19730  store._scope = scope;
19731
19732  // enable strict mode for new state
19733  if (store.strict) {
19734    enableStrictMode(store);
19735  }
19736
19737  if (oldState) {
19738    if (hot) {
19739      // dispatch changes in all subscribed watchers
19740      // to force getter re-evaluation for hot reloading.
19741      store._withCommit(function () {
19742        oldState.data = null;
19743      });
19744    }
19745  }
19746
19747  // dispose previously registered effect scope if there is one.
19748  if (oldScope) {
19749    oldScope.stop();
19750  }
19751}
19752
19753function installModule (store, rootState, path, module, hot) {
vendor: 4,632 bytes, lines 19754-19910
19754  var isRoot = !path.length;
19755  var namespace = store._modules.getNamespace(path);
19756
19757  // register in namespace map
19758  if (module.namespaced) {
19759    if (store._modulesNamespaceMap[namespace] && ("production" !== 'production')) // removed by dead control flow
19760{}
19761    store._modulesNamespaceMap[namespace] = module;
19762  }
19763
19764  // set state
19765  if (!isRoot && !hot) {
19766    var parentState = getNestedState(rootState, path.slice(0, -1));
19767    var moduleName = path[path.length - 1];
19768    store._withCommit(function () {
19769      if ((false)) // removed by dead control flow
19770{}
19771      parentState[moduleName] = module.state;
19772    });
19773  }
19774
19775  var local = module.context = makeLocalContext(store, namespace, path);
19776
19777  module.forEachMutation(function (mutation, key) {
19778    var namespacedType = namespace + key;
19779    registerMutation(store, namespacedType, mutation, local);
19780  });
19781
19782  module.forEachAction(function (action, key) {
19783    var type = action.root ? key : namespace + key;
19784    var handler = action.handler || action;
19785    registerAction(store, type, handler, local);
19786  });
19787
19788  module.forEachGetter(function (getter, key) {
19789    var namespacedType = namespace + key;
19790    registerGetter(store, namespacedType, getter, local);
19791  });
19792
19793  module.forEachChild(function (child, key) {
19794    installModule(store, rootState, path.concat(key), child, hot);
19795  });
19796}
19797
19798/**
19799 * make localized dispatch, commit, getters and state
19800 * if there is no namespace, just use root ones
19801 */
19802function makeLocalContext (store, namespace, path) {
19803  var noNamespace = namespace === '';
19804
19805  var local = {
19806    dispatch: noNamespace ? store.dispatch : function (_type, _payload, _options) {
19807      var args = unifyObjectStyle(_type, _payload, _options);
19808      var payload = args.payload;
19809      var options = args.options;
19810      var type = args.type;
19811
19812      if (!options || !options.root) {
19813        type = namespace + type;
19814        if (false) // removed by dead control flow
19815{}
19816      }
19817
19818      return store.dispatch(type, payload)
19819    },
19820
19821    commit: noNamespace ? store.commit : function (_type, _payload, _options) {
19822      var args = unifyObjectStyle(_type, _payload, _options);
19823      var payload = args.payload;
19824      var options = args.options;
19825      var type = args.type;
19826
19827      if (!options || !options.root) {
19828        type = namespace + type;
19829        if (false) // removed by dead control flow
19830{}
19831      }
19832
19833      store.commit(type, payload, options);
19834    }
19835  };
19836
19837  // getters and state object must be gotten lazily
19838  // because they will be changed by state update
19839  Object.defineProperties(local, {
19840    getters: {
19841      get: noNamespace
19842        ? function () { return store.getters; }
19843        : function () { return makeLocalGetters(store, namespace); }
19844    },
19845    state: {
19846      get: function () { return getNestedState(store.state, path); }
19847    }
19848  });
19849
19850  return local
19851}
19852
19853function makeLocalGetters (store, namespace) {
19854  if (!store._makeLocalGettersCache[namespace]) {
19855    var gettersProxy = {};
19856    var splitPos = namespace.length;
19857    Object.keys(store.getters).forEach(function (type) {
19858      // skip if the target getter is not match this namespace
19859      if (type.slice(0, splitPos) !== namespace) { return }
19860
19861      // extract local getter type
19862      var localType = type.slice(splitPos);
19863
19864      // Add a port to the getters proxy.
19865      // Define as getter property because
19866      // we do not want to evaluate the getters in this time.
19867      Object.defineProperty(gettersProxy, localType, {
19868        get: function () { return store.getters[type]; },
19869        enumerable: true
19870      });
19871    });
19872    store._makeLocalGettersCache[namespace] = gettersProxy;
19873  }
19874
19875  return store._makeLocalGettersCache[namespace]
19876}
19877
19878function registerMutation (store, type, handler, local) {
19879  var entry = store._mutations[type] || (store._mutations[type] = []);
19880  entry.push(function wrappedMutationHandler (payload) {
19881    handler.call(store, local.state, payload);
19882  });
19883}
19884
19885function registerAction (store, type, handler, local) {
19886  var entry = store._actions[type] || (store._actions[type] = []);
19887  entry.push(function wrappedActionHandler (payload) {
19888    var res = handler.call(store, {
19889      dispatch: local.dispatch,
19890      commit: local.commit,
19891      getters: local.getters,
19892      state: local.state,
19893      rootGetters: store.getters,
19894      rootState: store.state
19895    }, payload);
19896    if (!isPromise(res)) {
19897      res = Promise.resolve(res);
19898    }
19899    if (store._devtoolHook) {
19900      return res.catch(function (err) {
19901        store._devtoolHook.emit('vuex:error', err);
19902        throw err
19903      })
19904    } else {
19905      return res
19906    }
19907  });
19908}
19909
19910function registerGetter (store, type, rawGetter, local) {
19911  if (store._wrappedGetters[type]) {
19912    if ((false)) // removed by dead control flow
19913{}
19914    return
19915  }
19916  store._wrappedGetters[type] = function wrappedGetter (store) {
19917    return rawGetter(
19918      local.state, // local state
19919      local.getters, // local getters
19920      store.state, // root state
19921      store.getters // root getters
19922    )
19923  };
19924}
19925
19926function enableStrictMode (store) {
19927  (0,vue_esm_bundler/* watch */.wB)(function () { return store._state.data; }, function () {
19928    if ((false)) // removed by dead control flow
19929{}
19930  }, { deep: true, flush: 'sync' });
19931}
19932
19933function getNestedState (state, path) {
19934  return path.reduce(function (state, key) { return state[key]; }, state)
19935}
19936
19937function unifyObjectStyle (type, payload, options) {
19938  if (isObject(type) && type.type) {
19939    options = payload;
19940    payload = type;
19941    type = type.type;
19942  }
19943
19944  if ((false)) // removed by dead control flow
19945{
vendor: 10,788 bytes, lines 19945-20336
19945}
19946
19947  return { type: type, payload: payload, options: options }
19948}
19949
19950var LABEL_VUEX_BINDINGS = 'vuex bindings';
19951var MUTATIONS_LAYER_ID = 'vuex:mutations';
19952var ACTIONS_LAYER_ID = 'vuex:actions';
19953var INSPECTOR_ID = 'vuex';
19954
19955var actionId = 0;
19956
19957function addDevtools (app, store) {
19958  setupDevtoolsPlugin(
19959    {
19960      id: 'org.vuejs.vuex',
19961      app: app,
19962      label: 'Vuex',
19963      homepage: 'https://next.vuex.vuejs.org/',
19964      logo: 'https://vuejs.org/images/icons/favicon-96x96.png',
19965      packageName: 'vuex',
19966      componentStateTypes: [LABEL_VUEX_BINDINGS]
19967    },
19968    function (api) {
19969      api.addTimelineLayer({
19970        id: MUTATIONS_LAYER_ID,
19971        label: 'Vuex Mutations',
19972        color: COLOR_LIME_500
19973      });
19974
19975      api.addTimelineLayer({
19976        id: ACTIONS_LAYER_ID,
19977        label: 'Vuex Actions',
19978        color: COLOR_LIME_500
19979      });
19980
19981      api.addInspector({
19982        id: INSPECTOR_ID,
19983        label: 'Vuex',
19984        icon: 'storage',
19985        treeFilterPlaceholder: 'Filter stores...'
19986      });
19987
19988      api.on.getInspectorTree(function (payload) {
19989        if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
19990          if (payload.filter) {
19991            var nodes = [];
19992            flattenStoreForInspectorTree(nodes, store._modules.root, payload.filter, '');
19993            payload.rootNodes = nodes;
19994          } else {
19995            payload.rootNodes = [
19996              formatStoreForInspectorTree(store._modules.root, '')
19997            ];
19998          }
19999        }
20000      });
20001
20002      api.on.getInspectorState(function (payload) {
20003        if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
20004          var modulePath = payload.nodeId;
20005          makeLocalGetters(store, modulePath);
20006          payload.state = formatStoreForInspectorState(
20007            getStoreModule(store._modules, modulePath),
20008            modulePath === 'root' ? store.getters : store._makeLocalGettersCache,
20009            modulePath
20010          );
20011        }
20012      });
20013
20014      api.on.editInspectorState(function (payload) {
20015        if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
20016          var modulePath = payload.nodeId;
20017          var path = payload.path;
20018          if (modulePath !== 'root') {
20019            path = modulePath.split('/').filter(Boolean).concat( path);
20020          }
20021          store._withCommit(function () {
20022            payload.set(store._state.data, path, payload.state.value);
20023          });
20024        }
20025      });
20026
20027      store.subscribe(function (mutation, state) {
20028        var data = {};
20029
20030        if (mutation.payload) {
20031          data.payload = mutation.payload;
20032        }
20033
20034        data.state = state;
20035
20036        api.notifyComponentUpdate();
20037        api.sendInspectorTree(INSPECTOR_ID);
20038        api.sendInspectorState(INSPECTOR_ID);
20039
20040        api.addTimelineEvent({
20041          layerId: MUTATIONS_LAYER_ID,
20042          event: {
20043            time: Date.now(),
20044            title: mutation.type,
20045            data: data
20046          }
20047        });
20048      });
20049
20050      store.subscribeAction({
20051        before: function (action, state) {
20052          var data = {};
20053          if (action.payload) {
20054            data.payload = action.payload;
20055          }
20056          action._id = actionId++;
20057          action._time = Date.now();
20058          data.state = state;
20059
20060          api.addTimelineEvent({
20061            layerId: ACTIONS_LAYER_ID,
20062            event: {
20063              time: action._time,
20064              title: action.type,
20065              groupId: action._id,
20066              subtitle: 'start',
20067              data: data
20068            }
20069          });
20070        },
20071        after: function (action, state) {
20072          var data = {};
20073          var duration = Date.now() - action._time;
20074          data.duration = {
20075            _custom: {
20076              type: 'duration',
20077              display: (duration + "ms"),
20078              tooltip: 'Action duration',
20079              value: duration
20080            }
20081          };
20082          if (action.payload) {
20083            data.payload = action.payload;
20084          }
20085          data.state = state;
20086
20087          api.addTimelineEvent({
20088            layerId: ACTIONS_LAYER_ID,
20089            event: {
20090              time: Date.now(),
20091              title: action.type,
20092              groupId: action._id,
20093              subtitle: 'end',
20094              data: data
20095            }
20096          });
20097        }
20098      });
20099    }
20100  );
20101}
20102
20103// extracted from tailwind palette
20104var COLOR_LIME_500 = 0x84cc16;
20105var COLOR_DARK = 0x666666;
20106var COLOR_WHITE = 0xffffff;
20107
20108var TAG_NAMESPACED = {
20109  label: 'namespaced',
20110  textColor: COLOR_WHITE,
20111  backgroundColor: COLOR_DARK
20112};
20113
20114/**
20115 * @param {string} path
20116 */
20117function extractNameFromPath (path) {
20118  return path && path !== 'root' ? path.split('/').slice(-2, -1)[0] : 'Root'
20119}
20120
20121/**
20122 * @param {*} module
20123 * @return {import('@vue/devtools-api').CustomInspectorNode}
20124 */
20125function formatStoreForInspectorTree (module, path) {
20126  return {
20127    id: path || 'root',
20128    // all modules end with a `/`, we want the last segment only
20129    // cart/ -> cart
20130    // nested/cart/ -> cart
20131    label: extractNameFromPath(path),
20132    tags: module.namespaced ? [TAG_NAMESPACED] : [],
20133    children: Object.keys(module._children).map(function (moduleName) { return formatStoreForInspectorTree(
20134        module._children[moduleName],
20135        path + moduleName + '/'
20136      ); }
20137    )
20138  }
20139}
20140
20141/**
20142 * @param {import('@vue/devtools-api').CustomInspectorNode[]} result
20143 * @param {*} module
20144 * @param {string} filter
20145 * @param {string} path
20146 */
20147function flattenStoreForInspectorTree (result, module, filter, path) {
20148  if (path.includes(filter)) {
20149    result.push({
20150      id: path || 'root',
20151      label: path.endsWith('/') ? path.slice(0, path.length - 1) : path || 'Root',
20152      tags: module.namespaced ? [TAG_NAMESPACED] : []
20153    });
20154  }
20155  Object.keys(module._children).forEach(function (moduleName) {
20156    flattenStoreForInspectorTree(result, module._children[moduleName], filter, path + moduleName + '/');
20157  });
20158}
20159
20160/**
20161 * @param {*} module
20162 * @return {import('@vue/devtools-api').CustomInspectorState}
20163 */
20164function formatStoreForInspectorState (module, getters, path) {
20165  getters = path === 'root' ? getters : getters[path];
20166  var gettersKeys = Object.keys(getters);
20167  var storeState = {
20168    state: Object.keys(module.state).map(function (key) { return ({
20169      key: key,
20170      editable: true,
20171      value: module.state[key]
20172    }); })
20173  };
20174
20175  if (gettersKeys.length) {
20176    var tree = transformPathsToObjectTree(getters);
20177    storeState.getters = Object.keys(tree).map(function (key) { return ({
20178      key: key.endsWith('/') ? extractNameFromPath(key) : key,
20179      editable: false,
20180      value: canThrow(function () { return tree[key]; })
20181    }); });
20182  }
20183
20184  return storeState
20185}
20186
20187function transformPathsToObjectTree (getters) {
20188  var result = {};
20189  Object.keys(getters).forEach(function (key) {
20190    var path = key.split('/');
20191    if (path.length > 1) {
20192      var target = result;
20193      var leafKey = path.pop();
20194      path.forEach(function (p) {
20195        if (!target[p]) {
20196          target[p] = {
20197            _custom: {
20198              value: {},
20199              display: p,
20200              tooltip: 'Module',
20201              abstract: true
20202            }
20203          };
20204        }
20205        target = target[p]._custom.value;
20206      });
20207      target[leafKey] = canThrow(function () { return getters[key]; });
20208    } else {
20209      result[key] = canThrow(function () { return getters[key]; });
20210    }
20211  });
20212  return result
20213}
20214
20215function getStoreModule (moduleMap, path) {
20216  var names = path.split('/').filter(function (n) { return n; });
20217  return names.reduce(
20218    function (module, moduleName, i) {
20219      var child = module[moduleName];
20220      if (!child) {
20221        throw new Error(("Missing module \"" + moduleName + "\" for path \"" + path + "\"."))
20222      }
20223      return i === names.length - 1 ? child : child._children
20224    },
20225    path === 'root' ? moduleMap : moduleMap.root._children
20226  )
20227}
20228
20229function canThrow (cb) {
20230  try {
20231    return cb()
20232  } catch (e) {
20233    return e
20234  }
20235}
20236
20237// Base data struct for store's module, package with some attribute and method
20238var Module = function Module (rawModule, runtime) {
20239  this.runtime = runtime;
20240  // Store some children item
20241  this._children = Object.create(null);
20242  // Store the origin module object which passed by programmer
20243  this._rawModule = rawModule;
20244  var rawState = rawModule.state;
20245
20246  // Store the origin module's state
20247  this.state = (typeof rawState === 'function' ? rawState() : rawState) || {};
20248};
20249
20250var prototypeAccessors$1 = { namespaced: { configurable: true } };
20251
20252prototypeAccessors$1.namespaced.get = function () {
20253  return !!this._rawModule.namespaced
20254};
20255
20256Module.prototype.addChild = function addChild (key, module) {
20257  this._children[key] = module;
20258};
20259
20260Module.prototype.removeChild = function removeChild (key) {
20261  delete this._children[key];
20262};
20263
20264Module.prototype.getChild = function getChild (key) {
20265  return this._children[key]
20266};
20267
20268Module.prototype.hasChild = function hasChild (key) {
20269  return key in this._children
20270};
20271
20272Module.prototype.update = function update (rawModule) {
20273  this._rawModule.namespaced = rawModule.namespaced;
20274  if (rawModule.actions) {
20275    this._rawModule.actions = rawModule.actions;
20276  }
20277  if (rawModule.mutations) {
20278    this._rawModule.mutations = rawModule.mutations;
20279  }
20280  if (rawModule.getters) {
20281    this._rawModule.getters = rawModule.getters;
20282  }
20283};
20284
20285Module.prototype.forEachChild = function forEachChild (fn) {
20286  forEachValue(this._children, fn);
20287};
20288
20289Module.prototype.forEachGetter = function forEachGetter (fn) {
20290  if (this._rawModule.getters) {
20291    forEachValue(this._rawModule.getters, fn);
20292  }
20293};
20294
20295Module.prototype.forEachAction = function forEachAction (fn) {
20296  if (this._rawModule.actions) {
20297    forEachValue(this._rawModule.actions, fn);
20298  }
20299};
20300
20301Module.prototype.forEachMutation = function forEachMutation (fn) {
20302  if (this._rawModule.mutations) {
20303    forEachValue(this._rawModule.mutations, fn);
20304  }
20305};
20306
20307Object.defineProperties( Module.prototype, prototypeAccessors$1 );
20308
20309var ModuleCollection = function ModuleCollection (rawRootModule) {
20310  // register root module (Vuex.Store options)
20311  this.register([], rawRootModule, false);
20312};
20313
20314ModuleCollection.prototype.get = function get (path) {
20315  return path.reduce(function (module, key) {
20316    return module.getChild(key)
20317  }, this.root)
20318};
20319
20320ModuleCollection.prototype.getNamespace = function getNamespace (path) {
20321  var module = this.root;
20322  return path.reduce(function (namespace, key) {
20323    module = module.getChild(key);
20324    return namespace + (module.namespaced ? key + '/' : '')
20325  }, '')
20326};
20327
20328ModuleCollection.prototype.update = function update$1 (rawRootModule) {
20329  update([], this.root, rawRootModule);
20330};
20331
20332ModuleCollection.prototype.register = function register (path, rawModule, runtime) {
20333    var this$1$1 = this;
20334    if ( runtime === void 0 ) runtime = true;
20335
20336  
vendor: 3,137 bytes, lines 20336-20465
20336if ((false)) // removed by dead control flow
20337{}
20338
20339  var newModule = new Module(rawModule, runtime);
20340  if (path.length === 0) {
20341    this.root = newModule;
20342  } else {
20343    var parent = this.get(path.slice(0, -1));
20344    parent.addChild(path[path.length - 1], newModule);
20345  }
20346
20347  // register nested modules
20348  if (rawModule.modules) {
20349    forEachValue(rawModule.modules, function (rawChildModule, key) {
20350      this$1$1.register(path.concat(key), rawChildModule, runtime);
20351    });
20352  }
20353};
20354
20355ModuleCollection.prototype.unregister = function unregister (path) {
20356  var parent = this.get(path.slice(0, -1));
20357  var key = path[path.length - 1];
20358  var child = parent.getChild(key);
20359
20360  if (!child) {
20361    if ((false)) // removed by dead control flow
20362{}
20363    return
20364  }
20365
20366  if (!child.runtime) {
20367    return
20368  }
20369
20370  parent.removeChild(key);
20371};
20372
20373ModuleCollection.prototype.isRegistered = function isRegistered (path) {
20374  var parent = this.get(path.slice(0, -1));
20375  var key = path[path.length - 1];
20376
20377  if (parent) {
20378    return parent.hasChild(key)
20379  }
20380
20381  return false
20382};
20383
20384function update (path, targetModule, newModule) {
20385  if ((false)) // removed by dead control flow
20386{}
20387
20388  // update target module
20389  targetModule.update(newModule);
20390
20391  // update nested modules
20392  if (newModule.modules) {
20393    for (var key in newModule.modules) {
20394      if (!targetModule.getChild(key)) {
20395        if ((false)) // removed by dead control flow
20396{}
20397        return
20398      }
20399      update(
20400        path.concat(key),
20401        targetModule.getChild(key),
20402        newModule.modules[key]
20403      );
20404    }
20405  }
20406}
20407
20408var functionAssert = {
20409  assert: function (value) { return typeof value === 'function'; },
20410  expected: 'function'
20411};
20412
20413var objectAssert = {
20414  assert: function (value) { return typeof value === 'function' ||
20415    (typeof value === 'object' && typeof value.handler === 'function'); },
20416  expected: 'function or object with "handler" function'
20417};
20418
20419var assertTypes = {
20420  getters: functionAssert,
20421  mutations: functionAssert,
20422  actions: objectAssert
20423};
20424
20425function assertRawModule (path, rawModule) {
20426  Object.keys(assertTypes).forEach(function (key) {
20427    if (!rawModule[key]) { return }
20428
20429    var assertOptions = assertTypes[key];
20430
20431    forEachValue(rawModule[key], function (value, type) {
20432      assert(
20433        assertOptions.assert(value),
20434        makeAssertionMessage(path, key, type, value, assertOptions.expected)
20435      );
20436    });
20437  });
20438}
20439
20440function makeAssertionMessage (path, key, type, value, expected) {
20441  var buf = key + " should be " + expected + " but \"" + key + "." + type + "\"";
20442  if (path.length > 0) {
20443    buf += " in module \"" + (path.join('.')) + "\"";
20444  }
20445  buf += " is " + (JSON.stringify(value)) + ".";
20446  return buf
20447}
20448
20449function createStore (options) {
20450  return new Store(options)
20451}
20452
20453var Store = function Store (options) {
20454  var this$1$1 = this;
20455  if ( options === void 0 ) options = {};
20456
20457  if ((false)) // removed by dead control flow
20458{}
20459
20460  var plugins = options.plugins; if ( plugins === void 0 ) plugins = [];
20461  var strict = options.strict; if ( strict === void 0 ) strict = false;
20462  var devtools = options.devtools;
20463
20464  // store internal state
20465  this._committing = false;
20466  this._actions = Object.create(null);
20467  this._actionSubscribers = [];
20468  this._mutations = Object.create(null);
20469  this._wrappedGetters = Object.create(null);
20470  this._modules = new ModuleCollection(options);
20471  this._modulesNamespaceMap = Object.create(null);
20472  this._subscribers = [];
20473  this._makeLocalGettersCache = Object.create(null);
20474
20475  // EffectScope instance. when registering new getters, we wrap them inside
20476  // EffectScope so that getters (computed) would not be destroyed on
20477  // component unmount.
20478  this._scope = null;
20479
20480  this._devtools = devtools;
20481
20482  // bind commit and dispatch to self
20483  var store = this;
20484  var ref = this;
20485  var dispatch = ref.dispatch;
20486  var commit = ref.commit;
20487  this.dispatch = function boundDispatch (type, payload) {
20488    return dispatch.call(store, type, payload)
20489  };
20490  this.commit = function boundCommit (type, payload, options) {
20491    return commit.call(store, type, payload, options)
20492  };
20493
20494  // strict mode
20495  this.strict = strict;
20496
20497  var state = this._modules.root.state;
20498
20499  // init root module.
20500  // this also recursively registers all sub-modules
20501  // and collects all module getters inside this._wrappedGetters
20502  installModule(this, state, [], this._modules.root);
20503
20504  // initialize the store state, which is responsible for the reactivity
20505  // (also registers _wrappedGetters as computed properties)
20506  resetStoreState(this, state);
20507
20508  // apply plugins
20509  plugins.forEach(function (plugin) { return plugin(this$1$1); });
20510};
20511
20512var prototypeAccessors = { state: { configurable: true } };
20513
20514Store.prototype.install = function install (app, injectKey) {
20515  app.provide(injectKey || storeKey, this);
20516  app.config.globalProperties.$store = this;
20517
20518  var useDevtools = this._devtools !== undefined
20519    ? this._devtools
20520    : ( false) || __VUE_PROD_DEVTOOLS__;
20521
20522  if (useDevtools) {
20523    addDevtools(app, this);
20524  }
20525};
20526
20527prototypeAccessors.state.get = function () {
20528  return this._state.data
20529};
20530
20531prototypeAccessors.state.set = function (v) {
20532  if ((false)) // removed by dead control flow
20533{}
20534};
20535
20536Store.prototype.commit = function commit (_type, _payload, _options) {
20537    var this$1$1 = this;
20538
20539  // check object-style commit
20540  var ref = unifyObjectStyle(_type, _payload, _options);
20541    var type = ref.type;
20542    var payload = ref.payload;
20543    var options = ref.options;
20544
20545  var mutation = { type: type, payload: payload };
20546  var entry = this._mutations[type];
20547  if (!entry) {
20548    if ((false)) // removed by dead control flow
20549{}
20550    return
20551  }
20552  this._withCommit(function () {
20553    entry.forEach(function commitIterator (handler) {
20554      handler(payload);
20555    });
20556  });
20557
20558  this._subscribers
20559    .slice() // shallow copy to prevent iterator invalidation if subscriber synchronously calls unsubscribe
20560    .forEach(function (sub) { return sub(mutation, this$1$1.state); });
20561
20562  if (
20563    false
20564  ) // removed by dead control flow
20565{}
20566};
20567
20568Store.prototype.dispatch = function dispatch (_type, _payload) {
20569    var this$1$1 = this;
20570
20571  // check object-style dispatch
20572  var ref = unifyObjectStyle(_type, _payload);
20573    var type = ref.type;
20574    var payload = ref.payload;
20575
20576  var action = { type: type, payload: payload };
20577  var entry = this._actions[type];
20578  if (!entry) {
20579    if ((false)) // removed by dead control flow
20580{}
20581    return
20582  }
20583
20584  try {
20585    this._actionSubscribers
20586      .slice() // shallow copy to prevent iterator invalidation if subscriber synchronously calls unsubscribe
20587      .filter(function (sub) { return sub.before; })
20588      .forEach(function (sub) { return sub.before(action, this$1$1.state); });
20589  } catch (e) {
20590    if ((false)) // removed by dead control flow
20591{}
20592  }
20593
20594  var result = entry.length > 1
20595    ? Promise.all(entry.map(function (handler) { return handler(payload); }))
20596    : entry[0](payload);
20597
20598  return new Promise(function (resolve, reject) {
20599    result.then(function (res) {
20600      try {
20601        this$1$1._actionSubscribers
20602          .filter(function (sub) { return sub.after; })
20603          .forEach(function (sub) { return sub.after(action, this$1$1.state); });
20604      } catch (e) {
20605        if ((false)) // removed by dead control flow
20606{}
20607      }
20608      resolve(res);
20609    }, function (error) {
20610      try {
20611        this$1$1._actionSubscribers
20612          .filter(function (sub) { return sub.error; })
20613          .forEach(function (sub) { return sub.error(action, this$1$1.state, error); });
20614      } catch (e) {
20615        if ((false)) // removed by dead control flow
20616{}
20617      }
20618      reject(error);
20619    });
20620  })
20621};
20622
20623Store.prototype.subscribe = function subscribe (fn, options) {
20624  return genericSubscribe(fn, this._subscribers, options)
20625};
20626
20627Store.prototype.subscribeAction = function subscribeAction (fn, options) {
20628  var subs = typeof fn === 'function' ? { before: fn } : fn;
20629  return genericSubscribe(subs, this._actionSubscribers, options)
20630};
20631
20632Store.prototype.watch = function watch$1 (getter, cb, options) {
20633    var this$1$1 = this;
20634
20635  if ((false)) // removed by dead control flow
20636{}
20637  return (0,vue_esm_bundler/* watch */.wB)(function () { return getter(this$1$1.state, this$1$1.getters); }, cb, Object.assign({}, options))
20638};
20639
20640Store.prototype.replaceState = function replaceState (state) {
20641    var this$1$1 = this;
20642
20643  this._withCommit(function () {
20644    this$1$1._state.data = state;
20645  });
20646};
20647
20648Store.prototype.registerModule = function registerModule (path, rawModule, options) {
20649    if ( options === void 0 ) options = {};
20650
20651  if (typeof path === 'string') { path = [path]; }
20652
20653  if ((false)) // removed by dead control flow
20654{}
20655
20656  this._modules.register(path, rawModule);
20657  installModule(this, this.state, path, this._modules.get(path), options.preserveState);
20658  // reset store to update getters...
20659  resetStoreState(this, this.state);
20660};
20661
20662Store.prototype.unregisterModule = function unregisterModule (path) {
20663    var this$1$1 = this;
20664
20665  if (typeof path === 'string') { path = [path]; }
20666
20667  if ((false)) // removed by dead control flow
20668{}
20669
20670  this._modules.unregister(path);
20671  this._withCommit(function () {
20672    var parentState = getNestedState(this$1$1.state, path.slice(0, -1));
20673    delete parentState[path[path.length - 1]];
20674  });
20675  resetStore(this);
20676};
20677
20678Store.prototype.hasModule = function hasModule (path) {
20679  if (typeof path === 'string') { path = [path]; }
20680
20681  if ((false)) // removed by dead control flow
20682{}
20683
20684  return this._modules.isRegistered(path)
20685};
20686
20687Store.prototype.hotUpdate = function hotUpdate (newOptions) {
20688  this._modules.update(newOptions);
20689  resetStore(this, true);
20690};
20691
20692Store.prototype._withCommit = function _withCommit (fn) {
20693  var committing = this._committing;
20694  this._committing = true;
20695  fn();
20696  this._committing = committing;
20697};
20698
20699Object.defineProperties( Store.prototype, prototypeAccessors );
20700
20701/**
20702 * Reduce the code which written in Vue.js for getting the state.
20703 * @param {String} [namespace] - Module's namespace
20704 * @param {Object|Array} states # Object's item can be a function which accept state and getters for param, you can do something for state and getters in it.
20705 * @param {Object}
20706 */
20707var mapState = normalizeNamespace(function (namespace, states) {
20708  var res = {};
20709  if (false) // removed by dead control flow
20710{}
20711  normalizeMap(states).forEach(function (ref) {
20712    var key = ref.key;
20713    var val = ref.val;
20714
20715    res[key] = function mappedState () {
20716      var state = this.$store.state;
20717      var getters = this.$store.getters;
20718      if (namespace) {
20719        var module = getModuleByNamespace(this.$store, 'mapState', namespace);
20720        if (!module) {
20721          return
20722        }
20723        state = module.context.state;
20724        getters = module.context.getters;
20725      }
20726      return typeof val === 'function'
20727        ? val.call(this, state, getters)
20728        : state[val]
20729    };
20730    // mark vuex getter for devtools
20731    res[key].vuex = true;
20732  });
20733  return res
20734});
20735
20736/**
20737 * Reduce the code which written in Vue.js for committing the mutation
20738 * @param {String} [namespace] - Module's namespace
20739 * @param {Object|Array} mutations # Object's item can be a function which accept `commit` function as the first param, it can accept another params. You can commit mutation and do any other things in this function. specially, You need to pass anthor params from the mapped function.
20740 * @return {Object}
20741 */
20742var mapMutations = normalizeNamespace(function (namespace, mutations) {
20743  var res = {};
20744  if (false) // removed by dead control flow
20745{}
vendor: 4,265 bytes, lines 20746-20880
20746  normalizeMap(mutations).forEach(function (ref) {
20747    var key = ref.key;
20748    var val = ref.val;
20749
20750    res[key] = function mappedMutation () {
20751      var args = [], len = arguments.length;
20752      while ( len-- ) args[ len ] = arguments[ len ];
20753
20754      // Get the commit method from store
20755      var commit = this.$store.commit;
20756      if (namespace) {
20757        var module = getModuleByNamespace(this.$store, 'mapMutations', namespace);
20758        if (!module) {
20759          return
20760        }
20761        commit = module.context.commit;
20762      }
20763      return typeof val === 'function'
20764        ? val.apply(this, [commit].concat(args))
20765        : commit.apply(this.$store, [val].concat(args))
20766    };
20767  });
20768  return res
20769});
20770
20771/**
20772 * Reduce the code which written in Vue.js for getting the getters
20773 * @param {String} [namespace] - Module's namespace
20774 * @param {Object|Array} getters
20775 * @return {Object}
20776 */
20777var mapGetters = normalizeNamespace(function (namespace, getters) {
20778  var res = {};
20779  if (false) // removed by dead control flow
20780{}
20781  normalizeMap(getters).forEach(function (ref) {
20782    var key = ref.key;
20783    var val = ref.val;
20784
20785    // The namespace has been mutated by normalizeNamespace
20786    val = namespace + val;
20787    res[key] = function mappedGetter () {
20788      if (namespace && !getModuleByNamespace(this.$store, 'mapGetters', namespace)) {
20789        return
20790      }
20791      if (false) // removed by dead control flow
20792{}
20793      return this.$store.getters[val]
20794    };
20795    // mark vuex getter for devtools
20796    res[key].vuex = true;
20797  });
20798  return res
20799});
20800
20801/**
20802 * Reduce the code which written in Vue.js for dispatch the action
20803 * @param {String} [namespace] - Module's namespace
20804 * @param {Object|Array} actions # Object's item can be a function which accept `dispatch` function as the first param, it can accept anthor params. You can dispatch action and do any other things in this function. specially, You need to pass anthor params from the mapped function.
20805 * @return {Object}
20806 */
20807var mapActions = normalizeNamespace(function (namespace, actions) {
20808  var res = {};
20809  if (false) // removed by dead control flow
20810{}
20811  normalizeMap(actions).forEach(function (ref) {
20812    var key = ref.key;
20813    var val = ref.val;
20814
20815    res[key] = function mappedAction () {
20816      var args = [], len = arguments.length;
20817      while ( len-- ) args[ len ] = arguments[ len ];
20818
20819      // get dispatch function from store
20820      var dispatch = this.$store.dispatch;
20821      if (namespace) {
20822        var module = getModuleByNamespace(this.$store, 'mapActions', namespace);
20823        if (!module) {
20824          return
20825        }
20826        dispatch = module.context.dispatch;
20827      }
20828      return typeof val === 'function'
20829        ? val.apply(this, [dispatch].concat(args))
20830        : dispatch.apply(this.$store, [val].concat(args))
20831    };
20832  });
20833  return res
20834});
20835
20836/**
20837 * Rebinding namespace param for mapXXX function in special scoped, and return them by simple object
20838 * @param {String} namespace
20839 * @return {Object}
20840 */
20841var createNamespacedHelpers = function (namespace) { return ({
20842  mapState: mapState.bind(null, namespace),
20843  mapGetters: mapGetters.bind(null, namespace),
20844  mapMutations: mapMutations.bind(null, namespace),
20845  mapActions: mapActions.bind(null, namespace)
20846}); };
20847
20848/**
20849 * Normalize the map
20850 * normalizeMap([1, 2, 3]) => [ { key: 1, val: 1 }, { key: 2, val: 2 }, { key: 3, val: 3 } ]
20851 * normalizeMap({a: 1, b: 2, c: 3}) => [ { key: 'a', val: 1 }, { key: 'b', val: 2 }, { key: 'c', val: 3 } ]
20852 * @param {Array|Object} map
20853 * @return {Object}
20854 */
20855function normalizeMap (map) {
20856  if (!isValidMap(map)) {
20857    return []
20858  }
20859  return Array.isArray(map)
20860    ? map.map(function (key) { return ({ key: key, val: key }); })
20861    : Object.keys(map).map(function (key) { return ({ key: key, val: map[key] }); })
20862}
20863
20864/**
20865 * Validate whether given map is valid or not
20866 * @param {*} map
20867 * @return {Boolean}
20868 */
20869function isValidMap (map) {
20870  return Array.isArray(map) || isObject(map)
20871}
20872
20873/**
20874 * Return a function expect two param contains namespace and map. it will normalize the namespace and then the param's function will handle the new namespace and the map.
20875 * @param {Function} fn
20876 * @return {Function}
20877 */
20878function normalizeNamespace (fn) {
20879  return function (namespace, map) {
20880    if (typeof namespace !== 'string') {
20881      map = namespace;
20882      namespace = '';
20883    } else if (namespace.charAt(namespace.length - 1) !== '/') {
20884      namespace += '/';
20885    }
20886    return fn(namespace, map)
20887  }
20888}
20889
20890/**
20891 * Search a special module from store by namespace. if module not exist, print error message.
20892 * @param {Object} store
20893 * @param {String} helper
20894 * @param {String} namespace
20895 * @return {Object}
20896 */
20897function getModuleByNamespace (store, helper, namespace) {
20898  var module = store._modulesNamespaceMap[namespace];
20899  if (false) // removed by dead control flow
20900{}
20901  return module
20902}
20903
20904// Credits: borrowed code from fcomb/redux-logger
20905
20906function createLogger (ref) {
20907  if ( ref === void 0 ) ref = {};
20908  var collapsed = ref.collapsed; if ( collapsed === void 0 ) collapsed = true;
20909  var filter = ref.filter; if ( filter === void 0 ) filter = function (mutation, stateBefore, stateAfter) { return true; };
20910  var transformer = ref.transformer; if ( transformer === void 0 ) transformer = function (state) { return state; };
20911  var mutationTransformer = ref.mutationTransformer; if ( mutationTransformer === void 0 ) mutationTransformer = function (mut) { return mut; };
20912  var actionFilter = ref.actionFilter; if ( actionFilter === void 0 ) actionFilter = function (action, state) { return true; };
20913  var actionTransformer = ref.actionTransformer; if ( actionTransformer === void 0 ) actionTransformer = function (act) { return act; };
20914  var logMutations = ref.logMutations; if ( logMutations === void 0 ) logMutations = true;
20915  var logActions = ref.logActions; if ( logActions === void 0 ) logActions = true;
20916  var logger = ref.logger; if ( logger === void 0 ) logger = console;
20917
20918  return function (store) {
20919    var prevState = deepCopy(store.state);
20920
20921    if (typeof logger === 'undefined') {
20922      return
20923    }
20924
20925    if (logMutations) {
20926      store.subscribe(function (mutation, state) {
20927        var nextState = deepCopy(state);
20928
20929        if (filter(mutation, prevState, nextState)) {
20930          var formattedTime = getFormattedTime();
20931          var formattedMutation = mutationTransformer(mutation);
20932          var message = "mutation " + (mutation.type) + formattedTime;
20933
20934          startMessage(logger, message, collapsed);
20935          logger.log('%c prev state', 'color: #9E9E9E; font-weight: bold', transformer(prevState));
20936          logger.log('%c mutation', 'color: #03A9F4; font-weight: bold', formattedMutation);
20937          logger.log('%c next state', 'color: #4CAF50; font-weight: bold', transformer(nextState));
20938          endMessage(logger);
20939        }
20940
20941        prevState = nextState;
20942      });
20943    }
20944
20945    if (logActions) {
20946      store.subscribeAction(function (action, state) {
20947        if (actionFilter(action, state)) {
20948          var formattedTime = getFormattedTime();
20949          var formattedAction = actionTransformer(action);
20950          var message = "action " + (action.type) + formattedTime;
20951
20952          startMessage(logger, message, collapsed);
20953          logger.log('%c action', 'color: #03A9F4; font-weight: bold', formattedAction);
20954          endMessage(logger);
20955        }
20956      });
20957    }
20958  }
20959}
20960
20961function startMessage (logger, message, collapsed) {
20962  var startMessage = collapsed
20963    ? logger.groupCollapsed
20964    : logger.group;
20965
20966  // render
20967  try {
20968    startMessage.call(logger, message);
20969  } catch (e) {
20970    logger.log(message);
20971  }
20972}
20973
20974function endMessage (logger) {
20975  try {
20976    logger.groupEnd();
20977  } catch (e) {
20978    logger.log('—— log end ——');
20979  }
20980}
20981
20982function getFormattedTime () {
20983  var time = new Date();
20984  return (" @ " + (pad(time.getHours(), 2)) + ":" + (pad(time.getMinutes(), 2)) + ":" + (pad(time.getSeconds(), 2)) + "." + (pad(time.getMilliseconds(), 3)))
20985}
20986
20987function repeat (str, times) {
20988  return (new Array(times + 1)).join(str)
20989}
20990
20991function pad (num, maxLength) {
20992  return repeat('0', maxLength - num.toString().length) + num
20993}
20994
20995var index = {
20996  version: '4.1.0',
20997  Store: Store,
20998  storeKey: storeKey,
20999  createStore: createStore,
21000  useStore: useStore,
21001  mapState: mapState,
21002  mapMutations: mapMutations,
21003  mapGetters: mapGetters,
21004  mapActions: mapActions,
21005  createNamespacedHelpers: createNamespacedHelpers,
21006  createLogger: createLogger
21007};
21008
21009/* harmony default export */ const vuex_esm_bundler = ((/* unused pure expression or super */ null && (index)));
21010
21011
21012
21013/***/ },
21014
21015/***/ 2580
21016(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
21017
21018"use strict";
21019
21020// EXPORTS
21021__webpack_require__.d(__webpack_exports__, {
21022  A: () => (/* binding */ Button)
21023});
21024
21025// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 6 modules
21026var vue_esm_bundler = __webpack_require__(1425);
21027;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Button.vue?vue&type=template&id=115f418a
21028
21029
21030const _hoisted_1 = ["disabled", "tabindex", "href"]
21031const _hoisted_2 = ["disabled", "tabindex"]
21032
21033function render(_ctx, _cache, $props, $setup, $data, $options) {
21034  return ($props.href)
21035    ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("button", {
21036        key: 0,
21037        disabled: $props.disabled,
21038        tabindex: $props.tabindex,
21039        onClick: _cache[0] || (_cache[0] = $event => ($options.goToLocation())),
21040        href: $props.href,
21041        class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-button ' + $options.classes)
21042      }, [
21043        ($props.icon)
21044          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("i", {
21045              key: 0,
21046              class: (0,vue_esm_bundler/* normalizeClass */.C4)($props.icon + ' ' + $props.iconClass + ' ' + ($data.hasContent && !$props.disableIconSpace ? 'mr-2' : ''))
21047            }, null, 2 /* CLASS */))
21048          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
21049        (0,vue_esm_bundler/* renderSlot */.RG)(_ctx.$slots, "default")
21050      ], 10 /* CLASS, PROPS */, _hoisted_1))
21051    : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("button", (0,vue_esm_bundler/* mergeProps */.v6)({
21052        key: 1,
21053        disabled: $props.disabled,
21054        tabindex: $props.tabindex
21055      }, _ctx.$attrs, {
21056        class: 'sp-button ' + $options.classes
21057      }), [
21058        ($props.icon)
21059          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("i", {
21060              key: 0,
21061              class: (0,vue_esm_bundler/* normalizeClass */.C4)($props.icon + ' ' + $props.iconClass + ' ' + ($data.hasContent && !$props.disableIconSpace ? 'mr-2' : ''))
21062            }, null, 2 /* CLASS */))
21063          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
21064        (0,vue_esm_bundler/* renderSlot */.RG)(_ctx.$slots, "default")
21065      ], 16 /* FULL_PROPS */, _hoisted_2))
21066}
21067;// ./vue/components/Button.vue?vue&type=template&id=115f418a
21068
21069;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Button.vue?vue&type=script&lang=js
21070
21071/* harmony default export */ const Buttonvue_type_script_lang_js = ({
21072	name: 'Button',
21073	props: {
21074		type: String,
21075		align: String,
21076		disabled: Boolean,
21077		icon: String,
21078		iconClass: String,
21079		href: String,
21080		tabindex: Number,
21081		disableIconSpace: {
21082			type: Boolean,
21083			default: false
21084		}
21085	},
21086	data() {
21087		return {
21088			label: '',
21089			hasContent: false
21090		}
21091	},
21092	methods: {
21093		goToLocation() {
21094			window.location.href = this.href;
21095		}
21096	},
21097	computed: {
21098		classes() {
21099			let classes = [];
21100			if (this.type) classes.push('sp-button--type-'+this.type);
21101			if (this.disabled) classes.push('sp-button--disabled');
21102			if (this.align) classes.push('text-'+this.align);
21103			return classes.join(' ');
21104		}
21105	},
21106	mounted() {
21107		if (this.$slots.default) this.hasContent = true;
21108	}
21109});
21110
21111;// ./vue/components/Button.vue?vue&type=script&lang=js
21112 
21113// EXTERNAL MODULE: ./node_modules/vue-loader/dist/exportHelper.js
21114var exportHelper = __webpack_require__(6262);
21115;// ./vue/components/Button.vue
21116
21117
21118
21119
21120;
21121const __exports__ = /*#__PURE__*/(0,exportHelper/* default */.A)(Buttonvue_type_script_lang_js, [['render',render]])
21122
21123/* harmony default export */ const Button = (__exports__);
21124
21125/***/ },
21126
21127/***/ 3133
21128(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
21129
21130"use strict";
21131/* harmony export */ __webpack_require__.d(__webpack_exports__, {
21132/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
21133/* harmony export */ });
21134/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
21135    methods: {
21136        formatPrice(price, formatZero) {
21137
21138			const currencySymbols = {
21139				"AUD": "$",
21140				"BGN": "лв",
21141				"CAD": "$",
21142				"CHF": "CHF",
21143				"CNY": "Â¥",
21144				"CZK": "Kč",
21145				"DKK": "kr",
21146				"EUR": "€",
21147				"GBP": "£",
21148				"HKD": "$",
21149				"HRK": "kn",
21150				"HUF": "Ft",
21151				"JPY": "Â¥",
21152				"MDL": "L",
21153				"NOK": "kr",
21154				"NZD": "$",
21155				"PLN": "zł",
21156				"RON": "lei",
21157				"RSD": "дин",
21158				"RUB": "₽",
21159				"SEK": "kr",
21160				"TRY": "₺",
21161				"UAH": "₴",
21162				"USD": "$"
21163			};
21164
21165			let currencySymbol = currencySymbols[SP_CONSTANTS.SHOP.CURRENCY_CODE];
21166
21167			if (price || (formatZero && price === 0)) {
21168				let priceFixed = price.toFixed(2);
21169				priceFixed = priceFixed.replace('.', ',');
21170				priceFixed = priceFixed.replace(/\B(?=(\d{3})+(?!\d))/g, '.');
21171				return currencySymbol + ' ' + priceFixed;
21172				// return currencySymbol + ' ' + price.toFixed(2).replace('.', ',');
21173			} else {
21174				return 0;
21175			}
21176        },
21177        formatDate(value) {
21178
21179			let date = new Date(value);
21180			let dateLocale, dateOptions;
21181
21182			switch (SP_CONSTANTS.LOCALE) {
21183				case 'de':
21184					dateLocale = 'de-DE';
21185					dateOptions = {
21186						weekday: 'long',
21187						year: 'numeric',
21188						month: '2-digit',
21189						day: '2-digit',
21190						hour: '2-digit',
21191						minute: '2-digit'
21192					}
21193					break;
21194			
21195				default:
21196
21197					dateLocale = 'en-US';
21198					dateOptions = {
21199						weekday: 'long',
21200						year: 'numeric',
21201						month: 'short',
21202						day: '2-digit',
21203						hour: 'numeric',
21204						minute: '2-digit'
21205					}
21206
21207					break;
21208			}
21209
21210			return date.toLocaleDateString(dateLocale, dateOptions);
21211
21212		},
21213    }
21214});
21215
21216
21217/***/ },
21218
21219/***/ 3285
21220(module, __webpack_exports__, __webpack_require__) {
21221
21222"use strict";
21223/* harmony export */ __webpack_require__.d(__webpack_exports__, {
21224/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
21225/* harmony export */ });
21226/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1601);
21227/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
21228/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6314);
21229/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
21230// Imports
21231
21232
21233var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
21234// Module
21235___CSS_LOADER_EXPORT___.push([module.id, `
21236.c-o-i__focus-anchor[data-v-26d6dc2e] {
21237	position: absolute;
21238	width: 1px;
21239	height: 1px;
21240	overflow: hidden;
21241	clip: rect(0, 0, 0, 0);
21242	white-space: nowrap;
21243}
21244.c-o-i[data-v-26d6dc2e] {
21245	position: fixed;
21246	left: calc(50% - 250px);
21247	top: 0;
21248	width: 500px;
21249	max-height: 95vh;
21250	overflow-y: auto;
21251	overscroll-behavior: contain;
21252}
21253@media (max-width: 767px) {
21254.c-o-i[data-v-26d6dc2e] {
21255		width: 80vw;
21256		left: 10vw;
21257		max-height: 85dvh;
21258}
21259}
21260.c-o-i__settings[data-v-26d6dc2e] {
21261	text-align: center;
21262	display: block;
21263	cursor: pointer;
21264}
21265.c-o-i__legal-links[data-v-26d6dc2e] {
21266	text-align: center;
21267	margin-top: 12px;
21268}
21269.c-o-i__legal-links a[data-v-26d6dc2e] {
21270	margin: 0 8px;
21271}
21272.c-o-i-wrapper[data-v-26d6dc2e] {
21273	position: fixed;
21274	left: 0;
21275	top: 0;
21276	width: 100%;
21277	height: 100%;
21278	background-color: rgba(0, 0, 0, 0.5);
21279	z-index: 99999999;
21280}
21281.c-o-i input[type="checkbox"][data-v-26d6dc2e] {
21282	margin-left: 10px;
21283}
21284.c-o-i input[type="checkbox"][data-v-26d6dc2e]:first-child {
21285	margin-left: 0;
21286}
21287.c-o-i input[type="submit"][data-v-26d6dc2e] {
21288	width: 100%;
21289	margin-top: 10px;
21290	border: 0;
21291}
21292.c-o-i input[type="submit"][data-v-26d6dc2e]:hover,
21293.c-o-i input[type="submit"][data-v-26d6dc2e]:focus-visible,
21294.c-o-i input[type="submit"][data-v-26d6dc2e]:focus {
21295	background-color: #333;
21296	color: #fff;
21297}
21298
21299/* ADVANCED */
21300.c-o-i__view-advanced[data-v-26d6dc2e] {
21301	overflow-y: auto;
21302	max-height: 30vh;
21303}
21304.c-o-i__detail p[data-v-26d6dc2e] {
21305	margin-bottom: 0;
21306}
21307input[type="submit"][data-v-26d6dc2e] {
21308	cursor: pointer;
21309}
21310
21311`, ""]);
21312// Exports
21313/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
21314
21315
21316/***/ },
21317
21318/***/ 3565
21319(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
21320
21321"use strict";
21322/* harmony export */ __webpack_require__.d(__webpack_exports__, {
21323/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
21324/* harmony export */ });
21325/* harmony import */ var whatwg_fetch__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8624);
21326/* harmony import */ var whatwg_fetch__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(whatwg_fetch__WEBPACK_IMPORTED_MODULE_0__);
21327
21328
21329class APIClient {
21330
21331	constructor(store) {
21332		this._method = 'GET';
21333		this._data = '';
21334		this._object = {};
21335		// No Content-Type by default: GET requests carry no body, and declaring one
21336		// there would only cost a CORS preflight. call() derives the header from
21337		// _contentType whenever a body is actually sent.
21338		this._headers = {};
21339		this._contentType = 'json';
21340		this._store = store;
21341		this._basepath = SP_CONSTANTS.SHOP.API_PATH +'/';
21342
21343		if (SP_CONSTANTS.SHOP.ID) {
21344			this._path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/';
21345		} else {
21346			this._path = '';
21347		}
21348	}
21349
21350	set method(method) {
21351		this._method = method;
21352	}
21353
21354	set data(data) {
21355		this._data = data;
21356		// console.warn('APICaller.data is deprecated');
21357	}
21358
21359	set object(object) {
21360		this._object = object;
21361	}
21362
21363	// Merges instead of replacing, so a call site that only wants to add
21364	// Authorization or Accept-Language cannot silently drop the rest.
21365	set headers(headers) {
21366		this._headers = {...this._headers, ...headers};
21367	}
21368
21369	hasContentType(headers) {
21370		return Object.keys(headers).some(name => name.toLowerCase() == 'content-type');
21371	}
21372
21373	set contentType(headers) {
21374		this._contentType = headers;
21375	}
21376
21377	set path(path) {
21378		this._path = path;
21379	}
21380
21381	set basepath(basepath) {
21382		this._basepath = basepath;
21383	}
21384
21385	serialize(obj, prefix) {
21386	  var str = [],
21387	    p;
21388	  for (p in obj) {
21389	    if (obj.hasOwnProperty(p)) {
21390	      var k = prefix ? prefix + "[" + p + "]" : p,
21391	        v = obj[p];
21392	      str.push((v !== null && typeof v === "object") ?
21393	        this.serialize(v, k) :
21394	        encodeURIComponent(k) + "=" + encodeURIComponent(v));
21395	    }
21396	  }
21397	  return str.join("&");
21398	}
21399
21400	async call(callback) {
21401		let urlPath = '';
21402		let serializedData = (this._object && Object.keys(this._object).length > 0) ? this.serialize(this._object) : '';
21403
21404		let fetchConfig = {
21405			method: this._method,
21406			headers: {...this._headers}
21407		};
21408
21409		if (this._method == 'GET') {
21410			urlPath = (serializedData) ? '?'+serializedData : '';
21411		} else if (serializedData) {
21412			fetchConfig.body = (this._contentType == 'urlencoded') ? serializedData : JSON.stringify(this._object);
21413		}
21414		if (this._data && this._data != '') {
21415			fetchConfig.body = this._data;
21416		}
21417
21418		// Declaring the body's real type matters beyond correctness: Cloud Armor only
21419		// splits a request body into fields when the content type says JSON, and its
21420		// WAF exclusions (the one for `password`, for instance) key on those field
21421		// names. Without the header the whole body is inspected as a single argument
21422		// name, which is what got customer logins denied with a 403.
21423		if (typeof fetchConfig.body !== 'undefined' && !this.hasContentType(fetchConfig.headers)) {
21424			fetchConfig.headers['Content-Type'] = (this._contentType == 'urlencoded')
21425				? 'application/x-www-form-urlencoded'
21426				: 'application/json';
21427		}
21428
21429		// if (this._store && this._store.getters.token && this._store.getters.token.length > 0) {
21430		// 	fetchConfig.headers.Authorization = 'Bearer ' + this._store.getters.token;
21431		// }
21432
21433
21434		return await window.fetch(this._basepath + this._path + urlPath, fetchConfig)
21435		.then(async (response) => {
21436			let contentType = response.headers.get('Content-Type');
21437			if (contentType && (contentType.includes('image') || contentType.includes('pdf'))) {
21438				return [await response.blob(), 'no-parse'];
21439			} else {
21440				return [await response.text(), 'parse'];
21441			}
21442		})
21443		.then((message) => {
21444			try {
21445				if (message && message[1] == 'parse') {
21446					var data = JSON.parse(message[0]);
21447				} else {
21448					var data = message[0];
21449				}
21450			} catch (e) {
21451
21452				let apiError = new CustomEvent('apiError', {detail: 'API SYNTAX ERROR!'});
21453				document.dispatchEvent(apiError);
21454				console.warn('API SYNTAX ERROR: '+ message[0]);
21455				return data;
21456			}
21457
21458			// A payment was already committed for this checkout but no order exists yet.
21459			// This can be returned by a payment-init endpoint (e.g. stripe/paymentIntents)
21460			// or by a checkout PATCH. Signal the checkout UI to finalize the existing
21461			// payment via order/create instead of surfacing it as a hard error.
21462			if (data && typeof data === 'object' && data.code === 'CHECKOUT_ALREADY_HAS_PAYMENT') {
21463				let alreadyPaidEvent = new CustomEvent('checkoutAlreadyHasPayment', {detail: data});
21464				document.dispatchEvent(alreadyPaidEvent);
21465			}
21466
21467			// The stored payment authorization is no longer valid (expired / canceled at
21468			// the provider). The backend has dropped the params from the checkout; signal
21469			// the checkout UI to clear its local authorization too, so the customer can
21470			// pay again or pick another method instead of re-sending stale params.
21471			if (data && typeof data === 'object' && data.code === 'PAYMENT_AUTHORIZATION_EXPIRED') {
21472				let authExpiredEvent = new CustomEvent('checkoutAuthorizationExpired', {detail: data});
21473				document.dispatchEvent(authExpiredEvent);
21474			}
21475
21476			return data;
21477		})
21478		.then(callback);
21479	}
21480
21481	// static async getList(path, data, store) {
21482	// 	let filtersByField = {};
21483	// 	for (let filter of data.filters) {
21484	// 		if (filter.operator && filter.value) {
21485	// 			filtersByField[filter.field] = filter.operator + '.' + filter.value;
21486	// 		}
21487	// 	}
21488	// 	delete data.filters;
21489	//
21490	// 	let api = new this(store);
21491	// 	api.path = api._path + path;
21492	// 	api.object = {...data, ...filtersByField};
21493	// 	return await api.call(data => data);
21494	// }
21495	//
21496	// static async getItem(path, data, store) {
21497	// 	let api = new this(store);
21498	// 	api.path = api._path + path;
21499	// 	api.object = data;
21500	// 	return await api.call(data => data);
21501	// }
21502}
21503
21504/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (APIClient);
21505
21506
21507/***/ },
21508
21509/***/ 4345
21510() {
21511
21512paymentSubscriberRegistry = {
21513    subscribers: [],
21514
21515    register: function(subscriber) {
21516        this.subscribers.push(subscriber);
21517    },
21518    remove: function(identifier) {
21519        this.subscribers = this.subscribers.filter(s => s.identifier != identifier);
21520    }
21521}
21522
21523paymentSubscriberNotifier = {
21524    notify: function (eventName, ...params) {
21525        paymentSubscriberRegistry.subscribers.forEach(
21526            function (subscriber) {
21527                subscriber.subscriptions.forEach(
21528                    function (subscription) {
21529                        if (subscription.eventName == eventName) {
21530                            subscriber[subscription.functionName](...params);
21531                        }
21532                    }
21533                );
21534            }
21535        );
21536    }
21537}
21538
21539paymentService = {
21540    authorizationData: {}
21541}
21542
21543/***/ },
21544
21545/***/ 4894
21546(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
21547
21548"use strict";
21549
21550// EXPORTS
21551__webpack_require__.d(__webpack_exports__, {
21552  A: () => (/* binding */ MinimumOrderValueNotice)
21553});
21554
21555// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 6 modules
21556var vue_esm_bundler = __webpack_require__(1425);
21557;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/MinimumOrderValueNotice.vue?vue&type=template&id=3ccd5116
21558
21559
21560const _hoisted_1 = {
21561  key: 0,
21562  class: "minimum-order-value-notice",
21563  role: "status"
21564}
21565const _hoisted_2 = { class: "minimum-order-value-notice__text" }
21566
21567function render(_ctx, _cache, $props, $setup, $data, $options) {
21568  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
21569
21570  return ($options.missingAmount > 0)
21571    ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", _hoisted_1, [
21572        (0,vue_esm_bundler/* createElementVNode */.Lk)("p", _hoisted_2, [
21573          ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, {
21574            key: 'missing-' + $options.missingAmount + '-' + $options.minimumOrderValueAmount,
21575            variables: {missingAmount: _ctx.formatPrice($options.missingAmount/100, true), minimumOrderValue: _ctx.formatPrice($options.minimumOrderValueAmount/100, true)}
21576          }, {
21577            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[0] || (_cache[0] = [
21578              (0,vue_esm_bundler/* createTextVNode */.eW)("checkout.minimum_order_value_missing", -1 /* CACHED */)
21579            ]))]),
21580            _: 1 /* STABLE */
21581          }, 8 /* PROPS */, ["variables"]))
21582        ])
21583      ]))
21584    : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
21585}
21586;// ./vue/components/MinimumOrderValueNotice.vue?vue&type=template&id=3ccd5116
21587
21588// EXTERNAL MODULE: ./node_modules/vuex/dist/vuex.esm-bundler.js + 5 modules
21589var vuex_esm_bundler = __webpack_require__(2124);
21590// EXTERNAL MODULE: ./vue/mixin/Format.js
21591var Format = __webpack_require__(3133);
21592;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/MinimumOrderValueNotice.vue?vue&type=script&lang=js
21593
21594
21595
21596
21597/* harmony default export */ const MinimumOrderValueNoticevue_type_script_lang_js = ({
21598	name: 'MinimumOrderValueNotice',
21599	mixins: [Format/* default */.A],
21600	computed: {
21601		...(0,vuex_esm_bundler/* mapState */.aH)('checkout', [
21602			'minimumOrderValueInfo'
21603		]),
21604		missingAmount() {
21605			let info = this.minimumOrderValueInfo;
21606			if (!info || !info.totalPriceUpToMinimumOrderValue) return 0;
21607
21608			return info.totalPriceUpToMinimumOrderValue.amount;
21609		},
21610		minimumOrderValueAmount() {
21611			let info = this.minimumOrderValueInfo;
21612			if (!info || !info.minimumOrderValue) return 0;
21613
21614			return info.minimumOrderValue.amount;
21615		}
21616	}
21617});
21618
21619;// ./vue/components/MinimumOrderValueNotice.vue?vue&type=script&lang=js
21620 
21621// EXTERNAL MODULE: ./node_modules/vue-loader/dist/exportHelper.js
21622var exportHelper = __webpack_require__(6262);
21623;// ./vue/components/MinimumOrderValueNotice.vue
21624
21625
21626
21627
21628;
21629const __exports__ = /*#__PURE__*/(0,exportHelper/* default */.A)(MinimumOrderValueNoticevue_type_script_lang_js, [['render',render]])
21630
21631/* harmony default export */ const MinimumOrderValueNotice = (__exports__);
21632
21633/***/ },
21634
21635/***/ 5056
21636(module, __unused_webpack_exports, __webpack_require__) {
21637
21638"use strict";
21639
21640
21641/* istanbul ignore next  */
21642function setAttributesWithoutAttributes(styleElement) {
21643  var nonce =  true ? __webpack_require__.nc : 0;
21644  if (nonce) {
21645    styleElement.setAttribute("nonce", nonce);
21646  }
21647}
21648module.exports = setAttributesWithoutAttributes;
21649
21650/***/ },
21651
21652/***/ 5072
21653(module) {
21654
21655"use strict";
21656
21657
21658var stylesInDOM = [];
21659function getIndexByIdentifier(identifier) {
21660  var result = -1;
21661  for (var i = 0; i < stylesInDOM.length; i++) {
21662    if (stylesInDOM[i].identifier === identifier) {
21663      result = i;
21664      break;
21665    }
21666  }
21667  return result;
21668}
21669function modulesToDom(list, options) {
21670  var idCountMap = {};
21671  var identifiers = [];
21672  for (var i = 0; i < list.length; i++) {
21673    var item = list[i];
21674    var id = options.base ? item[0] + options.base : item[0];
21675    var count = idCountMap[id] || 0;
21676    var identifier = "".concat(id, " ").concat(count);
21677    idCountMap[id] = count + 1;
21678    var indexByIdentifier = getIndexByIdentifier(identifier);
21679    var obj = {
21680      css: item[1],
21681      media: item[2],
21682      sourceMap: item[3],
21683      supports: item[4],
21684      layer: item[5]
21685    };
21686    if (indexByIdentifier !== -1) {
21687      stylesInDOM[indexByIdentifier].references++;
21688      stylesInDOM[indexByIdentifier].updater(obj);
21689    } else {
21690      var updater = addElementStyle(obj, options);
21691      options.byIndex = i;
21692      stylesInDOM.splice(i, 0, {
21693        identifier: identifier,
21694        updater: updater,
21695        references: 1
21696      });
21697    }
21698    identifiers.push(identifier);
21699  }
21700  return identifiers;
21701}
21702function addElementStyle(obj, options) {
21703  var api = options.domAPI(options);
21704  api.update(obj);
21705  var updater = function updater(newObj) {
21706    if (newObj) {
21707      if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) {
21708        return;
21709      }
21710      api.update(obj = newObj);
21711    } else {
21712      api.remove();
21713    }
21714  };
21715  return updater;
21716}
21717module.exports = function (list, options) {
21718  options = options || {};
21719  list = list || [];
21720  var lastIdentifiers = modulesToDom(list, options);
21721  return function update(newList) {
21722    newList = newList || [];
21723    for (var i = 0; i < lastIdentifiers.length; i++) {
21724      var identifier = lastIdentifiers[i];
21725      var index = getIndexByIdentifier(identifier);
21726      stylesInDOM[index].references--;
21727    }
21728    var newLastIdentifiers = modulesToDom(newList, options);
21729    for (var _i = 0; _i < lastIdentifiers.length; _i++) {
21730      var _identifier = lastIdentifiers[_i];
21731      var _index = getIndexByIdentifier(_identifier);
21732      if (stylesInDOM[_index].references === 0) {
21733        stylesInDOM[_index].updater();
21734        stylesInDOM.splice(_index, 1);
21735      }
21736    }
21737    lastIdentifiers = newLastIdentifiers;
21738  };
21739};
21740
21741/***/ },
21742
21743/***/ 5348
21744(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
21745
21746"use strict";
21747
21748// EXPORTS
21749__webpack_require__.d(__webpack_exports__, {
21750  A: () => (/* binding */ entity_CheckoutEntity)
21751});
21752
21753// EXTERNAL MODULE: ./vue/entity/Entity.js
21754var Entity = __webpack_require__(7249);
21755// EXTERNAL MODULE: ./vue/entity/CartItemEntity.js
21756var CartItemEntity = __webpack_require__(8044);
21757// EXTERNAL MODULE: ./vue/entity/PaymentMethodEntity.js
21758var PaymentMethodEntity = __webpack_require__(7520);
21759;// ./vue/entity/ShippingRateEntity.js
21760
21761
21762class ShippingRateEntity extends Entity/* default */.A {
21763	constructor() {
21764		super();
21765	}
21766
21767	static createFromAPIData(obj) {
21768		return ShippingRateEntity.map({
21769            id: 'id',
21770            name: 'name',
21771            chargeAmount: 'price',
21772            excludeFromDefaultAndFreeShippingCalculation: 'excludeFromDefaultAndFreeShippingCalculation'
21773        },
21774        obj);
21775    }
21776    
21777    static toPOJO(obj) {
21778		return ShippingRateEntity.map({
21779            id: 'id',
21780            name: 'name'
21781        },
21782        obj,
21783        true);
21784	}
21785}
21786
21787/* harmony default export */ const entity_ShippingRateEntity = (ShippingRateEntity);
21788
21789;// ./vue/entity/DiscountCodeEntity.js
21790
21791
21792class DiscountCodeEntity extends Entity/* default */.A {
21793	constructor() {
21794		super();
21795	}
21796
21797	static createFromAPIData(obj) {
21798		return DiscountCodeEntity.map({
21799            code: 'code',
21800            title: 'title',
21801            type: 'type',
21802            amount: 'amount',
21803            reductionAmount: 'reductionAmount'
21804        },
21805        obj);
21806    }
21807    
21808    static toPOJO(obj) {
21809		let pojo = DiscountCodeEntity.map({
21810            code: 'code'
21811        },
21812        obj,
21813        true);
21814
21815        if (!pojo) pojo = {};
21816
21817        if (typeof pojo.code === 'string' && pojo.code.trim() === '') pojo.code = null;
21818
21819        return pojo;
21820	}
21821}
21822
21823/* harmony default export */ const entity_DiscountCodeEntity = (DiscountCodeEntity);
21824
21825// EXTERNAL MODULE: ./vue/entity/DiscountEntity.js
21826var DiscountEntity = __webpack_require__(1858);
21827;// ./vue/entity/CheckoutEntity.js
21828
21829
21830
21831
21832
21833
21834
21835class CheckoutEntity extends Entity/* default */.A {
21836	constructor() {
21837		super();
21838	}
21839
21840	static createFromAPIData(obj) {
21841
21842		let checkout = CheckoutEntity.map({
21843			cartItems: {
21844				type: CartItemEntity/* default */.A,
21845				property: 'cartItems',
21846				converter: 'createFromAPIData'
21847			},
21848			paymentMethods: {
21849				type: PaymentMethodEntity/* default */.A,
21850				property: 'paymentMethods',
21851				converter: 'createFromAPIData'
21852			},
21853			shippingRates: {
21854				type: entity_ShippingRateEntity,
21855				property: 'shippingRates',
21856				converter: 'createFromAPIData'
21857			},
21858			cartItemsTotalPrice: {
21859				type: {},
21860				properties: {
21861					amount: 'amount',
21862					currency: 'currencyCode',
21863					taxModel: 'taxModel'
21864				}
21865			},
21866			deliveryPeriod: {
21867				type: {},
21868				properties: {
21869					min: 'min',
21870					max: 'max',
21871					unit: 'unit'
21872				}
21873			},
21874			shippingPrice: {
21875				type: {},
21876				properties: {
21877					amount: 'amount',
21878					currency: 'currencyCode',
21879					taxModel: 'taxModel',
21880					taxRate: 'taxRate',
21881					taxAmount: 'taxAmount'
21882				}
21883			},
21884			shippingGrossPrice: {
21885				type: {},
21886				properties: {
21887					amount: 'amount',
21888					currency: 'currencyCode',
21889					taxModel: 'taxModel',
21890					taxRate: 'taxRate',
21891					taxAmount: 'taxAmount'
21892				}
21893			},
21894			totalPrice: {
21895				type: {},
21896				properties: {
21897					amount: 'amount',
21898					currency: 'currencyCode',
21899					taxModel: 'taxModel',
21900				}
21901			},
21902			totalGrossPrice: {
21903				type: {},
21904				properties: {
21905					amount: 'amount',
21906					taxAmount: 'taxAmount',
21907					currency: 'currencyCode',
21908					taxModel: 'taxModel'
21909				}
21910			},
21911			deliveryAddress: {
21912				type: {},
21913				properties: {
21914					street: 'street',
21915					street2: 'street2',
21916					postCode: 'postCode',
21917					city: 'city',
21918					countryCode: 'countryCode',
21919					firstName: 'firstName',
21920					lastName: 'lastName',
21921					company: 'company'
21922				}
21923			},
21924			billingAddress: {
21925				type: {},
21926				properties: {
21927					street: 'street',
21928					street2: 'street2',
21929					postCode: 'postCode',
21930					city: 'city',
21931					countryCode: 'countryCode',
21932					firstName: 'firstName',
21933					lastName: 'lastName',
21934					company: 'company'
21935				}
21936			},
21937			discountCodes: {
21938				type: entity_DiscountCodeEntity,
21939				property: 'discountCodes',
21940				converter: 'createFromAPIData'
21941			},
21942			discounts: {
21943				type: DiscountEntity/* default */.A,
21944				property: 'discounts',
21945				converter: 'createFromAPIData'
21946			},
21947			billingAddressSameAsDeliveryAddress: 'billingAddressSameAsDeliveryAddress',
21948			shippingRateId: 'shippingRateId',
21949			paymentMethodId: 'paymentMethodId',
21950			paymentMethodCharge: 'paymentMethodCharge',
21951			paymentMethodGrossCharge: 'paymentMethodGrossCharge',
21952			paymentRequired: 'paymentRequired',
21953			customerDeliveryAddressId: 'customerDeliveryAddressId',
21954			customerBillingAddressId: 'customerBillingAddressId',
21955			emailAddress: 'emailAddress',
21956			phone: 'phone',
21957			birthday: 'birthday',
21958			note: 'note',
21959			firstName: 'firstName',
21960			lastName: 'lastName',
21961			orderId: 'orderId',
21962			id: 'id',
21963			customerNumber: 'customerNumber',
21964			companyRegisterNumber: 'companyRegisterNumber',
21965			company: 'company',
21966			vatin: 'vatin',
21967			provisionalDeliveryCountryCode: 'provisionalDeliveryCountryCode',
21968			provisionalDeliveryPostCode: 'provisionalDeliveryPostCode',
21969			acceptsMarketing: 'acceptsMarketing',
21970			isShippingRequired: 'isShippingRequired',
21971			freeShippingInfo: 'freeShippingInfo',
21972			minimumOrderValueInfo: 'minimumOrderValueInfo',
21973			completeness: {
21974				type: {},
21975				properties: {
21976					completable: 'completable',
21977					cartComplete: 'cartComplete',
21978					billingAddressComplete: 'billingAddressComplete',
21979					deliveryAddressComplete: 'deliveryAddressComplete',
21980					paymentMethodComplete: 'paymentMethodComplete',
21981					shippingRateComplete: 'shippingRateComplete',
21982					customerDataComplete: 'customerDataComplete',
21983					vatinComplete: 'vatinComplete',
21984					minimumOrderValueComplete: 'minimumOrderValueComplete',
21985				}
21986			}
21987		},
21988		obj);
21989
21990		// set confirm boxes from _embedded visibleConfirmBoxes
21991		if (obj._embedded && obj._embedded.visibleConfirmBoxes) {
21992			checkout.checkoutConfirmBoxes = obj._embedded.visibleConfirmBoxes;
21993		}
21994
21995		// set confirm boxes status from checkoutConfirmBoxRelations
21996		if (obj.checkoutConfirmBoxRelations) {
21997			let confirmBoxes = obj.checkoutConfirmBoxRelations;
21998			let confirmBoxesStatus = [];
21999			for (let i = 0; i < checkout.checkoutConfirmBoxes.length; i++) {
22000				confirmBoxesStatus[i] = false;
22001				for (let j = 0; j < confirmBoxes.length; j++) {
22002					if (checkout.checkoutConfirmBoxes[i].id === confirmBoxes[j].checkoutConfirmBoxId) {
22003						confirmBoxesStatus[i] = true;
22004						break;
22005					}
22006				}
22007			}
22008			checkout.confirmBoxesStatus = confirmBoxesStatus;
22009		}
22010
22011		return checkout;
22012	}
22013
22014	static toPOJO(obj) {
22015        let pojo = CheckoutEntity.map({
22016			cartItems: {
22017				type: CartItemEntity/* default */.A,
22018				property: 'cartItems',
22019				converter: 'toPOJO'
22020			},
22021			deliveryAddress: {
22022				type: {},
22023				properties: {
22024					street: 'street',
22025					street2: 'street2',
22026					postCode: 'postCode',
22027					city: 'city',
22028					countryCode: 'countryCode',
22029					firstName: 'firstName',
22030					lastName: 'lastName',
22031					company: "company"
22032				}
22033			},
22034			billingAddress: {
22035				type: {},
22036				properties: {
22037					street: 'street',
22038					street2: 'street2',
22039					postCode: 'postCode',
22040					city: 'city',
22041					countryCode: 'countryCode',
22042					firstName: 'firstName',
22043					lastName: 'lastName',
22044					company: "company"
22045				}
22046			},
22047			discountCodes: {
22048				type: entity_DiscountCodeEntity,
22049				property: 'discountCodes',
22050				converter: 'toPOJO'
22051			},
22052			billingAddressSameAsDeliveryAddress: 'billingAddressSameAsDeliveryAddress',
22053			shippingRateId: 'shippingRateId',
22054			paymentMethodId: 'paymentMethodId',
22055			customerDeliveryAddressId: 'customerDeliveryAddressId',
22056			customerBillingAddressId: 'customerBillingAddressId',
22057			emailAddress: 'emailAddress',
22058			phone: 'phone',
22059			birthday: 'birthday',
22060			note: 'note',
22061			firstName: 'firstName',
22062			lastName: 'lastName',
22063			customerNumber: 'customerNumber',
22064			paymentAuthorizationParams: 'paymentAuthorizationParams',
22065			checkoutConfirmBoxRelations: 'checkoutConfirmBoxRelations',
22066			companyRegisterNumber: 'companyRegisterNumber',
22067			company: 'company',
22068			vatin: 'vatin',
22069			provisionalDeliveryCountryCode: 'provisionalDeliveryCountryCode',
22070			provisionalDeliveryPostCode: 'provisionalDeliveryPostCode',
22071			acceptsMarketing: 'acceptsMarketing',
22072			timezone: 'timezone'
22073			// complete: 'complete'
22074		},
22075		obj,
22076		true);
22077
22078		pojo.timezone = Intl.DateTimeFormat().resolvedOptions().timeZone;
22079		if (typeof pojo.customerDeliveryAddressId === 'string' && pojo.customerDeliveryAddressId.trim() === '') pojo.customerDeliveryAddressId = null;
22080		if (typeof pojo.customerBillingAddressId === 'string' && pojo.customerBillingAddressId.trim() === '') pojo.customerBillingAddressId = null;
22081		if (typeof pojo.paymentMethodId === 'string' && pojo.paymentMethodId.trim() === '') pojo.paymentMethodId = null;
22082		if (typeof pojo.shippingRateId === 'string' && pojo.shippingRateId.trim() === '') pojo.shippingRateId = null;
22083		if (typeof pojo.company === 'string' && pojo.company.trim() === '') pojo.company = null;
22084		if (typeof pojo.phone === 'string' && pojo.phone.trim() === '') pojo.phone = null;
22085		if (typeof pojo.vatin === 'string' && pojo.vatin.trim() === '') pojo.vatin = null;
22086		if (typeof pojo.emailAddress === 'string' && pojo.emailAddress.trim() === '') pojo.emailAddress = null;
22087		if (typeof pojo.phone === 'string' && pojo.phone.trim() === '') pojo.phone = null;
22088		if (typeof pojo.firstName === 'string' && pojo.firstName.trim() === '') pojo.firstName = null;
22089		if (typeof pojo.lastName === 'string' && pojo.lastName.trim() === '') pojo.lastName = null;
22090		if (typeof pojo.companyRegisterNumber === 'string' && pojo.companyRegisterNumber.trim() === '') pojo.companyRegisterNumber = null;
22091		if (typeof pojo.company === 'string' && pojo.company.trim() === '') pojo.company = null;
22092		if (typeof pojo.companyRegisterNumber === 'string' && pojo.companyRegisterNumber.trim() === '') pojo.companyRegisterNumber = null;
22093		if (typeof pojo.birthday === 'string' && pojo.birthday.trim() === '') pojo.birthday = null;
22094		if (typeof pojo.customerNumber === 'string' && pojo.customerNumber.trim() === '') pojo.customerNumber = null;
22095		if (typeof pojo.note === 'string' && pojo.note.trim() === '') pojo.note = null;
22096		if (typeof pojo.provisionalDeliveryCountryCode === 'string' && pojo.provisionalDeliveryCountryCode.trim() === '') pojo.provisionalDeliveryCountryCode = null;
22097		if (typeof pojo.provisionalDeliveryPostCode === 'string' && pojo.provisionalDeliveryPostCode.trim() === '') pojo.provisionalDeliveryPostCode = null;
22098
22099		if (typeof pojo.deliveryAddress === 'object' && JSON.stringify(pojo.deliveryAddress) == '{}') pojo.deliveryAddress = null;
22100		if (pojo.deliveryAddress) {
22101			if (typeof pojo.deliveryAddress.street === 'string' && pojo.deliveryAddress.street.trim() === '') pojo.deliveryAddress.street = null;
22102			if (typeof pojo.deliveryAddress.street2 === 'string' && pojo.deliveryAddress.street2.trim() === '') pojo.deliveryAddress.street2 = null;
22103			if (typeof pojo.deliveryAddress.postCode === 'string' && pojo.deliveryAddress.postCode.trim() === '') pojo.deliveryAddress.postCode = null;
22104			if (typeof pojo.deliveryAddress.city === 'string' && pojo.deliveryAddress.city.trim() === '') pojo.deliveryAddress.city = null;
22105			if (typeof pojo.deliveryAddress.countryCode === 'string' && pojo.deliveryAddress.countryCode.trim() === '') pojo.deliveryAddress.countryCode = null;
22106			if (typeof pojo.deliveryAddress.firstName === 'string' && pojo.deliveryAddress.firstName.trim() === '') pojo.deliveryAddress.firstName = null;
22107			if (typeof pojo.deliveryAddress.lastName === 'string' && pojo.deliveryAddress.lastName.trim() === '') pojo.deliveryAddress.lastName = null;
22108			if (typeof pojo.deliveryAddress.company === 'string' && pojo.deliveryAddress.company.trim() === '') pojo.deliveryAddress.company = null;
22109		}
22110		if (typeof pojo.billingAddress === 'object' && JSON.stringify(pojo.billingAddress) == '{}') pojo.billingAddress = null;
22111		if (pojo.billingAddress) {
22112			if (typeof pojo.billingAddress.street === 'string' && pojo.billingAddress.street.trim() === '') pojo.billingAddress.street = null;
22113			if (typeof pojo.billingAddress.street2 === 'string' && pojo.billingAddress.street2.trim() === '') pojo.billingAddress.street2 = null;
22114			if (typeof pojo.billingAddress.postCode === 'string' && pojo.billingAddress.postCode.trim() === '') pojo.billingAddress.postCode = null;
22115			if (typeof pojo.billingAddress.city === 'string' && pojo.billingAddress.city.trim() === '') pojo.billingAddress.city = null;
22116			if (typeof pojo.billingAddress.countryCode === 'string' && pojo.billingAddress.countryCode.trim() === '') pojo.billingAddress.countryCode = null;
22117			if (typeof pojo.billingAddress.firstName === 'string' && pojo.billingAddress.firstName.trim() === '') pojo.billingAddress.firstName = null;
22118			if (typeof pojo.billingAddress.lastName === 'string' && pojo.billingAddress.lastName.trim() === '') pojo.billingAddress.lastName = null;
22119			if (typeof pojo.billingAddress.company === 'string' && pojo.billingAddress.company.trim() === '') pojo.billingAddress.company = null;
22120		}
22121
22122		if (obj.isShippingRequired === false) {
22123			pojo.shippingRateId = null;
22124		}
22125
22126		if (obj.confirmBoxesStatus) {
22127			let confirmBoxes = obj.checkoutConfirmBoxes;
22128			let confirmBoxesStatus = obj.confirmBoxesStatus;
22129			let confirmBoxRelations = [];
22130			for (let i = 0; i < confirmBoxes.length; i++) {
22131				if (confirmBoxesStatus[i]) {
22132					let relation = {
22133						checkoutConfirmBoxId: confirmBoxes[i].id
22134					};
22135					confirmBoxRelations.push(relation);
22136				}
22137			}
22138			pojo.checkoutConfirmBoxRelations = confirmBoxRelations;
22139		}
22140
22141		if (pojo.discountCodes) {
22142			for (let index in pojo.discountCodes) {
22143				if (pojo.discountCodes[index].code === null) {
22144					pojo.discountCodes.splice(index, 1);
22145				}
22146			}
22147		}
22148
22149		return pojo;
22150	}
22151
22152	static toPaymentPOJO(obj) {
22153
22154        let pojo = CheckoutEntity.map({
22155			cartItems: {
22156				type: CartItemEntity/* default */.A,
22157				property: 'cartItems',
22158				converter: 'toPaymentPOJO'
22159			},
22160			deliveryAddress: {
22161				type: {},
22162				properties: {
22163					street: 'street',
22164					street2: 'street2',
22165					postCode: 'postCode',
22166					city: 'city',
22167					countryCode: 'countryCode',
22168					firstName: 'firstName',
22169					lastName: 'lastName',
22170					company: "company"
22171				}
22172			},
22173			billingAddress: {
22174				type: {},
22175				properties: {
22176					street: 'street',
22177					street2: 'street2',
22178					postCode: 'postCode',
22179					city: 'city',
22180					countryCode: 'countryCode',
22181					firstName: 'firstName',
22182					lastName: 'lastName',
22183					company: "company"
22184				}
22185			},
22186			shippingPrice: {
22187				type: {},
22188				properties: {
22189					amount: 'amount',
22190					currency: 'currency',
22191					taxModel: 'taxModel',
22192					taxRate: 'taxRate',
22193					taxAmount: 'taxAmount'
22194				}
22195			},
22196			shippingGrossPrice: {
22197				type: {},
22198				properties: {
22199					amount: 'amount',
22200					currency: 'currency',
22201					taxModel: 'taxModel',
22202					taxRate: 'taxRate',
22203					taxAmount: 'taxAmount'
22204				}
22205			},
22206			totalPrice: {
22207				type: {},
22208				properties: {
22209					amount: 'amount',
22210					currency: 'currency',
22211					taxModel: 'taxModel'
22212				}
22213			},
22214			totalGrossPrice: {
22215				type: {},
22216				properties: {
22217					amount: 'amount',
22218					taxAmount: 'taxAmount',
22219					currency: 'currency',
22220					taxModel: 'taxModel'
22221				}
22222			},
22223			paymentMethods: {
22224				type: PaymentMethodEntity/* default */.A,
22225				property: 'paymentMethods',
22226				converter: 'toPOJO'
22227			},
22228			discountCodes: {
22229				type: entity_DiscountCodeEntity,
22230				property: 'discountCodes',
22231				converter: 'toPOJO'
22232			},
22233			discounts: {
22234				type: DiscountEntity/* default */.A,
22235				property: 'discounts',
22236				converter: 'toPaymentPOJO'
22237			},
22238			billingAddressSameAsDeliveryAddress: 'billingAddressSameAsDeliveryAddress',
22239			shippingRateId: 'shippingRateId',
22240			paymentMethodId: 'paymentMethodId',
22241			customerDeliveryAddressId: 'customerDeliveryAddressId',
22242			customerBillingAddressId: 'customerBillingAddressId',
22243			emailAddress: 'emailAddress',
22244			phone: 'phone',
22245			firstName: 'firstName',
22246			lastName: 'lastName',
22247			companyRegisterNumber: 'companyRegisterNumber',
22248			company: 'company',
22249			vatin: 'vatin',
22250			paymentMethodCharge: 'paymentMethodCharge',
22251			paymentMethodGrossCharge: 'paymentMethodGrossCharge',
22252			id: 'id'
22253			// complete: 'complete'
22254		},
22255		obj,
22256        true);
22257
22258		if (typeof pojo.customerDeliveryAddressId === 'string' && pojo.customerDeliveryAddressId.trim() === '') pojo.customerDeliveryAddressId = null;
22259		if (typeof pojo.customerBillingAddressId === 'string' && pojo.customerBillingAddressId.trim() === '') pojo.customerBillingAddressId = null;
22260		if (typeof pojo.paymentMethodId === 'string' && pojo.paymentMethodId.trim() === '') pojo.paymentMethodId = null;
22261		if (typeof pojo.shippingRateId === 'string' && pojo.shippingRateId.trim() === '') pojo.shippingRateId = null;
22262		if (typeof pojo.company === 'string' && pojo.company.trim() === '') pojo.company = null;
22263		if (typeof pojo.emailAddress === 'string' && pojo.emailAddress.trim() === '') pojo.emailAddress = null;
22264		if (typeof pojo.firstName === 'string' && pojo.firstName.trim() === '') pojo.firstName = null;
22265		if (typeof pojo.lastName === 'string' && pojo.lastName.trim() === '') pojo.lastName = null;
22266		if (typeof pojo.phone === 'string' && pojo.phone.trim() === '') pojo.phone = null;
22267		if (typeof pojo.vatin === 'string' && pojo.vatin.trim() === '') pojo.vatin = null;
22268		if (typeof pojo.companyRegisterNumber === 'string' && pojo.companyRegisterNumber.trim() === '') pojo.companyRegisterNumber = null;
22269		// if (typeof pojo.billingAddress === 'object' && JSON.stringify(pojo.billingAddress) == '{}') pojo.billingAddress = null;
22270
22271		return pojo;
22272	}
22273
22274
22275	static toAnalyticsPOJO(obj) {
22276		let pojo = CheckoutEntity.map({
22277			transaction_id: 'id',
22278			affiliation: 'affiliation',
22279			value: 'value',
22280			shipping: 'shipping',
22281			currency: 'currency',
22282			items: {
22283				type: CartItemEntity/* default */.A,
22284				property: 'cartItems',
22285				converter: 'toAnalyticsPOJO'
22286			}
22287		},
22288		obj,
22289        true);
22290
22291		pojo.shipping /= 100;
22292		pojo.value /= 100;
22293
22294		return pojo;
22295	}
22296}
22297
22298/* harmony default export */ const entity_CheckoutEntity = (CheckoutEntity);
22299
22300
22301/***/ },
22302
22303/***/ 5416
22304(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
22305
22306"use strict";
22307/* harmony export */ __webpack_require__.d(__webpack_exports__, {
22308/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
22309/* harmony export */ });
22310/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
22311    methods: {
22312        localizeURL(url) {
22313            if (SP_CONSTANTS.DEFAULT_LOCALE == SP_CONSTANTS.LOCALE) {
22314                return url;
22315            }
22316            return '/' + SP_CONSTANTS.LOCALE + url;
22317        }
22318    }
22319});
22320
22321/***/ },
22322
22323/***/ 5449
22324(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
22325
22326"use strict";
22327
22328// EXPORTS
22329__webpack_require__.d(__webpack_exports__, {
22330  A: () => (/* binding */ ProfileLogin)
22331});
22332
22333// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 6 modules
22334var vue_esm_bundler = __webpack_require__(1425);
22335;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/pages/profile/ProfileLogin.vue?vue&type=template&id=3e321113
22336
22337
22338const _hoisted_1 = { class: "row justify-content-center" }
22339const _hoisted_2 = { class: "col-lg-6" }
22340const _hoisted_3 = { class: "profile__login-column gs_profile__login-column" }
22341const _hoisted_4 = { class: "gs_profile__title" }
22342const _hoisted_5 = { style: {"display":"inline"} }
22343const _hoisted_6 = { style: {"display":"inline"} }
22344const _hoisted_7 = { class: "gs_profile__login-text" }
22345const _hoisted_8 = { "aria-live": "assertive" }
22346const _hoisted_9 = {
22347  key: 0,
22348  class: "profile__error-message gs_profile__error-message mt-3"
22349}
22350const _hoisted_10 = ["href"]
22351const _hoisted_11 = {
22352  key: 0,
22353  class: "col-lg-6"
22354}
22355const _hoisted_12 = { class: "profile__create-account-column gs_profile__create-account-column" }
22356const _hoisted_13 = { class: "gs_profile__title" }
22357const _hoisted_14 = { class: "gs_profile__register-text" }
22358
22359function render(_ctx, _cache, $props, $setup, $data, $options) {
22360  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
22361  const _component_sp_input = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-input")
22362  const _component_sp_button = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-button")
22363
22364  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", null, [
22365    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_1, [
22366      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_2, [
22367        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_3, [
22368          (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_4, [
22369            (0,vue_esm_bundler/* createCommentVNode */.Q3)(" Registrierte Kunden "),
22370            (0,vue_esm_bundler/* createElementVNode */.Lk)("h1", _hoisted_5, [
22371              (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
22372                default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[4] || (_cache[4] = [
22373                  (0,vue_esm_bundler/* createTextVNode */.eW)("toolbox.account_login", -1 /* CACHED */)
22374                ]))]),
22375                _: 1 /* STABLE */
22376              }),
22377              _cache[5] || (_cache[5] = (0,vue_esm_bundler/* createTextVNode */.eW)(": ", -1 /* CACHED */))
22378            ]),
22379            (0,vue_esm_bundler/* createElementVNode */.Lk)("h2", _hoisted_6, [
22380              (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
22381                default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[6] || (_cache[6] = [
22382                  (0,vue_esm_bundler/* createTextVNode */.eW)("profile.registered_account", -1 /* CACHED */)
22383                ]))]),
22384                _: 1 /* STABLE */
22385              })
22386            ])
22387          ]),
22388          (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_7, [
22389            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
22390              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[7] || (_cache[7] = [
22391                (0,vue_esm_bundler/* createTextVNode */.eW)("profile.registered_account_text", -1 /* CACHED */)
22392              ]))]),
22393              _: 1 /* STABLE */
22394            })
22395          ]),
22396          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_input, {
22397            class: "e2e_profile-login__email",
22398            label: "profile.email_address",
22399            name: "username",
22400            modelValue: $data.emailAddress,
22401            "onUpdate:modelValue": _cache[0] || (_cache[0] = $event => (($data.emailAddress) = $event))
22402          }, null, 8 /* PROPS */, ["modelValue"]),
22403          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_input, {
22404            class: "e2e_profile-login__password",
22405            type: "Password",
22406            label: "profile.password",
22407            modelValue: $data.password,
22408            "onUpdate:modelValue": _cache[1] || (_cache[1] = $event => (($data.password) = $event))
22409          }, null, 8 /* PROPS */, ["modelValue"]),
22410          (0,vue_esm_bundler/* createElementVNode */.Lk)("span", _hoisted_8, [
22411            ($data.message)
22412              ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", _hoisted_9, [
22413                  ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, { key: $data.message }, {
22414                    default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
22415                      (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($data.message), 1 /* TEXT */)
22416                    ]),
22417                    _: 1 /* STABLE */
22418                  }))
22419                ]))
22420              : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
22421          ]),
22422          _cache[10] || (_cache[10] = (0,vue_esm_bundler/* createElementVNode */.Lk)("br", null, null, -1 /* CACHED */)),
22423          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_button, {
22424            class: "gs_button__default__text gs_button__login__text e2e_profile-login__button sp-button--full-width",
22425            onClick: _cache[2] || (_cache[2] = $event => ($options.login()))
22426          }, {
22427            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
22428              (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
22429                default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[8] || (_cache[8] = [
22430                  (0,vue_esm_bundler/* createTextVNode */.eW)("general.login", -1 /* CACHED */)
22431                ]))]),
22432                _: 1 /* STABLE */
22433              })
22434            ]),
22435            _: 1 /* STABLE */
22436          }),
22437          (0,vue_esm_bundler/* createElementVNode */.Lk)("a", {
22438            href: _ctx.localizeURL('/profile#!reset-password'),
22439            class: "d-block gs_profile__change-view-link e2e_profile-forgot-password__link text-link"
22440          }, [
22441            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
22442              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[9] || (_cache[9] = [
22443                (0,vue_esm_bundler/* createTextVNode */.eW)("profile.forgot_password", -1 /* CACHED */)
22444              ]))]),
22445              _: 1 /* STABLE */
22446            })
22447          ], 8 /* PROPS */, _hoisted_10)
22448        ])
22449      ]),
22450      ($options.canRegister)
22451        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", _hoisted_11, [
22452            (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_12, [
22453              (0,vue_esm_bundler/* createElementVNode */.Lk)("h2", _hoisted_13, [
22454                (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
22455                  default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[11] || (_cache[11] = [
22456                    (0,vue_esm_bundler/* createTextVNode */.eW)("profile.new_account", -1 /* CACHED */)
22457                  ]))]),
22458                  _: 1 /* STABLE */
22459                })
22460              ]),
22461              (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_14, [
22462                ($options.isRestrictedPage)
22463                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, { key: 0 }, {
22464                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[12] || (_cache[12] = [
22465                        (0,vue_esm_bundler/* createTextVNode */.eW)("profile.new_account_text_page", -1 /* CACHED */)
22466                      ]))]),
22467                      _: 1 /* STABLE */
22468                    }))
22469                  : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, { key: 1 }, {
22470                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[13] || (_cache[13] = [
22471                        (0,vue_esm_bundler/* createTextVNode */.eW)("profile.new_account_text", -1 /* CACHED */)
22472                      ]))]),
22473                      _: 1 /* STABLE */
22474                    })),
22475                (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_button, {
22476                  class: "mt-3 gs_button__default__text gs_button__register__text e2e_profile-register__button sp-button--full-width",
22477                  onClick: _cache[3] || (_cache[3] = $event => ($options.goToLocalizedUrl('/profile#!create')))
22478                }, {
22479                  default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
22480                    (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
22481                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[14] || (_cache[14] = [
22482                        (0,vue_esm_bundler/* createTextVNode */.eW)("profile.create_account_button", -1 /* CACHED */)
22483                      ]))]),
22484                      _: 1 /* STABLE */
22485                    })
22486                  ]),
22487                  _: 1 /* STABLE */
22488                }),
22489                (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <sp-lang>profile.register_text</sp-lang> ")
22490              ])
22491            ])
22492          ]))
22493        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
22494    ]),
22495    (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <a :href=\"localizeURL('/profile#!create')\" class=\"d-block mt-2 e2e_profile-not-registered__link\"><sp-lang>profile.not_registered_link</sp-lang></a> ")
22496  ]))
22497}
22498;// ./vue/pages/profile/ProfileLogin.vue?vue&type=template&id=3e321113
22499
22500// EXTERNAL MODULE: ./vue/mixin/LocalizeURL.js
22501var LocalizeURL = __webpack_require__(5416);
22502;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/pages/profile/ProfileLogin.vue?vue&type=script&lang=js
22503
22504
22505
22506
22507/* harmony default export */ const ProfileLoginvue_type_script_lang_js = ({
22508	name: 'Login',
22509	mixins: [LocalizeURL/* default */.A],
22510  	data() {
22511		return {
22512            emailAddress: '',
22513			password: '',
22514			message: '',
22515		}
22516	},
22517	computed: {
22518		canRegister() {
22519			// show register for shops on profile even if registration on restricted pages is disabled because it is needed for shop functionality
22520			// for websites dont show because else it would be possible to register 
22521
22522			let hasRegisterFunctionOnRestrictedPages = Boolean(SP_CONSTANTS.SHOP.CAN_REGISTER_ACCOUNT);
22523			let isWebsiteMode = SP_CONSTANTS.SHOP.WEBSITE_MODE === '1';
22524			let isProfilePage = window.location.pathname.includes('/profile');
22525			
22526			return hasRegisterFunctionOnRestrictedPages || (!isWebsiteMode && isProfilePage);
22527		},
22528		isRestrictedPage() {
22529			let isProfilePage = window.location.pathname.includes('/profile');
22530			return !isProfilePage;
22531		}
22532	},
22533	methods: {
22534		async login() {
22535			let apiData = await this.$store.dispatch('customer/login', [this.emailAddress, this.password]);
22536			if (!apiData.error) {
22537				this.$store.state.app.isWishlistPopupOpen = false;
22538
22539				if (this.isRestrictedPage) {
22540					// location.reload can't be used because it would cause the form resubmission dialog in some browsers
22541					window.location.href = window.location.href;
22542				} else if (localStorage.getItem('profile-refer-checkout') == '1') {
22543					window.location.href = this.localizeURL('/checkout');
22544				} else {
22545					this.message = '';
22546					await this.$store.dispatch('checkout/load');
22547					window.location.hash = '#!data';
22548					// this.loggedIn = true; // not used for checks, only that vue reevaluates the condition
22549					let event = new CustomEvent('loggedIn');
22550					document.dispatchEvent(event);
22551				}
22552
22553			} else {
22554				this.message = 'errors.user_or_password';
22555			}
22556		},
22557		goToLocalizedUrl(url) {
22558			window.location.href = this.localizeURL(url);
22559		}
22560	},
22561	mounted() {
22562		// remove the refer query parameter
22563		if (window.location.search.includes('refer')) {
22564			window.history.replaceState({}, document.title, window.location.pathname);
22565		}
22566	}
22567});
22568
22569;// ./vue/pages/profile/ProfileLogin.vue?vue&type=script&lang=js
22570 
22571// EXTERNAL MODULE: ./node_modules/vue-loader/dist/exportHelper.js
22572var exportHelper = __webpack_require__(6262);
22573;// ./vue/pages/profile/ProfileLogin.vue
22574
22575
22576
22577
22578;
22579const __exports__ = /*#__PURE__*/(0,exportHelper/* default */.A)(ProfileLoginvue_type_script_lang_js, [['render',render]])
22580
22581/* harmony default export */ const ProfileLogin = (__exports__);
22582
22583/***/ },
22584
22585/***/ 6262
22586(__unused_webpack_module, exports) {
22587
22588"use strict";
22589var __webpack_unused_export__;
22590
22591__webpack_unused_export__ = ({ value: true });
22592// runtime helper for setting properties on components
22593// in a tree-shakable way
22594exports.A = (sfc, props) => {
22595    const target = sfc.__vccOpts || sfc;
22596    for (const [key, val] of props) {
22597        target[key] = val;
22598    }
22599    return target;
22600};
22601
22602
22603/***/ },
22604
22605/***/ 6314
22606(module) {
22607
22608"use strict";
22609
22610
22611/*
22612  MIT License http://www.opensource.org/licenses/mit-license.php
22613  Author Tobias Koppers @sokra
22614*/
22615module.exports = function (cssWithMappingToString) {
22616  var list = [];
22617
22618  // return the list of modules as css string
22619  list.toString = function toString() {
22620    return this.map(function (item) {
22621      var content = "";
22622      var needLayer = typeof item[5] !== "undefined";
22623      if (item[4]) {
22624        content += "@supports (".concat(item[4], ") {");
22625      }
22626      if (item[2]) {
22627        content += "@media ".concat(item[2], " {");
22628      }
22629      if (needLayer) {
22630        content += "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {");
22631      }
22632      content += cssWithMappingToString(item);
22633      if (needLayer) {
22634        content += "}";
22635      }
22636      if (item[2]) {
22637        content += "}";
22638      }
22639      if (item[4]) {
22640        content += "}";
22641      }
22642      return content;
22643    }).join("");
22644  };
22645
22646  // import a list of modules into the list
22647  list.i = function i(modules, media, dedupe, supports, layer) {
22648    if (typeof modules === "string") {
22649      modules = [[null, modules, undefined]];
22650    }
22651    var alreadyImportedModules = {};
22652    if (dedupe) {
22653      for (var k = 0; k < this.length; k++) {
22654        var id = this[k][0];
22655        if (id != null) {
22656          alreadyImportedModules[id] = true;
22657        }
22658      }
22659    }
22660    for (var _k = 0; _k < modules.length; _k++) {
22661      var item = [].concat(modules[_k]);
22662      if (dedupe && alreadyImportedModules[item[0]]) {
22663        continue;
22664      }
22665      if (typeof layer !== "undefined") {
22666        if (typeof item[5] === "undefined") {
22667          item[5] = layer;
22668        } else {
22669          item[1] = "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {").concat(item[1], "}");
22670          item[5] = layer;
22671        }
22672      }
22673      if (media) {
22674        if (!item[2]) {
22675          item[2] = media;
22676        } else {
22677          item[1] = "@media ".concat(item[2], " {").concat(item[1], "}");
22678          item[2] = media;
22679        }
22680      }
22681      if (supports) {
22682        if (!item[4]) {
22683          item[4] = "".concat(supports);
22684        } else {
22685          item[1] = "@supports (".concat(item[4], ") {").concat(item[1], "}");
22686          item[4] = supports;
22687        }
22688      }
22689      list.push(item);
22690    }
22691  };
22692  return list;
22693};
22694
22695/***/ },
22696
22697/***/ 6791
22698(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
22699
22700"use strict";
22701/* harmony export */ __webpack_require__.d(__webpack_exports__, {
22702/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
22703/* harmony export */ });
22704/*
22705  One image url for the parts of the storefront that render in the browser
22706  (SPEC-imgproxy.md).
22707
22708  Cart, cart popup and wishlist fetch their contents after the page was built,
22709  so twig cannot prepare their urls the way it does for the product detail.
22710
22711  The rules stay in PHP regardless: everything below reads SP_CONSTANTS.IMAGE,
22712  which ImgproxyUrlBuilder::clientConfig() fills. Quality, the width grid, the
22713  path, the allowed sources - all values, none of them decided here. Change one
22714  in the builder and this follows without being touched.
22715
22716  Falls back to the url it was handed wherever the service is off for the shop
22717  or the source is not one it may load, which is what happened before.
22718*/
22719
22720function config() {
22721	if (typeof SP_CONSTANTS === 'undefined') return null;
22722	const c = SP_CONSTANTS.IMAGE;
22723	return c && c.enabled ? c : null;
22724}
22725
22726/** Same wildcard rule the service uses: `*` covers anything but a slash. */
22727function allowed(source, c) {
22728	return (c.allowed || []).some((prefix) => {
22729		const pattern = prefix
22730			.split('*')
22731			.map((part) => part.replace(/[.+?^${}()|[\]\\]/g, '\\$&'))
22732			.join('[^/]*');
22733		return new RegExp('^' + pattern).test(source);
22734	});
22735}
22736
22737function shorten(source, c) {
22738	for (const prefix of Object.keys(c.shorthands || {})) {
22739		if (source.indexOf(prefix) === 0) return c.shorthands[prefix] + source.slice(prefix.length);
22740	}
22741	return source;
22742}
22743
22744/** With /plain/ only the characters that would confuse the option parser move. */
22745function escapeSource(url) {
22746	return url.replace(/%/g, '%25').replace(/\?/g, '%3F').replace(/#/g, '%23').replace(/@/g, '%40');
22747}
22748
22749/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = ({
22750	methods: {
22751		/**
22752		 * @param image An image object, or a bare url string as the cart and
22753		 *   order payloads deliver it.
22754		 * @param width Rendered width in css pixels. Rounded UP to the grid -
22755		 *   rounding down would deliver a blurry image.
22756		 */
22757		imageSrc(image, width) {
22758			const fallback = typeof image === 'string' ? image : ((image && image.file) || '');
22759			const c = config();
22760			if (!image || !c) return fallback;
22761
22762			// `file` is the largest pre-scaled variant, not the original, and the
22763			// var/ tree it lives in goes away in phase 5 (SPEC B18).
22764			const source = typeof image === 'string'
22765				? image
22766				: (image.originalFile || image.file || '');
22767
22768			if (!source || !allowed(source, c)) return fallback;
22769
22770			const asked = width > 0 ? width : c.step;
22771			const target = Math.min(Math.ceil(asked / c.step) * c.step, c.maxDimension);
22772
22773			return c.base + c.prefix + '/' + c.signature
22774				+ '/rs:fit:' + target + ':0/g:sm/q:' + c.quality.webp
22775				+ '/plain/' + escapeSource(shorten(source, c)) + '@webp';
22776		},
22777	},
22778});
22779
22780
22781/***/ },
22782
22783/***/ 6968
22784(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
22785
22786"use strict";
22787/* harmony export */ __webpack_require__.d(__webpack_exports__, {
22788/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
22789/* harmony export */ });
22790/* harmony import */ var _Entity__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7249);
22791
22792
22793class ProductEntity extends _Entity__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A {
22794	constructor() {
22795		super();
22796	}
22797
22798	static createFromAPIData(obj) {
22799		return ProductEntity.map({
22800            id: 'id',
22801            title: 'title',
22802            type: 'type',
22803            giftVoucherType: 'giftVoucherType',
22804            giftVoucherPeriodOfValidity: 'giftVoucherPeriodOfValidity',
22805            image: 'image',
22806            manufacturer: 'manufacturer',
22807            slugName: 'slugName',
22808            shortDescription: 'shortDescription',
22809            slug: 'slug',
22810            stockLevel: 'stockLevel',
22811            maximalHouseholdAllowance: 'maximalHouseholdAllowance',
22812            visible: 'visible',
22813            purchaseUrl: 'purchaseUrl',
22814            cartButtonTitle: 'cartButtonTitle',
22815            guarantee: 'guarantee',
22816            fullPrice: {
22817                type: {},
22818                properties: {
22819                    amount: 'amount',
22820                    currencyCode: 'currencyCode',
22821                    taxAmount: 1416,
22822                    taxModel: "gross",
22823                    taxRate: 20
22824                }
22825            }
22826        },
22827		obj);
22828	}
22829
22830}
22831
22832/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (ProductEntity);
22833
22834
22835/***/ },
22836
22837/***/ 7249
22838(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
22839
22840"use strict";
22841/* harmony export */ __webpack_require__.d(__webpack_exports__, {
22842/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
22843/* harmony export */ });
22844// COPY FROM BACKEND ENTITY
22845
22846class Entity {
22847	static map(map, inputObject, toStdObj, filter) {
22848		if (!inputObject) return undefined;
22849
22850		// Use Entity or Standard Object
22851		let entity = (toStdObj) ? {} : new this();
22852
22853		for (let entityPropertyName in map) {
22854			let objectProperty = map[entityPropertyName];
22855
22856			// Setting Output Property
22857			if (typeof objectProperty == 'string' || Array.isArray(objectProperty)) {
22858				// Standard Mapping
22859				entity[entityPropertyName] = this.mapGetValue(objectProperty, inputObject, filter);
22860
22861				// if (typeof entity[entityPropertyName] == 'undefined') delete entity[entityPropertyName]; // removing the undefined fields generated by filter
22862
22863			} else {
22864				// Deep Mapping
22865				entity[entityPropertyName] = (() => {
22866
22867					let convertFunction = objectProperty.type[objectProperty.converter] || Entity.defaultConvert;
22868					let oldPropertyLocation = this.mapGetValue(objectProperty.property, inputObject, filter);
22869
22870					if (objectProperty.properties) {
22871						return convertFunction(inputObject[entityPropertyName], objectProperty);
22872					} else {
22873
22874						if (Array.isArray(oldPropertyLocation) || (typeof oldPropertyLocation == 'object' && objectProperty.toArray)) {
22875
22876							if (typeof oldPropertyLocation == 'object' && objectProperty.toArray) {
22877								oldPropertyLocation = Object.values(oldPropertyLocation);
22878							}
22879
22880							let list = [];
22881							for (let entry of oldPropertyLocation) {
22882								list.push(convertFunction(entry));
22883							}
22884
22885							if (objectProperty.useObject) list = {...list};
22886
22887							return list;
22888						} else {
22889							return convertFunction(oldPropertyLocation);
22890						}
22891					}
22892
22893				})();
22894			}
22895
22896		}
22897
22898		return entity;
22899	}
22900
22901	static mapGetValue(property, inputObject, filter) {
22902
22903		if (typeof property == 'string') {
22904			let [propertyName, usedFilter] = property.split(' | ');
22905			if (usedFilter) {
22906				if (filter == usedFilter) {
22907					property = propertyName;
22908				} else {
22909					return undefined;
22910				}
22911			}
22912		}
22913
22914		if (Array.isArray(property)) {
22915			let propertyValue = {...inputObject};
22916			for (let propertyPart of property) {
22917				if (propertyValue) {
22918					propertyValue = propertyValue[propertyPart];
22919				}
22920			}
22921			if (typeof propertyValue != 'undefined')  {
22922				return propertyValue;
22923			}// return (typeof propertyValue != 'undefined') ? propertyValue : null;
22924		} else {
22925			if (typeof inputObject[property] != 'undefined')  {
22926				return inputObject[property];
22927			}
22928			// return (typeof inputObject[property] != 'undefined') ? inputObject[property] : null;
22929		}
22930	}
22931
22932	static defaultConvert(values, settings) {
22933		if (values === null && settings.nullable === true) {
22934			return null;
22935		}
22936		let valueObject = {};
22937		if (settings && settings.properties && values) {
22938			for (let property in settings.properties) {
22939				valueObject[property] = values[settings.properties[property]]
22940			}
22941		}
22942		return valueObject;
22943	}
22944}
22945
22946/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Entity);
22947
22948
22949/***/ },
22950
22951/***/ 7520
22952(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
22953
22954"use strict";
22955/* harmony export */ __webpack_require__.d(__webpack_exports__, {
22956/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
22957/* harmony export */ });
22958/* harmony import */ var _Entity__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7249);
22959
22960
22961class PaymentMethodEntity extends _Entity__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A {
22962	constructor() {
22963		super();
22964	}
22965
22966	static createFromAPIData(obj) {
22967		return PaymentMethodEntity.map({
22968            id: 'id',
22969			name: 'name',
22970			identifier: 'identifier',
22971			chargeAmount: 'chargeAmount',
22972			chargeTaxRate: 'chargeTaxRate',
22973			activated: 'activated'
22974		},
22975		obj);
22976	}
22977
22978	static toPOJO(obj) {
22979		return PaymentMethodEntity.map({
22980            id: 'id',
22981            name: 'name',
22982			identifier: 'identifier',
22983			chargeAmount: 'chargeAmount',
22984			chargeTaxRate: 'chargeTaxRate',
22985		},
22986		obj,
22987		true);
22988	}
22989}
22990
22991/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (PaymentMethodEntity);
22992
22993
22994/***/ },
22995
22996/***/ 7659
22997(module) {
22998
22999"use strict";
23000
23001
23002var memo = {};
23003
23004/* istanbul ignore next  */
23005function getTarget(target) {
23006  if (typeof memo[target] === "undefined") {
23007    var styleTarget = document.querySelector(target);
23008
23009    // Special case to return head of iframe instead of iframe itself
23010    if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {
23011      try {
23012        // This will throw an exception if access to iframe is blocked
23013        // due to cross-origin restrictions
23014        styleTarget = styleTarget.contentDocument.head;
23015      } catch (e) {
23016        // istanbul ignore next
23017        styleTarget = null;
23018      }
23019    }
23020    memo[target] = styleTarget;
23021  }
23022  return memo[target];
23023}
23024
23025/* istanbul ignore next  */
23026function insertBySelector(insert, style) {
23027  var target = getTarget(insert);
23028  if (!target) {
23029    throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");
23030  }
23031  target.appendChild(style);
23032}
23033module.exports = insertBySelector;
23034
23035/***/ },
23036
23037/***/ 7825
23038(module) {
23039
23040"use strict";
23041
23042
23043/* istanbul ignore next  */
23044function apply(styleElement, options, obj) {
23045  var css = "";
23046  if (obj.supports) {
23047    css += "@supports (".concat(obj.supports, ") {");
23048  }
23049  if (obj.media) {
23050    css += "@media ".concat(obj.media, " {");
23051  }
23052  var needLayer = typeof obj.layer !== "undefined";
23053  if (needLayer) {
23054    css += "@layer".concat(obj.layer.length > 0 ? " ".concat(obj.layer) : "", " {");
23055  }
23056  css += obj.css;
23057  if (needLayer) {
23058    css += "}";
23059  }
23060  if (obj.media) {
23061    css += "}";
23062  }
23063  if (obj.supports) {
23064    css += "}";
23065  }
23066  var sourceMap = obj.sourceMap;
23067  if (sourceMap && typeof btoa !== "undefined") {
23068    css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */");
23069  }
23070
23071  // For old IE
23072  /* istanbul ignore if  */
23073  options.styleTagTransform(css, styleElement, options.options);
23074}
23075function removeStyleElement(styleElement) {
23076  // istanbul ignore if
23077  if (styleElement.parentNode === null) {
23078    return false;
23079  }
23080  styleElement.parentNode.removeChild(styleElement);
23081}
23082
23083/* istanbul ignore next  */
23084function domAPI(options) {
23085  if (typeof document === "undefined") {
23086    return {
23087      update: function update() {},
23088      remove: function remove() {}
23089    };
23090  }
23091  var styleElement = options.insertStyleElement(options);
23092  return {
23093    update: function update(obj) {
23094      apply(styleElement, options, obj);
23095    },
23096    remove: function remove() {
23097      removeStyleElement(styleElement);
23098    }
23099  };
23100}
23101module.exports = domAPI;
23102
23103/***/ },
23104
23105/***/ 8044
23106(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
23107
23108"use strict";
23109/* harmony export */ __webpack_require__.d(__webpack_exports__, {
23110/* harmony export */   A: () => (__WEBPACK_DEFAULT_EXPORT__)
23111/* harmony export */ });
23112/* harmony import */ var _Entity__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7249);
23113/* harmony import */ var _ProductEntity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6968);
23114
23115
23116
23117class CartItemEntity extends _Entity__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A {
23118	constructor() {
23119		super();
23120	}
23121
23122	static createFromAPIData(obj) {
23123		return CartItemEntity.map({
23124            title: 'title',
23125            type: 'type',
23126            optionChoice: 'optionChoice',
23127            quantity: 'quantity',
23128            variantId: 'variantId',
23129            variantSku: 'variantSku',
23130            configuration: 'configuration',
23131            cartItemConfigurations: 'cartItemConfigurations',
23132            orderItemConfigurations: 'orderItemConfigurations',
23133            price: {
23134                type: {},
23135                properties: {
23136					amount: 'amount',
23137					currency: 'currency',
23138                    taxModel: 'taxModel',
23139                    taxAmount: 'taxAmount',
23140                    taxRate: 'taxRate'
23141				}
23142            },
23143            totalPrice: {
23144                type: {},
23145                properties: {
23146					amount: 'amount',
23147					currency: 'currency',
23148                    taxModel: 'taxModel',
23149                    taxAmount: 'taxAmount',
23150                    taxRate: 'taxRate'
23151				}
23152            },
23153            pricePerUnit: {
23154                type: {},
23155                properties: {
23156					amount: 'amount',
23157					currency: 'currency',
23158                    taxModel: 'taxModel',
23159                    taxAmount: 'taxAmount',
23160                    taxRate: 'taxRate'
23161				}
23162            },
23163            grossPricePerUnit: {
23164                type: {},
23165                properties: {
23166					amount: 'amount',
23167					currency: 'currency',
23168                    taxModel: 'taxModel',
23169                    taxAmount: 'taxAmount',
23170                    taxRate: 'taxRate'
23171				}
23172            },
23173            grossPrice: {
23174                type: {},
23175                properties: {
23176					amount: 'amount',
23177					currency: 'currency',
23178                    taxModel: 'taxModel',
23179                    taxAmount: 'taxAmount',
23180                    taxRate: 'taxRate'
23181				}
23182            },
23183            productInfo: {
23184                type: {},
23185                properties: {
23186					title: 'title',
23187					essentialFeatures: 'essentialFeatures',
23188                    options: 'options',
23189                    image: 'image',
23190                    slugName: 'slugName'
23191				}
23192            },
23193            product: {
23194                type: _ProductEntity__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A,
23195                property: ['_embedded', 'product'],
23196				converter: 'createFromAPIData'
23197            }
23198        },
23199        obj);
23200    }
23201
23202    static toPOJO(obj) {
23203        let pojo = CartItemEntity.map({
23204            quantity: 'quantity',
23205            variantId: 'variantId',
23206            configuration: 'configuration',
23207            cartItemConfigurations: 'cartItemConfigurations',
23208        },
23209        obj,
23210        true);
23211
23212        let configurations = [];
23213        for (let cartItemConfiguration of pojo.cartItemConfigurations) {
23214            delete cartItemConfiguration.title;
23215            delete cartItemConfiguration.optionLabel;
23216            configurations.push(cartItemConfiguration);
23217        }
23218
23219
23220        return pojo;
23221    }
23222
23223    static toPaymentPOJO(obj) {
23224        return CartItemEntity.map({
23225            quantity: 'quantity',
23226            variantId: 'variantId',
23227            productInfo: {
23228                type: {},
23229                properties: {
23230					title: 'title',
23231					essentialFeatures: 'essentialFeatures',
23232                    options: 'options',
23233                    image: 'image',
23234                    slugName: 'slugName'
23235				}
23236            },
23237            price: {
23238                type: {},
23239                properties: {
23240					amount: 'amount',
23241					currency: 'currency',
23242                    taxModel: 'taxModel',
23243                    taxAmount: 'taxAmount',
23244                    taxRate: 'taxRate'
23245				}
23246            },
23247            grossPrice: {
23248                type: {},
23249                properties: {
23250					amount: 'amount',
23251					currency: 'currency',
23252                    taxModel: 'taxModel',
23253                    taxAmount: 'taxAmount',
23254                    taxRate: 'taxRate'
23255				}
23256            },
23257            pricePerUnit: {
23258                type: {},
23259                properties: {
23260					amount: 'amount',
23261					currency: 'currency',
23262                    taxModel: 'taxModel',
23263                    taxAmount: 'taxAmount',
23264                    taxRate: 'taxRate'
23265				}
23266            },
23267            grossPricePerUnit: {
23268                type: {},
23269                properties: {
23270					amount: 'amount',
23271					currency: 'currency',
23272                    taxModel: 'taxModel',
23273                    taxAmount: 'taxAmount',
23274                    taxRate: 'taxRate'
23275				}
23276            }
23277
23278        },
23279        obj,
23280        true);
23281    }
23282
23283    static toAnalyticsPOJO(obj) {
23284        let pojo = CartItemEntity.map({
23285            item_name: ['product', 'title'],
23286            item_id: 'variantId',
23287            price: ['pricePerUnit', 'amount'],
23288            // tax: ['pricePerUnit', 'taxAmount'],
23289            quantity: 'quantity'
23290        },
23291        obj,
23292        true);
23293
23294        pojo.price /= 100;
23295        // pojo.tax /= 100;
23296
23297        return pojo;
23298    }
23299
23300}
23301
23302/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (CartItemEntity);
23303
23304
23305/***/ },
23306
23307/***/ 8624
23308() {
23309
23310(function() {
23311  'use strict';
23312
23313  if (self.fetch) {
23314    return
23315  }
23316
23317  function normalizeName(name) {
23318    if (typeof name !== 'string') {
23319      name = name.toString();
23320    }
23321    if (/[^a-z0-9\-#$%&'*+.\^_`|~]/i.test(name)) {
23322      throw new TypeError('Invalid character in header field name')
23323    }
23324    return name.toLowerCase()
23325  }
23326
23327  function normalizeValue(value) {
23328    if (typeof value !== 'string') {
23329      value = value.toString();
23330    }
23331    return value
23332  }
23333
23334  function Headers(headers) {
23335    this.map = {}
23336
23337    if (headers instanceof Headers) {
23338      headers.forEach(function(value, name) {
23339        this.append(name, value)
23340      }, this)
23341
23342    } else if (headers) {
23343      Object.getOwnPropertyNames(headers).forEach(function(name) {
23344        this.append(name, headers[name])
23345      }, this)
23346    }
23347  }
23348
23349  Headers.prototype.append = function(name, value) {
23350    name = normalizeName(name)
23351    value = normalizeValue(value)
23352    var list = this.map[name]
23353    if (!list) {
23354      list = []
23355      this.map[name] = list
23356    }
23357    list.push(value)
23358  }
23359
23360  Headers.prototype['delete'] = function(name) {
23361    delete this.map[normalizeName(name)]
23362  }
23363
23364  Headers.prototype.get = function(name) {
23365    var values = this.map[normalizeName(name)]
23366    return values ? values[0] : null
23367  }
23368
23369  Headers.prototype.getAll = function(name) {
23370    return this.map[normalizeName(name)] || []
23371  }
23372
23373  Headers.prototype.has = function(name) {
23374    return this.map.hasOwnProperty(normalizeName(name))
23375  }
23376
23377  Headers.prototype.set = function(name, value) {
23378    this.map[normalizeName(name)] = [normalizeValue(value)]
23379  }
23380
23381  Headers.prototype.forEach = function(callback, thisArg) {
23382    Object.getOwnPropertyNames(this.map).forEach(function(name) {
23383      this.map[name].forEach(function(value) {
23384        callback.call(thisArg, value, name, this)
23385      }, this)
23386    }, this)
23387  }
23388
23389  function consumed(body) {
23390    if (body.bodyUsed) {
23391      return Promise.reject(new TypeError('Already read'))
23392    }
23393    body.bodyUsed = true
23394  }
23395
23396  function fileReaderReady(reader) {
23397    return new Promise(function(resolve, reject) {
23398      reader.onload = function() {
23399        resolve(reader.result)
23400      }
23401      reader.onerror = function() {
23402        reject(reader.error)
23403      }
23404    })
23405  }
23406
23407  function readBlobAsArrayBuffer(blob) {
23408    var reader = new FileReader()
23409    reader.readAsArrayBuffer(blob)
23410    return fileReaderReady(reader)
23411  }
23412
23413  function readBlobAsText(blob) {
23414    var reader = new FileReader()
23415    reader.readAsText(blob)
23416    return fileReaderReady(reader)
23417  }
23418
23419  var support = {
23420    blob: 'FileReader' in self && 'Blob' in self && (function() {
23421      try {
23422        new Blob();
23423        return true
23424      } catch(e) {
23425        return false
23426      }
23427    })(),
23428    formData: 'FormData' in self
23429  }
23430
23431  function Body() {
23432    this.bodyUsed = false
23433
23434
23435    this._initBody = function(body) {
23436      this._bodyInit = body
23437      if (typeof body === 'string') {
23438        this._bodyText = body
23439      } else if (support.blob && Blob.prototype.isPrototypeOf(body)) {
23440        this._bodyBlob = body
23441      } else if (support.formData && FormData.prototype.isPrototypeOf(body)) {
23442        this._bodyFormData = body
23443      } else if (!body) {
23444        this._bodyText = ''
23445      } else {
23446        throw new Error('unsupported BodyInit type')
23447      }
23448    }
23449
23450    if (support.blob) {
23451      this.blob = function() {
23452        var rejected = consumed(this)
23453        if (rejected) {
23454          return rejected
23455        }
23456
23457        if (this._bodyBlob) {
23458          return Promise.resolve(this._bodyBlob)
23459        } else if (this._bodyFormData) {
23460          throw new Error('could not read FormData body as blob')
23461        } else {
23462          return Promise.resolve(new Blob([this._bodyText]))
23463        }
23464      }
23465
23466      this.arrayBuffer = function() {
23467        return this.blob().then(readBlobAsArrayBuffer)
23468      }
23469
23470      this.text = function() {
23471        var rejected = consumed(this)
23472        if (rejected) {
23473          return rejected
23474        }
23475
23476        if (this._bodyBlob) {
23477          return readBlobAsText(this._bodyBlob)
23478        } else if (this._bodyFormData) {
23479          throw new Error('could not read FormData body as text')
23480        } else {
23481          return Promise.resolve(this._bodyText)
23482        }
23483      }
23484    } else {
23485      this.text = function() {
23486        var rejected = consumed(this)
23487        return rejected ? rejected : Promise.resolve(this._bodyText)
23488      }
23489    }
23490
23491    if (support.formData) {
23492      this.formData = function() {
23493        return this.text().then(decode)
23494      }
23495    }
23496
23497    this.json = function() {
23498      return this.text().then(JSON.parse)
23499    }
23500
23501    return this
23502  }
23503
23504  // HTTP methods whose capitalization should be normalized
23505  var methods = ['DELETE', 'GET', 'HEAD', 'OPTIONS', 'POST', 'PUT']
23506
23507  function normalizeMethod(method) {
23508    var upcased = method.toUpperCase()
23509    return (methods.indexOf(upcased) > -1) ? upcased : method
23510  }
23511
23512  function Request(url, options) {
23513    options = options || {}
23514    this.url = url
23515
23516    this.credentials = options.credentials || 'omit'
23517    this.headers = new Headers(options.headers)
23518    this.method = normalizeMethod(options.method || 'GET')
23519    this.mode = options.mode || null
23520    this.referrer = null
23521
23522    if ((this.method === 'GET' || this.method === 'HEAD') && options.body) {
23523      throw new TypeError('Body not allowed for GET or HEAD requests')
23524    }
23525    this._initBody(options.body)
23526  }
23527
23528  function decode(body) {
23529    var form = new FormData()
23530    body.trim().split('&').forEach(function(bytes) {
23531      if (bytes) {
23532        var split = bytes.split('=')
23533        var name = split.shift().replace(/\+/g, ' ')
23534        var value = split.join('=').replace(/\+/g, ' ')
23535        form.append(decodeURIComponent(name), decodeURIComponent(value))
23536      }
23537    })
23538    return form
23539  }
23540
23541  function headers(xhr) {
23542    var head = new Headers()
23543    var pairs = xhr.getAllResponseHeaders().trim().split('\n')
23544    pairs.forEach(function(header) {
23545      var split = header.trim().split(':')
23546      var key = split.shift().trim()
23547      var value = split.join(':').trim()
23548      head.append(key, value)
23549    })
23550    return head
23551  }
23552
23553  Body.call(Request.prototype)
23554
23555  function Response(bodyInit, options) {
23556    if (!options) {
23557      options = {}
23558    }
23559
23560    this._initBody(bodyInit)
23561    this.type = 'default'
23562    this.url = null
23563    this.status = options.status
23564    this.ok = this.status >= 200 && this.status < 300
23565    this.statusText = options.statusText
23566    this.headers = options.headers instanceof Headers ? options.headers : new Headers(options.headers)
23567    this.url = options.url || ''
23568  }
23569
23570  Body.call(Response.prototype)
23571
23572  self.Headers = Headers;
23573  self.Request = Request;
23574  self.Response = Response;
23575
23576  self.fetch = function(input, init) {
23577    // TODO: Request constructor should accept input, init
23578    var request
23579    if (Request.prototype.isPrototypeOf(input) && !init) {
23580      request = input
23581    } else {
23582      request = new Request(input, init)
23583    }
23584
23585    return new Promise(function(resolve, reject) {
23586      var xhr = new XMLHttpRequest()
23587
23588      function responseURL() {
23589        if ('responseURL' in xhr) {
23590          return xhr.responseURL
23591        }
23592
23593        // Avoid security warnings on getResponseHeader when not allowed by CORS
23594        if (/^X-Request-URL:/m.test(xhr.getAllResponseHeaders())) {
23595          return xhr.getResponseHeader('X-Request-URL')
23596        }
23597
23598        return;
23599      }
23600
23601      xhr.onload = function() {
23602        var status = (xhr.status === 1223) ? 204 : xhr.status
23603        if (status < 100 || status > 599) {
23604          reject(new TypeError('Network request failed'))
23605          return
23606        }
23607        var options = {
23608          status: status,
23609          statusText: xhr.statusText,
23610          headers: headers(xhr),
23611          url: responseURL()
23612        }
23613        var body = 'response' in xhr ? xhr.response : xhr.responseText;
23614        resolve(new Response(body, options))
23615      }
23616
23617      xhr.onerror = function() {
23618        reject(new TypeError('Network request failed'))
23619      }
23620
23621      xhr.open(request.method, request.url, true)
23622
23623      if (request.credentials === 'include') {
23624        xhr.withCredentials = true
23625      }
23626
23627      if ('responseType' in xhr && support.blob) {
23628        xhr.responseType = 'blob'
23629      }
23630
23631      request.headers.forEach(function(value, name) {
23632        xhr.setRequestHeader(name, value)
23633      })
23634
23635      xhr.send(typeof request._bodyInit === 'undefined' ? null : request._bodyInit)
23636    })
23637  }
23638  self.fetch.polyfill = true
23639})();
23640
23641
23642/***/ },
23643
23644/***/ 9945
23645() {
23646
23647class KlarnaPaymentService {
23648    constructor() {
23649
23650        this.subscriptions = [
23651            {
23652                "eventName": "payment.init",
23653                "functionName": "initKlarna"
23654            },
23655            {
23656                "eventName": "payment.paymentMethod.init",
23657                "functionName": "initPaymentMethod"
23658            },
23659            {
23660                "eventName": "payment.updateCheckout",
23661                "functionName": "updateCheckout"
23662            },
23663            {
23664                "eventName": "payment.confirm",
23665                "functionName": "confirm"
23666            }
23667
23668        ];
23669
23670        this.paymentMethodNames = ['klarna-pay-now', 'klarna-pay-later', 'klarna-pay-over-time'];
23671
23672    }
23673
23674    initKlarna(apiBaseUrl, shop, checkout, activePaymentMethods) {
23675
23676
23677        this.activePaymentMethods = activePaymentMethods;
23678
23679        let paymentMethodFound = false;
23680        for (let i=0; i<this.paymentMethodNames.length; i++) {
23681                let paymentMethodName = this.paymentMethodNames[i];
23682                if (activePaymentMethods.includes(paymentMethodName)) paymentMethodFound = true;
23683        }
23684        if (!paymentMethodFound) return;
23685
23686        this.apiBaseUrl = apiBaseUrl;
23687        this.shop = shop;
23688        this.checkout = checkout;
23689
23690        console.debug("klarna init happens now");
23691
23692        this.setPayloadFromCheckout(checkout);
23693
23694
23695        this.loadKlarnaJs();
23696
23697    }
23698
23699    loadKlarnaJs(){
23700        let script = document.createElement('script');
23701        script.src = "https://x.klarnacdn.net/kp/lib/v1/api.js";
23702        script.type = 'text/javascript';
23703        script.defer = true;
23704        script.async = true;
23705        document.getElementsByTagName('BODY').item(0).appendChild(script);
23706    }
23707
23708    initPaymentMethod(paymentMethodIdentifier, checkout) {
23709        if (this.paymentMethodNames.indexOf(paymentMethodIdentifier) >= 0) {
23710            console.debug("klarna payment method " + paymentMethodIdentifier + " is initialised now");
23711        }
23712    }
23713
23714    updateCheckout(checkout) {
23715        //TODO: call Klarna.Payments.load() with updated info
23716        // console.debug("klarna checkout update handler has recieved update notification");
23717    }
23718
23719
23720    setPayloadFromCheckout(checkout) {
23721
23722        let self = this;
23723
23724        let locale = this.shop.locale;
23725        if (locale.indexOf('_') < 2) {
23726            locale += "-" + this.shop.country.code;
23727        }
23728
23729        let payload = {
23730            "purchase_country": this.shop.country.code,
23731            "purchase_currency": this.shop.currencyCode,
23732            "locale": locale
23733        }
23734
23735        if (checkout.totalGrossPrice != undefined) {
23736            payload.order_amount = checkout.totalGrossPrice.amount;
23737        }
23738        payload.order_tax_amount = checkout.totalGrossPrice.taxAmount;
23739
23740        payload.order_lines = [];
23741        checkout.cartItems.forEach(
23742            function (cartItem) {
23743                let orderLine = {};
23744                orderLine.type = "physical"; //FIXME hardcoded
23745                orderLine.reference = cartItem.variantId; //FIXME use SKU instead
23746                orderLine.name = cartItem.productInfo.title;
23747                orderLine.quantity = cartItem.quantity;
23748                orderLine.unit_price = cartItem.grossPricePerUnit.amount;
23749                orderLine.tax_rate = cartItem.grossPrice.taxRate;
23750                orderLine.total_tax_amount = cartItem.grossPrice.taxAmount;
23751                orderLine.total_discount_amount = 0;
23752                orderLine.total_amount = cartItem.grossPrice.amount;
23753                orderLine.image_url = cartItem.productInfo.image.file;
23754                let slug = cartItem.productInfo ? cartItem.productInfo.slugName : '';
23755                orderLine.product_url = "https://" + self.shop.mainDomain.name + "/" + slug;
23756                payload.order_lines.push(orderLine);
23757            }
23758        );
23759
23760        if (checkout.paymentMethods) {
23761            let klarnaPaymentMethods = checkout.paymentMethods.filter(p => p.identifier == 'klarna-pay-now' || p.identifier == 'klarna-pay-later' || p.identifier == 'klarna-pay-over-time')
23762            if (klarnaPaymentMethods) {
23763                let paymentMethod = klarnaPaymentMethods.find(m => m.id == checkout.paymentMethodId);
23764
23765                if (paymentMethod && paymentMethod.chargeAmount) {
23766                    let orderLineSurcharge = {};
23767                    orderLineSurcharge.type = "surcharge";
23768                    orderLineSurcharge.reference = 'payment_method_charge';
23769                    orderLineSurcharge.name = 'Payment Method';
23770                    orderLineSurcharge.quantity = 1;
23771                    orderLineSurcharge.unit_price = paymentMethod.chargeAmount;
23772                    orderLineSurcharge.tax_rate = 0;
23773                    orderLineSurcharge.total_tax_amount = 0;
23774                    orderLineSurcharge.total_discount_amount = 0;
23775                    orderLineSurcharge.total_amount = paymentMethod.chargeAmount;
23776                    payload.order_lines.push(orderLineSurcharge);
23777                }
23778            }
23779        }
23780
23781        if (checkout.shippingGrossPrice && checkout.shippingGrossPrice.amount > 0) {
23782            let orderLine = {};
23783            orderLine.type = "shipping_fee";
23784            orderLine.reference = 'shipping'
23785            orderLine.name = 'Shipping';
23786            orderLine.quantity = 1;
23787            orderLine.unit_price = checkout.shippingGrossPrice.amount;
23788            orderLine.tax_rate = checkout.shippingGrossPrice.taxRate;
23789            orderLine.total_tax_amount = checkout.shippingGrossPrice.taxAmount;
23790            orderLine.total_discount_amount = 0;
23791            orderLine.total_amount = checkout.shippingGrossPrice.amount;
23792            payload.order_lines.push(orderLine);
23793        }
23794
23795        if (checkout.discounts && checkout.discounts.length > 0) {
23796            for (let discountKey in checkout.discounts) {
23797                let discount = checkout.discounts[discountKey];
23798
23799                let orderLine = {};
23800                orderLine.type = "discount";
23801                orderLine.reference = 'discount'
23802                orderLine.name = discount.title;
23803                orderLine.quantity = 1;
23804                orderLine.unit_price = -discount.grossReduction.amount;
23805                orderLine.tax_rate = discount.grossReduction.taxRate;
23806                orderLine.total_tax_amount = -discount.grossReduction.taxAmount;
23807                orderLine.total_discount_amount = 0;
23808                orderLine.total_amount = -discount.grossReduction.amount;
23809                payload.order_lines.push(orderLine);
23810            }
23811        }
23812
23813
23814        let customerBillingAddress = {}
23815        let customerDeliveryAddress = {}
23816        if (checkout.userdata && checkout.userdata.addresses) {
23817            if (!checkout.billingAddress.street) {
23818                // billingAddress is not set
23819
23820                let searchedBillingAddressId = checkout.customerBillingAddressId || checkout.customerDeliveryAddressId;
23821                for (let addressKey in checkout.userdata.addresses) {
23822                    let address = checkout.userdata.addresses[addressKey];
23823                    if (address.id == searchedBillingAddressId) {
23824                        customerBillingAddress = address;
23825                        break;
23826                    }
23827                }
23828                
23829            }
23830            
23831            if (!checkout.deliveryAddress.street) {
23832                // billingAddress is not set
23833                
23834                for (let addressKey in checkout.userdata.addresses) {
23835                    let address = checkout.userdata.addresses[addressKey];
23836                    if (address.id == checkout.customerDeliveryAddressId) {
23837                        customerDeliveryAddress = address;
23838                        break;
23839                    }
23840                }
23841                
23842            }
23843        }
23844
23845        payload.billing_address = {}
23846        payload.billing_address.given_name = checkout.billingAddress.firstName || customerBillingAddress.firstName;
23847        payload.billing_address.family_name = checkout.billingAddress.lastName || customerBillingAddress.lastName;
23848        payload.billing_address.email = checkout.emailAddress || checkout.userdata.emailAddress;
23849
23850        payload.billing_address.street_address = checkout.billingAddress.street || customerBillingAddress.street;
23851        // TODO: check payload.title = "Herr";
23852        // TODO: check street2
23853        payload.billing_address.postal_code = checkout.billingAddress.postCode || customerBillingAddress.postCode;
23854        payload.billing_address.city = checkout.billingAddress.city || customerBillingAddress.city;
23855        payload.billing_address.phone = checkout.phone || checkout.userdata.phone;
23856        payload.billing_address.country = checkout.billingAddress.countryCode || customerBillingAddress.countryCode;
23857
23858
23859
23860        payload.shipping_address = {}
23861        payload.shipping_address.given_name = checkout.deliveryAddress.firstName || customerDeliveryAddress.firstName;
23862        payload.shipping_address.family_name = checkout.deliveryAddress.lastName || customerDeliveryAddress.lastName;
23863        payload.shipping_address.email = checkout.emailAddress || checkout.userdata.emailAddress;
23864
23865        payload.shipping_address.street_address = checkout.deliveryAddress.street || customerDeliveryAddress.street;
23866        payload.shipping_address.postal_code = checkout.deliveryAddress.postCode || customerDeliveryAddress.postCode;
23867        payload.shipping_address.city = checkout.deliveryAddress.city || customerDeliveryAddress.city;
23868        payload.shipping_address.phone = checkout.phone || checkout.userdata.phone;
23869        payload.shipping_address.country = checkout.deliveryAddress.countryCode || customerDeliveryAddress.countryCode;
23870
23871        //TODO: provide real data
23872        // payload.customer = {
23873        //     date_of_birth: "1970-01-01"
23874        // }
23875
23876
23877        //TODO: provide deliveryAddress too
23878
23879        this.payload = payload;
23880    }
23881
23882    confirm(paymentMethodIdentifier, checkout) {
23883
23884        let self = this;
23885
23886        /*
23887        Klarna Doku on authorizing the purchase: https://developers.klarna.com/documentation/klarna-payments/single-call-descriptions/authorize-the-purchase/
23888        */
23889
23890        /*
23891        Best practice: To ensure that customers understand that some processing is going on in the background,
23892        when authorize() is called, it should be visually shown that something is happening (e.g. a spinner in
23893        the button that triggered the authorize() call).
23894
23895        When authorizing the order, Klarna conducts a full risk assessment. Therefore, from the point where you call authorize until you receive the callback y
23895ou must:
23896        - Avoid sending another authorize call (e.g. disable the buy button from being clicked again)
23897        - Show to the consumer that the order is being processed (e.g. by showing a loading spinner)
23898        - Prevent consumer from changing order or billing details (e.g. lock the input fields on your page)
23899        */
23900
23901
23902
23903        if (this.paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
23904
23905        self.setPayloadFromCheckout(checkout);
23906
23907        let klarnaPaymentCategoryIdentifier = paymentMethodIdentifier.replace("klarna-", "").replaceAll("-", "_");
23908
23909
23910
23911        Klarna.Payments.authorize(
23912            {
23913                payment_method_category: klarnaPaymentCategoryIdentifier
23914            },
23915            self.payload,
23916            function (res) {
23917
23918                // console.debug(res);
23919
23920                if (res.approved) {
23921                    console.info("Klarna approved");
23922                    // console.debug("token" + res.authorization_token);
23923                    let authorizationData = [
23924                        {key: 'authorizationToken', value: res.authorization_token},
23925                        {key: 'payload', value: JSON.stringify(self.payload)}
23926                    ];
23927                    paymentSubscriberNotifier.notify("payment.confirmed", authorizationData);
23928
23929
23930                } else {
23931                    console.info("Klarna not approved", res);
23932
23933                    let errorInfo = {
23934                    };
23935                    paymentSubscriberNotifier.notify("payment.confirmation-error", errorInfo);
23936
23937                    if (res.show_form) {
23938                        //TODO: Display Klarna’s widget
23939
23940                        if (res.error) {
23941                            //TODO: show error message to customer
23942                            //res.error.invalid_fields contains the names of the invalid properties
23943
23944
23945                        }
23946
23947                        //Let consumer change details and try again.
23948
23949                    } else {
23950                        //TODO: Disable the Klarna widget that matches the payment_method_category and pre-select another payment method.
23951                    }
23952
23953                }
23954
23955            }
23956        );
23957
23958
23959    }
23960
23961}
23962
23963
23964//Klarna Docu: https://developers.klarna.com/documentation/klarna-payments/single-call-descriptions/load-klarna-payments/
23965window.klarnaAsyncCallback = function () {
23966
23967
23968    var data = {
23969        payload: klarnaPaymentService.payload
23970    }
23971    let apiBaseUrl = klarnaPaymentService.apiBaseUrl;
23972    let shopId = klarnaPaymentService.shop.id;
23973    let checkoutId = klarnaPaymentService.checkout.id;
23974
23975    let url = apiBaseUrl + "/shops/" + shopId + "/checkout/" + checkoutId + "/payment/klarna/sessions";
23976    fetch(
23977        url,
23978        {
23979            method: 'POST', // *GET, POST, PUT, DELETE, etc.
23980            //mode: 'cors', // no-cors, *cors, same-origin
23981            //cache: 'no-cache', // *default, no-cache, reload, force-cache, only-if-cached
23982            //credentials: 'same-origin', // include, *same-origin, omit
23983            headers: {
23984                'Content-Type': 'application/json'
23985                // 'Content-Type': 'application/x-www-form-urlencoded',
23986            },
23987            //redirect: 'follow', // manual, *follow, error
23988            //referrerPolicy: 'no-referrer', // no-referrer, *no-referrer-when-downgrade, origin, origin-when-cross-origin, same-origin, strict-origin, strict-origin-when-cross-origin, unsafe-url
23989            body: JSON.stringify(data) // body data type must match "Content-Type" header
23990        }
23991    )
23992        .then(
23993            rawResponse => rawResponse.json()
23994        ).then(
23995        function(response){
23996
23997            //console.debug(response);
23998
23999            sessionData = response.payload;
24000
24001
24002            klarnaPaymentService.activePaymentMethods.includes('klarna-pay-now');
24003
24004
24005            try {
24006                Klarna.Payments.init({
24007                    client_token: sessionData.client_token
24008                });
24009
24010                klarnaPaymentMethodCategories = sessionData.payment_method_categories;
24011
24012
24013                for (var i = 0; i < klarnaPaymentMethodCategories.length; i++) {
24014
24015                    let klarnaPaymentMethodCategory = klarnaPaymentMethodCategories[i];
24016
24017                    let paymentMethodIdentifier = "klarna-" + klarnaPaymentMethodCategory.identifier.replaceAll("_", "-");
24018
24019                    if (!klarnaPaymentService.activePaymentMethods.includes(paymentMethodIdentifier)) continue;
24020
24021                    //TODO: we should try to initialize all klarna payment methods not only those which we get in session, because it c
24021ould happen that a change in our checkout leads to new payment types
24022
24023                    Klarna.Payments.load(
24024                        {
24025                            container: '#hook-container-' + paymentMethodIdentifier,
24026                            payment_method_category: klarnaPaymentMethodCategory.identifier
24027                        }, function (res) {
24028                            // console.debug("klarna-loaded");
24029                            // console.debug(res);
24030                            //res.show_form:true/false indicates whether you should make the Klarna option available in your checkout or if this option should not be available for this order
24031                            //res.error contains details of potential error messages
24032
24033                            if (res.show_form) {
24034                                //TODO: enable Klarna payment type as a choice
24035
24036                                if (res.error) {
24037                                    // res.error.invalid_fields contains infos about invalid fields
24038                                }
24039
24040                            } else {
24041                                // one of three ways to react:
24042                                // 1. Hide the Klarna option from the checkout.
24043                                // 2. Grey out the Klarna option and disable clicking.
24044                                // 3. Keep the Klarna option and accept an error message in the widget. Klarna will inform the consumer that this option is not available.
24045
24046                                let radioBox = document.getElementById("payment-method-" + paymentMethodIdentifier + "-radio");
24047                                if (radioBox !== null){
24048                                    radiobox.disabled = true;
24049                                }
24050
24051                            }
24052                        }
24053                    );
24054
24055                }
24056            } catch (e) {
24057                console.debug("klarna-error");
24058                // console.debug(e);
24059                // Handle error. The load~callback will have been called swith "{ show_form: false }" at this point.
24060            }
24061
24062        }
24063    );
24064}
24065
24066
24067let klarnaPaymentService = new KlarnaPaymentService();
24068paymentSubscriberRegistry.register(klarnaPaymentService);
24069
24070
24071/***/ }
24072
24073/******/ 	});
24074/************************************************************************/
24075/******/ 	// The module cache
24076/******/ 	var __webpack_module_cache__ = {};
24077/******/ 	
24078/******/ 	// The require function
24079/******/ 	function __webpack_require__(moduleId) {
24080/******/ 		// Check if module is in cache
24081/******/ 		var cachedModule = __webpack_module_cache__[moduleId];
24082/******/ 		if (cachedModule !== undefined) {
24083/******/ 			return cachedModule.exports;
24084/******/ 		}
24085/******/ 		// Create a new module (and put it into the cache)
24086/******/ 		var module = __webpack_module_cache__[moduleId] = {
24087/******/ 			id: moduleId,
24088/******/ 			// no module.loaded needed
24089/******/ 			exports: {}
24090/******/ 		};
24091/******/ 	
24092/******/ 		// Execute the module function
24093/******/ 		__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);
24094/******/ 	
24095/******/ 		// Return the exports of the module
24096/******/ 		return module.exports;
24097/******/ 	}
24098/******/ 	
24099/******/ 	// expose the modules object (__webpack_modules__)
24100/******/ 	__webpack_require__.m = __webpack_modules__;
24101/******/ 	
24102/************************************************************************/
24103/******/ 	/* webpack/runtime/compat get default export */
24104/******/ 	(() => {
24105/******/ 		// getDefaultExport function for compatibility with non-harmony modules
24106/******/ 		__webpack_require__.n = (module) => {
24107/******/ 			var getter = module && module.__esModule ?
24108/******/ 				() => (module['default']) :
24109/******/ 				() => (module);
24110/******/ 			__webpack_require__.d(getter, { a: getter });
24111/******/ 			return getter;
24112/******/ 		};
24113/******/ 	})();
24114/******/ 	
24115/******/ 	/* webpack/runtime/define property getters */
24116/******/ 	(() => {
24117/******/ 		// define getter functions for harmony exports
24118/******/ 		__webpack_require__.d = (exports, definition) => {
24119/******/ 			for(var key in definition) {
24120/******/ 				if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
24121/******/ 					Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
24122/******/ 				}
24123/******/ 			}
24124/******/ 		};
24125/******/ 	})();
24126/******/ 	
24127/******/ 	/* webpack/runtime/ensure chunk */
24128/******/ 	(() => {
24129/******/ 		__webpack_require__.f = {};
24130/******/ 		// This file contains only the entry chunk.
vendor: 9,080 bytes, lines 24131-24335
24131/******/ 		// The chunk loading function for additional chunks
24132/******/ 		__webpack_require__.e = (chunkId) => {
24133/******/ 			return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {
24134/******/ 				__webpack_require__.f[key](chunkId, promises);
24135/******/ 				return promises;
24136/******/ 			}, []));
24137/******/ 		};
24138/******/ 	})();
24139/******/ 	
24140/******/ 	/* webpack/runtime/get javascript chunk filename */
24141/******/ 	(() => {
24142/******/ 		// This function allow to reference async chunks
24143/******/ 		__webpack_require__.u = (chunkId) => {
24144/******/ 			// return url for filenames based on template
24145/******/ 			return "chunk." + {"46":"545b4d50484db57b2dfa","56":"b0aa447310c5f8bdedae","84":"f33d2faf021ab9f1add1","92":"ed459594275d96b22c05","214":"eb3860fff22f13738890","215":"4b970d82260285f30b7e","322":"239e2f8a3e4dc7a1aa83","326":"c15dfe2c447ceb5cc2ab","549":"476bb7e50b094e459f49","596":"cccb8915ba7417464134","608":"a6bf183480aa8b1937ef","865":"8c0ab018c4f4a5738d36","903":"d64ed69f99e630c063fb"}[chunkId] + ".js";
24146/******/ 		};
24147/******/ 	})();
24148/******/ 	
24149/******/ 	/* webpack/runtime/get mini-css chunk filename */
24150/******/ 	(() => {
24151/******/ 		// This function allow to reference async chunks
24152/******/ 		__webpack_require__.miniCssF = (chunkId) => {
24153/******/ 			// return url for filenames based on template
24154/******/ 			return undefined;
24155/******/ 		};
24156/******/ 	})();
24157/******/ 	
24158/******/ 	/* webpack/runtime/hasOwnProperty shorthand */
24159/******/ 	(() => {
24160/******/ 		__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
24161/******/ 	})();
24162/******/ 	
24163/******/ 	/* webpack/runtime/load script */
24164/******/ 	(() => {
24165/******/ 		var inProgress = {};
24166/******/ 		var dataWebpackPrefix = "frontend:";
24167/******/ 		// loadScript function to load a script via script tag
24168/******/ 		__webpack_require__.l = (url, done, key, chunkId) => {
24169/******/ 			if(inProgress[url]) { inProgress[url].push(done); return; }
24170/******/ 			var script, needAttach;
24171/******/ 			if(key !== undefined) {
24172/******/ 				var scripts = document.getElementsByTagName("script");
24173/******/ 				for(var i = 0; i < scripts.length; i++) {
24174/******/ 					var s = scripts[i];
24175/******/ 					if(s.getAttribute("src") == url || s.getAttribute("data-webpack") == dataWebpackPrefix + key) { script = s; break; }
24176/******/ 				}
24177/******/ 			}
24178/******/ 			if(!script) {
24179/******/ 				needAttach = true;
24180/******/ 				script = document.createElement('script');
24181/******/ 		
24182/******/ 				script.charset = 'utf-8';
24183/******/ 				if (__webpack_require__.nc) {
24184/******/ 					script.setAttribute("nonce", __webpack_require__.nc);
24185/******/ 				}
24186/******/ 				script.setAttribute("data-webpack", dataWebpackPrefix + key);
24187/******/ 		
24188/******/ 				script.src = url;
24189/******/ 			}
24190/******/ 			inProgress[url] = [done];
24191/******/ 			var onScriptComplete = (prev, event) => {
24192/******/ 				// avoid mem leaks in IE.
24193/******/ 				script.onerror = script.onload = null;
24194/******/ 				clearTimeout(timeout);
24195/******/ 				var doneFns = inProgress[url];
24196/******/ 				delete inProgress[url];
24197/******/ 				script.parentNode && script.parentNode.removeChild(script);
24198/******/ 				doneFns && doneFns.forEach((fn) => (fn(event)));
24199/******/ 				if(prev) return prev(event);
24200/******/ 			}
24201/******/ 			var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);
24202/******/ 			script.onerror = onScriptComplete.bind(null, script.onerror);
24203/******/ 			script.onload = onScriptComplete.bind(null, script.onload);
24204/******/ 			needAttach && document.head.appendChild(script);
24205/******/ 		};
24206/******/ 	})();
24207/******/ 	
24208/******/ 	/* webpack/runtime/make namespace object */
24209/******/ 	(() => {
24210/******/ 		// define __esModule on exports
24211/******/ 		__webpack_require__.r = (exports) => {
24212/******/ 			if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
24213/******/ 				Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
24214/******/ 			}
24215/******/ 			Object.defineProperty(exports, '__esModule', { value: true });
24216/******/ 		};
24217/******/ 	})();
24218/******/ 	
24219/******/ 	/* webpack/runtime/publicPath */
24220/******/ 	(() => {
24221/******/ 		__webpack_require__.p = "/build/";
24222/******/ 	})();
24223/******/ 	
24224/******/ 	/* webpack/runtime/jsonp chunk loading */
24225/******/ 	(() => {
24226/******/ 		// no baseURI
24227/******/ 		
24228/******/ 		// object to store loaded and loading chunks
24229/******/ 		// undefined = chunk not loaded, null = chunk preloaded/prefetched
24230/******/ 		// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded
24231/******/ 		var installedChunks = {
24232/******/ 			792: 0
24233/******/ 		};
24234/******/ 		
24235/******/ 		__webpack_require__.f.j = (chunkId, promises) => {
24236/******/ 				// JSONP chunk loading for javascript
24237/******/ 				var installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;
24238/******/ 				if(installedChunkData !== 0) { // 0 means "already installed".
24239/******/ 		
24240/******/ 					// a Promise means "currently loading".
24241/******/ 					if(installedChunkData) {
24242/******/ 						promises.push(installedChunkData[2]);
24243/******/ 					} else {
24244/******/ 						if(true) { // all chunks have JS
24245/******/ 							// setup Promise in chunk cache
24246/******/ 							var promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));
24247/******/ 							promises.push(installedChunkData[2] = promise);
24248/******/ 		
24249/******/ 							// start chunk loading
24250/******/ 							var url = __webpack_require__.p + __webpack_require__.u(chunkId);
24251/******/ 							// create error before stack unwound to get useful stacktrace later
24252/******/ 							var error = new Error();
24253/******/ 							var loadingEnded = (event) => {
24254/******/ 								if(__webpack_require__.o(installedChunks, chunkId)) {
24255/******/ 									installedChunkData = installedChunks[chunkId];
24256/******/ 									if(installedChunkData !== 0) installedChunks[chunkId] = undefined;
24257/******/ 									if(installedChunkData) {
24258/******/ 										var errorType = event && (event.type === 'load' ? 'missing' : event.type);
24259/******/ 										var realSrc = event && event.target && event.target.src;
24260/******/ 										error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')';
24261/******/ 										error.name = 'ChunkLoadError';
24262/******/ 										error.type = errorType;
24263/******/ 										error.request = realSrc;
24264/******/ 										installedChunkData[1](error);
24265/******/ 									}
24266/******/ 								}
24267/******/ 							};
24268/******/ 							__webpack_require__.l(url, loadingEnded, "chunk-" + chunkId, chunkId);
24269/******/ 						}
24270/******/ 					}
24271/******/ 				}
24272/******/ 		};
24273/******/ 		
24274/******/ 		// no prefetching
24275/******/ 		
24276/******/ 		// no preloaded
24277/******/ 		
24278/******/ 		// no HMR
24279/******/ 		
24280/******/ 		// no HMR manifest
24281/******/ 		
24282/******/ 		// no on chunks loaded
24283/******/ 		
24284/******/ 		// install a JSONP callback for chunk loading
24285/******/ 		var webpackJsonpCallback = (parentChunkLoadingFunction, data) => {
24286/******/ 			var [chunkIds, moreModules, runtime] = data;
24287/******/ 			// add "moreModules" to the modules object,
24288/******/ 			// then flag all "chunkIds" as loaded and fire callback
24289/******/ 			var moduleId, chunkId, i = 0;
24290/******/ 			if(chunkIds.some((id) => (installedChunks[id] !== 0))) {
24291/******/ 				for(moduleId in moreModules) {
24292/******/ 					if(__webpack_require__.o(moreModules, moduleId)) {
24293/******/ 						__webpack_require__.m[moduleId] = moreModules[moduleId];
24294/******/ 					}
24295/******/ 				}
24296/******/ 				if(runtime) var result = runtime(__webpack_require__);
24297/******/ 			}
24298/******/ 			if(parentChunkLoadingFunction) parentChunkLoadingFunction(data);
24299/******/ 			for(;i < chunkIds.length; i++) {
24300/******/ 				chunkId = chunkIds[i];
24301/******/ 				if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {
24302/******/ 					installedChunks[chunkId][0]();
24303/******/ 				}
24304/******/ 				installedChunks[chunkId] = 0;
24305/******/ 			}
24306/******/ 		
24307/******/ 		}
24308/******/ 		
24309/******/ 		var chunkLoadingGlobal = globalThis["webpackChunkfrontend"] = globalThis["webpackChunkfrontend"] || [];
24310/******/ 		chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));
24311/******/ 		chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));
24312/******/ 	})();
24313/******/ 	
24314/******/ 	/* webpack/runtime/nonce */
24315/******/ 	(() => {
24316/******/ 		__webpack_require__.nc = undefined;
24317/******/ 	})();
24318/******/ 	
24319/************************************************************************/
24320var __webpack_exports__ = {};
24321// This entry needs to be wrapped in an IIFE because it needs to be in strict mode.
24322(() => {
24323"use strict";
24324
24325// EXTERNAL MODULE: ./vue/payment/payment.js
24326var payment = __webpack_require__(4345);
24327// EXTERNAL MODULE: ./vue/payment/klarna/klarna-payment-service.js
24328var klarna_payment_service = __webpack_require__(9945);
24329// EXTERNAL MODULE: ./vue/misc/SecureCookie.js
24330var SecureCookie = __webpack_require__(1016);
24331;// ./vue/payment/stripe/stripe-payment-service.js
24332
24333
24334let stripePaymentService = {};
24335let waitForStripeInit = false;
24336stripePaymentService =
24337{
24338    subscriptions: [
24339        {
24340            "eventName": "payment.init",
24341            "functionName": "initStripe"
24342        },
24343        {
24344            "eventName": "payment.paymentMethod.init",
24345            "functionName": "initPaymentMethod"
24346        },
24347        {
24348            "eventName": "payment.confirm",
24349            "functionName": "confirm"
24350        }
24351
24352    ],
24353
24354    initStripe: function(apiBaseUrl,  shop, checkout) {
24355        console.debug("stripe init happens now");
24356        this.checkout = checkout;
24357        this.apiBaseUrl = apiBaseUrl;
24358        this.shop = shop;
24359        if (this.waitForStripeInit) this.createPaymentIntent();
24360    },
24361
24362
24363    initPaymentMethod: function(paymentMethodIdentifier, checkout) {
24364
24365        let paymentMethodNames = ['stripe-payments'];
24366        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
24367
24368        console.debug("stripe payment method " + paymentMethodIdentifier + " gets initialised now");
24369
24370        this.checkout = checkout;
24371
24372        this.createHtmlForm(paymentMethodIdentifier);
24373        return this.createPaymentIntent();
24374
24375
24376    },
24377
24378    confirm(paymentMethodIdentifier, checkout) {
24379
24380        let self = this;
24381
24382        let paymentMethodNames = ['stripe-payments'];
24383        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
24384
24385        console.debug("confirming " + paymentMethodIdentifier + " payment now");
24386
24387        self.stripe.confirmCardPayment(
24388            self.clientSecret,
24389            {
24390                payment_method: {
24391                    card: self.cardNumber,
24392                    billing_details: {
24393                        //name: 'Jenny Rosen'
24394                    }
24395                }
24396            }
24397        ).then(
24398            function(result) {
24399                if (result.error) {
24400                    // Show error to your customer (e.g., insufficient funds)
24401                    console.info(result.error);
24402                    let errorInfo = {
24403                        "message": result.error.message
24404                    };
24405                    paymentSubscriberNotifier.notify("payment.confirmation-error", errorInfo);
24406
24407                } else {
24408                    // The payment has been processed!
24409                    // console.debug(result.paymentIntent);
24410                    if (result.paymentIntent && result.paymentIntent.status === 'requires_capture') {
24411                        console.info("Stripe payment successfully confirmed");
24412
24413                        let authorizationData = [
24414                            {key: 'paymentIntentId', value: result.paymentIntent.id}
24415                        ];
24416
24417                        paymentSubscriberNotifier.notify("payment.confirmed", authorizationData);
24418
24419                        // Show a success message to your customer
24420                        // There's a risk of the customer closing the window before callback
24421                        // execution. Set up a webhook or plugin to listen for the
24422                        // payment_intent.succeeded event that handles any business critical
24423                        // post-payment actions.
24424                    }
24425                }
24426            }
24427        );
24428
24429    },
24430
24431    loadStripeJs: function(){
24432
24433        // Stripe.js has to be present before any Element can be created. Resolve right
24434        // away when it is already there and reuse a pending load, so repeated payment
24435        // method activations do not inject the script tag more than once.
24436        if (typeof Stripe !== 'undefined') return Promise.resolve();
24437        if (this.stripeJsPromise) return this.stripeJsPromise;
24438
24439        this.stripeJsPromise = new Promise(function(resolve, reject) {
24440            let script = document.createElement('script');
24441            script.src = "https://js.stripe.com/v3/";
24442            script.type = 'text/javascript';
24443            script.onload = resolve;
24444            script.onerror = function() {
24445                reject(new Error('Could not load Stripe.js'));
24446            };
24447            document.getElementsByTagName('BODY').item(0).appendChild(script);
24448        });
24449
24450        return this.stripeJsPromise;
24451    },
24452
24453    createWalletButton: function(elements){
24454
24455        // Apple Pay / Google Pay are offered through the Payment Request API. Stripe
24456        // decides which wallet is shown based on the browser, so a single button covers
24457        // both of them.
24458        let self = this;
24459
24460        let container = document.getElementById('payment-request-button');
24461        if (!container) return;
24462
24463        let countryCode = (self.shop && self.shop.country) ? self.shop.country.code : null;
24464        if (!countryCode) {
24465            // Without the merchant country Stripe cannot tell whether a wallet may be
24466            // offered, and a wrong country makes the wallet sheet fail. Skip the button
24467            // instead of guessing.
24468            container.style.display = 'none';
24469            console.warn("Stripe payment service: no shop country available, wallet button (Apple Pay / Google Pay) is skipped");
24470            return;
24471        }
24472
24473        let paymentRequest = self.stripe.paymentRequest({
24474            country: countryCode.toUpperCase(),
24475            currency: self.checkout.totalGrossPrice.currency.toLowerCase(),
24476            total: {
24477                label: self.shop.name ? self.shop.name : 'Gesamtsumme',
24478                amount: self.checkout.totalGrossPrice.amount,
24479            },
24480            requestPayerName: true,
24481            requestPayerEmail: true,
24482        });
24483        self.paymentRequest = paymentRequest;
24484
24485        const isDark = window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches;
24486        const prButton = elements.create('paymentRequestButton', {
24487            paymentRequest: paymentRequest,
24488            style: {
24489                paymentRequestButton: {
24490                    type: 'buy',
24491                    theme: isDark ? 'dark': 'light',
24492                    height: '44px',
24493                },
24494            }
24495        });
24496
24497        paymentRequest.on('paymentmethod', function(event) {
24498            self.confirmWalletPayment(event);
24499        });
24500
24501        paymentRequest.canMakePayment().then(function (result) {
24502            if (result) {
24503                prButton.mount('#payment-request-button');
24504            } else {
24505                // No wallet available: unsupported browser, no card set up in the wallet,
24506                // or the shop domain is not registered as a payment method domain in the
24507                // connected Stripe account.
24508                container.style.display = 'none';
24509                console.debug("Stripe payment service: no wallet available for Apple Pay / Google Pay");
24510            }
24511        });
24512    },
24513
24514    confirmWalletPayment: async function(event){
24515
24516        let self = this;
24517
24518        // The wallet sheet pays immediately and bypasses the regular "place order"
24519        // button, so the checks that button runs have to happen here as well.
24520        let validation = {valid: true, message: null};
24521        document.dispatchEvent(new CustomEvent('checkoutWalletPaymentValidate', {detail: validation}));
24522
24523        if (!validation.valid) {
24524            event.complete('fail');
24525            paymentSubscriberNotifier.notify("payment.confirmation-error", {message: validation.message});
24526            return;
24527        }
24528
24529        document.dispatchEvent(new CustomEvent('checkoutWalletPaymentStarted'));
24530
24531        // handleActions false lets us close the wallet sheet through event.complete()
24532        // first and run a possible 3-D Secure step afterwards, outside of the sheet.
24533        let firstConfirmation = await self.stripe.confirmCardPayment(
24534            self.clientSecret,
24535            {
24536                payment_method: event.paymentMethod.id
24537            },
24538            {
24539                handleActions: false
24540            }
24541        );
24542
24543        if (firstConfirmation.error) {
24544            console.info(firstConfirmation.error);
24545            event.complete('fail');
24546            paymentSubscriberNotifier.notify("payment.confirmation-error", {message: firstConfirmation.error.message});
24547            return;
24548        }
24549
24550        event.complete('success');
24551
24552        let paymentIntent = firstConfirmation.paymentIntent;
24553
24554        if (paymentIntent && paymentIntent.status === 'requires_action') {
24555            let secondConfirmation = await self.stripe.confirmCardPayment(self.clientSecret);
24556            if (secondConfirmation.error) {
24557                console.info(secondConfirmation.error);
24558                paymentSubscriberNotifier.notify("payment.confirmation-error", {message: secondConfirmation.error.message});
24559                return;
24560            }
24561            paymentIntent = secondConfirmation.paymentIntent;
24562        }
24563
24564        // Payment intents are created with capture_method "manual", so an authorized
24565        // payment ends up as "requires_capture". The capture itself happens in the API
24566        // when the order is created.
24567        if (!paymentIntent || paymentIntent.status !== 'requires_capture') {
24568            paymentSubscriberNotifier.notify("payment.confirmation-error", {message: 'errors.unexpected_error'});
24569            return;
24570        }
24571
24572        console.info("Stripe wallet payment successfully confirmed");
24573
24574        let authorizationData = [
24575            {key: 'paymentIntentId', value: paymentIntent.id}
24576        ];
24577
24578        paymentSubscriberNotifier.notify("payment.confirmed", authorizationData);
24579    },
24580
24581    createHtmlForm: function(paymentMethodIdentifier){
24582
24583        let hookContainer = document.getElementById("hook-container-" + paymentMethodIdentifier);
24584
24585        let html = '';
24586
24587        html += '<div id="payment-request-button" class="mt-2"></div>';
24588
24589        html += '<form id="stripe-payment-form">';
24590
24591        html += '<div class="gs_input_fieldset input__fieldset fieldset--active mb-2 mt-2"><div class="sp-input__title-wrapper"><label class="gs_input__title sp-input__title">Kreditkartennummer</label></div><div class="sp-input gs_input__input" id="card-number"></div></div>';
24592
24593        html += '<div class="gs_input_fieldset input__fieldset fieldset--active mb-2"><div class="sp-input__title-wrapper"><label class="gs_input__title sp-input__title">Gültig bis</label></div><div class="sp-input gs_input__input" id="card-expiry"></div></div>';
24594
24595        html += '<div class="gs_input_fieldset input__fieldset fieldset--active mb-2"><div class="sp-input__title-wrapper"><label class="gs_input__title sp-input__title">Sicherheitscode</label></div><div class="sp-input gs_input__input" id="card-cvc"></div></div>';
24596
24597        html += '<div id="card-errors" class="checkout__error-message" role="alert"></div>';
24598
24599        html += '</form>';
24600
24601        hookContainer.innerHTML = html;
24602
24603    },
24604    createPaymentIntent: function(){
24605
24606        let self = this;
24607        let headers = {
24608            'Content-Type': 'application/json',
24609        };
24610        if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
24611            headers = {
24612                'Content-Type': 'application/json',
24613                'Authorization': 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token')
24614            };
24615        }
24616
24617        if (!self.checkout || !self.shop) {
24618            console.error("Stripe payment service: No checkout or shop data available. Wait for init.");
24619            self.waitForStripeInit = true;
24620            return;
24621        }
24622
24623        let url = self.apiBaseUrl + "/shops/" + self.shop.id + "/checkout/" + self.checkout.id + "/payment/stripe/paymentIntents";
24624
24625        // The payment intent request and the Stripe.js download run in parallel, but the
24626        // global Stripe object is only used once both are finished.
24627        return Promise.all([
24628            fetch(
24629                url,
24630                {
24631                    method: 'POST', // *GET, POST, PUT, DELETE, etc.
24632                    //mode: 'cors', // no-cors, *cors, same-origin
24633                    //cache: 'no-cache', // *default, no-cache, reload, force-cache, only-if-cached
24634                    //credentials: 'same-origin', // include, *same-origin, omit
24635                    headers: headers,
24636                    //redirect: 'follow', // manual, *follow, error
24637                    //referrerPolicy: 'no-referrer', // no-referrer, *no-referrer-when-downgrade, origin, origin-when-cross-origin, same-origin, strict-origin, strict-origin-when-cross-origin, unsafe-url
24638                    // body: JSON.stringify(data) // body data type must match "Content-Type" header
24639                }
24640            ).then(
24641                rawResponse => rawResponse.json()
24642            ),
24643            self.loadStripeJs()
24644        ]).then(
24645            function ([response]) {
24646                self.clientSecret = response.clientSecret;
24647                self.connectedStripeAccountId = response.connectedStripeAccountId;
24648                self.publicKey = response.publicKey;
24649
24650                // Set up Stripe.js and Elements to use in checkout form
24651                let style = {
24652                    base: {
24653                        color: "#000"
24654                    }
24655                };
24656
24657                let stripeCardHandler = function(event) {
24658                    var displayError = document.getElementById('card-errors');
24659                    if (event.error) {
24660                        displayError.textContent = event.error.message;
24661                    } else {
24662                        displayError.textContent = '';
24663                    }
24664                }
24665
24666                self.stripe = Stripe(
24667                    self.publicKey,
24668                    {
24669                        stripeAccount: self.connectedStripeAccountId
24670                    }
24671                );
24672
24673                let elements = self.stripe.elements({clientSecret: self.clientSecret});
24674
24675                self.createWalletButton(elements);
24676
24677                self.cardNumber = elements.create("cardNumber", { style: style });
24678                self.cardNumber.mount("#card-number");
24679                self.cardNumber.on('change', stripeCardHandler);
24680
24681                self.cardCvc = elements.create("cardCvc", { style: style });
24682                self.cardCvc.mount("#card-cvc");
24683                self.cardCvc.on('change', stripeCardHandler);
24684
24685                self.cardExpiry = elements.create("cardExpiry", { style: style });
24686                self.cardExpiry.mount("#card-expiry");
24687                self.cardExpiry.on('change', stripeCardHandler);
24688
24689                let form = document.getElementById('stripe-payment-form');
24690
24691            }
24692        ).catch(
24693            function (error) {
24694                // Without this the whole setup fail
24694s silently and the customer just sees
24695                // an empty payment area.
24696                console.error("Stripe payment service: could not initialise payment", error);
24697                paymentSubscriberNotifier.notify("payment.confirmation-error", {message: 'errors.unexpected_error'});
24698            }
24699        );
24700    }
24701
24702}
24703
24704paymentSubscriberRegistry.register(stripePaymentService);
24705
24706;// ./vue/payment/paypal/paypal-payment-service.js
24707
24708
24709let paypalPaymentService = {};
24710paypalPaymentService =
24711{
24712    subscriptions: [
24713        {
24714            "eventName": "payment.init",
24715            "functionName": "initPaypal"
24716        },
24717        {
24718            "eventName": "payment.paymentMethod.init",
24719            "functionName": "initPaymentMethod"
24720        },
24721        {
24722            "eventName": "payment.confirm",
24723            "functionName": "confirm"
24724        }
24725    ],
24726
24727    initPaypal(apiBaseUrl, shop, checkout) {
24728
24729        console.debug("paypal init happens now");
24730
24731        this.apiBaseUrl = apiBaseUrl;
24732        this.shop = shop;
24733        this.checkout = checkout;
24734    },
24735
24736    initPaymentMethod(paymentMethodIdentifier, checkout) {
24737
24738        let paymentMethodNames = ['paypal-standard'];
24739        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
24740
24741        console.debug("paypal payment method " + paymentMethodIdentifier + " gets initialised now");
24742        this.checkout = checkout;
24743
24744    },
24745    confirm(paymentMethodIdentifier, checkout) {
24746
24747        let paymentMethodNames = ['paypal-standard'];
24748        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
24749
24750        console.debug('Paypal payment confirm');
24751
24752        let self = this;
24753
24754        self.checkout = checkout;
24755
24756        self.createOrder(
24757            function(orderStatus, orderId, approvalLinkHref){
24758                if (orderStatus == 'CREATED'){
24759                    console.info("PayPal order with ID " + orderId + ' created. Please redirect user to ' + approvalLinkHref) + ' to approve the order';
24760                    let authParams = [{key: 'orderId', value: orderId, redirectUrl: approvalLinkHref}];
24761                    paymentSubscriberNotifier.notify("payment.save-authorizations", authParams);
24762                } else {
24763                    console.info("PayPal returned an unexpected order status: " + orderStatus);
24764                    let errorInfo = {
24765                    };//TODO: PROVIDE MORE INFO
24766                    paymentSubscriberNotifier.notify("payment.confirmation-error", errorInfo);
24767                }
24768
24769            }
24770        );
24771
24772    },
24773    createOrder(callback){
24774
24775        let self = this;
24776        let headers = {
24777            'Content-Type': 'application/json',
24778        };
24779        if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
24780            headers = {
24781                'Content-Type': 'application/json',
24782                'Authorization': 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token')
24783            };
24784        }
24785
24786        let url = this.apiBaseUrl + "/shops/" + this.shop.id + "/checkout/" + self.checkout.id + "/payment/paypal/orders";
24787        //let [checkoutURL, checkoutHash] = window.location.href.split('#');
24788        //let callbackUrl = checkoutURL.split('?').slice(0, 1).join('/') + '?paypalreturn=1';
24789        let callbackUrl = '/checkout?paypalreturn=1';
24790        let data = {
24791            callbackUrl: callbackUrl
24792        }
24793        fetch(
24794            url,
24795            {
24796                method: 'POST', // *GET, POST, PUT, DELETE, etc.
24797                //mode: 'same-origin', // no-cors, *cors, same-origin
24798                //cache: 'no-cache', // *default, no-cache, reload, force-cache, only-if-cached
24799                //withCredentials: true,
24800                //credentials: 'include', // include, *same-origin, omit
24801                headers: headers,
24802                //redirect: 'follow', // manual, *follow, error
24803                //referrerPolicy: 'no-referrer', // no-referrer, *no-referrer-when-downgrade, origin, origin-when-cross-origin, same-origin, strict-origin, strict-origin-when-cross-origin, unsafe-url
24804                body: JSON.stringify(data) // body data type must match "Content-Type" header
24805            }
24806        ).then(
24807            function(rawResponse){
24808                if (!rawResponse.ok){
24809                    throw new Error('Order could not be created');
24810                }
24811                return rawResponse;
24812            }
24813        ).then(
24814            rawResponse => rawResponse.json()
24815        ).then(
24816            paypalOrder => callback(paypalOrder.status, paypalOrder.id, paypalOrder._links.approve.href)
24817        ).catch(error => {
24818            console.info('There has been a problem with PayPal confirmation');
24819            let errorInfo = {}
24820            paymentSubscriberNotifier.notify("payment.confirmation-error", errorInfo);
24821        });
24822    }
24823}
24824
24825paymentSubscriberRegistry.register(paypalPaymentService);
24826
24827;// ./vue/payment/mollie/mollie-payment-service.js
24828
24829
24830let molliePaymentService = {};
24831molliePaymentService =
24832{
24833    subscriptions: [
24834        {
24835            "eventName": "payment.init",
24836            "functionName": "initMollie"
24837        },
24838        {
24839            "eventName": "payment.paymentMethod.init",
24840            "functionName": "initPaymentMethod"
24841        },
24842        {
24843            "eventName": "payment.confirm",
24844            "functionName": "confirm"
24845        }
24846    ],
24847
24848    initMollie(apiBaseUrl, shop, checkout) {
24849
24850        console.debug("mollie init happens now");
24851
24852        this.apiBaseUrl = apiBaseUrl;
24853        this.shop = shop;
24854        this.checkout = checkout;
24855    },
24856
24857    initPaymentMethod(paymentMethodIdentifier, checkout) {
24858
24859        let paymentMethodNames = ['mollie-credit-card', 'mollie-eps', 'mollie-direct-debit'];
24860        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
24861
24862        console.debug("mollie payment method " + paymentMethodIdentifier + " gets initialised now");
24863        this.checkout = checkout;
24864
24865    },
24866    confirm(paymentMethodIdentifier, checkout) {
24867
24868        let paymentMethodNames = ['mollie-credit-card', 'mollie-eps', 'mollie-direct-debit'];
24869        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
24870
24871        console.debug('Mollie payment confirm');
24872
24873        let self = this;
24874
24875        self.checkout = checkout;
24876
24877        self.createOrder(
24878            function(orderStatus, paymentId, approvalLinkHref){
24879                if (orderStatus == 'open'){
24880                    console.info("Mollie order with ID " + paymentId + ' created. Please redirect user to ' + approvalLinkHref) + ' to approve the order';
24881                    localStorage.setItem('molliePaymentId', paymentId);
24882                    let authParams = [{key: 'paymentId', value: paymentId, redirectUrl: approvalLinkHref}];
24883                    paymentSubscriberNotifier.notify("payment.save-authorizations", authParams);
24884                } else {
24885                    console.info("Mollie returned an unexpected order status: " + orderStatus);
24886                    let errorInfo = {
24887                    };//TODO: PROVIDE MORE INFO
24888                    paymentSubscriberNotifier.notify("payment.confirmation-error", errorInfo);
24889                }
24890
24891            }, 
24892            paymentMethodIdentifier
24893        );
24894
24895    },
24896    createOrder(callback, paymentMethodIdentifier){
24897
24898        const methodListByIdentifier = {
24899            'mollie-credit-card': 'creditcard',
24900            'mollie-eps': 'eps',
24901            'mollie-direct-debit': 'directdebit',
24902        };
24903
24904        let self = this;
24905
24906        let url = this.apiBaseUrl + "/shops/" + this.shop.id + "/checkout/" + self.checkout.id + "/payment/mollie/payments";
24907        //let [checkoutURL, checkoutHash] = window.location.href.split('#');
24908        //let callbackUrl = checkoutURL.split('?').slice(0, 1).join('/') + '?molliereturn=1';
24909        let callbackUrl = '/checkout?molliereturn=1';
24910        let data = {
24911            callbackUrl: callbackUrl,
24912            method: methodListByIdentifier[paymentMethodIdentifier]
24913        }
24914
24915        let headers = {
24916            'Content-Type': 'application/json',
24917        };
24918        if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
24919            headers = {
24920                'Content-Type': 'application/json',
24921                'Authorization': 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token')
24922            };
24923        }
24924        fetch(
24925            url,
24926            {
24927                method: 'POST', // *GET, POST, PUT, DELETE, etc.
24928                //mode: 'same-origin', // no-cors, *cors, same-origin
24929                //cache: 'no-cache', // *default, no-cache, reload, force-cache, only-if-cached
24930                //withCredentials: true,
24931                //credentials: 'include', // include, *same-origin, omit
24932                headers: headers,
24933                //redirect: 'follow', // manual, *follow, error
24934                //referrerPolicy: 'no-referrer', // no-referrer, *no-referrer-when-downgrade, origin, origin-when-cross-origin, same-origin, strict-origin, strict-origin-when-cross-origin, unsafe-url
24935                body: JSON.stringify(data) // body data type must match "Content-Type" header
24936            }
24937        ).then(
24938            function(rawResponse){
24939                if (!rawResponse.ok){
24940                    throw new Error('Order could not be created');
24941                }
24942                return rawResponse;
24943            }
24944        ).then(
24945            rawResponse => rawResponse.json()
24946        ).then(
24947            mollieOrder => callback(mollieOrder.status, mollieOrder.id, mollieOrder._links.checkout.href)
24948        ).catch(error => {
24949            console.info('There has been a problem with Mollie confirmation');
24950            let errorInfo = {}
24951            paymentSubscriberNotifier.notify("payment.confirmation-error", errorInfo);
24952        });
24953    }
24954}
24955
24956paymentSubscriberRegistry.register(molliePaymentService);
24957
24958;// ./vue/payment/nexi/nexi-payment-service.js
24959
24960
24961let nexiPaymentService = {};
24962nexiPaymentService =
24963{
24964    subscriptions: [
24965        {
24966            "eventName": "payment.init",
24967            "functionName": "initNexi"
24968        },
24969        {
24970            "eventName": "payment.paymentMethod.init",
24971            "functionName": "initPaymentMethod"
24972        },
24973        {
24974            "eventName": "payment.confirm",
24975            "functionName": "confirm"
24976        }
24977
24978    ],
24979
24980    initNexi: function(apiBaseUrl,  shop, checkout) {
24981        console.debug("nexi init happens now");
24982        this.checkout = checkout;
24983        this.apiBaseUrl = apiBaseUrl;
24984        this.shop = shop;
24985    },
24986
24987
24988    initPaymentMethod: function(paymentMethodIdentifier, checkout) {
24989        let paymentMethodNames = ['nexi-payments'];
24990        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
24991
24992        console.debug("nexi payment method " + paymentMethodIdentifier + " gets initialised now");
24993
24994        this.checkout = checkout;
24995    },
24996
24997    confirm: async function(paymentMethodIdentifier, checkout) {
24998
24999        let self = this;
25000
25001        let paymentMethodNames = ['nexi-payments'];
25002        if (paymentMethodNames.indexOf(paymentMethodIdentifier) == -1) return;
25003
25004        self.checkout = checkout;
25005        let paymentIntent = await self.createPaymentIntent();
25006
25007        if (paymentIntent && paymentIntent.redirectUrl) {
25008            let authParams = [{key: 'paymentId', value: paymentIntent.paymentId, redirectUrl: paymentIntent.redirectUrl}];
25009            paymentSubscriberNotifier.notify("payment.save-authorizations", authParams);
25010        } else {
25011            console.info("Nexi returned an unexpected order status: " + orderStatus);
25012            let errorInfo = {};
25013            paymentSubscriberNotifier.notify("payment.confirmation-error", errorInfo);
25014        }
25015
25016
25017    },
25018    createPaymentIntent: async function(){
25019
25020        let self = this;
25021        let checkout = self.checkout;
25022
25023        let customerBillingAddress = {};
25024        let customerDeliveryAddress = {};
25025        if (checkout.userdata && checkout.userdata.addresses) {
25026            if (!checkout.billingAddress.street) {
25027                // billingAddress is not set
25028                let searchedBillingAddressId = checkout.customerBillingAddressId || checkout.customerDeliveryAddressId;
25029                for (let addressKey in checkout.userdata.addresses) {
25030                    let address = checkout.userdata.addresses[addressKey];
25031                    if (address.id == searchedBillingAddressId) {
25032                        customerBillingAddress = address;
25033                        break;
25034                    }
25035                }
25036            }
25037
25038            if (!checkout.deliveryAddress.street) {
25039                // deliveryAddress is not set
25040                for (let addressKey in checkout.userdata.addresses) {
25041                    let address = checkout.userdata.addresses[addressKey];
25042                    if (address.id == checkout.customerDeliveryAddressId) {
25043                        customerDeliveryAddress = address;
25044                        break;
25045                    }
25046                }
25047            }
25048        }
25049
25050
25051        let data = {
25052            // shopando
25053            callbackUrl: '/checkout?nexireturn=1',
25054            cancelUrl: '/checkout#!3',
25055            locale: SP_CONSTANTS.LOCALE,
25056            // nexi
25057            integrationType: 'HostedPaymentPage',
25058        };
25059
25060        // return '{"paymentId":"01fb00006565f7ec7767f7b0bcae447c","redirectUrl":"https://test.checkout.dibspayment.eu/hostedpaymentpage/?checkoutKey=c80a24e54090464f979eb8ca4b9884bf&pid=01f300006565f8f9a51b4916351283d2"}';
25061
25062        let headers = {
25063            'Content-Type': 'application/json',
25064        };
25065        if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
25066            headers = {
25067                'Content-Type': 'application/json',
25068                'Authorization': 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token')
25069            };
25070        }
25071
25072        let url = self.apiBaseUrl + "/shops/" + self.shop.id + "/checkout/" + self.checkout.id + "/payment/nexi/paymentIntents";
25073        let response = await fetch(
25074            url,
25075            {
25076                method: 'POST', // *GET, POST, PUT, DELETE, etc.
25077                headers: headers,
25078                body: JSON.stringify(data) // body data type must match "Content-Type" header
25079            }
25080        ).then(
25081            rawResponse => rawResponse.json()
25082        ).then(
25083            function (response) {
25084                return response;
25085            }
25086        );
25087        return response;
25088    }
25089
25090}
25091
25092paymentSubscriberRegistry.register(nexiPaymentService);
25093
25094// EXTERNAL MODULE: ./vue/payment/offline/offline-payment-service.js
25095var offline_payment_service = __webpack_require__(729);
25096// EXTERNAL MODULE: ./node_modules/vue/dist/vue.esm-bundler.js + 6 modules
25097var vue_esm_bundler = __webpack_require__(1425);
25098// EXTERNAL MODULE: ./node_modules/vuex/dist/vuex.esm-bundler.js + 5 modules
25099var vuex_esm_bundler = __webpack_require__(2124);
25100// EXTERNAL MODULE: ./vue/APIClient.js
25101var APIClient = __webpack_require__(3565);
25102// EXTERNAL MODULE: ./vue/entity/Entity.js
25103var Entity = __webpack_require__(7249);
25104;// ./vue/entity/AddressEntity.js
25105
25106
25107class AddressEntity extends Entity/* default */.A {
25108	constructor() {
25109		super();
25110	}
25111
25112	static createFromAPIData(obj) {
25113		return AddressEntity.map({
25114            id: 'id',
25115            street: 'street',
25116            street2: 'street2',
25117            postCode: 'postCode',
25118            city: 'city',
25119            countryCode: 'countryCode',
25120            firstName: 'firstName',
25121            lastName: 'lastName',
25122            company: 'company'
25123        },
25124		obj);
25125	}
25126
25127	static toPOJO(obj) {
25128		let pojo =  AddressEntity.map({
25129            id: 'id',
25130            street: 'street',
25131            street2: 'street2',
25132            postCode: 'postCode',
25133            city: 'city',
25134            countryCode: 'countryCode',
25135            firstName: 'firstName',
25136            lastName: 'lastName',
25137            company: 'company'
25138        },
25139        obj,
25140        true);
25141
25142        if (!pojo) return pojo;
25143
25144		if (typeof pojo.firstName === 'string' && pojo.firstName.trim() === '') pojo.firstName = null;
25145		if (typeof pojo.lastName === 'string' && pojo.lastName.trim() === '') pojo.lastName = null;
25146		if (typeof pojo.street === 'string' && pojo.street.trim() === '') pojo.street = null;
25147		if (typeof pojo.street2 === 'string' && pojo.street2.trim() === '') pojo.street2 = null;
25148		if (typeof pojo.city === 'string' && pojo.city.trim() === '') pojo.city = null;
25149		if (typeof pojo.company === 'string' && pojo.company.trim() === '') pojo.company = null;
25150
25151		return pojo;
25152
25153	}
25154}
25155
25156/* harmony default export */ const entity_AddressEntity = (AddressEntity);
25157
25158// EXTERNAL MODULE: ./vue/entity/ProductEntity.js
25159var ProductEntity = __webpack_require__(6968);
25160;// ./vue/entity/WishlistItemEntity.js
25161
25162
25163
25164class WishlistItemEntity extends Entity/* default */.A {
25165	constructor() {
25166		super();
25167	}
25168
25169	static createFromAPIData(obj) {
25170		return WishlistItemEntity.map({
25171            productId: 'productId',
25172            product: {
25173                type: ProductEntity/* default */.A,
25174                property: ['_embedded', 'product'],
25175                converter: 'createFromAPIData'
25176            }
25177        },
25178		obj);
25179	}
25180
25181	static toPOJO(obj) {
25182		return WishlistItemEntity.map({
25183            productId: 'productId'
25184        },
25185        obj,
25186        true);
25187	}
25188}
25189
25190/* harmony default export */ const entity_WishlistItemEntity = (WishlistItemEntity);
25191
25192;// ./vue/entity/BackInStockItemEntity.js
25193
25194
25195class BackInStockItemEntity extends Entity/* default */.A {
25196	constructor() {
25197		super();
25198	}
25199
25200	static createFromAPIData(obj) {
25201		return BackInStockItemEntity.map({
25202            variantId: 'variantId'
25203        },
25204		obj);
25205	}
25206
25207	static toPOJO(obj) {
25208		return BackInStockItemEntity.map({
25209            variantId: 'variantId'
25210        },
25211        obj,
25212        true);
25213	}
25214}
25215
25216/* harmony default export */ const entity_BackInStockItemEntity = (BackInStockItemEntity);
25217
25218;// ./vue/entity/CustomerEntity.js
25219
25220
25221
25222
25223
25224class CustomerEntity extends Entity/* default */.A {
25225	constructor() {
25226		super();
25227	}
25228
25229	static createFromAPIData(obj) {
25230		return CustomerEntity.map({
25231			id: 'id',
25232            emailAddress: 'emailAddress',
25233            firstName: 'firstName',
25234            lastName: 'lastName',
25235            phone: 'phone',
25236            acceptsMarketing: 'acceptsMarketing',
25237            birthday: 'birthday',
25238            vatin: 'vatin',
25239            company: 'company',
25240            companyRegisterNumber: 'companyRegisterNumber',
25241			merchantCustomerNumber: 'merchantCustomerNumber',
25242            addresses: {
25243				type: entity_AddressEntity,
25244				property: 'addresses',
25245				converter: 'createFromAPIData'
25246			},
25247			wishlistItems: {
25248				type: entity_WishlistItemEntity,
25249				property: 'wishlistItems',
25250				converter: 'createFromAPIData'
25251			},
25252			backInStockItems: {
25253				type: entity_BackInStockItemEntity,
25254				property: 'backInStockItems',
25255				converter: 'createFromAPIData'
25256			}
25257        },
25258		obj);
25259	}
25260
25261	static toPOJO(obj) {
25262		let pojo = CustomerEntity.map({
25263            emailAddress: 'emailAddress',
25264            firstName: 'firstName',
25265            lastName: 'lastName',
25266            phone: 'phone',
25267            acceptsMarketing: 'acceptsMarketing',
25268			password: 'password',
25269			birthday: 'birthday',
25270			vatin: 'vatin',
25271            company: 'company',
25272            companyRegisterNumber: 'companyRegisterNumber',
25273			merchantCustomerNumber: 'merchantCustomerNumber',
25274			termsAndConditionAccept: 'termsAndConditionAccept',
25275			privacyPolicyAccept: 'privacyPolicyAccept',
25276            addresses: {
25277				type: entity_AddressEntity,
25278				property: 'addresses',
25279				converter: 'toPOJO'
25280			},
25281			wishlistItems: {
25282				type: entity_WishlistItemEntity,
25283				property: 'wishlistItems',
25284				converter: 'toPOJO'
25285			},
25286			backInStockItems: {
25287				type: entity_BackInStockItemEntity,
25288				property: 'backInStockItems',
25289				converter: 'toPOJO'
25290			}
25291        },
25292        obj,
25293        true);
25294
25295		if (typeof pojo.company === 'string' && pojo.company.trim() === '') pojo.company = null;
25296		if (typeof pojo.emailAddress === 'string' && pojo.emailAddress.trim() === '') pojo.emailAddress = null;
25297		if (typeof pojo.firstName === 'string' && pojo.firstName.trim() === '') pojo.firstName = null;
25298		if (typeof pojo.lastName === 'string' && pojo.lastName.trim() === '') pojo.lastName = null;
25299		if (typeof pojo.phone === 'string' && pojo.phone.trim() === '') pojo.phone = null;
25300		if (typeof pojo.vatin === 'string' && pojo.vatin.trim() === '') pojo.vatin = null;
25301		if (typeof pojo.birthday === 'string' && pojo.birthday.trim() === '') pojo.birthday = null;
25302		if (typeof pojo.merchantCustomerNumber === 'string' && pojo.merchantCustomerNumber.trim() === '') pojo.merchantCustomerNumber = null;
25303		if (typeof pojo.companyRegisterNumber === 'string' && pojo.companyRegisterNumber.trim() === '') pojo.companyRegisterNumber = null;
25304
25305		return pojo;
25306	}
25307}
25308
25309/* harmony default export */ const entity_CustomerEntity = (CustomerEntity);
25310
25311;// ./vue/store/customer.js
25312
25313
25314
25315
25316
25317
25318/* harmony default export */ const customer = ({
25319	namespaced: true,
25320	state: {
25321		userdata: {},
25322		orders: [],
25323		accountCreateErrorMessage: '',
25324		accountCreateErrorVariables: {},
25325	},
25326	mutations: {
25327		setUserdata(state, userdata) {
25328			state.userdata = entity_CustomerEntity.createFromAPIData(userdata);
25329		}
25330	},
25331	actions: {
25332		async load({state}) {
25333			if ((0,SecureCookie/* SecureCookie */.o)('sp_customer_id') && (0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
25334
25335				let apiClient = new APIClient/* default */.A();
25336				apiClient.method = 'GET';
25337				apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customers/' + (0,SecureCookie/* SecureCookie */.o)('sp_customer_id');
25338				apiClient.headers = {
25339					Authorization: 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token'),
25340					'Accept-Language': SP_CONSTANTS.LOCALE
25341				};
25342				return await apiClient.call(data => {
25343					state.userdata = entity_CustomerEntity.createFromAPIData(data);
25344				});
25345			} else {
25346				return false;
25347			}
25348		},
25349		async update({state}) {
25350			if ((0,SecureCookie/* SecureCookie */.o)('sp_customer_id') && (0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
25351				let userdata = {...state.userdata};
25352				// delete userdata.id;
25353				// todo entity
25354				let data = entity_CustomerEntity.toPOJO(userdata);
25355
25356				let apiClient = new APIClient/* default */.A();
25357				apiClient.method = 'PATCH';
25358				apiClient.data = JSON.stringify(data);
25359				apiClient.headers = {
25360					Authorization: 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token'),
25361					'Accept-Language': SP_CONSTANTS.LOCALE
25362				};
25363				apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customers/'+ (0,SecureCookie/* SecureCookie */.o)('sp_customer_id');
25364				return await apiClient.call(data => {
25365					return data;
25366				});
25367			} else {
25368				return false;
25369			}
25370		},
25371		async createAccountFromOrder({state}, payload) {
25372			let commandData = {
25373				"command": "create-customer",
25374				"params": [
25375					{
25376						"key": "token",
25377						"value": payload.token
25378					},
25379					{
25380						"key": "password",
25381						"value": payload.password
25382					},
25383					{
25384						"key": "acceptsMarketing",
25385						"value": payload.acceptsMarketing
25386					},
25387					{
25388						"key": "privacyPolicyAccept",
25389						"value": payload.privacyPolicyAccept
25390					},
25391					{
25392						"key": "termsAndConditionAccept",
25393						"value": payload.termsAndConditionAccept
25394					}
25395				]
25396			};
25397			let apiClient = new APIClient/* default */.A();
25398			apiClient.method = 'POST';
25399			apiClient.data = JSON.stringify(commandData);
25400			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/orders/' + payload.orderId + '/actions';
25401
25402			return await apiClient.call(data => {
25403
25404				if (data && !data.error) {
25405					return true;
25406				} else {
25407					return data;
25408				}
25409			});
25410		},
25411		async createAccount({state}, userdata) {
25412			let customer = entity_CustomerEntity.toPOJO(userdata);
25413			let apiClient = new APIClient/* default */.A();
25414			apiClient.method = 'POST';
25415			apiClient.data = JSON.stringify(customer);
25416			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customers';
25417
25418			let data = await apiClient.call(data => {
25419
25420				// if (data && !data.error) {
25421				// 	return true;
25422				// } else {
25423				// 	return false;
25424				// }
25425				return data;
25426			});
25427
25428			if (!data.error) {
25429				let facebookRegisterEventId = Math.random().toString(36).substr(2, 14)+Math.random().toString(36).substr(2, 14);
25430				if (typeof window.fbq === 'function') {
25431					fbq('track', 'CompleteRegistration', { eventID: facebookRegisterEventId });
25432				}
25433				if (SP_CONSTANTS.SHOP.FACEBOOK_CAPI_ACTIVE) {
25434
25435					window.fetch(
25436						'https://'+ SP_CONSTANTS.MAIN_DOMAIN + '/fbconversionapi?eventName=CompleteRegistration'+
25437						'&eventId='+facebookRegisterEventId, {
25438						method: 'GET',
25439						headers: {
25440							"Content-type": "application/x-www-form-urlencoded",
25441						}
25442					})
25443				}
25444			}
25445
25446			return data;
25447		},
25448		async deleteAccount({state}, userdata) {
25449			console.log(userdata);
25450			let customer = {
25451				command: 'delete',
25452				password: userdata.password
25453			};
25454			let apiClient = new APIClient/* default */.A();
25455			apiClient.method = 'POST';
25456			apiClient.data = JSON.stringify(customer);
25457			apiClient.headers = {
25458				Authorization: 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token'),
25459			};
25460			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customers/'+(0,SecureCookie/* SecureCookie */.o)('sp_customer_id')+'/actions';
25461
25462			let data = await apiClient.call(data => {
25463				return data;
25464			});
25465			return data;
25466		},
25467		async login({state}, [username, password]) {
25468
25469			let apiClient = new APIClient/* default */.A();
25470			apiClient.method = 'POST';
25471			apiClient.data = JSON.stringify({username, password});
25472			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customerAccessTokens';
25473			return await apiClient.call(data => {
25474				if (data) {
25475					if (data.accessToken) {
25476						(0,SecureCookie/* SecureCookie */.o)('sp_access_token', data.accessToken, data.validUntil);
25477						(0,SecureCookie/* SecureCookie */.o)('sp_customer_id', data.customerId, data.validUntil);
25478						if (data.customerGroupId) {
25479							(0,SecureCookie/* SecureCookie */.o)('sp_customer_group_id', data.customerGroupId, data.validUntil);
25480						}
25481						return data;
25482					} else {
25483						return data;
25484					}
25485
25486				}
25487			});
25488
25489		},
25490		addAddress({state}) {
25491			if (state.userdata.addresses) {
25492				state.userdata.addresses = [...state.userdata.addresses, {}];
25493			} else {
25494				state.userdata.addresses = [{}];
25495			}
25496		},
25497		removeAddress({state}, key) {
25498			state.userdata.addresses.splice(key,1);
25499		},
25500		async loadOrders({state}) {
25501
25502			let apiClient = new APIClient/* default */.A();
25503			apiClient.method = 'GET';
25504			apiClient.headers = {
25505				Authorization: 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token'),
25506				'Accept-Language': SP_CONSTANTS.LOCALE
25507			};
25508			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customers/' + (0,SecureCookie/* SecureCookie */.o)('sp_customer_id') + '/orders';
25509
25510			return await apiClient.call(data => {
25511				if (data) {
25512					if (data._embedded && data._embedded.orders) {
25513						state.orders = data._embedded.orders;
25514					}
25515				} else {
25516					return false;
25517				}
25518			});
25519		},
25520		async addToWishlist({state,dispatch}, value) {
25521
25522			let wishlistItems = state.userdata.wishlistItems || [];
25523			
25524			wishlistItems.push(value);
25525
25526			state.userdata.wishlistItems = wishlistItems;
25527			dispatch('update');
25528
25529			let facebookWishlistEventId = Math.random().toString(36).substr(2, 14)+Math.random().toString(36).substr(2, 14);
25530			if (typeof window.fbq === 'function') {
25531				fbq('track', 'AddToWishlist', { eventID: facebookWishlistEventId });
25532			}
25533
25534			if (SP_CONSTANTS.SHOP.FACEBOOK_CAPI_ACTIVE) {
25535
25536				window.fetch(
25537					'https://'+ SP_CONSTANTS.MAIN_DOMAIN + '/fbconversionapi?eventName=AddToWishlist'+
25538					'&eventId='+facebookWishlistEventId, {
25539					method: 'GET',
25540					headers: {
25541						"Content-type": "application/x-www-form-urlencoded",
25542					}
25543				})
25544			}
25545
25546			setTimeout(() => {
25547				document.querySelector('.wishlist-popup').focus();
25548			}, 100);
25549		},
25550		removeWishlistItem({state}, wishlistItemProductId) {
25551			let wishlistItems = [];
25552			for (let wishlistItem of state.userdata.wishlistItems) {
25553				if (wishlistItem.productId != wishlistItemProductId) {
25554					wishlistItems.push(wishlistItem);
25555				}
25556			}
25557			state.userdata.wishlistItems = wishlistItems;
25558		},
25559		addBackInStockItem({state,dispatch}, value) {
25560			let backInStockItems = state.userdata.backInStockItems || [];
25561			backInStockItems.push(value);
25562			state.userdata.backInStockItems = backInStockItems;
25563			dispatch('update');
25564		},
25565		removeBackInStockItems({state,dispatch}, variantIds) {
25566			let backInStockItems = [];
25567			for (let backInStockItem of state.userdata.backInStockItems) {
25568				if (!variantIds.includes(backInStockItem.variantId)) {
25569					backInStockItems.push(backInStockItem);
25570				}
25571			}
25572			state.userdata.backInStockItems = backInStockItems;
25573			dispatch('update');
25574		},
25575		async changePasswordWithToken({state}, payload) {
25576			let apiClient = new APIClient/* default */.A();
25577			apiClient.method = 'PATCH';
25578			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customers/'+payload.customerId;
25579			apiClient.headers = {
25580				Authorization: 'Bearer ' + payload.token,
25581				'Accept-Language': SP_CONSTANTS.LOCALE
25582			};
25583			apiClient.data = JSON.stringify({
25584				password: payload.password
25585			});
25586			return await apiClient.call(data => {
25587				return data;
25588			});
25589		},
25590		async openGiftVoucherPdf({state}, payload) {
25591			let apiClient = new APIClient/* default */.A();
25592			apiClient.method = 'GET';
25593			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/customers/' + payload.customerId + '/giftVouchers/'+ payload.giftVoucherId + '/pdf';
25594			apiClient.headers = {
25595				Authorization: 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token'),
25596				'Accept-Language': SP_CONSTANTS.LOCALE
25597			};
25598
25599			return await apiClient.call(data => {
25600
25601				return data;
25602			});
25603		},
25604
25605	}
25606});
25607
25608// EXTERNAL MODULE: ./vue/entity/CheckoutEntity.js + 2 modules
25609var CheckoutEntity = __webpack_require__(5348);
25610// EXTERNAL MODULE: ./vue/entity/CartItemEntity.js
25611var CartItemEntity = __webpack_require__(8044);
25612;// ./vue/store/checkout.js
25613
25614
25615
25616
25617
25618
25619// Deduplicates concurrent checkout creations within one page load — see the create action.
25620let createInFlight = null;
25621
25622// Every update sends the whole checkout and writes the response back into the state. Updates
25623// started in quick succession (rapid clicks on the cart quantity buttons) can come back out of
25624// order, so an older response would overwrite the newer state and the quantity visibly jumps
25625// back. Only the response of the most recently started update may touch the state.
25626let latestUpdateNumber = 0;
25627
25628function getCheckoutId() {
25629	try {
25630		let raw = (0,SecureCookie/* SecureCookie */.o)('sp_checkout_info');
25631		if (!raw) return null;
25632		let parsed = JSON.parse(raw);
25633		if (parsed && parsed.checkoutId) return parsed.checkoutId;
25634	} catch (e) {}
25635	return null;
25636}
25637
25638const CART_ITEM_AVAILABILITY_CODES = [
25639	'CART_ITEM_PRODUCT_IS_NOT_PURCHASABLE',
25640	'CART_ITEM_PRODUCT_IS_NOT_PUBLICLY_ACCESSIBLE',
25641	'CART_ITEM_VARIANT_IS_NOT_PURCHASABLE',
25642	'CART_ITEM_VARIANT_IS_NOT_PUBLICLY_ACCESSIBLE',
25643	'CART_ITEM_NOT_ENOUGH_UNITS_AVAILABLE',
25644	'CART_ITEM_FEATURE_GIFT_VOUCHER_IS_DEACTIVATED',
25645	'VARIANT_PRICE_IN_CART_NOT_AVAILABLE',
25646];
25647
25648// Adding to the cart counts up an item that is already there instead of adding a
25649// second one. Which item that is depends on the configuration, not on the variant
25650// alone, so the rule lives here: addToCart counts the match up, and the quantity
25651// counters ask through cartQuantityForAddition how much of the household limit
25652// that match has already used.
25653function isSameCartItem(value, cartItem) {
25654
25655	if (value.cartItemConfigurations && value.cartItemConfigurations.length >= 1) {
25656		// product configuration
25657
25658		if (value.variantId != cartItem.variantId) return false;
25659
25660		let aObj = {};
25661		for (let i of value.cartItemConfigurations) {
25662			aObj[i.productConfigurationFieldId] = i.productConfigurationOptionId || i.value;
25663		}
25664		for (let j of cartItem.cartItemConfigurations) {
25665			let configurationValue = j.productConfigurationOptionId || j.value;
25666
25667			if (aObj[j.productConfigurationFieldId] != configurationValue) return false;
25668		}
25669
25670		return true;
25671	}
25672
25673	if (value.configuration && cartItem.configuration) {
25674		// gift voucher configuration
25675
25676		let a = value.configuration;
25677		let b = cartItem.configuration;
25678
25679		return a.amount == b.amount &&
25680			a.dedication == b.dedication &&
25681			a.giftVoucherLayoutId == b.giftVoucherLayoutId &&
25682			(JSON.stringify(a.image) == JSON.stringify(b.image)) &&
25683			a.variantId == b.variantId;
25684	}
25685
25686	return value.variantId == cartItem.variantId;
25687}
25688
25689function getDefaultState() {
25690	return {
25691		id: '',
25692		cartItems: [],
25693		shippingPrice: {},
25694		shippingGrossPrice: {},
25695		cartItemsTotalPrice: {},
25696		totalPrice: {},
25697		totalGrossPrice: {},
25698		isCartPopupOpen: false,
25699		isWishlistPopupOpen: false,
25700		paymentMethods: {},
25701		shippingRates: [],
25702		deliveryAddress: {},
25703		deliveryPeriod: null,
25704		billingAddress: null,
25705		vatin: null,
25706		companyRegisterNumber: null,
25707		company: null,
25708		shippingRateId: '',
25709		paymentMethodId: '',
25710		customerDeliveryAddressId: null,
25711		customerBillingAddressId: null,
25712		emailAddress: '',
25713		phone: '',
25714		birthday: '',
25715		firstName: '',
25716		lastName: '',
25717		customerNumber: '',
25718		complete: false,
25719		orderId: '',
25720		order: {},
25721		paymentAuthorizationParams: null,
25722		billingAddressSameAsDeliveryAddress: true,
25723		discountCodes: [],
25724		discounts: [],
25725		completeness: {},
25726		problems: [],
25727		discountCodeErrorMessage: '',
25728		discountCodeErrorVariables: {},
25729		paymentRequired: true,
25730		provisionalDeliveryCountryCode: '',
25731		provisionalDeliveryPostCode: '',
25732		acceptsMarketing: false,
25733		isShippingRequired: true,
25734		note: '',
25735		checkoutConfirmBoxes: [],
25736		confirmBoxesStatus: [],
25737		freeShippingInfo: null,
25738		minimumOrderValueInfo: null,
25739		paymentInitInfo: {
25740			enrichedCheckout: {},
25741			initializedPaymentMethods: []
25742		},
25743
25744		initialLoaded: false
25745	}
25746}
25747
25748/* harmony default export */ const checkout = ({
25749	namespaced: true,
25750	state: getDefaultState(),
25751	getters: {
25752		unavailableCartItemVariantIds(state) {
25753			if (!Array.isArray(state.problems)) return [];
25754			const variantIds = state.problems
25755				.filter(p => p && CART_ITEM_AVAILABILITY_CODES.includes(p.code))
25756				.map(p => p.additionalInfo && p.additionalInfo.variantId)
25757				.filter(Boolean);
25758			return [...new Set(variantIds)];
25759		},
25760		isBelowMinimumOrderValue(state) {
25761			return Boolean(state.completeness) && state.completeness.minimumOrderValueComplete === false;
25762		},
25763		hasUnavailableCartItems(state, getters) {
25764			if (state.completeness && state.completeness.cartComplete) return false;
25765			return getters.unavailableCartItemVariantIds.length > 0;
25766		},
25767		// How many units the cart already holds for the item an addition would be
25768		// counted up into. The quantity counters subtract it from the household
25769		// limit so the limit cannot be exceeded by adding a second time.
25770		cartQuantityForAddition(state) {
25771			return (value) => {
25772				if (!value || !Array.isArray(state.cartItems)) return 0;
25773				for (let cartItem of state.cartItems) {
25774					if (isSameCartItem(value, cartItem)) return Number(cartItem.quantity) || 0;
25775				}
25776				return 0;
25777			};
25778		},
25779		unavailableCartItemProductTitles(state, getters) {
25780			const variantIds = getters.unavailableCartItemVariantIds;
25781			if (variantIds.length === 0) return [];
25782			return state.cartItems
25783				.filter(item => variantIds.includes(item.variantId))
25784				.map(item => item.product && item.product.title)
25785				.filter(Boolean);
25786		}
25787	},
25788	mutations: {
25789		updateDiscountCodes(state) {
25790			if (state.discountCodes) {
25791				state.discountCodes = [...state.discountCodes];
25792			} else {
25793				state.discountCodes = [];
25794			}
25795			if (state.discounts && state.discounts.length > 0) {
25796				state.discounts = [...state.discounts];
25797			}
25798		},
25799		setItemsCookie(state) {
25800
25801			let quantity = 0;
25802			if (state.cartItems.length > 0) {
25803				for (let item of state.cartItems) {
25804					quantity += item.quantity;
25805				}
25806			}
25807
25808			(0,SecureCookie/* SecureCookie */.o)('sp_cart_items_amount', quantity);
25809		},
25810		reset(state) {
25811			const defaultState = getDefaultState();
25812
25813			for (let key in defaultState) {
25814				let value = defaultState[key];
25815
25816				state[key] = value;
25817			}
25818			(0,SecureCookie/* SecureCookie */.o)('sp_cart_items_amount', 0);
25819		},
25820		resetInitializedPaymentMethods(state) {
25821			state.paymentInitInfo.initializedPaymentMethods = [];
25822		}
25823	},
25824	actions: {
25825		async load({state, dispatch}, createNew) {
25826			let checkoutId = getCheckoutId();
25827
25828			if (!checkoutId) {
25829				if (createNew) {
25830					let data = await dispatch('create');
25831					if (data && data.id) {
25832						checkoutId = data.id;
25833					} else {
25834						return;
25835					}
25836				} else {
25837					return;
25838				}
25839			}
25840
25841			let apiClient = new APIClient/* default */.A();
25842
25843			if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
25844				apiClient.headers = {
25845					'Accept-Language': SP_CONSTANTS.LOCALE,
25846					'Authorization': 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token')
25847				};
25848			} else {
25849				apiClient.headers = {
25850					'Accept-Language': SP_CONSTANTS.LOCALE
25851				};
25852			}
25853
25854			apiClient.method = 'GET';
25855			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/checkout/' + checkoutId;
25856
25857			return await apiClient.call(async data => {
25858
25859				if (data.error && (data.status == 404 || data.status == 401) && createNew) {
25860					let newData = await dispatch('create');
25861					if (newData && newData.id) {
25862						return await dispatch('load', false);
25863					}
25864					return;
25865				}
25866
25867				let checkoutEntity = CheckoutEntity/* default */.A.createFromAPIData(data);
25868
25869				for (let propertyName in checkoutEntity) {
25870					state[propertyName] = checkoutEntity[propertyName];
25871				}
25872
25873				state.problems = Array.isArray(data.problems) ? data.problems : [];
25874
25875				state.initialLoaded = true;
25876
25877				// autofill country
25878				if (state.deliveryAddress && !state.deliveryAddress.countryCode && !state.provisionalDeliveryCountryCode) {
25879					if (getCountryCode() !== null) state.provisionalDeliveryCountryCode = getCountryCode();
25880					
25881					
25882					data = await dispatch('update');
25883
25884				}
25885
25886				return true;
25887
25888			});
25889		},
25890		async loadOrCreateNew({dispatch}) {
25891			return await dispatch('load', true);
25892		},
25893		async addToCart({state,dispatch}, value) {
25894
25895			// wait for initial load to be done
25896			if (!state.initialLoaded) {
25897				await new Promise(resolve => {
25898					let interval = setInterval(() => {
25899						if (state.initialLoaded) {
25900							clearInterval(interval);
25901							resolve();
25902						}
25903					}, 100);
25904				});
25905			}
25906
25907			let cartItems = state.cartItems || [];
25908			let productFoundInCart = false;
25909
25910			// count up quantity if product is in cart
25911			for (let i in cartItems) {
25912				let cartItem = cartItems[i];
25913
25914				if (isSameCartItem(value, cartItem)) {
25915					value.quantity = Number(cartItem.quantity) + Number(value.quantity);
25916					cartItems[i] = value;
25917					productFoundInCart = true;
25918					break;
25919				}
25920			}
25921
25922
25923			// add to cart if not already in cart
25924			if (!productFoundInCart) {
25925				cartItems.push(value);
25926
25927				if (typeof window.gtag === 'function') {
25928					gtag('event', 'addToCart', {
25929						'event_category': 'shopFunctions',
25930						'event_label': 'Add to Cart',
25931						'value': 1
25932					});
25933				}
25934	
25935	
25936				let facebookAddToCartEventId = Math.random().toString(36).substr(2, 14)+Math.random().toString(36).substr(2, 14);
25937				if (typeof window.fbq === 'function') {
25938					fbq('track', 'AddToCart', { eventID: facebookAddToCartEventId });
25939				}
25940				
25941				if (SP_CONSTANTS.SHOP.FACEBOOK_CAPI_ACTIVE) {
25942
25943					window.fetch(
25944						'https://'+ SP_CONSTANTS.MAIN_DOMAIN + '/fbconversionapi?eventName=AddToCart'+
25945						'&eventId='+facebookAddToCartEventId, {
25946						method: 'GET',
25947						headers: {
25948							"Content-type": "application/x-www-form-urlencoded",
25949						}
25950					})
25951				}
25952	
25953	
25954	
25955				if (typeof window.pintrk === 'function') {
25956					pintrk('track', 'AddToCart');
25957				}
25958			}
25959			
25960			state.cartItems = cartItems;
25961			let checkout = await dispatch('update');
25962			
25963			
25964			if (checkout.status && checkout.status == 400) {
25965				for (let i in cartItems) {
25966					let cartItem = cartItems[i];
25967					if (value.variantId == cartItem.variantId) {
25968						value.quantity = Number(cartItem.quantity) - Number(value.quantity);
25969						cartItems[i] = value;
25970						break;
25971					}
25972				}
25973			}
25974
25975			if (checkout && typeof window.gtag === 'function') {
25976				let newItem = state.cartItems.find(cartItem => cartItem.variantId == value.variantId);
25977				if (newItem) {
25978					let checkoutAnalyticsPojo = CheckoutEntity/* default */.A.toAnalyticsPOJO({cartItems: [newItem]});
25979					
25980					gtag('event', 'add_to_cart', {
25981						currency: SP_CONSTANTS.SHOP.CURRENCY_CODE,
25982						value: newItem.price.amount/100,
25983						items: checkoutAnalyticsPojo.items
25984					});
25985				}
25986			}
25987
25988			return checkout;
25989		},
25990
25991		async create({dispatch}) {
25992			// The cookie is only written once the response comes back, so every caller that
25993			// dispatches while a create is still in flight would see "no checkout" and post a
25994			// second one — App.vue and Checkout.vue both dispatch loadOrCreateNew on the checkout
25995			// page. Hand out the running promise instead of starting another request.
25996			if (createInFlight) return await createInFlight;
25997
25998			createInFlight = (async () => {
25999				let apiClient = new APIClient/* default */.A();
26000				apiClient.method = 'POST';
26001				apiClient.data = JSON.stringify({ timezone: Intl.DateTimeFormat().resolvedOptions().timeZone });
26002				let headers = {
26003					'Accept-Language': SP_CONSTANTS.LOCALE
26004				};
26005				if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
26006					headers['Authorization'] = 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token');
26007				}
26008				apiClient.headers = headers;
26009				apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/checkout';
26010				return await apiClient.call(data => {
26011					if (data.id) {
26012
26013						(0,SecureCookie/* SecureCookie */.o)('sp_checkout_info', JSON.stringify({'checkoutId': data.id, 'shopId': SP_CONSTANTS.SHOP.ID}), 7);
26014
26015						return data;
26016						//dispatch('update');
26017					}
26018				});
26019			})();
26020
26021			try {
26022				return await createInFlight;
26023			} finally {
26024				// Cleared on purpose: after a completed checkout the cookie is removed and the
26025				// next dispatch has to be able to create a fresh one.
26026				createInFlight = null;
26027			}
26028		},
26029
26030		
26031
26032		async update({state, dispatch, commit}) {
26033
26034
26035			// wait for initial load to be done
26036			if (!state.initialLoaded) {
26037				await new Promise(resolve => {
26038					let interval = setInterval(() => {
26039						if (state.initialLoaded) {
26040							clearInterval(interval);
26041							resolve();
26042						}
26043					}, 100);
26044				});
26045			}
26046
26047
26048			let apiClient = new APIClient/* default */.A();
26049			apiClient.method = 'PATCH';
26050
26051			if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
26052				apiClient.headers = {
26053					Authorization: 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token'),
26054					'Accept-Language': SP_CONSTANTS.LOCALE
26055				};
26056			} else {
26057				apiClient.headers = {
26058					'Accept-Language': SP_CONSTANTS.LOCALE
26059				};
26060			}
26061
26062			let cartItems = [];
26063			if (state.cartItems) {
26064				for (let cartItem of state.cartItems) {
26065					cartItems.push(CartItemEntity/* default */.A.toPOJO(cartItem));
26066				}
26067			}
26068
26069			let params = CheckoutEntity/* default */.A.toPOJO(state);
26070
26071			if (params['customerDeliveryAddressId']) params['deliveryAddress'] = null;
26072			if (params['customerBillingAddressId']) params['billingAddress'] = null;
26073			if (params['billingAddressSameAsDeliveryAddress']) params['billingAddress'] = null;
26074
26075
26076			let cleanedParams = params;
26077			// delete null values from params
26078			// let cleanedParams = {};
26079			// for (let paramName in params) {
26080			// 	let paramValue = params[paramName];
26081
26082			// 	if (typeof paramValue == 'object' && !Array.isArray(paramValue)) {
26083			// 		// delete null params from objects
26084			// 		let newParamValue = {};
26085			// 		for (let subParamName in paramValue) {
26086						
26087			// 			if (paramValue[subParamName]) newParamValue[subParamName] = paramValue[subParamName];
26088			// 		}
26089			// 		paramValue = newParamValue;
26090			// 	}
26091
26092			// 	let paramStringValue = JSON.stringify(paramValue);
26093
26094			// 	if ((paramValue != null && paramStringValue != '{}' && paramStringValue != '[]') || paramName == 'cartItems') {
26095					
26096			// 		// only add billing address if it is complete
26097			// 		if (paramName != 'billingAddress' || 
26098			// 			(paramName == 'billingAddress' && 
26099			// 			(paramValue.firstName &&
26100			// 			paramValue.lastName &&
26101			// 			paramValue.street &&
26102			// 			paramValue.postCode &&
26103			// 			paramValue.city &&
26104			// 			paramValue.countryCode))) {
26105						
26106			// 			cleanedParams[paramName] = paramValue;
26107
26108			// 		}
26109					
26110			// 	} else if (paramName == 'discountCodes') {
26111			// 		cleanedParams[paramName] = paramValue;
26112			// 	}
26113			// }
26114
26115			apiClient.data = JSON.stringify(cleanedParams);
26116
26117			let checkoutId = getCheckoutId();
26118			if (!checkoutId) return;
26119
26120			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/checkout/' + checkoutId;
26121
26122			let updateNumber = ++latestUpdateNumber;
26123
26124			return apiClient.call(async data => {
26125
26126				let isLatestUpdate = updateNumber == latestUpdateNumber;
26127
26128				if (data.status == 404 || data.status == 401) {
26129					// delete
26130					(0,SecureCookie/* SecureCookieRemove */.M)('sp_checkout_info');
26131					(0,SecureCookie/* SecureCookieRemove */.M)('sp_checkout_info');
26132					(0,SecureCookie/* SecureCookieRemove */.M)('sp_cart_items_amount');
26133
26134					if (data.status == 401) {
26135						(0,SecureCookie/* SecureCookieRemove */.M)('sp_access_token');
26136						(0,SecureCookie/* SecureCookieRemove */.M)('sp_customer_id');
26137						(0,SecureCookie/* SecureCookieRemove */.M)('sp_customer_group_id');
26138					}
26139
26140					// window.location.href = '.';
26141				}
26142
26143				// A newer update was started in the meantime: hand the data back to the caller but
26144				// leave the state alone, it already reflects a newer request.
26145				if (!isLatestUpdate) return data;
26146
26147				// FIXME: NEEDS REAL ERROR HANDLING NOT STRING PARSING
26148				// FIXME: MOVE
26149				
26150				// find discount code error in invalidParams
26151				let hasDiscountCodeError = false;
26152				if (data.invalidParams) {
26153					for (let invalidParam of data.invalidParams) {
26154						if (invalidParam.name && invalidParam.name.indexOf('discountCode') != -1) {
26155							hasDiscountCodeError = true;
26156							break;
26157						}
26158					}
26159				}
26160
26161				
26162				if (data.error && data.code &&
26163				    (
26164				        data.code.indexOf('DISCOUNT_CODE') != -1
26165				        || hasDiscountCodeError
26166				    )
26167			    ) {
26168
26169					//let regex = /"(.*)"/g;
26170					//let discountCode = data.detail.match(regex)[0].replace('"', '').replace('"', '');
26171					//await dispatch('removeDiscount', discountCode);
26172					
26173                    state.discountCodeErrorMessage = 'errors.'+data.code.toLowerCase();
26174                    state.discountCodeErrorVariables = data.additionalInfo;
26175
26176				} else {
26177
26178					state.discountCodeErrorMessage = '';
26179					state.discountCodeErrorVariables = {};
26180				}
26181
26182				let validCheckoutResponse = false;
26183				if (typeof data.id === "string") {
26184					validCheckoutResponse = true;
26185				}
26186
26187				if (validCheckoutResponse) {
26188					let checkoutEntity = CheckoutEntity/* default */.A.createFromAPIData(data);
26189
26190					state.problems = Array.isArray(data.problems) ? data.problems : [];
26191
26192					for (let propertyName in checkoutEntity) {
26193						if (propertyName == 'totalPrice' ||
26194							propertyName == 'totalGrossPrice' ||
26195							propertyName == 'cartItemsTotalPrice' ||
26196							propertyName == 'shippingPrice' ||
26197							propertyName == 'shippingGrossPrice' ||
26198							propertyName == 'shippingRates' ||
26199							propertyName == 'orderId' ||
26200							propertyName == 'discountCodes' ||
26201							propertyName == 'discounts' ||
26202							propertyName == 'deliveryPeriod' ||
26203							propertyName == 'completeness' ||
26204							propertyName == 'shippingRateId' ||
26205							propertyName == 'paymentMethods' ||
26206							propertyName == 'paymentRequired' ||
26207							propertyName == 'paymentMethodCharge' ||
26208							propertyName == 'paymentMethodGrossCharge' ||
26209							propertyName == 'isShippingRequired' ||
26210							propertyName == 'freeShippingInfo' ||
26211							propertyName == 'minimumOrderValueInfo' ||
26212							propertyName == 'cartItems') {
26213							state[propertyName] = checkoutEntity[propertyName];
26214						}
26215					}
26216				}
26217
26218				if (data.error) return data;
26219
26220				commit('setItemsCookie');
26221
26222				return data;
26223			});
26224		},
26225
26226		async cancel({commit}) {
26227			(0,SecureCookie/* SecureCookieRemove */.M)('sp_checkout_info');
26228			(0,SecureCookie/* SecureCookieRemove */.M)('sp_cart_items_amount');
26229			commit('reset');
26230		},
26231
26232		async removeCartItems({state,dispatch,commit}, variantIds) {
26233			if (!Array.isArray(variantIds) || variantIds.length === 0) return;
26234
26235			state.cartItems = state.cartItems.filter(
26236				cartItem => !variantIds.includes(cartItem.variantId)
26237			);
26238			state.problems = [];
26239
26240			commit('setItemsCookie');
26241			return dispatch('update');
26242		},
26243
26244		async removeCartItem({state,dispatch,commit}, value) {
26245
26246			// start empty and add all other cart items back
26247			let cartItems = [];
26248			for (let cartItem of state.cartItems) {
26249
26250				if (value.cartItemConfigurations && value.cartItemConfigurations.length >= 1) {
26251
26252					let addCartItemBack = true;
26253					if (value.variantId == cartItem.variantId) addCartItemBack = false;
26254
26255					let a = value.cartItemConfigurations;
26256					let aObj = {};
26257					for (let i of a) {
26258						aObj[i.productConfigurationFieldId] = i.productConfigurationOptionId || i.value;
26259					}
26260					let b = cartItem.cartItemConfigurations;
26261					for (let j of b) {
26262						let value = j.productConfigurationOptionId || j.value;
26263
26264						if (aObj[j.productConfigurationFieldId] != value) addCartItemBack = true;
26265						
26266					}
26267
26268					if (addCartItemBack) cartItems.push(cartItem);
26269
26270				} else if (value.configuration && cartItem.configuration) {
26271					let a = value.configuration;
26272					let b = cartItem.configuration;
26273
26274					if (a.amount != b.amount ||
26275						a.dedication != b.dedication ||
26276						a.giftVoucherLayoutId != b.giftVoucherLayoutId ||
26277						(JSON.stringify(a.image) != JSON.stringify(b.image)) ||
26278						a.variantId != b.variantId) {
26279						
26280						cartItems.push(cartItem);
26281					}
26282
26283				} else if (value.variantId != cartItem.variantId) {
26284					cartItems.push(cartItem);
26285				}
26286			}
26287
26288			state.cartItems = cartItems;
26289
26290			if (typeof window.gtag === 'function') {
26291			
26292				let checkoutAnalyticsPojo = CheckoutEntity/* default */.A.toAnalyticsPOJO({cartItems: [value]});
26293				gtag('event', 'remove_from_cart', {
26294					items: checkoutAnalyticsPojo.items
26295				});
26296			}
26297
26298			commit('setItemsCookie');
26299			dispatch('update');
26300		},
26301		setDeliveryAddress({state}, addressId) {
26302			state.customerDeliveryAddressId = addressId;
26303		},
26304		setBillingAddress({state}, address) {
26305			state.billingAddress = address;
26306		},
26307		setCustomerBillingAddressId({state}, addressId) {
26308			state.customerBillingAddressId = addressId;
26309		},
26310		setBillingAddressSameAsDeliveryAddress({state}, value) {
26311			state.billingAddressSameAsDeliveryAddress = value;
26312		},
26313		addCustomerData({state}, [firstName, lastName, phone, emailAddress, vatin, companyRegisterNumber, company, birthday, customerNumber]) {
26314			state.firstName = firstName;
26315			state.lastName = lastName;
26316
26317
26318			if (vatin) state.vatin = vatin;
26319			if (companyRegisterNumber) state.companyRegisterNumber = companyRegisterNumber;
26320			if (company) state.company = company;
26321			if (birthday) state.birthday = birthday;
26322			if (customerNumber) state.customerNumber = customerNumber;
26323			
26324			if (phone && emailAddress) {
26325				state.phone = phone;
26326				state.emailAddress = emailAddress;
26327			}
26328		},
26329		setAuthorization({state}, authorizationParams) {
26330			state.paymentAuthorizationParams = authorizationParams;
26331		},
26332		setIncomplete({state}) {
26333			state.complete = null;
26334		},
26335		async initPayment({state, getters}, customer) {
26336
26337			if (getters.isBelowMinimumOrderValue) return;
26338
26339			// TODO: move to service
26340			let checkoutPojo = CheckoutEntity/* default */.A.toPaymentPOJO(state);
26341
26342			let shopInfo = {
26343				id: SP_CONSTANTS.SHOP.ID,
26344				name: SP_CONSTANTS.SHOP.NAME,
26345				country: {
26346					code: SP_CONSTANTS.SHOP.COUNTRY_CODE
26347				},
26348				currencyCode: SP_CONSTANTS.SHOP.CURRENCY_CODE,
26349				locale: "de",
26350				mainDomain: {
26351					name: SP_CONSTANTS.MAIN_DOMAIN
26352				}
26353			};
26354			
26355			
26356			if ((this.billingAddressSameAsDeliveryAddress) && !state.customerBillingAddressId) {
26357				checkoutPojo.billingAddress = checkoutPojo.deliveryAddress;
26358			} else if (checkoutPojo.customerBillingAddressId) {
26359				
26360				if (customer.addresses) {
26361					for (let addressKey in customer.addresses) {
26362						let address = customer.addresses[addressKey];
26363						if (address.id == checkoutPojo.customerBillingAddressId) {
26364							checkoutPojo.billingAddress = address;
26365							break;
26366						}
26367					}
26368				}
26369			}
26370
26371			let enrichedCheckout = {...checkoutPojo};
26372			enrichedCheckout.userdata = customer;
26373
26374			
26375
26376			let activatedMethods = state.paymentMethods.map(m => m.identifier);
26377
26378			await paymentSubscriberNotifier.notify("payment.init", SP_CONSTANTS.SHOP.API_PATH, shopInfo, enrichedCheckout, activatedMethods);
26379			
26380			// if (activatedMethods.includes('klarna-pay-now')) paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'klarna-pay-now', enrichedCheckout);
26381			// if (activatedMethods.includes('klarna-pay-later')) paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'klarna-pay-later', enrichedCheckout);
26382			// if (activatedMethods.includes('paypal-standard')) paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'paypal-standard', checkoutPojo);
26383			// if (activatedMethods.includes('stripe-payments')) paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'stripe-payments', enrichedCheckout);
26384			
26385
26386			state.paymentInitInfo.enrichedCheckout = enrichedCheckout;
26387			
26388		},
26389		async activatePaymentMethod({state, getters}, identifier) {
26390
26391			if (getters.isBelowMinimumOrderValue) return;
26392
26393			let activatedMethods = state.paymentMethods.map(m => m.identifier);
26394
26395			const paymentMethods = [
26396				'klarna-pay-now',
26397				'klarna-pay-later',
26398				'paypal-standard',
26399				'stripe-payments',
26400				'mollie-credit-card', 
26401				'mollie-eps', 
26402				'mollie-direct-debit',
26403				'nexi-payments',
26404			];
26405
26406			for (let methodIdentifier of paymentMethods) {
26407
26408				if (activatedMethods.includes(methodIdentifier) && 
26409					identifier == methodIdentifier &&
26410					!state.paymentInitInfo.initializedPaymentMethods.includes(methodIdentifier)) {
26411
26412					await paymentSubscriberNotifier.notify("payment.paymentMethod.init", methodIdentifier, state.paymentInitInfo.enrichedCheckout);
26413					state.paymentInitInfo.initializedPaymentMethods.push(methodIdentifier);
26414				}
26415			}
26416			
26417			// if (activatedMethods.includes('klarna-pay-now') && 
26418			// 	identifier == 'klarna-pay-now' &&
26419			// 	!state.paymentInitInfo.initializedPaymentMethods.includes('klarna-pay-now')) {
26420
26421			// 	paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'klarna-pay-now', state.paymentInitInfo.enrichedCheckout);
26422			// 	state.paymentInitInfo.initializedPaymentMethods.push('klarna-pay-now');
26423			// }
26424
26425			// if (activatedMethods.includes('klarna-pay-later') && 
26426			// 	identifier == 'klarna-pay-later' &&
26427			// 	!state.paymentInitInfo.initializedPaymentMethods.includes('klarna-pay-later')) {
26428
26429			// 	paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'klarna-pay-later', state.paymentInitInfo.enrichedCheckout);
26430			// 	state.paymentInitInfo.initializedPaymentMethods.push('klarna-pay-later');
26431			// }
26432
26433			// if (activatedMethods.includes('paypal-standard') && 
26434			// 	identifier == 'paypal-standard' &&
26435			// 	!state.paymentInitInfo.initializedPaymentMethods.includes('paypal-standard')) {
26436
26437			// 	paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'paypal-standard', state.paymentInitInfo.checkout);
26438			// 	state.paymentInitInfo.initializedPaymentMethods.push('paypal-standard');
26439			// }
26440
26441			// if (activatedMethods.includes('stripe-payments') && 
26442			// 	identifier == 'stripe-payments' &&
26443			// 	!state.paymentInitInfo.initializedPaymentMethods.includes('stripe-payments')) {
26444
26445			// 	paymentSubscriberNotifier.notify("payment.paymentMethod.init", 'stripe-payments', state.paymentInitInfo.enrichedCheckout);
26446			// 	state.paymentInitInfo.initializedPaymentMethods.push('stripe-payments');
26447			// }
26448		},
26449		async confirmPayment({state}, customer) {
26450
26451			// TODO: move to service
26452
26453			let checkoutEntity = CheckoutEntity/* default */.A.toPaymentPOJO(state);
26454
26455			if ((JSON.stringify(state.billingAddress) == '{}' || !state.billingAddress) && !state.customerBillingAddressId) {
26456				checkoutEntity.billingAddress = checkoutEntity.deliveryAddress;
26457			} else if (checkoutEntity.customerBillingAddressId) {
26458				
26459				if (customer.addresses) {
26460					for (let addressKey in customer.addresses) {
26461						let address = customer.addresses[addressKey];
26462						if (address.id == checkoutEntity.customerBillingAddressId) {
26463							checkoutEntity.billingAddress = address;
26464							break;
26465						}
26466					}
26467				}
26468			}
26469
26470			let paymentMethodIdentifier = '';
26471			for (let paymentMethod of state.paymentMethods) {
26472				if (paymentMethod.id == state.paymentMethodId) {
26473					paymentMethodIdentifier = paymentMethod.identifier;
26474					break;
26475				}	
26476			}
26477
26478			if (paymentMethodIdentifier) {
26479
26480				let klarnaEnrichedCheckout = {...checkoutEntity};
26481				klarnaEnrichedCheckout.userdata = customer;
26482
26483				paymentSubscriberNotifier.notify("payment.confirm", paymentMethodIdentifier, klarnaEnrichedCheckout);
26484			} else if (!state.paymentRequired) {
26485				paymentSubscriberNotifier.notify("payment.confirmed", []);
26486			} 
26487		},
26488		async addDiscount({state, dispatch, commit}, discountCode) {
26489			if (!state.discountCodes) state.discountCodes = [];
26490			state.discountCodes.push({code: discountCode});
26491			await dispatch('update');
26492			
26493			if (typeof window.gtag === 'function') {
26494				gtag('event', 'addDiscountCode', {
26495					'event_category': 'shopFunctions',
26496					'event_label': 'Add Discount Code',
26497					'value': 1
26498				});
26499			}
26500			commit('updateDiscountCodes');
26501		},
26502		async removeDiscount({state, dispatch, commit}, discountCode) {
26503			let key;
26504			for (let discountCodeKey in state.discountCodes) {
26505				if (state.discountCodes[discountCodeKey].code == discountCode) {
26506					key = discountCodeKey;
26507				}
26508			}
26509			state.discountCodes.splice(key, 1);
26510			commit('updateDiscountCodes');
26511			await dispatch('update');
26512			commit('updateDiscountCodes');
26513		}
26514	}
26515});
26516
26517;// ./vue/store/app.js
26518
26519/* harmony default export */ const app = ({
26520	namespaced: true,
26521	state: {
26522        isWishlistPopupOpen: false,
26523        isCartPopupOpen: false
26524	}
26525});
26526
26527;// ./vue/store/filter.js
26528
26529
26530
26531/* harmony default export */ const filter = ({
26532    namespaced: true,
26533	state: {
26534		availableProductFilters: [],
26535		availableProductSortOrders: []
26536    },
26537    actions: {
26538        async load({state}, filterString) {
26539            
26540            if (filterString) {
26541                filterString = '?filters='+filterString;
26542            } else {
26543                filterString = '';
26544            }
26545
26546            let apiClient = new APIClient/* default */.A();
26547            apiClient.method = 'GET';
26548            apiClient.headers = {
26549                'Accept-Language': SP_CONSTANTS.LOCALE
26550            };
26551            apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/categories/' + SP_CONSTANTS.CATEGORY.ID + '/productFilters' + filterString;
26552
26553            
26554            return await apiClient.call(data => {
26555                if (data.availableProductFilters) {
26556                    state.availableProductFilters = data.availableProductFilters;
26557                }
26558            });
26559			
26560        },
26561        async loadFilteredProductsMarkup({state}, filterString) {
26562
26563            if (filterString && filterString.indexOf('&') !== 0) {
26564                filterString = '&filters='+filterString;
26565            } else if (filterString.indexOf('&') !== 0) {
26566                filterString = '';
26567            }
26568
26569            return await window.fetch('?ajax=true'+filterString, {method: 'GET'})
26570            .then((response) => response.text())
26571		    .then((message) => {
26572                return message;
26573            });
26574        }
26575    }
26576});
26577// EXTERNAL MODULE: ./vue/entity/DiscountEntity.js
26578var DiscountEntity = __webpack_require__(1858);
26579// EXTERNAL MODULE: ./vue/entity/PaymentMethodEntity.js
26580var PaymentMethodEntity = __webpack_require__(7520);
26581;// ./vue/entity/OrderEntity.js
26582
26583
26584
26585
26586
26587class OrderEntity extends Entity/* default */.A {
26588	constructor() {
26589		super();
26590	}
26591
26592	static createFromAPIData(obj) {
26593		return OrderEntity.map({
26594			id: 'id',
26595			number: 'number',
26596			createdAt: 'createdAt',
26597			fulfillmentState: 'fulfillmentState',
26598			orderItems: {
26599				type: CartItemEntity/* default */.A,
26600				property: 'orderItems',
26601				converter: 'createFromAPIData'
26602			},
26603			orderItemsTotalPrice: {
26604				type: {},
26605				properties: {
26606					amount: 'amount',
26607					currencyCode: 'currencyCode',
26608					taxModel: 'taxModel'
26609				}
26610			},
26611			shippingPrice: {
26612				type: {},
26613				properties: {
26614					amount: 'amount',
26615					currencyCode: 'currencyCode',
26616					taxModel: 'taxModel'
26617				}
26618			},
26619			totalPrice: {
26620				type: {},
26621				properties: {
26622					amount: 'amount',
26623					currencyCode: 'currencyCode',
26624					taxModel: 'taxModel'
26625				}
26626			},
26627			totalGrossPrice: {
26628				type: {},
26629				properties: {
26630					amount: 'amount',
26631					currencyCode: 'currencyCode',
26632					taxModel: 'taxModel'
26633				}
26634			},
26635			discounts: {
26636				type: DiscountEntity/* default */.A,
26637				property: 'discounts',
26638				converter: 'createFromAPIData'
26639			},
26640			deliveryAddress: {
26641				type: {},
26642				properties: {
26643					street: 'street',
26644					street2: 'street2',
26645					postCode: 'postCode',
26646					city: 'city',
26647					countryCode: 'countryCode',
26648					firstName: 'firstName',
26649					lastName: 'lastName',
26650					company: 'company'
26651				}
26652			},
26653			billingAddress: {
26654				type: {},
26655				properties: {
26656					street: 'street',
26657					street2: 'street2',
26658					postCode: 'postCode',
26659					city: 'city',
26660					countryCode: 'countryCode',
26661					firstName: 'firstName',
26662					lastName: 'lastName',
26663					company: 'company'
26664				}
26665			},
26666			deliveryPeriod: {
26667				type: {},
26668				properties: {
26669					min: 'min',
26670					max: 'max',
26671					unit: 'unit'
26672				}
26673			},
26674			discountCodeRedemptions: 'discountCodeRedemptions',
26675			shippingRateId: 'shippingRateId',
26676			emailAddress: 'emailAddress',
26677			phone: 'phone',
26678			firstName: 'firstName',
26679			lastName: 'lastName',
26680			paymentMethodCharge: 'paymentMethodCharge',
26681			paymentMethodAfterOrderMessage: 'paymentMethodAfterOrderMessage',
26682			shippingMethodAfterOrderMessage: 'shippingMethodAfterOrderMessage',
26683			token: 'token',
26684			withdrawalRequestedAt: 'withdrawalRequestedAt',
26685			paymentMethod: {
26686				type: PaymentMethodEntity/* default */.A,
26687				property: ['_embedded', 'paymentMethod'],
26688				converter: 'createFromAPIData'
26689			}
26690		},
26691		obj);
26692	}
26693}
26694
26695/* harmony default export */ const entity_OrderEntity = (OrderEntity);
26696
26697;// ./vue/store/order.js
26698
26699
26700
26701
26702/* harmony default export */ const order = ({
26703	namespaced: true,
26704	state: {
26705		id: '',
26706		number: 0,
26707		createdAt: {},
26708		orderItems: [],
26709		shippingPrice: {},
26710		orderItemsTotalPrice: {},
26711		totalPrice: {},
26712		totalGrossPrice: {},
26713		deliveryAddress: {},
26714		billingAddress: {},
26715		paymentMethodCharge: {},
26716		deliveryPeriod: null,
26717		emailAddress: '',
26718		discounts: [],
26719		phone: '',
26720		firstName: '',
26721		lastName: '',
26722		paymentMethodAfterOrderMessage: '',
26723		shippingMethodAfterOrderMessage: '',
26724		paymentMethod: {},
26725		fulfillmentState: '',
26726		token: '',
26727		withdrawalRequestedAt: null
26728	},
26729	mutations: {
26730		setOrder(state, order) {
26731			let orderEntity = entity_OrderEntity.createFromAPIData(order);
26732            state.id = orderEntity.id;
26733            state.number = orderEntity.number;
26734            state.createdAt = orderEntity.createdAt;
26735            state.fulfillmentState = orderEntity.fulfillmentState;
26736            state.orderItems = orderEntity.orderItems;
26737            state.discounts = orderEntity.discounts;
26738            state.shippingPrice = orderEntity.shippingPrice;
26739            state.orderItemsTotalPrice = orderEntity.orderItemsTotalPrice;
26740            state.totalPrice = orderEntity.totalPrice;
26741            state.totalGrossPrice = orderEntity.totalGrossPrice;
26742            state.deliveryAddress = orderEntity.deliveryAddress;
26743            state.billingAddress = orderEntity.billingAddress;
26744            state.emailAddress = orderEntity.emailAddress;
26745            state.phone = orderEntity.phone;
26746            state.firstName = orderEntity.firstName;
26747            state.lastName = orderEntity.lastName;
26748            state.paymentMethodCharge = orderEntity.paymentMethodCharge;
26749            state.deliveryPeriod = orderEntity.deliveryPeriod;
26750            state.paymentMethodAfterOrderMessage = orderEntity.paymentMethodAfterOrderMessage;
26751            state.shippingMethodAfterOrderMessage = orderEntity.shippingMethodAfterOrderMessage;
26752			state.paymentMethod = orderEntity.paymentMethod;
26753			state.token = orderEntity.token;
26754			state.withdrawalRequestedAt = orderEntity.withdrawalRequestedAt;
26755        }
26756    },
26757    actions: {
26758        async create({state, commit}) {
26759			let apiClient = new APIClient/* default */.A();
26760			apiClient.method = 'POST';
26761			apiClient.data = JSON.stringify({
26762				command: 'create-order'
26763			});
26764
26765			if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
26766				apiClient.headers = {
26767					'Accept-Language': SP_CONSTANTS.LOCALE,
26768					'Authorization': 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token')
26769				};
26770			} else {
26771				apiClient.headers = {
26772					'Accept-Language': SP_CONSTANTS.LOCALE
26773				};
26774			}
26775
26776			let checkoutId;
26777			try {
26778				let raw = (0,SecureCookie/* SecureCookie */.o)('sp_checkout_info');
26779				if (raw) checkoutId = JSON.parse(raw).checkoutId;
26780			} catch (e) {}
26781			if (!checkoutId) return;
26782
26783			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/checkout/' + checkoutId + '/actions';
26784
26785			return await apiClient.call(data => {
26786				if (data._embedded && data._embedded.order.id) {
26787					commit('setOrder', data._embedded.order);
26788					(0,SecureCookie/* SecureCookie */.o)('sp_create_customer_token', data._embedded.order.createCustomerToken);
26789					(0,SecureCookie/* SecureCookie */.o)('sp_order_id', data._embedded.order.id);
26790					return true;
26791				} else {
26792					return data;
26793				}
26794			});
26795		},
26796		async load({state, commit}, payload) {
26797			let apiClient = new APIClient/* default */.A();
26798			apiClient.method = 'GET';
26799			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/orders/' + payload.orderId;
26800			let headersObj = {'Accept-Language': SP_CONSTANTS.LOCALE}
26801			if ((0,SecureCookie/* SecureCookie */.o)('sp_access_token')) {
26802				headersObj['Authorization'] = 'Bearer ' + (0,SecureCookie/* SecureCookie */.o)('sp_access_token');
26803			}
26804			if (payload.accessToken) {
26805				headersObj['X-Order-Token'] = payload.accessToken;
26806			}
26807
26808			apiClient.headers = headersObj;
26809
26810			return await apiClient.call(data => {
26811				if (data && !data.error) {
26812					// state.order = data._embedded.order;
26813					commit('setOrder', data);
26814					return true;
26815				} else {
26816					return data;
26817				}
26818			});
26819		}
26820    }
26821});
26822
26823;// ./vue/entity/ProductReviewEntity.js
26824
26825
26826class ProductReviewEntity extends Entity/* default */.A {
26827	constructor() {
26828		super();
26829	}
26830
26831	static createFromAPIData(obj) {
26832		return ProductReviewEntity.map({
26833			id: 'id',
26834			authorName: 'authorName',
26835			rating: 'rating',
26836			title: 'title',
26837			text: 'text',
26838			anonymous: 'anonymous',
26839			status: 'status',
26840			editLocked: 'editLocked',
26841			createdAt: 'createdAt',
26842			reply: 'reply',
26843			images: 'images'
26844		},
26845		obj);
26846	}
26847}
26848
26849/* harmony default export */ const entity_ProductReviewEntity = (ProductReviewEntity);
26850
26851;// ./vue/entity/ProductReviewTokenItemEntity.js
26852
26853
26854
26855class ProductReviewTokenItemEntity extends Entity/* default */.A {
26856	constructor() {
26857		super();
26858	}
26859
26860	static createFromAPIData(obj) {
26861		return ProductReviewTokenItemEntity.map({
26862			orderItemId: 'orderItemId',
26863			variantId: 'variantId',
26864			productId: 'productId',
26865			title: 'title',
26866			slugName: ['_embedded', 'product', 'slugName'],
26867			optionChoice: 'optionChoice',
26868			image: 'image',
26869			reviewable: 'reviewable',
26870			alreadyReviewed: 'alreadyReviewed',
26871			productReviewId: 'productReviewId',
26872			existingReview: {
26873				type: entity_ProductReviewEntity,
26874				property: ['_embedded', 'productReview'],
26875				converter: 'createFromAPIData'
26876			}
26877		},
26878		obj);
26879	}
26880}
26881
26882/* harmony default export */ const entity_ProductReviewTokenItemEntity = (ProductReviewTokenItemEntity);
26883
26884;// ./vue/entity/ProductReviewTokenEntity.js
26885
26886
26887
26888class ProductReviewTokenEntity extends Entity/* default */.A {
26889	constructor() {
26890		super();
26891	}
26892
26893	static createFromAPIData(obj) {
26894		return ProductReviewTokenEntity.map({
26895			valid: 'valid',
26896			expiresAt: 'expiresAt',
26897			orderId: 'orderId',
26898			orderNumber: 'orderNumber',
26899			orderToken: 'orderToken',
26900			orderCreatedAt: 'orderCreatedAt',
26901			items: {
26902				type: entity_ProductReviewTokenItemEntity,
26903				property: 'items',
26904				converter: 'createFromAPIData'
26905			},
26906			settings: {
26907				type: {},
26908				properties: {
26909					requireTitle: 'requireTitle',
26910					requireText: 'requireText',
26911					maxImagesPerReview: 'maxImagesPerReview',
26912					allowAnonymousReviews: 'allowAnonymousReviews',
26913					votingEnabled: 'votingEnabled',
26914					reportsEnabled: 'reportsEnabled',
26915					reviewAggregationLevel: 'reviewAggregationLevel'
26916				}
26917			}
26918		},
26919		obj);
26920	}
26921}
26922
26923/* harmony default export */ const entity_ProductReviewTokenEntity = (ProductReviewTokenEntity);
26924
26925;// ./vue/store/productReview.js
26926
26927
26928
26929const PREVIEW_TOKEN = 'preview';
26930
26931/* harmony default export */ const productReview = ({
26932	namespaced: true,
26933	state: {
26934		token: '',
26935		tokenInfo: null,
26936		isLoaded: false,
26937		error: null,
26938		currentVariantId: null,
26939		statistics: null
26940	},
26941	getters: {
26942		isPreview(state) {
26943			return state.token === PREVIEW_TOKEN;
26944		}
26945	},
26946	mutations: {
26947		setToken(state, token) {
26948			state.token = token;
26949		},
26950		setTokenInfo(state, data) {
26951			state.tokenInfo = entity_ProductReviewTokenEntity.createFromAPIData(data);
26952		},
26953		setError(state, error) {
26954			state.error = error;
26955		},
26956		setLoaded(state, value) {
26957			state.isLoaded = value;
26958		},
26959		setCurrentVariantId(state, id) {
26960			state.currentVariantId = id || null;
26961		},
26962		setStatistics(state, statistics) {
26963			state.statistics = statistics || null;
26964		}
26965	},
26966	actions: {
26967		readTokenFromUrl({state, commit}) {
26968			if (state.token) return state.token;
26969
26970			const params = new URLSearchParams(window.location.search);
26971			const token = params.get('t');
26972			if (!token) return null;
26973
26974			commit('setToken', token);
26975
26976			params.delete('t');
26977			const search = params.toString();
26978			const cleanUrl = window.location.pathname + (search ? '?' + search : '') + window.location.hash;
26979			window.history.replaceState({}, document.title, cleanUrl);
26980
26981			return token;
26982		},
26983		async validateToken({commit}, {token}) {
26984			commit('setToken', token);
26985			commit('setError', null);
26986			commit('setLoaded', false);
26987
26988			let apiClient = new APIClient/* default */.A();
26989			apiClient.method = 'GET';
26990			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/productReviewToken/validate';
26991
26992			let headersObj = {'Accept-Language': SP_CONSTANTS.LOCALE};
26993			if (token) {
26994				headersObj['X-Product-Review-Token'] = token;
26995			}
26996			apiClient.headers = headersObj;
26997
26998			return await apiClient.call(data => {
26999				commit('setLoaded', true);
27000				if (data && !data.error && data.valid) {
27001					commit('setTokenInfo', data);
27002					return true;
27003				} else {
27004					commit('setError', (data && data.error) ? data.error : 'invalid');
27005					return false;
27006				}
27007			});
27008		},
27009		async loadStatistics({state, commit}, {productId, variantId, aggregateByVariant}) {
27010			let apiClient = new APIClient/* default */.A();
27011			apiClient.method = 'GET';
27012			if (aggregateByVariant) {
27013				if (!variantId) return null;
27014				apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/variants/' + variantId + '/productReviews/statistics';
27015			} else {
27016				if (!productId) return null;
27017				apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/products/' + productId + '/productReviews/statistics';
27018			}
27019			let headersObj = {'Accept-Language': SP_CONSTANTS.LOCALE};
27020			if (state.token) headersObj['X-Product-Review-Token'] = state.token;
27021			apiClient.headers = headersObj;
27022
27023			return await apiClient.call(data => {
27024				const statistics = (data && !data.error) ? data : null;
27025				commit('setStatistics', statistics);
27026				return statistics;
27027			});
27028		},
27029		async loadReviews({state}, {productId, variantId, aggregateByVariant, page, limit}) {
27030			page = page || 1;
27031			limit = limit || 10;
27032
27033			let apiClient = new APIClient/* default */.A();
27034			apiClient.method = 'GET';
27035			if (aggregateByVariant) {
27036				if (!variantId) return null;
27037				apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/variants/' + variantId + '/productReviews';
27038			} else {
27039				if (!productId) return null;
27040				apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/products/' + productId + '/productReviews';
27041			}
27042			
27043			let headersObj = {'Accept-Language': SP_CONSTANTS.LOCALE};
27044			if (state.token) headersObj['X-Product-Review-Token'] = state.token;
27045			apiClient.headers = headersObj;
27046			apiClient.object = {sortBy: 'createdAt', sortOrder: 'DESC', page, limit};
27047
27048			return await apiClient.call(data => {
27049				if (!data || data.error) return null;
27050				let reviews = [];
27051				if (Array.isArray(data)) reviews = data;
27052				else if (data._embedded && data._embedded.productReviews) reviews = data._embedded.productReviews;
27053				else if (data.items) reviews = data.items;
27054				const total = typeof data.total === 'number' ? data.total : reviews.length;
27055				const returnedLimit = (typeof data.limit === 'number' && data.limit > 0) ? data.limit : limit;
27056				return {reviews, total, limit: returnedLimit};
27057			});
27058		},
27059		async voteReview({}, {reviewId, helpful}) {
27060			let apiClient = new APIClient/* default */.A();
27061			apiClient.method = 'POST';
27062			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/productReviews/' + reviewId + '/votes';
27063			apiClient.headers = {'Accept-Language': SP_CONSTANTS.LOCALE};
27064			apiClient.data = JSON.stringify({helpful});
27065			return await apiClient.call(data => data);
27066		},
27067		async reportReview({}, {reviewId, reason, description}) {
27068			let apiClient = new APIClient/* default */.A();
27069			apiClient.method = 'POST';
27070			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/productReviews/' + reviewId + '/reports';
27071			apiClient.headers = {'Accept-Language': SP_CONSTANTS.LOCALE};
27072			apiClient.data = JSON.stringify({reason, description});
27073			return await apiClient.call(data => data);
27074		},
27075		// Returns null on any failure - the caller shows the upload error. Never rejects, as a
27076		// rejection would leave the form's upload counter (and with it the submit button) stuck.
27077		async uploadImage({}, {file}) {
27078			try {
27079				let api = new APIClient/* default */.A();
27080				api.method = 'POST';
27081				api.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/signedUrls';
27082				api.data = JSON.stringify({contentType: file.type});
27083				const signed = await api.call(data => data);
27084				if (!signed || !signed.signedUrl) return null;
27085
27086				const upload = await fetch(signed.signedUrl, {method: 'PUT', body: file});
27087				if (!upload.ok) return null;
27088
27089				api = new APIClient/* default */.A();
27090				api.method = 'PATCH';
27091				api.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/publishSignedUrls';
27092				// Review photos are shown publicly on the product page, so they must stay public.
27093				api.data = JSON.stringify({signedUrl: signed.signedUrl, isPublic: true});
27094				const result = await api.call(data => data);
27095
27096				return result && result.path ? result.path : null;
27097			} catch (e) {
27098				return null;
27099			}
27100		},
27101		async submitReview({state}, {orderItemId, variantId, rating, title, text, anonymous, reviewId, images}) {
27102			let apiClient = new APIClient/* default */.A();
27103			apiClient.method = reviewId ? 'PATCH' : 'POST';
27104			apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/productReviewToken/variants/' + variantId + '/productReviews' + (reviewId ? '/' + reviewId : '');
27105			apiClient.headers = {
27106				'Accept-Language': SP_CONSTANTS.LOCALE,
27107				'X-Product-Review-Token': state.token
27108			};
27109			apiClient.data = JSON.stringify({
27110				orderItemId,
27111				rating,
27112				title,
27113				text,
27114				anonymous: !!anonymous,
27115				images: images || []
27116			});
27117
27118			return await apiClient.call(data => {
27119				return data && !data.error ? data : false;
27120			});
27121		}
27122	}
27123});
27124
27125;// ./vue/store/index.js
27126
27127
27128
27129
27130
27131
27132
27133
27134
27135/* harmony default export */ const store = ((0,vuex_esm_bundler/* createStore */.y$)({
27136	modules: {
27137		checkout: checkout,
27138		customer: customer,
27139		app: app,
27140		filter: filter,
27141		order: order,
27142		productReview: productReview
27143	}
27144}));
27145
27146// EXTERNAL MODULE: ./vue/components/Button.vue + 4 modules
27147var Button = __webpack_require__(2580);
27148;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Select.vue?vue&type=template&id=4bc9f3ee&scoped=true
27149
27150
27151const _hoisted_1 = { class: "sp-input__title-wrapper" }
27152const _hoisted_2 = ["for", "id"]
27153const _hoisted_3 = ["id", "clearable", "aria-required", "aria-invalid", "aria-describedby"]
27154const _hoisted_4 = ["selected"]
27155const _hoisted_5 = ["value", "selected", "disabled"]
27156const _hoisted_6 = ["id"]
27157
27158function render(_ctx, _cache, $props, $setup, $data, $options) {
27159  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
27160
27161  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
27162    class: (0,vue_esm_bundler/* normalizeClass */.C4)('gs_input__container sp-input-wrapper sp-select-wrapper' + ($props.hasError ? ' sp-input-wrapper--error ' : ''))
27163  }, [
27164    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
27165      class: (0,vue_esm_bundler/* normalizeClass */.C4)((($props.value) ? 'fieldset--active ' : '') + ($data.isFocused ? 'gs_input__fieldset-focus ' : '') + ' gs_input__fieldset')
27166    }, [
27167      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_1, [
27168        (0,vue_esm_bundler/* createElementVNode */.Lk)("label", {
27169          for: $data.inputName,
27170          id: 'label-'+$data.inputName,
27171          class: "gs_input__title sp-input__title"
27172        }, (0,vue_esm_bundler/* toDisplayString */.v_)($options.translatedActiveLabel || $options.translatedLabel), 9 /* TEXT, PROPS */, _hoisted_2)
27173      ]),
27174      (0,vue_esm_bundler/* createElementVNode */.Lk)("select", {
27175        id: $data.inputName,
27176        label: "name",
27177        class: "gs_input__input sp-input__input-select",
27178        clearable: $props.clearable,
27179        "aria-required": $props.required,
27180        "aria-invalid": $props.hasError,
27181        "aria-describedby": $options.describedBy,
27182        onFocus: _cache[0] || (_cache[0] = $event => {$data.isFocused = true; _ctx.$emit('focus')}),
27183        onFocusout: _cache[1] || (_cache[1] = $event => {$data.isFocused = false; $options.emitBlur()}),
27184        onInput: _cache[2] || (_cache[2] = $event => (_ctx.$emit('change', $event ? ($event.value || $event.name) : null)))
27185      }, [
27186        (0,vue_esm_bundler/* createCommentVNode */.Q3)(" default option "),
27187        ($props.label)
27188          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("option", {
27189              key: 0,
27190              value: "",
27191              selected: typeof $props.value == 'undefined' || $props.value === null
27192            }, (0,vue_esm_bundler/* toDisplayString */.v_)($options.translatedLabel), 9 /* TEXT, PROPS */, _hoisted_4))
27193          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
27194        (0,vue_esm_bundler/* createCommentVNode */.Q3)(" options "),
27195        ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($props.options, (option) => {
27196          return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("option", {
27197            value: option.value || option.name,
27198            selected: $props.value == (option.value || option.name),
27199            key: option.value,
27200            disabled: (option.disabled && $props.markUnavailable) && !$options.hasBackInStockNotificationFeature
27201          }, [
27202            (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)(option.name) + " ", 1 /* TEXT */),
27203            (option.disabled && $props.markUnavailable)
27204              ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, { key: 0 }, [
27205                  (0,vue_esm_bundler/* createTextVNode */.eW)("(" + (0,vue_esm_bundler/* toDisplayString */.v_)($options.hasBackInStockNotificationFeature ? $options.getTranslatedLabel('product.email_inquiry') : $options.getTranslatedLabel('product.sold_out')) + ")", 1 /* TEXT */)
27206                ], 64 /* STABLE_FRAGMENT */))
27207              : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27208          ], 8 /* PROPS */, _hoisted_5))
27209        }), 128 /* KEYED_FRAGMENT */)),
27210        (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <template #no-options=\"\">\n\t\t\t\t&nbsp;\n\t\t\t</template>\n\t\t\t<template #option=\"option\">\n\t\t\t\t<div class=\"input-disabled\" v-if=\"option.disabled && markUnavailable\">\n\t\t\t\t\t<span :class=\"'input-disabled__name '+(hasBackInStockNotificationFeature ? 'input-disabled__name--back-in-stock' : '')\">{{option.name}}</span>\n\t\t\t\t\t<span class=\"input-disabled__label\">{{hasBackInStockNotificationFeature ? getTranslatedLabel('product.email_inquiry') : getTranslatedLabel('product.sold_out')}}</span>\n\t\t\t\t</div>\n\t\t\t\t<div v-else>\n\t\t\t\t\t{{option.name}}\n\t\t\t\t</div>\n\t\t\t</template> ")
27211      ], 40 /* PROPS, NEED_HYDRATION */, _hoisted_3),
27212      (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <select v-on=\"$listeners\" class=\"sp-select gs_input__input\" @change=\"mutatedValue = $event.target.value\">\n\t\t\t<option v-if=\"label\" value=\"\" :selected=\"value == ''\">{{translatedLabel}}</option>\n\t\t\t<option :value=\"option.value || option.name\" v-for=\"option in options\" :selected=\"value == (option.value || option.name)\">{{option.name}}</option>\n\t\t</select> ")
27213    ], 2 /* CLASS */),
27214    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
27215      id: $data.inputName+'-error',
27216      class: (0,vue_esm_bundler/* normalizeClass */.C4)($props.hasError && $props.errorMessage ? 'sp-input__error-message gs_input__error-message' : 'access-hide'),
27217      "aria-live": "assertive"
27218    }, [
27219      ($props.hasError && $props.errorMessage)
27220        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, {
27221            key: 'error-'+$props.errorMessage,
27222            labelString: $props.errorMessage,
27223            variables: {fieldName: $options.translatedLabel}
27224          }, {
27225            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
27226              (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($props.errorMessage), 1 /* TEXT */)
27227            ]),
27228            _: 1 /* STABLE */
27229          }, 8 /* PROPS */, ["labelString", "variables"]))
27230        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27231    ], 10 /* CLASS, PROPS */, _hoisted_6)
27232  ], 2 /* CLASS */))
27233}
27234;// ./vue/components/Select.vue?vue&type=template&id=4bc9f3ee&scoped=true
27235
27236;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Select.vue?vue&type=script&lang=js
27237
27238/* harmony default export */ const Selectvue_type_script_lang_js = ({
27239	name: 'Select',
27240	props: {
27241		label: String,
27242		labelActive: String,
27243		options: Array,
27244		value: [String,Number],
27245		hasError: Boolean,
27246		required: Boolean,
27247		markUnavailable: Boolean,
27248		clearable: Boolean,
27249		errorMessage: String,
27250		ariaDescribedby: String,
27251		keepOriginalActiveLabel: Boolean
27252	},
27253	data() {
27254		return {
27255			mutatedValue: '',
27256			inputName: '',
27257			isFocused: false
27258		}
27259	},
27260	computed: {
27261		translatedLabel() {
27262			return this.getTranslatedLabel(this.label);
27263		},
27264		translatedActiveLabel() {
27265			return this.getTranslatedLabel(this.labelActive, true);
27266		},
27267		hasBackInStockNotificationFeature() {
27268			return (SP_CONSTANTS.SHOP.HAS_BACK_IN_STOCK_FEATURE && SP_CONSTANTS.SHOP.BACK_IN_STOCK_NOTIFICATION_ACTIVE) ? true : false;
27269		},
27270		describedBy() {
27271			let describedBy = '';
27272			if (this.hasError) {
27273				describedBy = this.inputName+'-error';
27274			}
27275			if (this.ariaDescribedby) {
27276				describedBy += ' ' + this.ariaDescribedby;
27277			}
27278			if (describedBy == '') return null;
27279			return describedBy;
27280		}
27281	},
27282	methods: {
27283		emitBlur() {
27284			this.$emit('blur');
27285			this.$emit('validation');
27286		},
27287		getTranslatedLabel(label, isActiveLabel = false) {
27288
27289			
27290			let requiredMarker = '';
27291			if (this.required) requiredMarker = '*';
27292
27293			if (this.keepOriginalActiveLabel && isActiveLabel) return label + requiredMarker;
27294
27295			if (label) {
27296				let [labelDomain, labelName, replace] = label.split('.').join('|').split('|');
27297				if (labelName) {
27298					return (labels[labelDomain][labelName][SP_CONSTANTS.LOCALE] + requiredMarker).replace('###', replace);
27299				} else {
27300					return label + requiredMarker;
27301				}
27302			}
27303		}
27304	},
27305	mounted() {
27306		this.inputName = 'input-id-'+Math.random().toString(36).substring(3).replaceAll('.', '');
27307	}
27308});
27309
27310;// ./vue/components/Select.vue?vue&type=script&lang=js
27311 
27312// EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js
27313var injectStylesIntoStyleTag = __webpack_require__(5072);
27314var injectStylesIntoStyleTag_default = /*#__PURE__*/__webpack_require__.n(injectStylesIntoStyleTag);
27315// EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/styleDomAPI.js
27316var styleDomAPI = __webpack_require__(7825);
27317var styleDomAPI_default = /*#__PURE__*/__webpack_require__.n(styleDomAPI);
27318// EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/insertBySelector.js
27319var insertBySelector = __webpack_require__(7659);
27320var insertBySelector_default = /*#__PURE__*/__webpack_require__.n(insertBySelector);
27321// EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js
27322var setAttributesWithoutAttributes = __webpack_require__(5056);
27323var setAttributesWithoutAttributes_default = /*#__PURE__*/__webpack_require__.n(setAttributesWithoutAttributes);
27324// EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/insertStyleElement.js
27325var insertStyleElement = __webpack_require__(540);
27326var insertStyleElement_default = /*#__PURE__*/__webpack_require__.n(insertStyleElement);
27327// EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/styleTagTransform.js
27328var styleTagTransform = __webpack_require__(1113);
27329var styleTagTransform_default = /*#__PURE__*/__webpack_require__.n(styleTagTransform);
27330// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Select.vue?vue&type=style&index=0&id=4bc9f3ee&scoped=true&lang=css
27331var Selectvue_type_style_index_0_id_4bc9f3ee_scoped_true_lang_css = __webpack_require__(1580);
27332;// ./node_modules/style-loader/dist/cjs.js!./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Select.vue?vue&type=style&index=0&id=4bc9f3ee&scoped=true&lang=css
27333
27334      
27335      
27336      
27337      
27338      
27339      
27340      
27341      
27342      
27343
27344var options = {};
27345
27346options.styleTagTransform = (styleTagTransform_default());
27347options.setAttributes = (setAttributesWithoutAttributes_default());
27348options.insert = insertBySelector_default().bind(null, "head");
27349options.domAPI = (styleDomAPI_default());
27350options.insertStyleElement = (insertStyleElement_default());
27351
27352var update = injectStylesIntoStyleTag_default()(Selectvue_type_style_index_0_id_4bc9f3ee_scoped_true_lang_css/* default */.A, options);
27353
27354
27355
27356
27357       /* harmony default export */ const components_Selectvue_type_style_index_0_id_4bc9f3ee_scoped_true_lang_css = (Selectvue_type_style_index_0_id_4bc9f3ee_scoped_true_lang_css/* default */.A && Selectvue_type_style_index_0_id_4bc9f3ee_scoped_true_lang_css/* default */.A.locals ? Selectvue_type_style_index_0_id_4bc9f3ee_scoped_true_lang_css/* default */.A.locals : undefined);
27358
27359;// ./vue/components/Select.vue?vue&type=style&index=0&id=4bc9f3ee&scoped=true&lang=css
27360
27361// EXTERNAL MODULE: ./node_modules/vue-loader/dist/exportHelper.js
27362var exportHelper = __webpack_require__(6262);
27363;// ./vue/components/Select.vue
27364
27365
27366
27367
27368;
27369
27370
27371const __exports__ = /*#__PURE__*/(0,exportHelper/* default */.A)(Selectvue_type_script_lang_js, [['render',render],['__scopeId',"data-v-4bc9f3ee"]])
27372
27373/* harmony default export */ const Select = (__exports__);
27374;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/TextInput.vue?vue&type=template&id=7875cad8
27375
27376
27377const TextInputvue_type_template_id_7875cad8_hoisted_1 = { class: "sp-input__title-wrapper" }
27378const TextInputvue_type_template_id_7875cad8_hoisted_2 = ["for"]
27379const TextInputvue_type_template_id_7875cad8_hoisted_3 = ["min", "max", "id", "type", "placeholder", "value", "aria-required", "aria-invalid", "aria-describedby"]
27380const TextInputvue_type_template_id_7875cad8_hoisted_4 = ["title"]
27381const TextInputvue_type_template_id_7875cad8_hoisted_5 = ["id"]
27382
27383function TextInputvue_type_template_id_7875cad8_render(_ctx, _cache, $props, $setup, $data, $options) {
27384  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
27385
27386  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
27387    class: (0,vue_esm_bundler/* normalizeClass */.C4)('gs_input__container sp-input-wrapper' + ($props.hasError ? ' sp-input-wrapper--error' : '') + ($props.suffix ? ' sp-input-wrapper--with-suffix' : ''))
27388  }, [
27389    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
27390      class: (0,vue_esm_bundler/* normalizeClass */.C4)((($props.value || $props.modelValue || $props.type == 'date' || $props.type == 'datetime-local' || $props.type == 'time') ? 'fieldset--active' : '') + ' gs_input__fieldset input__fieldset ' + ($data.isFocused ? 'gs_input__fieldset-focus' : ''))
27391    }, [
27392      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", TextInputvue_type_template_id_7875cad8_hoisted_1, [
27393        (0,vue_esm_bundler/* createElementVNode */.Lk)("label", {
27394          for: $data.inputName,
27395          class: "sp-input__title gs_input__title"
27396        }, (0,vue_esm_bundler/* toDisplayString */.v_)($options.translatedLabel), 9 /* TEXT, PROPS */, TextInputvue_type_template_id_7875cad8_hoisted_2)
27397      ]),
27398      (0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
27399        min: $props.min,
27400        max: $props.max,
27401        id: $data.inputName,
27402        type: $options.fieldType,
27403        class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-input gs_input__input ' + $options.classes),
27404        style: (0,vue_esm_bundler/* normalizeStyle */.Tr)($options.suffixInputStyle),
27405        placeholder: $options.translatedLabel ? $options.translatedLabel : '',
27406        value: $props.value || $props.modelValue,
27407        "aria-required": $props.required,
27408        "aria-invalid": $props.hasError,
27409        "aria-describedby": $options.describedBy,
27410        onInput: _cache[0] || (_cache[0] = $event => ($options.emitInput($event))),
27411        onFocus: _cache[1] || (_cache[1] = $event => {$data.isFocused = true; _ctx.$emit('focus')}),
27412        onFocusout: _cache[2] || (_cache[2] = $event => {$data.isFocused = false; $options.emitBlur()}),
27413        onKeydown: _cache[3] || (_cache[3] = (0,vue_esm_bundler/* withKeys */.jR)($event => (_ctx.$emit('enter')), ["enter"])),
27414        onClick: _cache[4] || (_cache[4] = $event => (_ctx.$emit('click', $event)))
27415      }, null, 46 /* CLASS, STYLE, PROPS, NEED_HYDRATION */, TextInputvue_type_template_id_7875cad8_hoisted_3),
27416      ($props.suffix)
27417        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", {
27418            key: 0,
27419            class: "sp-input__suffix gs_input__suffix",
27420            title: $props.suffix
27421          }, [
27422            ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($options.suffixList, (variant) => {
27423              return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", {
27424                key: variant,
27425                class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-input__suffix-variant' + (variant == $props.suffix ? '' : ' sp-input__suffix-variant--hidden'))
27426              }, (0,vue_esm_bundler/* toDisplayString */.v_)(variant), 3 /* TEXT, CLASS */))
27427            }), 128 /* KEYED_FRAGMENT */))
27428          ], 8 /* PROPS */, TextInputvue_type_template_id_7875cad8_hoisted_4))
27429        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
27430      ($props.type == 'number')
27431        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("i", {
27432            key: 1,
27433            tabindex: "-1",
27434            "aria-hidden": "true",
27435            onClick: _cache[5] || (_cache[5] = $event => {$options.subtractInteger();}),
27436            class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon input__number-button input__number-button--subtract '+ $options.SP_CONSTANTS.THEME.SUBTRACT_NUMBER_ICON)
27437          }, null, 2 /* CLASS */))
27438        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
27439      ($props.type == 'number')
27440        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("i", {
27441            key: 2,
27442            tabindex: "-1",
27443            "aria-hidden": "true",
27444            onClick: _cache[6] || (_cache[6] = $event => {$options.addInteger();}),
27445            class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon input__number-button input__number-button--add '+ $options.SP_CONSTANTS.THEME.ADD_NUMBER_ICON)
27446          }, null, 2 /* CLASS */))
27447        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27448    ], 2 /* CLASS */),
27449    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
27450      id: $data.inputName+'-error',
27451      class: (0,vue_esm_bundler/* normalizeClass */.C4)($props.hasError && $props.errorMessage ? 'sp-input__error-message gs_input__error-message' : 'access-hide'),
27452      "aria-live": "assertive"
27453    }, [
27454      ($props.hasError && $props.errorMessage)
27455        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, {
27456            key: 'error-'+$props.errorMessage,
27457            labelString: $props.errorMessage,
27458            variables: {fieldName: $options.translatedLabel}
27459          }, {
27460            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
27461              (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($props.errorMessage), 1 /* TEXT */)
27462            ]),
27463            _: 1 /* STABLE */
27464          }, 8 /* PROPS */, ["labelString", "variables"]))
27465        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27466    ], 10 /* CLASS, PROPS */, TextInputvue_type_template_id_7875cad8_hoisted_5)
27467  ], 2 /* CLASS */))
27468}
27469;// ./vue/components/TextInput.vue?vue&type=template&id=7875cad8
27470
27471;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/TextInput.vue?vue&type=script&lang=js
27472
27473/* harmony default export */ const TextInputvue_type_script_lang_js = ({
27474	name: 'TextInput',
27475	props: {
27476		label: String,
27477		type: String,
27478		align: String,
27479		disabled: Boolean,
27480		placeholder: [String,Number],
27481		suffix: String,
27482		suffixVariants: Array,
27483		value: [String,Number],
27484		modelValue: [String,Number],
27485		hasError: Boolean,
27486		required: Boolean,
27487		min: Number,
27488		max: Number,
27489		errorMessage: String,
27490		ariaDescribedby: String,
27491		isLabel: {
27492			type: Boolean,
27493			default: true
27494		}
27495	},
27496	emits: [
27497		'update:modelValue', 
27498		'change', 
27499		'focus', 
27500		'blur', 
27501		'validation', 
27502		'click', 
27503		'enter'
27504	],
27505	data() {
27506		return {
27507			updated: 0,
27508			inputName: '',
27509			isFocused: false
27510		}
27511	},
27512	methods: {
27513		emitBlur() {
27514			this.$emit('blur');
27515			this.$emit('validation');
27516		},
27517		labelToName(value) {
27518			return value.replace(/\./g, '__');
27519		},
27520		emitInput(event) {
27521			let value = this.calculateValue(event.target.value);
27522
27523			// A value cut down to the maximum that already equals the bound one is no
27524			// change for vue, so the input would keep showing the larger number the
27525			// visitor typed while the component works with the limit. Only the upper
27526			// limit is written back: a half-typed number is always too small for the
27527			// lower one, and snapping that would eat the next keystroke.
27528			if (this.exceedsMax(event.target.value)) event.target.value = value;
27529
27530			this.$emit('update:modelValue', value);
27531			this.$emit('change', value);
27532		},
27533		exceedsMax(value) {
27534			if (this.type != 'number') return false;
27535			if (typeof this.max != 'number') return false;
27536			return this.toNumber(value) > this.max;
27537		},
27538		toNumber(value) {
27539			value = String(value).replace(',', '.').replace(/[^0-9.]/g, '');
27540			return value === '' ? null : Number(value);
27541		},
27542		calculateValue(value) {
27543			if (this.type != 'number') return value;
27544
27545			value = value.replace(',', '.');
27546			value = value.replace(/[^0-9.]/g, '');
27547			value = value == null ? null : Number(value);
27548			if (typeof this.max == 'number' && value > this.max) return this.max;
27549			if (typeof this.min == 'number' && value < this.min) return this.min;
27550
27551			// avoid negative values
27552			if (value < 0) value = 0;
27553
27554			return value;
27555		},
27556		addInteger() {
27557			let value = this.value || this.modelValue;
27558			if (this.type != 'number') return;
27559			if (value == null || typeof value == 'undefined') value = 0;
27560			value = Number(value) + 1;
27561			if (typeof this.max == 'number' && value > this.max) value = Number(this.max);
27562			this.$emit('update:modelValue', value);
27563			this.$emit('change', value);
27564		},
27565		subtractInteger() {
27566			let value = this.value || this.modelValue;
27567			if (this.type != 'number') return;
27568			if (value == null) value = 0;
27569			value = Number(value) - 1;
27570			if (typeof this.min == 'number' && value < this.min) value = Number(this.min);
27571			this.$emit('update:modelValue', value);
27572			this.$emit('change', value);
27573		}
27574	},
27575	computed: {
27576		fieldType() {
27577			let type = this.type ? this.type : 'text';
27578			if (type == 'number') type = 'text';
27579			return type;
27580		},
27581		classes() {
27582			let classes = [];
27583			// type not fieldType as we need the original type to style the input
27584			if (this.type) classes.push('input--type-'+this.type); 
27585			if (this.disabled) classes.push('input--disabled');
27586			if (this.align) classes.push('text-'+this.align);
27587			return classes.join(' ');
27588		},
27589		translatedLabel() {
27590
27591			let requiredMarker = '';
27592			if (this.required) requiredMarker = '*';
27593
27594			if (this.label) {
27595
27596				if (!this.isLabel) return this.label + requiredMarker;
27597
27598				let [labelDomain, labelName] = this.label.split('.');
27599				if (labelName) {
27600					return labels[labelDomain][labelName][SP_CONSTANTS.LOCALE] + requiredMarker;
27601				} else {
27602					return this.label + requiredMarker;
27603				}
27604			}
27605		},
27606		suffixList() {
27607			if (!this.suffix) return [];
27608			let variants = Array.isArray(this.suffixVariants) ? this.suffixVariants.filter(variant => variant) : [];
27609			if (!variants.includes(this.suffix)) variants = variants.concat([this.suffix]);
27610			return variants;
27611		},
27612		suffixInputStyle() {
27613			if (!this.suffix) return null;
27614			let value = this.value || this.modelValue;
27615			if (value == null) value = '';
27616			let characters = Math.max(String(value).length, 2);
27617			return { width: 'calc(' + characters + 'ch)' };
27618		},
27619		describedBy() {
27620			let describedBy = '';
27621			if (this.hasError) {
27622				describedBy = this.inputName+'-error';
27623			}
27624			if (this.ariaDescribedby) {
27625				describedBy += ' ' + this.ariaDescribedby;
27626			}
27627			if (describedBy == '') return null;
27628			return describedBy;
27629		},
27630		SP_CONSTANTS() {
27631			return SP_CONSTANTS;
27632		}
27633	},
27634	mounted() {
27635		//@change="$emit('change', $event)"
27636		// delete this.$listeners.input;
27637		this.inputName = 'input-id-'+Math.random().toString(36).substring(3).replaceAll('.', '');
27638	}
27639});
27640
27641;// ./vue/components/TextInput.vue?vue&type=script&lang=js
27642 
27643;// ./vue/components/TextInput.vue
27644
27645
27646
27647
27648;
27649const TextInput_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(TextInputvue_type_script_lang_js, [['render',TextInputvue_type_template_id_7875cad8_render]])
27650
27651/* harmony default export */ const TextInput = (TextInput_exports_);
27652;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/TextArea.vue?vue&type=template&id=b65a5520
27653
27654
27655const TextAreavue_type_template_id_b65a5520_hoisted_1 = { class: "sp-input__title-wrapper" }
27656const TextAreavue_type_template_id_b65a5520_hoisted_2 = ["for"]
27657const TextAreavue_type_template_id_b65a5520_hoisted_3 = ["min", "max", "id", "type", "placeholder", "value", "aria-required", "aria-invalid", "aria-describedby"]
27658const TextAreavue_type_template_id_b65a5520_hoisted_4 = ["id"]
27659
27660function TextAreavue_type_template_id_b65a5520_render(_ctx, _cache, $props, $setup, $data, $options) {
27661  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
27662
27663  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
27664    class: (0,vue_esm_bundler/* normalizeClass */.C4)('gs_input__container sp-input-wrapper' + ($props.hasError ? ' sp-input-wrapper--error ' : ''))
27665  }, [
27666    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
27667      class: (0,vue_esm_bundler/* normalizeClass */.C4)(($props.value || $props.modelValue ? 'fieldset--active ' : '') + ($data.isFocused ? 'gs_input__fieldset-focus ' : '') + ' gs_input__fieldset')
27668    }, [
27669      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", TextAreavue_type_template_id_b65a5520_hoisted_1, [
27670        (0,vue_esm_bundler/* createElementVNode */.Lk)("label", {
27671          for: $data.inputName,
27672          class: "sp-input__title gs_input__title"
27673        }, (0,vue_esm_bundler/* toDisplayString */.v_)($options.translatedLabel), 9 /* TEXT, PROPS */, TextAreavue_type_template_id_b65a5520_hoisted_2)
27674      ]),
27675      (0,vue_esm_bundler/* createElementVNode */.Lk)("textarea", {
27676        min: $props.min,
27677        max: $props.max,
27678        id: $data.inputName,
27679        type: $props.type ? $props.type : 'text',
27680        class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-input sp-input--textarea gs_input__input ' + $options.classes),
27681        placeholder: $options.translatedLabel ? $options.translatedLabel : '',
27682        value: $props.value || $props.modelValue,
27683        "aria-required": $props.required,
27684        "aria-invalid": $props.hasError,
27685        "aria-describedby": $options.describedBy,
27686        onFocus: _cache[0] || (_cache[0] = $event => {$data.isFocused = true; _ctx.$emit('focus')}),
27687        onFocusout: _cache[1] || (_cache[1] = $event => {$data.isFocused = false; $options.emitBlur()}),
27688        onInput: _cache[2] || (_cache[2] = $event => {_ctx.$emit('update:modelValue', $event.target.value); _ctx.$emit('change', $event.target.value)}),
27689        onKeydown: _cache[3] || (_cache[3] = (0,vue_esm_bundler/* withKeys */.jR)($event => (_ctx.$emit('enter')), ["enter"])),
27690        onClick: _cache[4] || (_cache[4] = $event => (_ctx.$emit('click', $event)))
27691      }, null, 42 /* CLASS, PROPS, NEED_HYDRATION */, TextAreavue_type_template_id_b65a5520_hoisted_3)
27692    ], 2 /* CLASS */),
27693    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
27694      id: $data.inputName+'-error',
27695      class: (0,vue_esm_bundler/* normalizeClass */.C4)($props.hasError && $props.errorMessage ? 'sp-input__error-message gs_input__error-message' : 'access-hide'),
27696      "aria-live": "assertive"
27697    }, [
27698      ($props.hasError && $props.errorMessage)
27699        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, {
27700            key: 'error-'+$props.errorMessage,
27701            labelString: $props.errorMessage,
27702            variables: {fieldName: $options.translatedLabel}
27703          }, {
27704            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
27705              (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($props.errorMessage), 1 /* TEXT */)
27706            ]),
27707            _: 1 /* STABLE */
27708          }, 8 /* PROPS */, ["labelString", "variables"]))
27709        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27710    ], 10 /* CLASS, PROPS */, TextAreavue_type_template_id_b65a5520_hoisted_4)
27711  ], 2 /* CLASS */))
27712}
27713;// ./vue/components/TextArea.vue?vue&type=template&id=b65a5520
27714
27715;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/TextArea.vue?vue&type=script&lang=js
27716
27717/* harmony default export */ const TextAreavue_type_script_lang_js = ({
27718	name: 'TextArea',
27719	props: {
27720		label: String,
27721		type: String,
27722		align: String,
27723		disabled: Boolean,
27724		placeholder: [String,Number],
27725		value: [String,Number],
27726		modelValue: [String,Number],
27727		hasError: Boolean,
27728		required: Boolean,
27729		min: Number,
27730		max: Number,
27731		errorMessage: String,
27732		ariaDescribedby: String,
27733		isLabel: {
27734			type: Boolean,
27735			default: true
27736		}
27737	},
27738	emits: ['update:modelValue', 'change', 'focus', 'blur', 'enter', 'click'],
27739	data() {
27740		return {
27741			inputName: '',
27742			isFocused: false
27743		}
27744	},
27745	computed: {
27746		classes() {
27747			let classes = [];
27748			if (this.type) classes.push('sp-button--type-'+this.type);
27749			if (this.disabled) classes.push('sp-button--disabled');
27750			if (this.align) classes.push('text-'+this.align);
27751			return classes.join(' ');
27752		},
27753		translatedLabel() {
27754
27755			let requiredMarker = '';
27756			if (this.required) requiredMarker = '*';
27757
27758			if (this.label) {
27759				
27760				if (!this.isLabel) return this.label + requiredMarker;
27761
27762				let [labelDomain, labelName] = this.label.split('.');
27763				if (labelName) {
27764					return labels[labelDomain][labelName][SP_CONSTANTS.LOCALE] + requiredMarker;
27765				} else {
27766					return this.label + requiredMarker;
27767				}
27768			}
27769		},
27770		describedBy() {
27771			let describedBy = '';
27772			if (this.hasError) {
27773				describedBy = this.inputName+'-error';
27774			}
27775			if (this.ariaDescribedby) {
27776				describedBy += ' ' + this.ariaDescribedby;
27777			}
27778			if (describedBy == '') return null;
27779			return describedBy;
27780		}
27781	},
27782	methods: {
27783		emitBlur() {
27784			this.$emit('blur');
27785			this.$emit('validation');
27786		}
27787	},
27788	mounted() {
27789		//@change="$emit('change', $event)"
27790		// delete this.$listeners.input;
27791		this.inputName = 'input-id-'+Math.random().toString(36).substring(3).replaceAll('.', '');
27792	}
27793});
27794
27795;// ./vue/components/TextArea.vue?vue&type=script&lang=js
27796 
27797;// ./vue/components/TextArea.vue
27798
27799
27800
27801
27802;
27803const TextArea_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(TextAreavue_type_script_lang_js, [['render',TextAreavue_type_template_id_b65a5520_render]])
27804
27805/* harmony default export */ const TextArea = (TextArea_exports_);
27806;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Lang.vue?vue&type=template&id=d587a6f8
27807
27808
27809const Langvue_type_template_id_d587a6f8_hoisted_1 = ["innerHTML"]
27810const Langvue_type_template_id_d587a6f8_hoisted_2 = { key: 1 }
27811
27812function Langvue_type_template_id_d587a6f8_render(_ctx, _cache, $props, $setup, $data, $options) {
27813  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", { key: $props.labelString }, [
27814    (_ctx.name != '')
27815      ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", {
27816          key: 0,
27817          innerHTML: $options.label
27818        }, null, 8 /* PROPS */, Langvue_type_template_id_d587a6f8_hoisted_1))
27819      : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", Langvue_type_template_id_d587a6f8_hoisted_2, [
27820          (0,vue_esm_bundler/* renderSlot */.RG)(_ctx.$slots, "default")
27821        ]))
27822  ]))
27823}
27824;// ./vue/components/Lang.vue?vue&type=template&id=d587a6f8
27825
27826;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Lang.vue?vue&type=script&lang=js
27827
27828
27829/* harmony default export */ const Langvue_type_script_lang_js = ({
27830	name: 'lang',
27831	props: {
27832		labelString: String,
27833		variables: Object,
27834	},
27835	data: () => ({
27836        name: ''
27837	}),
27838	watch: {
27839		$el() {
27840		}
27841	},
27842	computed: {
27843		label() {
27844			let name = this.labelString || this.name;
27845            let [labelDomain, labelName] = name.toLowerCase().split('.');
27846			if (labels[labelDomain] && labels[labelDomain][labelName] && labels[labelDomain][labelName][SP_CONSTANTS.LOCALE]) {
27847				let labelValue = labels[labelDomain][labelName][SP_CONSTANTS.LOCALE];
27848				if (labelValue.indexOf('{{') >= 0 && this.variables) {
27849					for (let variable in this.variables) {
27850						labelValue = labelValue.replace('{{'+variable+'}}', this.variables[variable]);
27851					}
27852				}
27853				return labelValue;
27854			} else if (labels[labelDomain] && labels[labelDomain][labelName] === undefined) {
27855				return labels[labelDomain]['error_occurred'][SP_CONSTANTS.LOCALE];
27856			} else {
27857				return this.labelString || this.name;
27858			}
27859		}
27860	},
27861	mounted() {
27862		this.name = this.$el.innerText;
27863	}
27864});
27865
27866;// ./vue/components/Lang.vue?vue&type=script&lang=js
27867 
27868;// ./vue/components/Lang.vue
27869
27870
27871
27872
27873;
27874const Lang_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(Langvue_type_script_lang_js, [['render',Langvue_type_template_id_d587a6f8_render]])
27875
27876/* harmony default export */ const Lang = (Lang_exports_);
27877;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/MethodRadio.vue?vue&type=template&id=0aca27f4
27878
27879
27880const MethodRadiovue_type_template_id_0aca27f4_hoisted_1 = { class: "method-radio__wrapper" }
27881const MethodRadiovue_type_template_id_0aca27f4_hoisted_2 = ["for", "onClick"]
27882const MethodRadiovue_type_template_id_0aca27f4_hoisted_3 = ["value", "name", "id", "checked", "disabled"]
27883const MethodRadiovue_type_template_id_0aca27f4_hoisted_4 = ["innerHTML"]
27884const MethodRadiovue_type_template_id_0aca27f4_hoisted_5 = {
27885  key: 0,
27886  class: "method-radio__back-in-stock-marker"
27887}
27888const MethodRadiovue_type_template_id_0aca27f4_hoisted_6 = {
27889  key: 0,
27890  class: "method-radio__price"
27891}
27892const _hoisted_7 = { key: 0 }
27893const _hoisted_8 = ["id"]
27894
27895function MethodRadiovue_type_template_id_0aca27f4_render(_ctx, _cache, $props, $setup, $data, $options) {
27896  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", MethodRadiovue_type_template_id_0aca27f4_hoisted_1, [
27897    ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($props.options, (option, key) => {
27898      return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, { key: key }, [
27899        (!$props.needsActivation || ($props.needsActivation && option.activated))
27900          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("label", {
27901              key: 0,
27902              for: 'method-radio-'+$data.inputName+'__' + $options.encodeId(option.id),
27903              class: (0,vue_esm_bundler/* normalizeClass */.C4)('method-radio ' + (($props.value == option.id || $props.modelValue == option.id) ? $props.optionClassesActive : $props.optionClasses)),
27904              style: (0,vue_esm_bundler/* normalizeStyle */.Tr)($options.getOptionStyle(option)),
27905              onClick: $event => ($options.handleLabelClick($event, option))
27906            }, [
27907              (0,vue_esm_bundler/* createElementVNode */.Lk)("div", null, [
27908                (0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
27909                  class: "method-radio__input",
27910                  type: "radio",
27911                  value: option.id,
27912                  name: $props.name || $data.inputName,
27913                  id: 'method-radio-'+$data.inputName+'__' + $options.encodeId(option.id),
27914                  onInput: _cache[0] || (_cache[0] = $event => {_ctx.$emit('update:modelValue', $event.target.value); _ctx.$emit('change', $event.target.value)}),
27915                  onChange: _cache[1] || (_cache[1] = $event => {_ctx.$emit('update:modelValue', $event.target.value); _ctx.$emit('change', $event.target.value)}),
27916                  checked: ($props.value == option.id || $props.modelValue == option.id) ? true : false,
27917                  disabled: $props.disabled || ((option.disabled && $props.markUnavailable) && !$options.hasBackInStockNotificationFeature)
27918                }, null, 40 /* PROPS, NEED_HYDRATION */, MethodRadiovue_type_template_id_0aca27f4_hoisted_3),
27919                (0,vue_esm_bundler/* createElementVNode */.Lk)("span", {
27920                  innerHTML: option.name
27921                }, null, 8 /* PROPS */, MethodRadiovue_type_template_id_0aca27f4_hoisted_4),
27922                _cache[2] || (_cache[2] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
27923                (option.disabled && $props.markUnavailable)
27924                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", MethodRadiovue_type_template_id_0aca27f4_hoisted_5, "(" + (0,vue_esm_bundler/* toDisplayString */.v_)($options.hasBackInStockNotificationFeature ? $options.getTranslatedLabel('product.email_inquiry') : $options.getTranslatedLabel('product.sold_out')) + ")", 1 /* TEXT */))
27925                  : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27926              ]),
27927              (option.chargeAmount)
27928                ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", MethodRadiovue_type_template_id_0aca27f4_hoisted_6, [
27929                    (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)(_ctx.formatPrice(option.chargeAmount/100)) + " ", 1 /* TEXT */),
27930                    (option.chargeSuffix)
27931                      ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", _hoisted_7, (0,vue_esm_bundler/* toDisplayString */.v_)(option.chargeSuffix), 1 /* TEXT */))
27932                      : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27933                  ]))
27934                : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
27935              (option.identifier)
27936                ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
27937                    key: 1,
27938                    style: (0,vue_esm_bundler/* normalizeStyle */.Tr)((($props.value == option.id || $props.modelValue == option.id) ? 'dis
27938play:block;' : 'display:none;') + ' width: 100%;')
27939                  }, [
27940                    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
27941                      id: 'hook-container-'+option.identifier
27942                    }, null, 8 /* PROPS */, _hoisted_8)
27943                  ], 4 /* STYLE */))
27944                : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27945            ], 14 /* CLASS, STYLE, PROPS */, MethodRadiovue_type_template_id_0aca27f4_hoisted_2))
27946          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
27947      ], 64 /* STABLE_FRAGMENT */))
27948    }), 128 /* KEYED_FRAGMENT */))
27949  ]))
27950}
27951;// ./vue/components/MethodRadio.vue?vue&type=template&id=0aca27f4
27952
27953// EXTERNAL MODULE: ./vue/mixin/Format.js
27954var Format = __webpack_require__(3133);
27955// EXTERNAL MODULE: ./vue/mixin/ImageSrc.js
27956var ImageSrc = __webpack_require__(6791);
27957;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/MethodRadio.vue?vue&type=script&lang=js
27958
27959
27960
27961
27962/* harmony default export */ const MethodRadiovue_type_script_lang_js = ({
27963    data() {
27964      return {
27965        inputName: ''
27966      }
27967    },
27968    emits: ['update:modelValue', 'change'],
27969    mixins: [Format/* default */.A, ImageSrc/* default */.A],
27970    props: {
27971        name: String,
27972        options: [Array, Object],
27973        value: [String, Number],
27974        modelValue: [String, Number],
27975        disabled: Boolean,
27976        needsActivation: Boolean,
27977        optionClasses: {
27978          type: String,
27979          default: ''
27980        },
27981        optionClassesActive: {
27982          type: String,
27983          default: ''
27984        },
27985        markUnavailable: {
27986          type: Boolean,
27987          default: true
27988        },
27989        allowDeselect: {
27990          type: Boolean,
27991          default: false
27992        },
27993    },
27994    computed: {
27995      hasBackInStockNotificationFeature() {
27996        return (SP_CONSTANTS.SHOP.HAS_BACK_IN_STOCK_FEATURE && SP_CONSTANTS.SHOP.BACK_IN_STOCK_NOTIFICATION_ACTIVE) ? true : false;
27997      },
27998    },
27999    methods: {
28000      getOptionStyle(option) {
28001        if (!option.image || !option.color) '';
28002
28003        if (option.image && option.image.file) {
28004          // Payment and shipping logos, rendered small (SPEC-imgproxy.md).
28005          return 'background-image: url(' + this.imageSrc(option.image, 200) + ');';
28006        } else if (option.color) {
28007          return 'background-color: rgba(' + option.color.red + ', ' + option.color.green + ', ' + option.color.blue + ', ' + (option.color.alpha/100) + ');';
28008        }
28009      },
28010      encodeId(value) {
28011        return encodeURIComponent(value).replace(/%/g, '_');
28012      },
28013      handleLabelClick(event, option) {
28014        if (!this.allowDeselect) return;
28015        let isSelected = (this.value == option.id || this.modelValue == option.id);
28016        if (!isSelected) return;
28017        event.preventDefault();
28018        this.$emit('update:modelValue', '');
28019        this.$emit('change', '');
28020      },
28021      getTranslatedLabel(label, isActiveLabel = false) {
28022        let requiredMarker = '';
28023        if (this.required) requiredMarker = '*';
28024
28025        if (this.keepOriginalActiveLabel && isActiveLabel) return label + requiredMarker;
28026
28027        if (label) {
28028          let [labelDomain, labelName, replace] = label.split('.').join('|').split('|');
28029          if (labelName) {
28030            return (labels[labelDomain][labelName][SP_CONSTANTS.LOCALE] + requiredMarker).replace('###', replace);
28031          } else {
28032            return label + requiredMarker;
28033          }
28034        }
28035      }
28036    },
28037    mounted() {
28038        this.inputName = Math.random().toString(36).substring(7);
28039    }
28040});
28041
28042;// ./vue/components/MethodRadio.vue?vue&type=script&lang=js
28043 
28044;// ./vue/components/MethodRadio.vue
28045
28046
28047
28048
28049;
28050const MethodRadio_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(MethodRadiovue_type_script_lang_js, [['render',MethodRadiovue_type_template_id_0aca27f4_render]])
28051
28052/* harmony default export */ const MethodRadio = (MethodRadio_exports_);
28053;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Checkbox.vue?vue&type=template&id=735787f2
28054
28055
28056const Checkboxvue_type_template_id_735787f2_hoisted_1 = ["id", "checked", "aria-required", "aria-invalid", "aria-describedby"]
28057const Checkboxvue_type_template_id_735787f2_hoisted_2 = ["for", "innerHTML"]
28058const Checkboxvue_type_template_id_735787f2_hoisted_3 = ["for"]
28059const Checkboxvue_type_template_id_735787f2_hoisted_4 = ["id"]
28060
28061function Checkboxvue_type_template_id_735787f2_render(_ctx, _cache, $props, $setup, $data, $options) {
28062  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
28063
28064  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
28065    class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-input-wrapper sp-checkbox-wrapper ' + ($props.hasError ? ' sp-input-wrapper--error' : ''))
28066  }, [
28067    (0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
28068      id: 'checkbox-'+$data.inputName,
28069      type: "checkbox",
28070      class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-checkbox ' + $options.classes),
28071      value: true,
28072      checked: $props.value || $props.modelValue,
28073      "aria-required": $props.required,
28074      "aria-invalid": $props.hasError,
28075      "aria-describedby": $options.describedBy,
28076      onFocusout: _cache[0] || (_cache[0] = $event => ($options.emitBlur())),
28077      onInput: _cache[1] || (_cache[1] = $event => {_ctx.$emit('update:modelValue', Boolean($event.target.checked)); _ctx.$emit('change', Boolean($event.target.checked))})
28078    }, null, 42 /* CLASS, PROPS, NEED_HYDRATION */, Checkboxvue_type_template_id_735787f2_hoisted_1),
28079    ($props.useHtml)
28080      ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("label", {
28081          key: 0,
28082          for: 'checkbox-'+$data.inputName,
28083          class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-checkbox__label ' + $props.labelClass),
28084          innerHTML: $options.translatedLabel
28085        }, null, 10 /* CLASS, PROPS */, Checkboxvue_type_template_id_735787f2_hoisted_2))
28086      : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("label", {
28087          key: 1,
28088          for: 'checkbox-'+$data.inputName,
28089          class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-checkbox__label ' + $props.labelClass)
28090        }, (0,vue_esm_bundler/* toDisplayString */.v_)($options.translatedLabel), 11 /* TEXT, CLASS, PROPS */, Checkboxvue_type_template_id_735787f2_hoisted_3)),
28091    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
28092      id: $data.inputName+'-error',
28093      class: (0,vue_esm_bundler/* normalizeClass */.C4)($props.hasError && $props.errorMessage ? 'sp-input__error-message gs_input__error-message' : 'access-hide'),
28094      "aria-live": "assertive"
28095    }, [
28096      ($props.hasError && $props.errorMessage)
28097        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, {
28098            key: 'error-'+$props.errorMessage,
28099            labelString: $props.errorMessage,
28100            variables: {fieldName: $options.getLabel('errors.checkbox')}
28101          }, {
28102            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
28103              (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($props.errorMessage), 1 /* TEXT */)
28104            ]),
28105            _: 1 /* STABLE */
28106          }, 8 /* PROPS */, ["labelString", "variables"]))
28107        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
28108    ], 10 /* CLASS, PROPS */, Checkboxvue_type_template_id_735787f2_hoisted_4)
28109  ], 2 /* CLASS */))
28110}
28111;// ./vue/components/Checkbox.vue?vue&type=template&id=735787f2
28112
28113;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Checkbox.vue?vue&type=script&lang=js
28114
28115
28116/* harmony default export */ const Checkboxvue_type_script_lang_js = ({
28117	name: 'Checkbox',
28118	props: {
28119		label: String,
28120		type: String,
28121		disabled: Boolean,
28122		value: [String,Number,Boolean],
28123		modelValue: [String,Number,Boolean],
28124		hasError: Boolean,
28125		useHtml: Boolean,
28126		required: Boolean,
28127		errorMessage: String,
28128		ariaDescribedby: String,
28129		labelClass: String,
28130		isLabel: {
28131			type: Boolean,
28132			default: true
28133		}
28134	},
28135	emits: ['update:modelValue', 'change'],
28136	data() {
28137		return {
28138			inputName: ''
28139		}
28140	},
28141	computed: {
28142		classes() {
28143			let classes = [];
28144			if (this.type) classes.push('sp-button--type-'+this.type);
28145			if (this.disabled) classes.push('sp-button--disabled');
28146			if (this.align) classes.push('text-'+this.align);
28147			if (this.hasError) classes.push('sp-checkbox--error');
28148			return classes.join(' ');
28149		},
28150		translatedLabel() {
28151			let requiredMarker = '';
28152			if (this.required) requiredMarker = '*';
28153			
28154			if (this.label) {
28155				
28156				if (!this.isLabel) return this.label + requiredMarker;
28157
28158				let [labelDomain, labelName] = this.label.split('.');
28159				if (labelName && labels[labelDomain]) {
28160					return labels[labelDomain][labelName][SP_CONSTANTS.LOCALE] + requiredMarker;
28161				} else {
28162					return this.label + requiredMarker;
28163				}
28164			}
28165		},
28166		describedBy() {
28167			let describedBy = '';
28168			if (this.hasError) {
28169				describedBy = this.inputName+'-error';
28170			}
28171			if (this.ariaDescribedby) {
28172				describedBy += ' ' + this.ariaDescribedby;
28173			}
28174			if (describedBy == '') return null;
28175			return describedBy;
28176		}
28177	},
28178	methods: {
28179		emitBlur() {
28180			this.$emit('blur');
28181			this.$emit('validation');
28182		},
28183		getLabel(label) {
28184			if (label) {
28185				let [labelDomain, labelName] = label.split('.');
28186				if (labelName && labels[labelDomain]) {
28187					return labels[labelDomain][labelName][SP_CONSTANTS.LOCALE];
28188				} else {
28189					return labelName;
28190				}
28191			}
28192		}
28193	},
28194	mounted() {
28195		this.inputName = Math.random().toString(36).substring(7);
28196	}
28197});
28198
28199;// ./vue/components/Checkbox.vue?vue&type=script&lang=js
28200 
28201;// ./vue/components/Checkbox.vue
28202
28203
28204
28205
28206;
28207const Checkbox_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(Checkboxvue_type_script_lang_js, [['render',Checkboxvue_type_template_id_735787f2_render]])
28208
28209/* harmony default export */ const Checkbox = (Checkbox_exports_);
28210;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Radio.vue?vue&type=template&id=9437ebce
28211
28212
28213const Radiovue_type_template_id_9437ebce_hoisted_1 = ["id", "name", "checked", "onInput"]
28214const Radiovue_type_template_id_9437ebce_hoisted_2 = ["for"]
28215
28216function Radiovue_type_template_id_9437ebce_render(_ctx, _cache, $props, $setup, $data, $options) {
28217  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
28218    class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-input-wrapper sp-radio-wrapper ' + ($props.hasError ? ' sp-input-wrapper--error' : ''))
28219  }, [
28220    ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($props.options, (option, optionKey) => {
28221      return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
28222        key: option.value
28223      }, [
28224        (0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
28225          id: 'radio-'+$data.inputName+optionKey,
28226          name: 'radio-'+$data.inputName,
28227          type: "radio",
28228          class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-radio ' + _ctx.classes),
28229          value: true,
28230          checked: ($props.value || $props.modelValue) == option.value,
28231          onInput: $event => {_ctx.$emit('update:modelValue', Boolean($event.target.checked) ? option.value : null); _ctx.$emit('change', Boolean($event.target.checked) ? option.value : null)}
28232        }, null, 42 /* CLASS, PROPS, NEED_HYDRATION */, Radiovue_type_template_id_9437ebce_hoisted_1),
28233        (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <label v-if=\"useHtml\" :for=\"'radio-'+inputName\" class=\"sp-radio__label\" v-html=\"translatedLabel\"></label> "),
28234        (0,vue_esm_bundler/* createElementVNode */.Lk)("label", {
28235          for: 'radio-'+$data.inputName+optionKey,
28236          class: "sp-radio__label"
28237        }, (0,vue_esm_bundler/* toDisplayString */.v_)(option.name), 9 /* TEXT, PROPS */, Radiovue_type_template_id_9437ebce_hoisted_2)
28238      ]))
28239    }), 128 /* KEYED_FRAGMENT */))
28240  ], 2 /* CLASS */))
28241}
28242;// ./vue/components/Radio.vue?vue&type=template&id=9437ebce
28243
28244;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Radio.vue?vue&type=script&lang=js
28245
28246/* harmony default export */ const Radiovue_type_script_lang_js = ({
28247	name: 'Radio',
28248	props: {
28249		label: String,
28250		labelActive: String,
28251		options: Array,
28252		value: [String,Number],
28253		modelValue: [String,Number],
28254		hasError: Boolean,
28255		required: Boolean,
28256		markUnavailable: Boolean,
28257		clearable: Boolean,
28258		keepOriginalActiveLabel: Boolean
28259	},
28260	data() {
28261		return {
28262			inputName: ''
28263		}
28264	},
28265	emits: ['update:modelValue', 'change'],
28266	computed: {
28267		translatedLabel() {
28268			return this.getTranslatedLabel(this.label);
28269		},
28270		translatedActiveLabel() {
28271			return this.getTranslatedLabel(this.labelActive, true);
28272		}
28273	},
28274	methods: {
28275		getTranslatedLabel(label, isActiveLabel = false) {
28276
28277			
28278			let requiredMarker = '';
28279			if (this.required) requiredMarker = '*';
28280
28281			if (this.keepOriginalActiveLabel && isActiveLabel) return label + requiredMarker;
28282
28283			if (label) {
28284				let [labelDomain, labelName, replace] = label.split('.').join('|').split('|');
28285				if (labelName) {
28286					return (labels[labelDomain][labelName][SP_CONSTANTS.LOCALE] + requiredMarker).replace('###', replace);
28287				} else {
28288					return label + requiredMarker;
28289				}
28290			}
28291		}
28292	},
28293	mounted() {
28294		// alert(1)
28295		this.inputName = Math.random().toString(36).substring(7);
28296	}
28297});
28298
28299;// ./vue/components/Radio.vue?vue&type=script&lang=js
28300 
28301;// ./vue/components/Radio.vue
28302
28303
28304
28305
28306;
28307const Radio_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(Radiovue_type_script_lang_js, [['render',Radiovue_type_template_id_9437ebce_render]])
28308
28309/* harmony default export */ const Radio = (Radio_exports_);
28310;// ./vue/components/index.js
28311
28312
28313
28314
28315
28316
28317
28318
28319
28320/* harmony default export */ const components = ({
28321	'sp-button': Button/* default */.A,
28322	'sp-select': Select,
28323	'sp-input': TextInput,
28324	'sp-lang': Lang,
28325	'sp-method-radio': MethodRadio,
28326	'sp-checkbox': Checkbox,
28327	'sp-textarea': TextArea,
28328	'sp-radio': Radio
28329});
28330
28331;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/App.vue?vue&type=template&id=331b2732
28332
28333
28334function Appvue_type_template_id_331b2732_render(_ctx, _cache, $props, $setup, $data, $options) {
28335  const _component_cart_popup = (0,vue_esm_bundler/* resolveComponent */.g2)("cart-popup")
28336  const _component_wishlist_popup = (0,vue_esm_bundler/* resolveComponent */.g2)("wishlist-popup")
28337  const _component_cookie_consent = (0,vue_esm_bundler/* resolveComponent */.g2)("cookie-consent")
28338  const _component_status_bar = (0,vue_esm_bundler/* resolveComponent */.g2)("status-bar")
28339  const _component_chatbot = (0,vue_esm_bundler/* resolveComponent */.g2)("chatbot")
28340
28341  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", null, [
28342    (0,vue_esm_bundler/* createVNode */.bF)(_component_cart_popup),
28343    (0,vue_esm_bundler/* createVNode */.bF)(_component_wishlist_popup),
28344    ($options.showConsent == '1' && $data.userInteracted)
28345      ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_consent, { key: 0 }))
28346      : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
28347    ($data.isPreview)
28348      ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_status_bar, { key: 1 }))
28349      : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
28350    (0,vue_esm_bundler/* createVNode */.bF)(_component_chatbot)
28351  ]))
28352}
28353;// ./vue/App.vue?vue&type=template&id=331b2732
28354
28355;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CartPopup.vue?vue&type=template&id=5a27e86a
28356
28357
28358const CartPopupvue_type_template_id_5a27e86a_hoisted_1 = {
28359  key: 0,
28360  class: "cart-popup-wrapper"
28361}
28362const CartPopupvue_type_template_id_5a27e86a_hoisted_2 = { class: "cart-popup__header gs_cart-popup__header" }
28363const CartPopupvue_type_template_id_5a27e86a_hoisted_3 = { class: "cart-popup__title gs_cart-popup__title" }
28364const CartPopupvue_type_template_id_5a27e86a_hoisted_4 = { class: "cart-popup__quantity gs_cart-popup__quantity" }
28365const CartPopupvue_type_template_id_5a27e86a_hoisted_5 = {
28366  key: 0,
28367  class: "cart-popup__free-shipping-meter free-shipping-meter gs_cart-popup__free-shipping-meter"
28368}
28369const CartPopupvue_type_template_id_5a27e86a_hoisted_6 = {
28370  key: 0,
28371  class: "gs_cart-popup__free-shipping-text"
28372}
28373const CartPopupvue_type_template_id_5a27e86a_hoisted_7 = {
28374  key: 1,
28375  class: "gs_cart-popup__free-shipping-text"
28376}
28377const CartPopupvue_type_template_id_5a27e86a_hoisted_8 = { class: "free-shipping-meter__progress-bar gs_cart-popup__free-shipping-bar" }
28378const _hoisted_9 = { class: "cart-popup__items gs_cart-popup__items-container" }
28379const _hoisted_10 = {
28380  key: 0,
28381  class: "cart-popup__item gs_cart-popup__item"
28382}
28383const _hoisted_11 = { class: "row no-gutters" }
28384const _hoisted_12 = { class: "col-4" }
28385const _hoisted_13 = { class: "cart-popup__image-wrapper gs_cart-popup__product-image" }
28386const _hoisted_14 = { class: "col-8" }
28387const _hoisted_15 = { class: "cart-popup__title gs_cart-popup__product-title" }
28388const _hoisted_16 = { class: "cart-popup__price gs_cart-popup__product-info" }
28389const _hoisted_17 = { class: "cart-popup__options" }
28390const _hoisted_18 = { class: "cart-popup__amount" }
28391const _hoisted_19 = ["onClick", "title", "aria-label"]
28392const _hoisted_20 = { class: "cart-popup__summary gs_cart-popup__summary-container" }
28393const _hoisted_21 = { class: "cart-summary__sub gs_cart-popup__summary-subtotal" }
28394const _hoisted_22 = { class: "cart-summary__value" }
28395const _hoisted_23 = {
28396  key: 0,
28397  class: "cart-summary__shipping gs_cart-popup__summary-shipping"
28398}
28399const _hoisted_24 = { class: "cart-summary__value" }
28400const _hoisted_25 = { key: 0 }
28401const _hoisted_26 = {
28402  key: 1,
28403  class: "cart-popup__header gs_cart-popup__header"
28404}
28405const _hoisted_27 = { class: "cart-popup__title gs_cart-popup__title" }
28406
28407function CartPopupvue_type_template_id_5a27e86a_render(_ctx, _cache, $props, $setup, $data, $options) {
28408  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
28409  const _component_minimum_order_value_notice = (0,vue_esm_bundler/* resolveComponent */.g2)("minimum-order-value-notice")
28410  const _component_sp_input = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-input")
28411  const _component_sp_button = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-button")
28412
28413  return ($options.isCartPopupOpen)
28414    ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CartPopupvue_type_template_id_5a27e86a_hoisted_1, [
28415        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
28416          class: "cart-popup-overlay gs_cart-popup__blend",
28417          onClick: _cache[0] || (_cache[0] = $event => ($options.isCartPopupOpen = false))
28418        }),
28419        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
28420          tabindex: "0",
28421          class: (0,vue_esm_bundler/* normalizeClass */.C4)('cart-popup cart-popup--submenu gs_cart-popup__container ' + ((_ctx.cartItems && _ctx.cartItems.length > 0) ? '' : 'cart-popup--empty'))
28422        }, [
28423          (_ctx.cartItems && _ctx.cartItems.length > 0)
28424            ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, { key: 0 }, [
28425                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CartPopupvue_type_template_id_5a27e86a_hoisted_2, [
28426                  (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CartPopupvue_type_template_id_5a27e86a_hoisted_3, [
28427                    (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28428                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[3] || (_cache[3] = [
28429                        (0,vue_esm_bundler/* createTextVNode */.eW)("cart_popup.title", -1 /* CACHED */)
28430                      ]))]),
28431                      _: 1 /* STABLE */
28432                    })
28433                  ]),
28434                  (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CartPopupvue_type_template_id_5a27e86a_hoisted_4, [
28435                    (0,vue_esm_bundler/* createTextVNode */.eW)(" (" + (0,vue_esm_bundler/* toDisplayString */.v_)($options.cartItemsQuantity) + " ", 1 /* TEXT */),
28436                    (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28437                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[4] || (_cache[4] = [
28438                        (0,vue_esm_bundler/* createTextVNode */.eW)("cart_popup.items", -1 /* CACHED */)
28439                      ]))]),
28440                      _: 1 /* STABLE */
28441                    }),
28442                    _cache[5] || (_cache[5] = (0,vue_esm_bundler/* createTextVNode */.eW)(") ", -1 /* CACHED */))
28443                  ]),
28444                  (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <sp-button type=\"primary\" :href=\"localizeURL('/cart')\" class=\"sp-button--full-width gs_button-default__text gs_button-go-to-cart__text e2e_product-popup-go-to-kart__button\">\n\t\t\t\t\t\t<sp-lang>cart_popup.go_to_cart</sp-lang>\n\t\t\t\t\t</sp-button> ")
28445                ]),
28446                (0,vue_esm_bundler/* createVNode */.bF)(_component_minimum_order_value_notice, { class: "cart-popup__minimum-order-value gs_cart-popup__minimum-order-value" }),
28447                (0,vue_esm_bundler/* createCommentVNode */.Q3)(" {{ freeShippingInfo }} "),
28448                (_ctx.freeShippingInfo && _ctx.freeShippingInfo !== null && _ctx.freeShippingInfo.totalPriceUpToFreeShipping !== null && _ctx.freeShippingInfo.totalPriceForFreeShipping !== null)
28449                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CartPopupvue_type_template_id_5a27e86a_hoisted_5, [
28450                      (_ctx.freeShippingInfo.totalPriceUpToFreeShipping.amount > 0)
28451                        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("p", CartPopupvue_type_template_id_5a27e86a_hoisted_6, [
28452                            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, {
28453                              variables: {amount: _ctx.formatPrice(_ctx.freeShippingInfo.totalPriceUpToFreeShipping.amount/100, true)}
28454                            }, {
28455                              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[6] || (_cache[6] = [
28456                                (0,vue_esm_bundler/* createTextVNode */.eW)("checkout.free_shipping_notice", -1 /* CACHED */)
28457                              ]))]),
28458                              _: 1 /* STABLE */
28459                            }, 8 /* PROPS */, ["variables"])
28460                          ]))
28461                        : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("p", CartPopupvue_type_template_id_5a27e86a_hoisted_7, [
28462                            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28463                              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[7] || (_cache[7] = [
28464                                (0,vue_esm_bundler/* createTextVNode */.eW)("checkout.free_shipping_available", -1 /* CACHED */)
28465                              ]))]),
28466                              _: 1 /* STABLE */
28467                            })
28468                          ])),
28469                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CartPopupvue_type_template_id_5a27e86a_hoisted_8, [
28470                        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
28471                          class: "free-shipping-meter__progress-bar-fill gs_cart-popup__free-shipping-progress",
28472                          style: (0,vue_esm_bundler/* normalizeStyle */.Tr)('width: ' + $options.freeShippingProgress + '%')
28473                        }
28473, null, 4 /* STYLE */)
28474                      ])
28475                    ]))
28476                  : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
28477                (0,vue_esm_bundler/* createElementVNode */.Lk)("ul", _hoisted_9, [
28478                  ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)(_ctx.cartItems, (cartItem, cartItemKey) => {
28479                    return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, { key: cartItemKey }, [
28480                      (cartItem.productInfo)
28481                        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("li", _hoisted_10, [
28482                            (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_11, [
28483                              (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_12, [
28484                                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_13, [
28485                                  _cache[8] || (_cache[8] = (0,vue_esm_bundler/* createElementVNode */.Lk)("div", { class: "cart-popup__image-blend gs_cart-popup__image-blend" }, null, -1 /* CACHED */)),
28486                                  (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
28487                                    class: "cart-popup__image gs_cart-popup__product-image",
28488                                    style: (0,vue_esm_bundler/* normalizeStyle */.Tr)('background-image: url('+_ctx.imageSrc(cartItem.productInfo.image, 200)+')')
28489                                  }, null, 4 /* STYLE */)
28490                                ])
28491                              ]),
28492                              (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_14, [
28493                                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_15, (0,vue_esm_bundler/* toDisplayString */.v_)(cartItem.productInfo.title), 1 /* TEXT */),
28494                                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_16, (0,vue_esm_bundler/* toDisplayString */.v_)(_ctx.formatPrice(cartItem.price.amount/100, true)), 1 /* TEXT */),
28495                                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_17, [
28496                                  ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)(cartItem.productInfo.options, (option, optionGroupName) => {
28497                                    return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
28498                                      class: "cart-popup__option gs_cart-popup__product-info",
28499                                      key: optionGroupName
28500                                    }, (0,vue_esm_bundler/* toDisplayString */.v_)(optionGroupName) + ": " + (0,vue_esm_bundler/* toDisplayString */.v_)(option), 1 /* TEXT */))
28501                                  }), 128 /* KEYED_FRAGMENT */)),
28502                                  ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)(cartItem.cartItemConfigurations, (field) => {
28503                                    return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
28504                                      class: "cart-popup__option gs_cart-popup__product-info",
28505                                      key: field.productConfigurationFieldId
28506                                    }, (0,vue_esm_bundler/* toDisplayString */.v_)(field.title) + ": " + (0,vue_esm_bundler/* toDisplayString */.v_)(field.optionLabel || $options.formatFieldValue(field.value)), 1 /* TEXT */))
28507                                  }), 128 /* KEYED_FRAGMENT */))
28508                                ]),
28509                                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_18, [
28510                                  (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <sp-lang>cart_popup.quantity</sp-lang>: {{cartItem.quantity}} "),
28511                                  (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_input, {
28512                                    type: "number",
28513                                    class: "cart-actions__input cart-popup__quantity-input",
28514                                    min: 1,
28515                                    max: cartItem.product ? cartItem.product.maximalHouseholdAllowance : null,
28516                                    modelValue: cartItem.quantity,
28517                                    "onUpdate:modelValue": $event => ((cartItem.quantity) = $event),
28518                                    modelModifiers: { number: true },
28519                                    label: "cart_popup.quantity",
28520                                    onChange: _cache[1] || (_cache[1] = $event => ($options.updateCart()))
28521                                  }, null, 8 /* PROPS */, ["max", "modelValue", "onUpdate:modelValue"]),
28522                                  (0,vue_esm_bundler/* createElementVNode */.Lk)("button", {
28523                                    class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon cart-popup__remove-item '+ $options.SP_CONSTANTS.THEME.REMOVE_ICON),
28524                                    onClick: $event => ($options.removeCartItem(cartItem)),
28525                                    title: $options.getLabel('accessibility.remove_product'),
28526                                    "aria-label": $options.getLabel('accessibility.remove_product')
28527                                  }, null, 10 /* CLASS, PROPS */, _hoisted_19)
28528                                ])
28529                              ])
28530                            ])
28531                          ]))
28532                        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
28533                    ], 64 /* STABLE_FRAGMENT */))
28534                  }), 128 /* KEYED_FRAGMENT */))
28535                ]),
28536                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_20, [
28537                  (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_21, [
28538                    (0,vue_esm_bundler/* createElementVNode */.Lk)("span", null, [
28539                      (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28540                        default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[9] || (_cache[9] = [
28541                          (0,vue_esm_bundler/* createTextVNode */.eW)("checkout.subtotal", -1 /* CACHED */)
28542                        ]))]),
28543                        _: 1 /* STABLE */
28544                      }),
28545                      _cache[10] || (_cache[10] = (0,vue_esm_bundler/* createTextVNode */.eW)(":", -1 /* CACHED */))
28546                    ]),
28547                    _cache[11] || (_cache[11] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
28548                    (0,vue_esm_bundler/* createElementVNode */.Lk)("span", _hoisted_22, (0,vue_esm_bundler/* toDisplayString */.v_)(_ctx.formatPrice(_ctx.cartItemsTotalPrice.amount/100)), 1 /* TEXT */)
28549                  ]),
28550                  (_ctx.shippingPrice && _ctx.shippingPrice.taxModel)
28551                    ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", _hoisted_23, [
28552                        (0,vue_esm_bundler/* createElementVNode */.Lk)("span", null, [
28553                          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28554                            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[12] || (_cache[12] = [
28555                              (0,vue_esm_bundler/* createTextVNode */.eW)("checkout.shipping_total", -1 /* CACHED */)
28556                            ]))]),
28557                            _: 1 /* STABLE */
28558                          }),
28559                          (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($options.shippingRateName) + " " + (0,vue_esm_bundler/* toDisplayString */.v_)($options.provisionalShippingCountryName) + ":", 1 /* TEXT */)
28560                        ]),
28561                        (0,vue_esm_bundler/* createElementVNode */.Lk)("span", _hoisted_24, [
28562                          (_ctx.shippingPrice.amount > 0)
28563                            ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", _hoisted_25, (0,vue_esm_bundler/* toDisplayString */.v_)(_ctx.formatPrice(_ctx.shippingPrice.amount/100, true)), 1 /* TEXT */))
28564                            : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_sp_lang, { key: 1 }, {
28565                                default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[13] || (_cache[13] = [
28566                                  (0,vue_esm_bundler/* createTextVNode */.eW)("checkout.free_shipping", -1 /* CACHED */)
28567                                ]))]),
28568                                _: 1 /* STABLE */
28569                              }))
28570                        ])
28571                      ]))
28572                    : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
28573                  (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_button, {
28574                    type: "primary",
28575                    href: _ctx.localizeURL('/checkout'),
28576                    disabled: $options.isBelowMinimumOrderValue,
28577                    class: "sp-button--full-width gs_button__default__text gs_button__go-to-checkout__text e2e_product-popup-go-to-cart__button"
28578                  }, {
28579                    default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
28580                      (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28581                        default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[14] || (_cache[14] = [
28582                          (0,vue_esm_bundler/* createTextVNode */.eW)("cart_popup.go_to_checkout", -1 /* CACHED */)
28583                        ]))]),
28584                        _: 1 /* STABLE */
28585                      })
28586                    ]),
28587                    _: 1 /* STABLE */
28588                  }, 8 /* PROPS */, ["href", "disabled"]),
28589                  (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_button, {
28590                    type: "primary",
28591                    onClick: _cache[2] || (_cache[2] = $event => ($options.closeCart())),
28592                    class: "cart-popup__close-button sp-button--full-width gs_button__default__text gs_button__close-cart__text e2e_product-popup-go-to-cart__button"
28593                  }, {
28594                    default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
28595                      (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28596                        default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[15] || (_cache[15] = [
28597                          (0,vue_esm_bundler/* createTextVNode */.eW)("cart_popup.close_cart", -1 /* CACHED */)
28598                        ]))]),
28599                        _: 1 /* STABLE */
28600                      })
28601                    ]),
28602                    _: 1 /* STABLE */
28603                  })
28604                ])
28605              ], 64 /* STABLE_FRAGMENT */))
28606            : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", _hoisted_26, [
28607                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", _hoisted_27, [
28608                  (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, { key: "cart-empty" }, {
28609                    default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[16] || (_cache[16] = [
28610                      (0,vue_esm_bundler/* createTextVNode */.eW)("cart_popup.empty", -1 /* CACHED */)
28611                    ]))]),
28612                    _: 1 /* STABLE */
28613                  })
28614                ])
28615              ]))
28616        ], 2 /* CLASS */)
28617      ]))
28618    : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
28619}
28620;// ./vue/components/CartPopup.vue?vue&type=template&id=5a27e86a
28621
28622// EXTERNAL MODULE: ./vue/components/MinimumOrderValueNotice.vue + 4 modules
28623var MinimumOrderValueNotice = __webpack_require__(4894);
28624// EXTERNAL MODULE: ./vue/mixin/LocalizeURL.js
28625var LocalizeURL = __webpack_require__(5416);
28626;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CartPopup.vue?vue&type=script&lang=js
28627
28628
28629
28630
28631
28632
28633
28634
28635/* harmony default export */ const CartPopupvue_type_script_lang_js = ({
28636	name: 'CartPopup',
28637  	data() {
28638		return {
28639			interval: {}
28640		}
28641	},
28642	components: {
28643		'sp-button': Button/* default */.A,
28644		'minimum-order-value-notice': MinimumOrderValueNotice/* default */.A
28645	},
28646	mixins: [LocalizeURL/* default */.A, Format/* default */.A, ImageSrc/* default */.A],
28647	computed: {
28648		...(0,vuex_esm_bundler/* mapState */.aH)('checkout', [
28649			'cartItems',
28650			'cartItemsTotalPrice',
28651			'shippingPrice',
28652			'provisionalDeliveryCountryCode',
28653			'shippingRates',
28654			'shippingRateId',
28655			'freeShippingInfo'
28656		]),
28657		isCartPopupOpen: {
28658			set(isOpen) {
28659				this.$store.state.checkout.isCartPopupOpen = isOpen;
28660			},
28661			get() {
28662				return this.$store.state.checkout.isCartPopupOpen;
28663			}
28664		},
28665		isBelowMinimumOrderValue() {
28666			return this.$store.getters['checkout/isBelowMinimumOrderValue'];
28667		},
28668		cartItemsQuantity() {
28669
28670			let totalQuantity = 0;
28671			for (let i = 0; i < this.cartItems.length; i++) {
28672				totalQuantity += this.cartItems[i].quantity;
28673			}
28674
28675			return totalQuantity;
28676		},
28677		provisionalShippingCountryName() {
28678			let country = SP_CONSTANTS.SHOP.SHIPPING_COUNTRIES.find(country => country.code === this.provisionalDeliveryCountryCode);
28679			if (country) {
28680				return ' (' + country.name + ')';
28681			} else {
28682				return '';
28683			}
28684		},
28685		shippingRateName() {
28686			let shippingRate = this.shippingRates.find(shippingRate => shippingRate.id === this.shippingRateId);
28687			if (shippingRate) {
28688				return ' ' + shippingRate.name;
28689			} else {
28690				return '';
28691			}
28692		},
28693		freeShippingProgress(){
28694			let freeShippingThreshold = this.freeShippingInfo.totalPriceForFreeShipping.amount;
28695			if(freeShippingThreshold === 0) return 100;
28696
28697			let amountNeeded = this.freeShippingInfo.totalPriceUpToFreeShipping.amount;
28698			return 100 - (amountNeeded / freeShippingThreshold * 100);
28699		},
28700		SP_CONSTANTS() {
28701			return SP_CONSTANTS;
28702		}
28703	},
28704	watch: {
28705		isCartPopupOpen(isOpen) {
28706			let self = this;
28707			setTimeout(function() {
28708				self.positionPopup();
28709			},10);
28710
28711			clearInterval(this.interval);
28712			//recalculate toolbox position every second 
28713			// for potential theme movements
28714			this.interval = setInterval(function() {
28715				self.positionPopup();
28716			},1000);
28717
28718			setTimeout(() => {
28719				if (isOpen && document.querySelector('.cart-popup')) {
28720					document.querySelector('.cart-popup').focus();
28721				}
28722			}, 100);
28723		}
28724	},
28725	methods: {
28726		positionPopup() {
28727
28728			let toolboxCart = document.querySelector('.header-toolbox__cart-tool');
28729			if (toolboxCart && document.querySelector('.cart-popup--submenu') && toolboxCart.offsetWidth > 0) {
28730				document.querySelector('.cart-popup--submenu').classList.remove('cart-popup--submenu-force-mobile');
28731				let popupWidth = document.querySelector('.cart-popup--submenu').offsetWidth;
28732				let scrollOffset = window.pageYOffset || document.documentElement.scrollTop;
28733				document.querySelector('.cart-popup--submenu').style.left = (toolboxCart.offsetLeft - popupWidth + toolboxCart.offsetWidth/2 + 15) + 'px';
28734				//set the top position to the bottom of the toolbox cart or edge of screen if scrolled
28735				document.querySelector('.cart-popup--submenu').style.top = Math.max(30, (toolboxCart.offsetTop + toolboxCart.offsetHeight - scrollOffset + 20)) + 'px';
28736				document.querySelector('.cart-popup--submenu').style.right = 'auto';
28737			} else if (document.querySelector('.cart-popup--submenu')) {
28738				document.querySelector('.cart-popup--submenu').classList.add('cart-popup--submenu-force-mobile');
28739			}
28740		},
28741		updateCart() {
28742			this.$store.dispatch('checkout/update', this.cartItems);
28743		},
28744		removeCartItem(cartItem) {
28745			this.$store.dispatch('checkout/removeCartItem', cartItem);
28746		},
28747		getLabel(name) {
28748            let [labelDomain, labelName] = name.toLowerCase().split('.');
28749			if (labels[labelDomain] && labels[labelDomain][labelName] && labels[labelDomain][labelName][SP_CONSTANTS.LOCALE]) {
28750				let labelValue = labels[labelDomain][labelName][SP_CONSTANTS.LOCALE];
28751				if (labelValue.indexOf('{{') >= 0 && this.variables) {
28752					for (let variable in this.variables) {
28753						labelValue = labelValue.replace('{{'+variable+'}}', this.variables[variable]);
28754					}
28755				}
28756				return labelValue;
28757			} else if (labels[labelDomain] && labels[labelDomain][labelName] === undefined) {
28758				return labels[labelDomain]['error_occurred'][SP_CONSTANTS.LOCALE];
28759			} else {
28760				return this.labelString || this.name;
28761			}
28762		},
28763		isChildOf(c,p){while((c=c.parentNode)&&c!==p);return !!c},
28764		formatFieldValue(value) {
28765
28766			if (value && typeof value == 'string' && value.indexOf('https://storage.googleapis.com/') >= 0) {
28767				return this.getLabel('checkout.file');
28768			}
28769
28770			if (value && Array.isArray(value)) {
28771				let first = value[0];
28772				if (first && typeof first == 'string' && first.indexOf('https://storage.googleapis.com/') >= 0) {
28773					return this.getLabel('checkout.files');
28774				}
28775			}
28776
28777			return value;
28778		},
28779		closeCart() {
28780			this.isCartPopupOpen = false;
28781		}
28782	},
28783	mounted() {
28784		let self = this;
28785		document.addEventListener('CartPopupOpen', function() {
28786			self.$store.state.checkout.isCartPopupOpen = true;
28787		});
28788
28789		document.addEventListener('focusin', function (event) {
28790			let target = event.target;
28791			if (document.querySelector('.cart-popup') && !document.querySelector('.cart-popup').contains(target)) {
28792				document.querySelector('#navigation a').focus();
28793				self.$store.state.checkout.isCartPopupOpen = false;
28794			}
28795		});
28796
28797	}
28798});
28799
28800;// ./vue/components/CartPopup.vue?vue&type=script&lang=js
28801 
28802;// ./vue/components/CartPopup.vue
28803
28804
28805
28806
28807;
28808const CartPopup_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(CartPopupvue_type_script_lang_js, [['render',CartPopupvue_type_template_id_5a27e86a_render]])
28809
28810/* harmony default export */ const CartPopup = (CartPopup_exports_);
28811;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/WishlistPopup.vue?vue&type=template&id=2ce0287b
28812
28813
28814const WishlistPopupvue_type_template_id_2ce0287b_hoisted_1 = {
28815  key: 0,
28816  class: "wishlist-popup-wrapper"
28817}
28818const WishlistPopupvue_type_template_id_2ce0287b_hoisted_2 = {
28819  tabindex: "0",
28820  class: "wishlist-popup gs_wishlist-popup__container e2e_wishlist-popup"
28821}
28822const WishlistPopupvue_type_template_id_2ce0287b_hoisted_3 = ["title", "aria-label"]
28823const WishlistPopupvue_type_template_id_2ce0287b_hoisted_4 = { key: 0 }
28824const WishlistPopupvue_type_template_id_2ce0287b_hoisted_5 = { class: "wishlist-popup__headline" }
28825const WishlistPopupvue_type_template_id_2ce0287b_hoisted_6 = { class: "gs_wishlist-popup__title" }
28826const WishlistPopupvue_type_template_id_2ce0287b_hoisted_7 = { class: "wishlist-popup__buttons gs_wishlist-popup__buttons-container" }
28827const WishlistPopupvue_type_template_id_2ce0287b_hoisted_8 = { key: 1 }
28828const WishlistPopupvue_type_template_id_2ce0287b_hoisted_9 = { class: "wishlist-popup__headline" }
28829const WishlistPopupvue_type_template_id_2ce0287b_hoisted_10 = { class: "gs_wishlist-popup__title" }
28830
28831function WishlistPopupvue_type_template_id_2ce0287b_render(_ctx, _cache, $props, $setup, $data, $options) {
28832  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
28833  const _component_sp_button = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-button")
28834  const _component_login = (0,vue_esm_bundler/* resolveComponent */.g2)("login")
28835
28836  return ($options.isWishlistPopupOpen)
28837    ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", WishlistPopupvue_type_template_id_2ce0287b_hoisted_1, [
28838        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
28839          class: "wishlist-popup-overlay gs_wishlist-popup__blend",
28840          onClick: _cache[0] || (_cache[0] = $event => ($options.isWishlistPopupOpen = false))
28841        }),
28842        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", WishlistPopupvue_type_template_id_2ce0287b_hoisted_2, [
28843          (0,vue_esm_bundler/* createElementVNode */.Lk)("button", {
28844            class: "gs_wishlist-popup__close wishlist-popup__close",
28845            title: $options.getLabel('accessibility.close_wishlist_popup'),
28846            "aria-label": $options.getLabel('accessibility.close_wishlist_popup'),
28847            onClick: _cache[1] || (_cache[1] = $event => ($options.isWishlistPopupOpen = false))
28848          }, [
28849            (0,vue_esm_bundler/* createElementVNode */.Lk)("span", {
28850              class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon '+ $options.SP_CONSTANTS.THEME.CLOSE_ICON)
28851            }, null, 2 /* CLASS */)
28852          ], 8 /* PROPS */, WishlistPopupvue_type_template_id_2ce0287b_hoisted_3),
28853          ($options.userId())
28854            ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", WishlistPopupvue_type_template_id_2ce0287b_hoisted_4, [
28855                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", WishlistPopupvue_type_template_id_2ce0287b_hoisted_5, [
28856                  (0,vue_esm_bundler/* createElementVNode */.Lk)("h2", WishlistPopupvue_type_template_id_2ce0287b_hoisted_6, [
28857                    (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28858                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[2] || (_cache[2] = [
28859                        (0,vue_esm_bundler/* createTextVNode */.eW)("wishlist_popup.product_added_message", -1 /* CACHED */)
28860                      ]))]),
28861                      _: 1 /* STABLE */
28862                    })
28863                  ])
28864                ]),
28865                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", WishlistPopupvue_type_template_id_2ce0287b_hoisted_7, [
28866                  (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_button, {
28867                    type: "primary",
28868                    href: _ctx.localizeURL('/wishlist'),
28869                    class: "gs_button__default__text gs_button__go-to-wishlist__text e2e_wishlist-popup__go-to-wishlist"
28870                  }, {
28871                    default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
28872                      (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28873                        default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[3] || (_cache[3] = [
28874                          (0,vue_esm_bundler/* createTextVNode */.eW)("wishlist_popup.go_to_wishlist", -1 /* CACHED */)
28875                        ]))]),
28876                        _: 1 /* STABLE */
28877                      })
28878                    ]),
28879                    _: 1 /* STABLE */
28880                  }, 8 /* PROPS */, ["href"])
28881                ])
28882              ]))
28883            : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", WishlistPopupvue_type_template_id_2ce0287b_hoisted_8, [
28884                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", WishlistPopupvue_type_template_id_2ce0287b_hoisted_9, [
28885                  (0,vue_esm_bundler/* createElementVNode */.Lk)("h2", WishlistPopupvue_type_template_id_2ce0287b_hoisted_10, [
28886                    (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
28887                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[4] || (_cache[4] = [
28888                        (0,vue_esm_bundler/* createTextVNode */.eW)("wishlist_popup.log_in_to_add", -1 /* CACHED */)
28889                      ]))]),
28890                      _: 1 /* STABLE */
28891                    })
28892                  ])
28893                ]),
28894                (0,vue_esm_bundler/* createVNode */.bF)(_component_login)
28895              ]))
28896        ])
28897      ]))
28898    : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
28899}
28900;// ./vue/components/WishlistPopup.vue?vue&type=template&id=2ce0287b
28901
28902// EXTERNAL MODULE: ./vue/pages/profile/ProfileLogin.vue + 4 modules
28903var ProfileLogin = __webpack_require__(5449);
28904;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/WishlistPopup.vue?vue&type=script&lang=js
28905
28906
28907
28908
28909
28910
28911
28912/* harmony default export */ const WishlistPopupvue_type_script_lang_js = ({
28913	name: 'WishlistPopup',
28914  	data() {
28915		return {
28916			
28917		}
28918	},
28919	mixins: [LocalizeURL/* default */.A],
28920	components: {
28921		'sp-button': Button/* default */.A,
28922		'login': ProfileLogin/* default */.A
28923	},
28924	computed: {
28925		...(0,vuex_esm_bundler/* mapState */.aH)('checkout', [
28926			'cartItems',
28927			'cartItemsTotalPrice'
28928		]),
28929		isWishlistPopupOpen: {
28930			set(isOpen) {
28931				this.$store.state.app.isWishlistPopupOpen = isOpen;
28932			},
28933			get() {
28934				return this.$store.state.app.isWishlistPopupOpen;
28935			}
28936		},
28937		SP_CONSTANTS() {
28938			return SP_CONSTANTS;
28939		}
28940	},
28941	watch: {
28942		isCartPopupOpen() {
28943			setTimeout(() => {
28944
28945				// let $toolboxCart = $('.header-toolbox__cart-tool');
28946				// if ($toolboxCart) {
28947					// let popupWidth = $('.wishlist-popup--submenu').width();
28948					// $('.wishlist-popup--submenu').css({
28949					// 	left: ($toolboxCart.offset().left - popupWidth + $toolboxCart.width()/2 + 15),
28950					// 	top: ($toolboxCart.offset().top + $toolboxCart.height() + 20),
28951					// 	right: 'auto'
28952					// });
28953				// }
28954
28955			},10)
28956		}
28957	},
28958	methods: {
28959		userId() {
28960			return (0,SecureCookie/* SecureCookie */.o)('sp_access_token');
28961		},
28962		getLabel(name) {
28963            let [labelDomain, labelName] = name.toLowerCase().split('.');
28964			if (labels[labelDomain] && labels[labelDomain][labelName] && labels[labelDomain][labelName][SP_CONSTANTS.LOCALE]) {
28965				let labelValue = labels[labelDomain][labelName][SP_CONSTANTS.LOCALE];
28966				if (labelValue.indexOf('{{') >= 0 && this.variables) {
28967					for (let variable in this.variables) {
28968						labelValue = labelValue.replace('{{'+variable+'}}', this.variables[variable]);
28969					}
28970				}
28971				return labelValue;
28972			} else if (labels[labelDomain] && labels[labelDomain][labelName] === undefined) {
28973				return labels[labelDomain]['error_occurred'][SP_CONSTANTS.LOCALE];
28974			} else {
28975				return this.labelString || this.name;
28976			}
28977		},
28978	}
28979});
28980
28981;// ./vue/components/WishlistPopup.vue?vue&type=script&lang=js
28982 
28983;// ./vue/components/WishlistPopup.vue
28984
28985
28986
28987
28988;
28989const WishlistPopup_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(WishlistPopupvue_type_script_lang_js, [['render',WishlistPopupvue_type_template_id_2ce0287b_render]])
28990
28991/* harmony default export */ const WishlistPopup = (WishlistPopup_exports_);
28992;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieConsent.vue?vue&type=template&id=26d6dc2e&scoped=true
28993
28994
28995const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_1 = {
28996  key: 0,
28997  class: "c-o-i-wrapper gs_cookie-consent__blend"
28998}
28999const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_2 = {
29000  class: "c-o-i gs_cookie-consent__container",
29001  role: "dialog",
29002  "aria-modal": "true",
29003  "aria-labelledby": "cookie-consent-headline"
29004}
29005const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_3 = {
29006  id: "cookie-consent-headline",
29007  class: "c-o-i__headline gs_cookie-consent__title"
29008}
29009const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_4 = { class: "c-o-i__text gs_cookie-consent__text" }
29010const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_5 = {
29011  key: 0,
29012  class: "c-o-i__view-advanced"
29013}
29014const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_6 = { class: "c-o-i__detail-wrapper gs_cookie-consent__detail-box" }
29015const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_7 = { class: "c-o-i__detail-group-header gs_cookie-consent__detail-box-header" }
29016const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_8 = { class: "c-o-i__detail gs_cookie-consent__detail-box-body" }
29017const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_9 = {
29018  key: 0,
29019  class: "c-o-i__detail-wrapper gs_cookie-consent__detail-box"
29020}
29021const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_10 = { class: "c-o-i__detail-group-header gs_cookie-consent__detail-box-header" }
29022const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_11 = { for: "marketing" }
29023const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_12 = { class: "c-o-i__detail gs_cookie-consent__detail-box-body" }
29024const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_13 = {
29025  key: 1,
29026  class: "c-o-i__detail-wrapper gs_cookie-consent__detail-box"
29027}
29028const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_14 = { class: "c-o-i__detail-group-header gs_cookie-consent__detail-box-header" }
29029const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_15 = { for: "media" }
29030const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_16 = { class: "c-o-i__detail gs_cookie-consent__detail-box-body" }
29031const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_17 = {
29032  key: 2,
29033  class: "c-o-i__detail-wrapper gs_cookie-consent__detail-box"
29034}
29035const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_18 = { class: "c-o-i__detail-group-header gs_cookie-consent__detail-box-header" }
29036const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_19 = { for: "statistics" }
29037const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_20 = { class: "c-o-i__detail gs_cookie-consent__detail-box-body" }
29038const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_21 = ["value"]
29039const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_22 = ["value"]
29040const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_23 = ["value"]
29041const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_24 = {
29042  key: 3,
29043  class: "c-o-i__legal-links gs_cookie-consent__legal-links"
29044}
29045const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_25 = ["href"]
29046const CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_26 = ["href"]
29047
29048function CookieConsentvue_type_template_id_26d6dc2e_scoped_true_render(_ctx, _cache, $props, $setup, $data, $options) {
29049  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
29050  const _component_cookie_detail = (0,vue_esm_bundler/* resolveComponent */.g2)("cookie-detail")
29051
29052  return (!_ctx.hidden)
29053    ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_1, [
29054        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_2, [
29055          _cache[35] || (_cache[35] = (0,vue_esm_bundler/* createElementVNode */.Lk)("span", {
29056            class: "c-o-i__focus-anchor",
29057            tabindex: "-1",
29058            "aria-hidden": "true"
29059          }, null, -1 /* CACHED */)),
29060          (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_3, [
29061            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29062              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[20] || (_cache[20] = [
29063                (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.headline", -1 /* CACHED */)
29064              ]))]),
29065              _: 1 /* STABLE */
29066            })
29067          ]),
29068          (0,vue_esm_bundler/* createElementVNode */.Lk)("p", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_4, [
29069            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29070              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[21] || (_cache[21] = [
29071                (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.text", -1 /* CACHED */)
29072              ]))]),
29073              _: 1 /* STABLE */
29074            })
29075          ]),
29076          (_ctx.view == 'advanced')
29077            ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_5, [
29078                (0,vue_esm_bundler/* createElementVNode */.Lk)("a", {
29079                  href: "javascript:;",
29080                  onClick: _cache[0] || (_cache[0] = $event => ($options.changeView())),
29081                  class: "c-o-i__settings c-o-i__settings-back text-link"
29082                }, [
29083                  (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29084                    default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[22] || (_cache[22] = [
29085                      (0,vue_esm_bundler/* createTextVNode */.eW)("general.back", -1 /* CACHED */)
29086                    ]))]),
29087                    _: 1 /* STABLE */
29088                  })
29089                ]),
29090                (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_6, [
29091                  (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_7, [
29092                    (0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
29093                      type: "checkbox",
29094                      onClick: _cache[1] || (_cache[1] = $event => ($options.updateCookieGroups($event))),
29095                      value: "essential",
29096                      checked: "",
29097                      disabled: ""
29098                    }),
29099                    _cache[24] || (_cache[24] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
29100                    (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29101                      default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[23] || (_cache[23] = [
29102                        (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.essential", -1 /* CACHED */)
29103                      ]))]),
29104                      _: 1 /* STABLE */
29105                    })
29106                  ]),
29107                  (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_8, [
29108                    (0,vue_esm_bundler/* createElementVNode */.Lk)("p", null, [
29109                      (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29110                        default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[25] || (_cache[25] = [
29111                          (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.essential_text", -1 /* CACHED */)
29112                        ]))]),
29113                        _: 1 /* STABLE */
29114                      })
29115                    ])
29116                  ])
29117                ]),
29118                (_ctx.groupsStructure.marketing.length > 0)
29119                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_9, [
29120                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_10, [
29121                        (0,vue_esm_bundler/* withDirectives */.bo)((0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
29122                          type: "checkbox",
29123                          "onUpdate:modelValue": _cache[2] || (_cache[2] = $event => ((_ctx.cookieGroups) = $event)),
29124                          onClick: _cache[3] || (_cache[3] = $event => ($options.updateCookieGroups($event))),
29125                          value: "marketing",
29126                          id: "marketing"
29127                        }, null, 512 /* NEED_PATCH */), [
29128                          [vue_esm_bundler/* vModelCheckbox */.lH, _ctx.cookieGroups]
29129                        ]),
29130                        _cache[27] || (_cache[27] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
29131                        (0,vue_esm_bundler/* createElementVNode */.Lk)("label", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_11, [
29132                          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29133                            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[26] || (_cache[26] = [
29134                              (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.marketing", -1 /* CACHED */)
29135                            ]))]),
29136                            _: 1 /* STABLE */
29137                          })
29138                        ])
29139                      ]),
29140                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_12, [
29141                        (_ctx.groupsStructure.marketing.includes('fb_pixel'))
29142                          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29143                              key: 0,
29144                              title: "Facebook Pixel",
29145                              trackerName: "fb_pixel",
29146                              provider: "Meta Inc.",
29147                              purpose: "cookie.fb_pixel_purpose",
29148                              privacyPolicyLink: "https://www.facebook.com/policy.php",
29149                              cookieNames: ['_fbp'],
29150                              modelValue: _ctx.cookieSettings,
29151                              "onUpdate:modelValue": _cache[4] || (_cache[4] = $event => ((_ctx.cookieSettings) = $event))
29152                            }, null, 8 /* PROPS */, ["modelValue"]))
29153                          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29154                        (_ctx.groupsStructure.marketing.includes('google_adwords'))
29155                          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29156                              key: 1,
29157                              title: "Google Adwords",
29158                              trackerName: "google_adwords",
29159                              provider: "Google Ireland Limited",
29160                              purpose: "cookie.adwords_purpose",
29161                              privacyPolicyLink: "https://policies.google.com/privacy",
29162                              cookieNames: ['_gcl_au','_gcl_aw'],
29163                              modelValue: _ctx.cookieSettings,
29164                              "onUpdate:modelValue": _cache[5] || (_cache[5] = $event => ((_ctx.cookieSettings) = $event))
29165                            }, null, 8 /* PROPS */, ["modelValue"]))
29166                          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29167                        (_ctx.groupsStructure.marketing.includes('pinterest'))
29168                          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29169                              key: 2,
29170                              title: "Pinterest",
29171                              trackerName: "pinterest",
29172                              provider: "Pinterest Europe Ltd.",
29173                              purpose: "cookie.pinterest_purpose",
29174                              privacyPolicyLink: "https://policy.pinterest.com/privacy-policy",
29175                              cookieNames: ['_pin_unauth'],
29176                              modelValue: _ctx.cookieSettings,
29177                              "onUpdate:modelValue": _cache[6] || (_cache[6] = $event => ((_ctx.cookieSettings) = $event))
29178                            }, null, 8 /* PROPS */, ["modelValue"]))
29179                          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29180                        (_ctx.groupsStructure.marketing.includes('billiger_de'))
29181                          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29182                              key: 3,
29183                              title: "billiger.de",
29184                              trackerName: "billiger_de",
29185                              provider: "solute GmbH",
29186                              purpose: "cookie.billiger_de_purpose",
29187                              privacyPolicyLink: "https://www.solute.de/ger/datenschutz/",
29188                              cookieNames: ['soluteclid'],
29189                              modelValue: _ctx.cookieSettings,
29190                              "onUpdate:modelValue": _cache[7] || (_cache[7] = $event => ((_ctx.cookieSettings) = $event))
29191                            }, null, 8 /* PROPS */, ["modelValue"]))
29192                          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29193                        ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($options.customCookiePlatformsByGroup['marketing'], (customCookiePlatform) => {
29194                          return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, [
29195                            (_ctx.groupsStructure.marketing.includes(cu
29195stomCookiePlatform.id))
29196                              ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29197                                  key: 0,
29198                                  title: customCookiePlatform.name,
29199                                  trackerName: customCookiePlatform.id,
29200                                  provider: customCookiePlatform.dataController,
29201                                  purpose: customCookiePlatform.description,
29202                                  privacyPolicyLink: customCookiePlatform.privacyPolicyUrl,
29203                                  cookieNames: customCookiePlatform.cookies,
29204                                  modelValue: _ctx.cookieSettings,
29205                                  "onUpdate:modelValue": _cache[8] || (_cache[8] = $event => ((_ctx.cookieSettings) = $event))
29206                                }, null, 8 /* PROPS */, ["title", "trackerName", "provider", "purpose", "privacyPolicyLink", "cookieNames", "modelValue"]))
29207                              : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
29208                          ], 64 /* STABLE_FRAGMENT */))
29209                        }), 256 /* UNKEYED_FRAGMENT */))
29210                      ])
29211                    ]))
29212                  : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29213                (_ctx.groupsStructure.media.length > 0)
29214                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_13, [
29215                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_14, [
29216                        (0,vue_esm_bundler/* withDirectives */.bo)((0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
29217                          type: "checkbox",
29218                          "onUpdate:modelValue": _cache[9] || (_cache[9] = $event => ((_ctx.cookieGroups) = $event)),
29219                          onClick: _cache[10] || (_cache[10] = $event => ($options.updateCookieGroups($event))),
29220                          value: "media",
29221                          id: "media"
29222                        }, null, 512 /* NEED_PATCH */), [
29223                          [vue_esm_bundler/* vModelCheckbox */.lH, _ctx.cookieGroups]
29224                        ]),
29225                        _cache[29] || (_cache[29] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
29226                        (0,vue_esm_bundler/* createElementVNode */.Lk)("label", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_15, [
29227                          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29228                            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[28] || (_cache[28] = [
29229                              (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.media", -1 /* CACHED */)
29230                            ]))]),
29231                            _: 1 /* STABLE */
29232                          })
29233                        ])
29234                      ]),
29235                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_16, [
29236                        ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($options.customCookiePlatformsByGroup['media'], (customCookiePlatform) => {
29237                          return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, [
29238                            (_ctx.groupsStructure.media.includes(customCookiePlatform.id))
29239                              ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29240                                  key: 0,
29241                                  title: customCookiePlatform.name,
29242                                  trackerName: customCookiePlatform.id,
29243                                  provider: customCookiePlatform.dataController,
29244                                  purpose: customCookiePlatform.description,
29245                                  privacyPolicyLink: customCookiePlatform.privacyPolicyUrl,
29246                                  cookieNames: customCookiePlatform.cookies,
29247                                  modelValue: _ctx.cookieSettings,
29248                                  "onUpdate:modelValue": _cache[11] || (_cache[11] = $event => ((_ctx.cookieSettings) = $event))
29249                                }, null, 8 /* PROPS */, ["title", "trackerName", "provider", "purpose", "privacyPolicyLink", "cookieNames", "modelValue"]))
29250                              : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
29251                          ], 64 /* STABLE_FRAGMENT */))
29252                        }), 256 /* UNKEYED_FRAGMENT */))
29253                      ])
29254                    ]))
29255                  : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29256                (_ctx.groupsStructure.statistics.length > 0)
29257                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_17, [
29258                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_18, [
29259                        (0,vue_esm_bundler/* withDirectives */.bo)((0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
29260                          type: "checkbox",
29261                          "onUpdate:modelValue": _cache[12] || (_cache[12] = $event => ((_ctx.cookieGroups) = $event)),
29262                          onClick: _cache[13] || (_cache[13] = $event => ($options.updateCookieGroups($event))),
29263                          value: "statistics",
29264                          id: "statistics"
29265                        }, null, 512 /* NEED_PATCH */), [
29266                          [vue_esm_bundler/* vModelCheckbox */.lH, _ctx.cookieGroups]
29267                        ]),
29268                        _cache[31] || (_cache[31] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
29269                        (0,vue_esm_bundler/* createElementVNode */.Lk)("label", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_19, [
29270                          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29271                            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[30] || (_cache[30] = [
29272                              (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.statistics", -1 /* CACHED */)
29273                            ]))]),
29274                            _: 1 /* STABLE */
29275                          })
29276                        ])
29277                      ]),
29278                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_20, [
29279                        (_ctx.groupsStructure.statistics.includes('google_analytics'))
29280                          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29281                              key: 0,
29282                              title: "Google Analytics",
29283                              trackerName: "google_analytics",
29284                              provider: "Google Ireland Limited",
29285                              purpose: "cookie.analytics_purpose",
29286                              privacyPolicyLink: "https://policies.google.com/privacy",
29287                              cookieNames: ['_ga', '_gat', '_gid'],
29288                              modelValue: _ctx.cookieSettings,
29289                              "onUpdate:modelValue": _cache[14] || (_cache[14] = $event => ((_ctx.cookieSettings) = $event))
29290                            }, null, 8 /* PROPS */, ["modelValue"]))
29291                          : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29292                        ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($options.customCookiePlatformsByGroup['statistics'], (customCookiePlatform) => {
29293                          return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, [
29294                            (_ctx.groupsStructure.statistics.includes(cu
29294stomCookiePlatform.id))
29295                              ? ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, { key: 0 }, (0,vue_esm_bundler/* renderList */.pI)($options.customCookiePlatformsByGroup['statistics'], (customCookiePlatform) => {
29296                                  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createBlock */.Wv)(_component_cookie_detail, {
29297                                    title: customCookiePlatform.name,
29298                                    trackerName: customCookiePlatform.id,
29299                                    provider: customCookiePlatform.dataController,
29300                                    purpose: customCookiePlatform.description,
29301                                    privacyPolicyLink: customCookiePlatform.privacyPolicyUrl,
29302                                    cookieNames: customCookiePlatform.cookies,
29303                                    modelValue: _ctx.cookieSettings,
29304                                    "onUpdate:modelValue": _cache[15] || (_cache[15] = $event => ((_ctx.cookieSettings) = $event))
29305                                  }, null, 8 /* PROPS */, ["title", "trackerName", "provider", "purpose", "privacyPolicyLink", "cookieNames", "modelValue"]))
29306                                }), 256 /* UNKEYED_FRAGMENT */))
29307                              : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
29308                          ], 64 /* STABLE_FRAGMENT */))
29309                        }), 256 /* UNKEYED_FRAGMENT */))
29310                      ])
29311                    ]))
29312                  : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29313                (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <div class=\"c-o-i__detail-group-header\">\n\t\t\t\t\t<input type=\"checkbox\" v-model=\"cookieGroups\" @click=\"updateCookieGroups($event)\" value=\"media\"> <sp-lang>cookie.media</sp-lang>\n\t\t\t\t</div>\n\t\t\t\t<div class=\"c-o-i__detail\">\n\t\t\t\t\t\n\t\t\t\t</div>\n\t\t\t\t<div class=\"c-o-i__detail-group-header\">\n\t\t\t\t\t<input type=\"checkbox\" v-model=\"cookieGroups\" @click=\"updateCookieGroups($event)\" value=\"statistics\"> <sp-lang>cookie.statistics</sp-lang>\n\t\t\t\t</div>\n\t\t\t\t<div class=\"c-o-i__detail\">\n\t\t\t\t\t\n\t\t\t\t</div> ")
29314              ]))
29315            : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29316          (0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
29317            type: "submit",
29318            name: "acceptAll",
29319            value: $options.getLabel('cookie.accept_all'),
29320            class: "c-o-i__accept-all gs_button__default__text gs_button__cookie-accept-all__text",
29321            onClick: _cache[16] || (_cache[16] = $event => ($options.saveAll()))
29322          }, null, 8 /* PROPS */, CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_21),
29323          (0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
29324            type: "submit",
29325            name: "rejectAll",
29326            value: $options.getLabel('cookie.reject_all'),
29327            class: "c-o-i__reject-all gs_button__default__text gs_button__cookie-reject-all__text",
29328            onClick: _cache[17] || (_cache[17] = $event => ($options.rejectAll()))
29329          }, null, 8 /* PROPS */, CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_22),
29330          (_ctx.view == 'advanced')
29331            ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("input", {
29332                key: 1,
29333                type: "submit",
29334                name: "save",
29335                value: $options.getLabel('cookie.save'),
29336                class: "c-o-i__save gs_button__default__text gs_button__cookie-save__text",
29337                onClick: _cache[18] || (_cache[18] = $event => ($options.save()))
29338              }, null, 8 /* PROPS */, CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_23))
29339            : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29340          (_ctx.view == 'simple')
29341            ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("a", {
29342                key: 2,
29343                href: "javascript:;",
29344                onClick: _cache[19] || (_cache[19] = $event => ($options.changeView())),
29345                class: "c-o-i__settings gs_cookie-consent__settings-link text-link"
29346              }, [
29347                (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29348                  default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[32] || (_cache[32] = [
29349                    (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.individual_settings", -1 /* CACHED */)
29350                  ]))]),
29351                  _: 1 /* STABLE */
29352                })
29353              ]))
29354            : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29355          ($options.imprintUrl || $options.privacyUrl)
29356            ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_24, [
29357                ($options.imprintUrl)
29358                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("a", {
29359                      key: 0,
29360                      href: $options.imprintUrl,
29361                      class: "gs_cookie-consent__legal-link text-link"
29362                    }, [
29363                      (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29364                        default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[33] || (_cache[33] = [
29365                          (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.imprint", -1 /* CACHED */)
29366                        ]))]),
29367                        _: 1 /* STABLE */
29368                      })
29369                    ], 8 /* PROPS */, CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_25))
29370                  : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
29371                ($options.privacyUrl)
29372                  ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("a", {
29373                      key: 1,
29374                      href: $options.privacyUrl,
29375                      class: "gs_cookie-consent__legal-link text-link"
29376                    }, [
29377                      (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29378                        default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[34] || (_cache[34] = [
29379                          (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.privacy_policy", -1 /* CACHED */)
29380                        ]))]),
29381                        _: 1 /* STABLE */
29382                      })
29383                    ], 8 /* PROPS */, CookieConsentvue_type_template_id_26d6dc2e_scoped_true_hoisted_26))
29384                  : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
29385              ]))
29386            : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
29387        ])
29388      ]))
29389    : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
29390}
29391;// ./vue/components/CookieConsent.vue?vue&type=template&id=26d6dc2e&scoped=true
29392
29393;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieDetail.vue?vue&type=template&id=dc305a40&scoped=true
29394
29395
29396const CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_1 = { class: "c-o-i__setting gs_cookie-consent__tooltip" }
29397const CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_2 = ["value", "id"]
29398const CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_3 = ["for"]
29399const CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_4 = {
29400  key: 0,
29401  class: "c-o-i__tooltip-popup"
29402}
29403const CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_5 = ["href"]
29404
29405function CookieDetailvue_type_template_id_dc305a40_scoped_true_render(_ctx, _cache, $props, $setup, $data, $options) {
29406  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
29407
29408  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_1, [
29409    (0,vue_esm_bundler/* withDirectives */.bo)((0,vue_esm_bundler/* createElementVNode */.Lk)("input", {
29410      type: "checkbox",
29411      "onUpdate:modelValue": _cache[0] || (_cache[0] = $event => (($options.cookieSettings) = $event)),
29412      value: $props.trackerName,
29413      id: $props.trackerName
29414    }, null, 8 /* PROPS */, CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_2), [
29415      [vue_esm_bundler/* vModelCheckbox */.lH, $options.cookieSettings]
29416    ]),
29417    _cache[15] || (_cache[15] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
29418    (0,vue_esm_bundler/* createElementVNode */.Lk)("label", { for: $props.trackerName }, (0,vue_esm_bundler/* toDisplayString */.v_)($props.title), 9 /* TEXT, PROPS */, CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_3),
29419    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
29420      class: "c-o-i__tooltip-button",
29421      onClick: _cache[1] || (_cache[1] = $event => ($options.toggleTooltip()))
29422    }, "i"),
29423    (_ctx.tooltipOpen)
29424      ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_4, [
29425          (0,vue_esm_bundler/* createElementVNode */.Lk)("strong", null, [
29426            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29427              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[2] || (_cache[2] = [
29428                (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.provider", -1 /* CACHED */)
29429              ]))]),
29430              _: 1 /* STABLE */
29431            }),
29432            _cache[3] || (_cache[3] = (0,vue_esm_bundler/* createTextVNode */.eW)(":", -1 /* CACHED */))
29433          ]),
29434          (0,vue_esm_bundler/* createTextVNode */.eW)(" " + (0,vue_esm_bundler/* toDisplayString */.v_)($props.provider) + " ", 1 /* TEXT */),
29435          _cache[10] || (_cache[10] = (0,vue_esm_bundler/* createElementVNode */.Lk)("br", null, null, -1 /* CACHED */)),
29436          (0,vue_esm_bundler/* createElementVNode */.Lk)("strong", null, [
29437            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29438              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[4] || (_cache[4] = [
29439                (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.purpose", -1 /* CACHED */)
29440              ]))]),
29441              _: 1 /* STABLE */
29442            }),
29443            _cache[5] || (_cache[5] = (0,vue_esm_bundler/* createTextVNode */.eW)(":", -1 /* CACHED */))
29444          ]),
29445          _cache[11] || (_cache[11] = (0,vue_esm_bundler/* createTextVNode */.eW)()),
29446          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29447            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
29448              (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($props.purpose), 1 /* TEXT */)
29449            ]),
29450            _: 1 /* STABLE */
29451          }),
29452          _cache[12] || (_cache[12] = (0,vue_esm_bundler/* createElementVNode */.Lk)("br", null, null, -1 /* CACHED */)),
29453          (0,vue_esm_bundler/* createElementVNode */.Lk)("strong", null, [
29454            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29455              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[6] || (_cache[6] = [
29456                (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.privacy_policy", -1 /* CACHED */)
29457              ]))]),
29458              _: 1 /* STABLE */
29459            }),
29460            _cache[7] || (_cache[7] = (0,vue_esm_bundler/* createTextVNode */.eW)(":", -1 /* CACHED */))
29461          ]),
29462          (0,vue_esm_bundler/* createElementVNode */.Lk)("a", {
29463            href: $props.privacyPolicyLink,
29464            target: "_blank",
29465            rel: "nofollow",
29466            class: "text-link"
29467          }, (0,vue_esm_bundler/* toDisplayString */.v_)($props.privacyPolicyLink), 9 /* TEXT, PROPS */, CookieDetailvue_type_template_id_dc305a40_scoped_true_hoisted_5),
29468          _cache[13] || (_cache[13] = (0,vue_esm_bundler/* createElementVNode */.Lk)("br", null, null, -1 /* CACHED */)),
29469          (0,vue_esm_bundler/* createElementVNode */.Lk)("strong", null, [
29470            (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
29471              default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[8] || (_cache[8] = [
29472                (0,vue_esm_bundler/* createTextVNode */.eW)("cookie.cookie_name", -1 /* CACHED */)
29473              ]))]),
29474              _: 1 /* STABLE */
29475            }),
29476            _cache[9] || (_cache[9] = (0,vue_esm_bundler/* createTextVNode */.eW)(":", -1 /* CACHED */))
29477          ]),
29478          (0,vue_esm_bundler/* createTextVNode */.eW)(" " + (0,vue_esm_bundler/* toDisplayString */.v_)($options.cookieNamesString) + " ", 1 /* TEXT */),
29479          _cache[14] || (_cache[14] = (0,vue_esm_bundler/* createElementVNode */.Lk)("br", null, null, -1 /* CACHED */))
29480        ]))
29481      : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
29482  ]))
29483}
29484;// ./vue/components/CookieDetail.vue?vue&type=template&id=dc305a40&scoped=true
29485
29486;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieDetail.vue?vue&type=script&lang=js
29487
29488
29489
29490
29491
29492/* harmony default export */ const CookieDetailvue_type_script_lang_js = ({
29493	name: "cookieDetail",
29494	props: {
29495        provider: String,
29496        purpose: String,
29497        privacyPolicyLink: String,
29498        title: String,
29499        trackerName: String,
29500        cookieNames: Array,
29501        value: Array,
29502        modelValue: Array
29503	},
29504	data: () => ({
29505        tooltipOpen: false,
29506	}),
29507    emits: ['update:modelValue'],
29508	computed: {
29509        cookieNamesString() {
29510            return this.cookieNames.join(', ');
29511        },
29512        cookieSettings: {
29513            get() {
29514                return this.modelValue;
29515            },
29516            set(v) {
29517                this.$emit('update:modelValue', v);
29518            }
29519        }
29520    },
29521	watch: {
29522
29523	},
29524	methods: {
29525		toggleTooltip() {
29526            this.tooltipOpen = !this.tooltipOpen;
29527        }
29528	},
29529	beforeMount() {
29530		
29531	}
29532});
29533
29534;// ./vue/components/CookieDetail.vue?vue&type=script&lang=js
29535 
29536// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieDetail.vue?vue&type=style&index=0&id=dc305a40&scoped=true&lang=css
29537var CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css = __webpack_require__(1174);
29538;// ./node_modules/style-loader/dist/cjs.js!./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieDetail.vue?vue&type=style&index=0&id=dc305a40&scoped=true&lang=css
29539
29540      
29541      
29542      
29543      
29544      
29545      
29546      
29547      
29548      
29549
29550var CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_options = {};
29551
29552CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_options.styleTagTransform = (styleTagTransform_default());
29553CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_options.setAttributes = (setAttributesWithoutAttributes_default());
29554CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_options.insert = insertBySelector_default().bind(null, "head");
29555CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_options.domAPI = (styleDomAPI_default());
29556CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_options.insertStyleElement = (insertStyleElement_default());
29557
29558var CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_update = injectStylesIntoStyleTag_default()(CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css/* default */.A, CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css_options);
29559
29560
29561
29562
29563       /* harmony default export */ const components_CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css = (CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css/* default */.A && CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css/* default */.A.locals ? CookieDetailvue_type_style_index_0_id_dc305a40_scoped_true_lang_css/* default */.A.locals : undefined);
29564
29565;// ./vue/components/CookieDetail.vue?vue&type=style&index=0&id=dc305a40&scoped=true&lang=css
29566
29567;// ./vue/components/CookieDetail.vue
29568
29569
29570
29571
29572;
29573
29574
29575const CookieDetail_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(CookieDetailvue_type_script_lang_js, [['render',CookieDetailvue_type_template_id_dc305a40_scoped_true_render],['__scopeId',"data-v-dc305a40"]])
29576
29577/* harmony default export */ const CookieDetail = (CookieDetail_exports_);
29578;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieConsent.vue?vue&type=script&lang=js
29579
29580
29581
29582
29583
29584
29585/* harmony default export */ const CookieConsentvue_type_script_lang_js = ({
29586	name: "cookieConsent",
29587	mixins: [LocalizeURL/* default */.A],
29588	components: {
29589		CookieDetail: CookieDetail
29590	},
29591	props: {
29592		labelString: String
29593	},
29594	data: () => ({
29595		name: "",
29596		view: 'simple',
29597		cookieGroups: ['essential'],
29598		cookieSettings: [],
29599		groupsStructure: {
29600			essential: [],
29601			marketing: [],
29602			media: [],
29603			statistics: []
29604		},
29605		tooltipsOpen: [],
29606		hidden: true,
29607		hardcodedCookiePlatforms: [
29608			'google_analytics',
29609			'google_adwords',
29610			'fb_pixel',
29611			'pinterest',
29612			'billiger_de'
29613		]
29614	}),
29615	computed: {
29616		imprintUrl() {
29617			let slug = SP_CONSTANTS.SHOP.IMPRINT_PAGE_LINK;
29618			return slug ? this.localizeURL('/' + slug) : '';
29619		},
29620		privacyUrl() {
29621			let slug = SP_CONSTANTS.SHOP.PRIVACY_POLICY_PAGE_LINK;
29622			return slug ? this.localizeURL('/' + slug) : '';
29623		},
29624		customCookiePlatformsByGroup() {
29625			let customCookiePlatformsByGroup = {};
29626			for (let groupName in this.groupsStructure) {
29627				customCookiePlatformsByGroup[groupName] = [];
29628			}
29629			for (let platform of SP_CONSTANTS.SHOP.COOKIE_PLATFORMS) {
29630				if (this.hardcodedCookiePlatforms.includes(platform.id)) continue;
29631				customCookiePlatformsByGroup[platform.cookieConsentCategory].push(platform);
29632			}
29633			return customCookiePlatformsByGroup;	
29634		}
29635	},
29636	watch: {
29637		cookieGroups(groups, oldGroups) {
29638
29639			// get difference between new and old groups
29640			let addedGroups = groups.filter(group => !oldGroups.includes(group));
29641
29642			// add all cookies from group to cookieSettings
29643			for (let groupName of addedGroups) {
29644				for (let settingName of this.groupsStructure[groupName]) {
29645					if (!this.cookieSettings.includes(settingName)) {
29646						this.cookieSettings.push(settingName);
29647					}
29648				}
29649			}
29650		},
29651		cookieSettings() {
29652			let activeGroups = [];
29653			for (let groupName in this.groupsStructure) {
29654				let group = this.groupsStructure[groupName];
29655				let includesAll = true;
29656				for (let settingName of group) {
29657					if (!this.cookieSettings.includes(settingName)) {
29658						includesAll = false;
29659						break;
29660					}
29661				}
29662				if (includesAll) activeGroups.push(groupName);
29663			}
29664			this.cookieGroups = activeGroups;
29665		}
29666	},
29667	methods: {
29668		getLabel(name) {
29669            let [labelDomain, labelName] = name.toLowerCase().split('.');
29670			if (labels[labelDomain] && labels[labelDomain][labelName] && labels[labelDomain][labelName][SP_CONSTANTS.LOCALE]) {
29671				let labelValue = labels[labelDomain][labelName][SP_CONSTANTS.LOCALE];
29672				if (labelValue.indexOf('{{') >= 0 && this.variables) {
29673					for (let variable in this.variables) {
29674						labelValue = labelValue.replace('{{'+variable+'}}', this.variables[variable]);
29675					}
29676				}
29677				return labelValue;
29678			} else if (labels[labelDomain] && labels[labelDomain][labelName] === undefined) {
29679				return labels['errors']['error_occurred'][SP_CONSTANTS.LOCALE];
29680			} else {
29681				return this.labelString || this.name;
29682			}
29683		},
29684		changeView() {
29685			this.view = (this.view == 'simple') ? 'advanced' : 'simple';
29686			if (this.view == 'advanced') {
29687				setTimeout(() => {
29688					document.querySelector('.c-o-i__settings-back').focus();
29689				}, 100);
29690			}
29691		},
29692		toggleTooltip(name) {
29693
29694			if (this.tooltipsOpen.includes(name)) {
29695				this.tooltipsOpen.splice(this.tooltipsOpen.indexOf(name), 1);
29696			} else {
29697				this.tooltipsOpen.push(name);
29698			}
29699		},
29700		persistConsent(cookieGroups, cookieSettings) {
29701			let oldGroups = (0,SecureCookie/* SecureCookie */.o)('sp_active_cookies_groups');
29702			let oldSettings = (0,SecureCookie/* SecureCookie */.o)('sp_active_cookies_scripts');
29703			let isFirstTime = !oldGroups || !oldSettings;
29704
29705			let newGroups = JSON.stringify(cookieGroups);
29706			let newSettings = JSON.stringify(cookieSettings);
29707
29708			(0,SecureCookie/* SecureCookie */.o)('sp_active_cookies_groups', newGroups, 30);
29709			(0,SecureCookie/* SecureCookie */.o)('sp_active_cookies_scripts', newSettings, 30);
29710			(0,SecureCookie/* SecureCookie */.o)('sp_seen_cookies_platforms', JSON.stringify(Object.values(this.groupsStructure).flat()), 30);
29711
29712			let hasChanged = !isFirstTime && (oldGroups !== newGroups || oldSettings !== newSettings);
29713
29714			this.hidden = true;
29715
29716			if (hasChanged) {
29717				location.reload();
29718				return;
29719			}
29720
29721			this.dispatchEvent();
29722		},
29723		saveAll() {
29724			let cookieGroups = Object.keys(this.groupsStructure);
29725			let cookieSettings = Object.values(this.groupsStructure).flat();
29726
29727			this.persistConsent(cookieGroups, cookieSettings);
29728			if (document.querySelector('.skip-navigation__link')) {
29729				document.querySelector('.skip-navigation__link').focus();
29730			}
29731		},
29732		rejectAll() {
29733			let cookieGroups = ['essential'];
29734			let cookieSettings = this.groupsStructure['essential'].slice();
29735
29736			this.persistConsent(cookieGroups, cookieSettings);
29737			if (document.querySelector('.skip-navigation__link')) {
29738				document.querySelector('.skip-navigation__link').focus();
29739			}
29740		},
29741		save() {
29742			this.persistConsent(this.cookieGroups, this.cookieSettings);
29743			if (document.querySelector('.skip-navigation__link')) {
29744				document.querySelector('.skip-navigation__link').focus();
29745			}
29746		},
29747		dispatchEvent() {
29748			let event = new Event('CookieOptInSubmit');
29749			document.dispatchEvent(event);
29750		},
29751		updateCookieGroups(event) {
29752			let unsetGroupName = false;
29753
29754			if (!event.target.checked) {
29755				unsetGroupName = event.target.value;
29756			}
29757
29758			if (unsetGroupName) {
29759				//remove trackers
29760				this.cookieSettings = this.cookieSettings.filter(x => !this.groupsStructure[unsetGroupName].includes(x));
29761			} else {
29762				//add trackers
29763				let groups = [].concat(this.cookieGroups, [event.target.value]);
29764				for (let groupName of groups) {
29765					let settings = this.groupsStructure[groupName];
29766					// combine arrays without duplicate values
29767					let newSettings = [...new Set([].concat(this.cookieSettings, settings))];
29768
29769					if (Object.values(this.cookieSettings).join('') != newSettings.join('')) {
29770						this.cookieSettings = newSettings;
29771					}
29772				}
29773			}
29774		},
29775		getGroupsLength() {
29776			let len = 0;
29777			for (let groupKey in this.groupsStructure) {
29778				len += this.groupsStructure[groupKey].length;
29779			}
29780			return len;
29781		},
29782		addCustomCookiePlatformsToGroupStructure() {
29783			for (let cookiePlatform of SP_CONSTANTS.SHOP.COOKIE_PLATFORMS) {
29784				if (this.hardcodedCookiePlatforms.includes(cookiePlatform.id)) continue;
29785				this.groupsStructure[cookiePlatform.cookieConsentCategory].push(cookiePlatform.id);
29786			}
29787		}
29788	},
29789	mounted() {
29790		if (!this.hidden) {
29791			this.$nextTick(() => {
29792				let anchor = this.$el.querySelector('.c-o-i__focus-anchor');
29793				if (anchor) anchor.focus();
29794			});
29795		}
29796	},
29797	beforeMount() {
29798		if (!(0,SecureCookie/* SecureCookie */.o)('sp-active-cookies_groups') && !(0,SecureCookie/* SecureCookie */.o)('sp_active_cookies_scripts')) {
29799			this.hidden = false;
29800		}
29801
29802		if (SP_CONSTANTS.SHOP.FACEBOOK_PIXEL_TRACKING_ID) {
29803			this.groupsStructure['marketing'].push('fb_pixel');
29804		}
29805
29806		if (SP_CONSTANTS.SHOP.GOOGLE_ADWORDS_TRACKING_ID) {
29807			this.groupsStructure['marketing'].push('google_adwords');
29808		}
29809
29810		if (SP_CONSTANTS.SHOP.GOOGLE_ANALYTICS_TRACKING_ID) {
29811			this.groupsStructure['statistics'].push('google_analytics');
29812		}
29813
29814		if (SP_CONSTANTS.SHOP.PINTEREST_TRACKING_ID) {
29815			this.groupsStructure['marketing'].push('pinterest');
29816		}
29817
29818		if (SP_CONSTANTS.SHOP.BILLIGER_DE_TRACKING_ACTIVE) {
29819			this.groupsStructure['marketing'].push('billiger_de');
29820		}
29821
29822		if (SP_CONSTANTS.SHOP.BILLIGER_DE_TRACKING_ACTIVE) {
29823			this.groupsStructure['marketing'].push('billiger_de');
29824		}
29825
29826		// if (SP_CONSTANTS.SHOP.HAS_YOUTUBE_VIDEOS) {
29827		// 	this.groupsStructure['media'].push('youtube');
29828		// }
29829
29830		// if (SP_CONSTANTS.SHOP.HAS_VIMEO_VIDEOS) {
29831		// 	this.groupsStructure['media'].push('vimeo');
29832		// }
29833
29834		this.addCustomCookiePlatformsToGroupStructure();
29835
29836		let seenJson = (0,SecureCookie/* SecureCookie */.o)('sp_seen_cookies_platforms');
29837		if (seenJson) {
29838			let seen = JSON.parse(seenJson);
29839			let currentPlatformIds = Object.values(this.groupsStructure).flat();
29840			let hasNewPlatform = currentPlatformIds.some(id => !seen.includes(id));
29841			if (hasNewPlatform) {
29842				this.hidden = false;
29843			}
29844		}
29845
29846		if (this.getGroupsLength() <= 0) {
29847			this.hidden = true;
29848		}
29849
29850		//eventlistener for cookie opt in open
29851		let self = this;
29852		document.addEventListener('CookieOptInOpen', () => {
29853			self.hidden = false;
29854			self.$nextTick(() => {
29855				let anchor = self.$el.querySelector('.c-o-i__focus-anchor');
29856				if (anchor) anchor.focus();
29857			});
29858		});	
29859
29860		let htmlElement = document.querySelector('html');
29861		if (htmlElement && htmlElement.classList.contains('theme-editor-document')) {
29862			this.saveAll();
29863		}
29864
29865	}
29866});
29867
29868;// ./vue/components/CookieConsent.vue?vue&type=script&lang=js
29869 
29870// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieConsent.vue?vue&type=style&index=0&id=26d6dc2e&scoped=true&lang=css
29871var CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css = __webpack_require__(3285);
29872;// ./node_modules/style-loader/dist/cjs.js!./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/CookieConsent.vue?vue&type=style&index=0&id=26d6dc2e&scoped=true&lang=css
29873
29874      
29875      
29876      
29877      
29878      
29879      
29880      
29881      
29882      
29883
29884var CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_options = {};
29885
29886CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_options.styleTagTransform = (styleTagTransform_default());
29887CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_options.setAttributes = (setAttributesWithoutAttributes_default());
29888CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_options.insert = insertBySelector_default().bind(null, "head");
29889CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_options.domAPI = (styleDomAPI_default());
29890CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_options.insertStyleElement = (insertStyleElement_default());
29891
29892var CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_update = injectStylesIntoStyleTag_default()(CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css/* default */.A, CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css_options);
29893
29894
29895
29896
29897       /* harmony default export */ const components_CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css = (CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css/* default */.A && CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css/* default */.A.locals ? CookieConsentvue_type_style_index_0_id_26d6dc2e_scoped_true_lang_css/* default */.A.locals : undefined);
29898
29899;// ./vue/components/CookieConsent.vue?vue&type=style&index=0&id=26d6dc2e&scoped=true&lang=css
29900
29901;// ./vue/components/CookieConsent.vue
29902
29903
29904
29905
29906;
29907
29908
29909const CookieConsent_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(CookieConsentvue_type_script_lang_js, [['render',CookieConsentvue_type_template_id_26d6dc2e_scoped_true_render],['__scopeId',"data-v-26d6dc2e"]])
29910
29911/* harmony default export */ const CookieConsent = (CookieConsent_exports_);
29912;// ./vue/entity/NewsletterSubscriptionEntity.js
29913
29914
29915class NewsletterSubscriptionEntity extends Entity/* default */.A {
29916	constructor() {
29917		super();
29918	}
29919
29920	static createFromAPIData(obj) {
29921		return NewsletterSubscriptionEntity.map({
29922            emailAddress: 'emailAddress',
29923            firstName: 'firstName',
29924            lastName: 'lastName'
29925        },
29926        obj);
29927    }
29928    
29929    static toPOJO(obj) {
29930		return NewsletterSubscriptionEntity.map({
29931            emailAddress: 'emailAddress',
29932            firstName: 'firstName',
29933            lastName: 'lastName'
29934        },
29935        obj,
29936        true);
29937	}
29938}
29939
29940/* harmony default export */ const entity_NewsletterSubscriptionEntity = (NewsletterSubscriptionEntity);
29941
29942;// ./vue/misc/NewsletterSubscriptionService.js
29943// import FormElement from "../entity/FormElement";
29944// import APIClient from "../APIClient";
29945
29946// class FormElementService {
29947
29948//     static async send(rawData) {
29949//         let entity = FormElement.createFromAPIData(rawData);
29950//         let pojo = FormElement.toPOJO(entity);
29951
29952//         let apiClient = new APIClient();
29953//         apiClient.method = 'POST';
29954//         apiClient.headers = {
29955//             'Accept-Language': SP_CONSTANTS.LOCALE
29956//         };
29957//         apiClient.data = JSON.stringify(pojo);
29958//         apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/formElement';
29959
29960//         let returnData = await apiClient.call(data => {
29961//             return data;
29962//         });
29963
29964//         return returnData;
29965//     }
29966// }
29967
29968// export default FormElementService;
29969
29970
29971
29972
29973class NewsletterSubscriptionService {
29974
29975    static async send(rawData) {
29976        let entity = entity_NewsletterSubscriptionEntity.createFromAPIData(rawData);
29977        let pojo = entity_NewsletterSubscriptionEntity.toPOJO(entity);
29978
29979        let apiClient = new APIClient/* default */.A();
29980        apiClient.method = 'POST';
29981        apiClient.headers = {
29982            'Accept-Language': SP_CONSTANTS.LOCALE
29983        };
29984        apiClient.data = JSON.stringify(pojo);
29985        apiClient.path = 'shops/' + SP_CONSTANTS.SHOP.ID + '/newsletterSubscription';
29986
29987        let returnData = await apiClient.call(data => {
29988            return data;
29989        });
29990
29991        return returnData;
29992    }
29993}
29994
29995/* harmony default export */ const misc_NewsletterSubscriptionService = (NewsletterSubscriptionService);
29996;// ./vue/misc/LabelService.js
29997class LabelService {
29998    static getLabel(name, variables) {
29999        let [labelDomain, labelName] = name.toLowerCase().split('.');
30000        if (labels[labelDomain] && labels[labelDomain][labelName] && labels[labelDomain][labelName][SP_CONSTANTS.LOCALE]) {
30001            let labelValue = labels[labelDomain][labelName][SP_CONSTANTS.LOCALE];
30002            if (labelValue.indexOf('{{') >= 0 && variables) {
30003                for (let variable in variables) {
30004                    labelValue = labelValue.replace('{{'+variable+'}}', variables[variable]);
30005                }
30006            }
30007            return labelValue;
30008        } else if (labels[labelDomain] && labels[labelDomain][labelName] === undefined) {
30009            return labels[labelDomain]['error_occurred'][SP_CONSTANTS.LOCALE];
30010        } else {
30011            return name;
30012        }
30013    }
30014}
30015
30016/* harmony default export */ const misc_LabelService = (LabelService);
30017;// ./vue/page-collection.js
30018
30019
30020class PageCollection {
30021
30022    constructor() {
30023
30024        let self = this;
30025        this.templates = [];
30026        this.randomSeed = Math.floor(Math.random() * 1000000);
30027
30028        document.querySelectorAll('[data-page-collection-id]').forEach(element => {
30029            let pageCollectionId = element.getAttribute('data-page-collection-id');
30030            let template = element.querySelector('template');
30031            self.templates[pageCollectionId] = template ? template.innerHTML : '';
30032
30033            let isRandom = Boolean(element.getAttribute('data-random')) || false;
30034            if (isRandom) {
30035                let pageNumber, totalPageNumber;
30036                let pageCollectionNav = element.querySelector('[data-page-collection-nav]');
30037
30038                if (!pageCollectionNav) {
30039                    pageNumber = 1;
30040                    totalPageNumber = 1;
30041                } else {
30042                    [pageNumber, totalPageNumber] = (pageCollectionNav.getAttribute('data-page-collection-nav') || '1').split('/');
30043                }
30044
30045                self.loadPage(pageCollectionId, 1, totalPageNumber, true);
30046            }
30047        });
30048
30049        document.querySelectorAll('.page-collection__filter-select').forEach(select => {
30050            select.addEventListener('change', function(e) {
30051                let pageCollectionId = e.currentTarget.closest('[data-page-collection-id]').getAttribute('data-page-collection-id');
30052                let pageData = self.getPageData(pageCollectionId);
30053                self.loadPage(pageCollectionId, pageData.pageNumber, pageData.totalPageNumber, pageData.isRandom, pageData.filterValues);
30054            });
30055        });
30056
30057        document.querySelectorAll('.page-collection-filter .page-collection__filter-button').forEach(button => {
30058            button.addEventListener('click', function(e) {
30059                let target = e.currentTarget;
30060
30061                if (target.getAttribute('data-active') === 'true') {
30062                    target.parentElement.querySelectorAll('.page-collection__filter-button').forEach(el => {
30063                        el.setAttribute('data-active', 'false');
30064                        el.classList.remove('page-collection__filter-button--active');
30065                    });
30066
30067                    // remove active of the generated classes
30068                    let matches = [...target.getAttribute('class').matchAll(/([\w-]+)__filter-choice--active/g)];
30069                    matches.forEach(function (match) {
30070                        let baseClass = match[1];
30071                        console.log(baseClass);
30072                        target.classList.remove(baseClass + '__filter-choice--active');
30073                        target.classList.add(baseClass + '__filter-choice--inactive');
30074                    });
30075                } else {
30076                    // siblings: all siblings of target that match the selector
30077                    Array.from(target.parentElement.children).forEac
30077h(sibling => {
30078                        if (sibling !== target && sibling.matches('.page-collection__filter-button')) {
30079                            sibling.setAttribute('data-active', 'false');
30080                            sibling.classList.remove('page-collection__filter-button--active');
30081                        }
30082                    });
30083                    target.setAttribute('data-active', 'true');
30084                    target.classList.add('page-collection__filter-button--active');
30085
30086                    // add / remove active of the generated classes
30087                    target.parentElement.querySelectorAll('[class*="__filter-choice--active"], [class*="__filter-choice--inactive"]').forEach(choice => {
30088                        let matches = [...choice.getAttribute('class').matchAll(/([\w-]+)__filter-choice--(?:active|inactive)/g)];
30089                        matches.forEach(function (match) {
30090                            let baseClass = match[1];
30091                            choice.classList.remove(baseClass + '__filter-choice--active');
30092                            choice.classList.remove(baseClass + '__filter-choice--inactive');
30093                            choice.classList.add(baseClass + '__filter-choice--inactive');
30094                        });
30095                    });
30096                    let matches = [...target.getAttribute('class').matchAll(/([\w-]+)__filter-choice--inactive/g)];
30097
30098                    matches.forEach(function (match) {
30099                        let baseClass = match[1];
30100                        target.classList.remove(baseClass + '__filter-choice--inactive');
30101                        target.classList.add(baseClass + '__filter-choice--active');
30102                    });
30103                }
30104
30105
30106                let pageCollectionId = target.closest('[data-page-collection-id]').getAttribute('data-page-collection-id');
30107                let pageData = self.getPageData(pageCollectionId);
30108                self.loadPage(pageCollectionId, pageData.pageNumber, pageData.totalPageNumber, pageData.isRandom, pageData.filterValues);
30109            });
30110        });
30111
30112        this.listener = null;
30113        this.navigationListener();
30114
30115    }
30116
30117    getPageData(pageCollectionId) {
30118        let filterValues = this.getAllFilterValues(pageCollectionId);
30119
30120        let _pageNumber, totalPageNumber;
30121        let pageCollectionNav = document.querySelector('[data-page-collection-id="'+pageCollectionId+'"] [data-page-collection-nav]');
30122
30123        if (!pageCollectionNav) {
30124            _pageNumber = 1;
30125            totalPageNumber = 1;
30126        } else {
30127            [_pageNumber, totalPageNumber] = (pageCollectionNav.getAttribute('data-page-collection-nav') || '1').split('/');
30128        }
30129
30130        let collectionEl = document.querySelector('[data-page-collection-id="'+pageCollectionId+'"]');
30131        let isRandom = Boolean(collectionEl?.getAttribute('data-random')) || false;
30132
30133        return {
30134            pageCollectionId: pageCollectionId,
30135            filterValues: filterValues,
30136            pageNumber: _pageNumber,
30137            totalPageNumber: totalPageNumber,
30138            isRandom: isRandom
30139        }
30140    }
30141
30142
30143    getAllFilterValues(pageCollectionId) {
30144        let values = {};
30145        // dropdowns
30146        document.querySelectorAll('[data-page-collection-id="'+pageCollectionId+'"] .page-collection__filters select').forEach(element => {
30147            let filterId = element.getAttribute('data-id');
30148            let filterValue = element.value;
30149            if (filterValue === '' || filterValue === null) return;
30150            values[filterId] = filterValue;
30151        });
30152        // buttons
30153        document.querySelectorAll('[data-page-collection-id="'+pageCollectionId+'"] .page-collection__filters .page-collection-filter__buttons').forEach(element => {
30154            let filterId = element.getAttribute('data-id');
30155            let activeButton = element.querySelector('.page-collection__filter-button[data-active="true"]');
30156            let filterValue = activeButton ? activeButton.getAttribute('data-value') : null;
30157
30158            if (filterValue === '' || filterValue === null) return;
30159            values[filterId] = filterValue;
30160        });
30161        return values;
30162    }
30163
30164    async loadPage(pageCollectionId, pageNumber, totalPageNumber, isRandom, filterValues = null) {
30165
30166        let randomSeed = null;
30167        if (isRandom) {
30168            randomSeed = this.randomSeed;
30169        }
30170
30171        let data = await this.fetchCollectionPage(pageCollectionId ,pageNumber, randomSeed, filterValues);
30172
30173        if (data && data._embedded && data._embedded.pages) {
30174
30175            let output = '';
30176            for (let page of data._embedded.pages) {
30177
30178                let pageString = this.templates[pageCollectionId].replaceAll('##title##', page.title);
30179                let excerpt = page.excerpt ? page.excerpt.replace(/<a\b[^>]*>([\s\S]*?)<\/a>/gi, '$1') : page.excerpt;
30180                pageString = pageString.replaceAll('##excerpt##', excerpt);
30181                pageString = pageString.replaceAll('##slug##', page.slugName);
30182
30183                if (page.date) {
30184                    let date = new Date(page.date);
30185                    let day = date.getDate();
30186                    let month = date.getMonth() + 1;
30187                    let year = date.getFullYear();
30188                    if (day < 10) {
30189                        day = '0' + day;
30190                    }
30191                    if (month < 10) {
30192                        month = '0' + month;
30193                    }
30194                    page.date = day + '.' + month + '.' + year;
30195                }
30196
30197                pageString = pageString.replaceAll('##date##', page.date);
30198                if (page.image && page.image.file) {
30199                    pageString = pageString.replaceAll('##image##', page.image.file);
30200                }
30201
30202                let tmpl = document.createElement('template');
30203                tmpl.innerHTML = pageString.trim();
30204                let pageEl = tmpl.content.firstElementChild;
30205
30206                if (pageEl) {
30207                    if (!page.image) {
30208                        pageEl.querySelectorAll('.page-collection__image-column').forEach(el => el.remove());
30209                    }
30210
30211                    if (!page.excerpt) {
30212                        pageEl.querySelectorAll('.page-collection__text').forEach(el => el.remove());
30213                    }
30214
30215                    if (!page.date) {
30216                        pageEl.querySelectorAll('.page-collection__date').forEach(el => el.remove());
30217                    }
30218
30219                    output += pageEl.outerHTML;
30220                }
30221            }
30222
30223            // recalculate total page number
30224            if (typeof data.total !== 'undefined' && typeof data.limit !== 'undefined') {
30225                totalPageNumber = Math.ceil(data.total / data.limit) || 1;
30226            }
30227
30228            document.querySelectorAll('[data-page-collection-id="'+pageCollectionId+'"] .page-collection__pages').forEach(el => el.innerHTML = output);
30229            this.setPagination(pageCollectionId, pageNumber, totalPageNumber);
30230        }
30231    }
30232
30233    async fetchCollectionPage(collectionId, pageNumber, randomSeed = null, filterValues = null) {
30234        let apiClient = new APIClient/* default */.A();
30235        apiClient.method = 'GET';
30236
30237        if (!pageNumber || pageNumber < 1) {
30238            pageNumber = 1;
30239        }
30240
30241		let path = 'shops/' + SP_CONSTANTS.SHOP.ID +
30242            '/pageCollectionElements/' + collectionId + '?page=' + pageNumber;
30243
30244        if (randomSeed) {
30245            path += '&sortingSeed=' + randomSeed;
30246        }
30247
30248        if (filterValues) {
30249            let filterArray = [];
30250            for (let filterId in filterValues) {
30251                let filterValue = filterValues[filterId];
30252                if (filterValue) {
30253                    filterArray.push(encodeURIComponent(filterId) + '_' + encodeURIComponent(filterValue));
30254                }
30255            }
30256
30257            if (filterArray.length > 0) {
30258                path += '&filters=';
30259                path += filterArray.join(' ');
30260            }
30261        }
30262
30263        apiClient.path = path;
30264
30265        apiClient.headers = {
30266            'Accept-Language': SP_CONSTANTS.LOCALE
30267        };
30268
30269        return await apiClient.call(data => data);
30270    }
30271
30272    navigationListener() {
30273        let self = this;
30274        this.listener = function(e) {
30275
30276            e.preventDefault();
30277            let pageNumber, totalPageNumber;
30278            [pageNumber, totalPageNumber] = e.currentTarget.getAttribute('data-page-collection-nav').split('/');
30279            if (Number(pageNumber) < 1 || Number(pageNumber) > Number(totalPageNumber)) {
30280                return;
30281            }
30282            let pageCollectionId = e.currentTarget.closest('[data-page-collection-id]').getAttribute('data-page-collection-id');
30283
30284            let collectionEl = document.querySelector('[data-page-collection-id="'+pageCollectionId+'"]');
30285            let isRandom = Boolean(collectionEl?.getAttribute('data-random')) || false;
30286            let filterValues = self.getAllFilterValues(pageCollectionId);
30287
30288            self.loadPage(pageCollectionId, pageNumber, totalPageNumber, isRandom, filterValues);
30289        };
30290
30291        document.querySelectorAll('[data-page-collection-nav]').forEach(el => el.addEventListener('click', this.listener));
30292    }
30293
30294    setPagination(pageCollectionId, pageNumber, totalPageNumber) {
30295        let prev = Number(pageNumber) - 1;
30296        let next = Number(pageNumber) + 1;
30297
30298        if (prev < 1) {
30299            prev = 1;
30300        }
30301
30302        if (next > totalPageNumber) {
30303            next = totalPageNumber;
30304        }
30305
30306        document.querySelectorAll('[data-page-collection-id="'+pageCollectionId+'"] .page-collection__pagination-prev').forEach(el => {
30307            el.setAttribute('data-page-collection-nav', prev + '/' + totalPageNumber);
30308        });
30309
30310        document.querySelectorAll('[data-page-collection-id="'+pageCollectionId+'"] .page-collection__pagination-next').forEach(el => {
30311            el.setAttribute('data-page-collection-nav', next + '/' + totalPageNumber);
30312        });
30313
30314        document.querySelectorAll('[data-page-collection-id="'+pageCollectionId+'"] .page-collection__current-page').forEach(el => {
30315            el.innerHTML = pageNumber;
30316        });
30317
30318        document.querySelectorAll('[data-page-collection-id="'+pageCollectionId+'"] .page-collection__total-pages').forEach(el => {
30319            el.innerHTML = totalPageNumber;
30320        });
30321
30322        // remove the listener and add it again
30323        document.querySelectorAll('[data-page-collection-nav]').forEach(el => el.removeEventListener('click', this.listener));
30324        this.navigationListener();
30325    }
30326}
30327
30328/* harmony default export */ const page_collection = (PageCollection);
30329
30330;// ./vue/frontend-trigger.js
30331
30332
30333function isCorrectResource(trigger, resource) {
30334    // combine the two arrays
30335    let allResourceTypes = trigger.resourceTypes.concat(trigger.specialResourceTypes);
30336    let includedInAnyResourceType = allResourceTypes.includes(resource);
30337    let exclude = trigger.excludeResourceTypes || trigger.excludeSpecialResourceTypes;
30338
30339    if ((!includedInAnyResourceType && exclude) || (includedInAnyResourceType && !exclude)) {
30340        return true;
30341    }
30342    
30343    return false;
30344}
30345
30346function setPopupStatusCookie(popupId, value) {
30347    let wrapperElement = document.querySelector('.floatbox__wrapper[data-id="'+popupId+'"]');
30348    if (wrapperElement) {
30349        let lifetimeType = wrapperElement.getAttribute('data-cookie-lifetime-type');
30350        if (lifetimeType === 'session') {
30351            (0,SecureCookie/* SecureCookie */.o)('sp_floatbox_'+popupId, value, null);
30352        } else if (lifetimeType === 'cookie') {
30353            let lifetimeInDays = Number(wrapperElement.getAttribute('data-cookie-lifetime'));
30354            (0,SecureCookie/* SecureCookie */.o)('sp_floatbox_'+popupId, value, lifetimeInDays);
30355        }
30356    }
30357}
30358
30359function getPopupStatusFromCookie(popupId) {
30360    return (0,SecureCookie/* SecureCookie */.o)('sp_floatbox_'+popupId) || null;
30361}
30362
30363function triggerPopup(popupId, triggerOpen, delay) {
30364    setTimeout(function() {
30365        let wrapperElement = document.querySelector('.floatbox__wrapper[data-id="'+popupId+'"]');
30366        if (wrapperElement) {
30367            let savedStatus = getPopupStatusFromCookie(popupId);
30368            if (triggerOpen && savedStatus !== 'closed') {
30369                wrapperElement.classList.add('floatbox__wrapper--active');
30370                setPopupStatusCookie(popupId, 'open');
30371            } else if (!triggerOpen) {
30372                wrapperElement.classList.remove('floatbox__wrapper--active');
30373                setPopupStatusCookie(popupId, 'closed');
30374            }
30375
30376            setPopupPositions();
30377            setCloseTriggers();
30378        }
30379    }, delay);
30380}
30381
30382function getDeviceSize() {
30383    let deviceWidth = window.innerWidth;
30384    if (deviceWidth < 576) {
30385        return 'xs';
30386    } else if (deviceWidth < 768) {
30387        return 'sm';
30388    } else if (deviceWidth < 992) {
30389        return 'md';
30390    } else if (deviceWidth < 1200) {
30391        return 'lg';
30392    } else {
30393        return 'xl';
30394    }
30395}
30396
30397function setCloseTriggers() {
30398    // determine if popup is not hovered then trigger close
30399    let popupWrapperElements = document.querySelectorAll('.floatbox__wrapper');
30400    for (let popupWrapperElement of popupWrapperElements) {
30401        let popupId = popupWrapperElement.getAttribute('data-id');
30402        let blendElement = popupWrapperElement.querySelector('.floatbox__blend--mouse-out');
30403        let isActive = popupWrapperElement.classList.contains('floatbox__wrapper--active');
30404        if (blendElement && isActive) {
30405            let popupElement = popupWrapperElement.querySelector('.floatbox');
30406            // mouseleave (1s delay to prevent immediate close)
30407            setTimeout(function() {
30408                document.addEventListener('mousemove', function(e) {
30409                    let isHovered = popupElement.matches(':hover');
30410                    if (!isHovered) {
30411                        popupWrapperElement.classList.remove('floatbox__wrapper--active');
30412                        setPopupStatusCookie(popupId, 'closed');
30413                        // document.removeEventListener('mousemove', arguments.callee);
30414                    }
30415                });
30416            }, 1000);
30417        }
30418        
30419        // click outside (click the blend)
30420        blendElement = popupWrapperElement.querySelector('.floatbox__blend--click-out');
30421        if (blendElement) blendElement.addEventListener('click', function(e) {
30422            if (e.target === blendElement) {
30423                let popupId = blendElement.closest('.floatbox__wrapper').getAttribute('data-id');
30424                popupWrapperElement.classList.remove('floatbox__wrapper--active');
30425                setPopupStatusCookie(popupId, 'closed');
30426                // blendElement.removeEventListener('click', arguments.callee);
30427            }
30428        });
30429    }
30430}
30431
30432function setPopupPositions() {
30433    let popupWrapperElements = document.querySelectorAll('.floatbox__wrapper');
30434    let deviceSize = getDeviceSize();
30435
30436    for (let popupWrapperElement of popupWrapperElements) {
30437
30438        // get the display setting variables
30439        let referenceElementTag = popupWrapperElement.getAttribute('data-reference-element-tag-'+deviceSize) || 'screen';
30440        let referenceElementAlignmentPoint = popupWrapperElement.getAttribute('data-reference-element-alignment-point-'+deviceSize) || 'center';
30441        let popupElementAlignmentPoint = popupWrapperElement.getAttribute('data-popup-alignment-point-'+deviceSize) || 'center';
30442        let horizontalOffset = parseInt(popupWrapperElement.getAttribute('data-horizontal-offset-'+deviceSize)) || 0;
30443        let verticalOffset = parseInt(popupWrapperElement.getAttribute('data-vertical-offset-'+deviceSize)) || 0;
30444
30445        let popupId = popupWrapperElement.getAttribute('data-id');
30446
30447        // get the reference element selector
30448        let referenceElementSelector = '.floatbox__wrapper[data-id="'+popupId+'"] .floatbox__blend'; // screen
30449        if (referenceElementTag === 'page') {
30450            referenceElementSelector = 'body';
30451        } else if (referenceElementTag !== '' && referenceElementTag !== null && referenceElementTag !== 'screen') {
30452            referenceElementSelector = '[data-reference-tags~="'+referenceElementTag+'"]';
30453        }
30454
30455        let popupElement = popupWrapperElement.querySelector('.floatbox');
30456        let referenceElement = document.querySelector(referenceElementSelector);
30457        if (!referenceElement) {
30458            referenceElementSelector = '.floatbox__wrapper[data-id="'+popupId+'"] .floatbox__blend';
30459            referenceElement = document.querySelector(referenceElementSelector);
30460        }
30461
30462
30463
30464        // get the absolute position of the reference element
30465        let reLeft = referenceElement.getBoundingClientRect().left + (referenceElementTag == 'screen' ? 0 : window.scrollX);
30466        let reTop = referenceElement.getBoundingClientRect().top + (referenceElementTag == 'screen' ? 0 : window.scrollY);
30467        let reWidth = referenceElement.offsetWidth;
30468        let reHeight = referenceElement.offsetHeight;
30469
30470        // Get the size of the popup element
30471        let poWidth = popupElement.offsetWidth;
30472        let poHeight = popupElement.offsetHeight;
30473
30474        let positionX = 0;
30475        let positionY = 0;
30476
30477        switch (referenceElementAlignmentPoint) {
30478            case 'top-left':
30479                positionX = reLeft;
30480                positionY = reTop;
30481                break;
30482            case 'top-right':
30483                positionX = reLeft + reWidth;
30484                positionY = reTop;
30485                break;
30486            case 'bottom-left':
30487                positionX = reLeft;
30488                positionY = reTop + reHeight;
30489                break;
30490            case 'bottom-right':
30491                positionX = reLeft + reWidth;
30492                positionY = reTop + reHeight;
30493                break;
30494            case 'left':
30495                positionX = reLeft;
30496                positionY = reTop + reHeight / 2;
30497                break;
30498            case 'right':
30499                positionX = reLeft + reWidth;
30500                positionY = reTop + reHeight / 2;
30501                break;
30502            case 'top':
30503                positionX = reLeft + reWidth / 2;
30504                positionY = reTop;
30505                break;
30506            case 'bottom':
30507                positionX = reLeft + reWidth / 2;
30508                positionY = reTop + reHeight;
30509                break;
30510            case 'center':
30511                positionX = reLeft + reWidth / 2;
30512                positionY = reTop + reHeight / 2;
30513                break;
30514            default:
30515                break;
30516        }
30517
30518        switch (popupElementAlignmentPoint) {
30519            case 'top-left':
30520                break;
30521            case 'top-right':
30522                positionX -= poWidth;
30523                break;
30524            case 'bottom-left':
30525                positionY -= poHeight;
30526                break;
30527            case 'bottom-right':
30528                positionX -= poWidth;
30529                positionY -= poHeight;
30530                break;
30531            case 'left':
30532                positionY -= poHeight / 2;
30533                break;
30534            case 'right':
30535                positionX -= poWidth;
30536                positionY -= poHeight / 2;
30537                break;
30538            case 'top':
30539                positionX -= poWidth / 2;
30540                break;
30541            case 'bottom':
30542                positionY -= poHeight;
30543                positionX -= poWidth / 2;
30544                break;
30545            case 'center':
30546                positionX -= poWidth / 2;
30547                positionY -= poHeight / 2;
30548                break;
30549            default:
30550                break;
30551        }
30552
30553
30554        positionX += horizontalOffset;
30555        positionY += verticalOffset;
30556
30557        if (referenceElementTag === 'screen') {
30558            popupElement.style.position = 'fixed';
30559        } else {
30560            popupElement.style.position = 'absolute';
30561        }
30562
30563        popupElement.style.top = positionY + 'px';
30564        popupElement.style.left = positionX + 'px';
30565    }
30566}
30567
30568/* harmony default export */ function frontend_trigger() {
30569
30570    // categorize by trigger type
30571    let resource = SP_CONSTANTS.RESOURCE.TYPE;
30572
30573    if (!resource) {
30574        return;
30575    }
30576
30577    let activeAutoTriggers = [];
30578    let activeScrollTriggers = [];
30579    let activePageLeaveTriggers = [];
30580
30581    if (SP_CONSTANTS.SHOP.FRONTEND_TRIGGERS) for (let trigger of SP_CONSTANTS.SHOP.FRONTEND_TRIGGERS) {
30582        if (!isCorrectResource(trigger, resource)) continue;
30583        let triggerType = trigger.triggerType;
30584
30585        if (triggerType === 'auto') {
30586            activeAutoTriggers.push(trigger);
30587        } else if (triggerType === 'scroll') {
30588            activeScrollTriggers.push(trigger);
30589        } else if (triggerType === 'page-leave') {
30590            activePageLeaveTriggers.push(trigger);
30591        }
30592    }
30593
30594    // call auto triggers
30595
30596    if (activeAutoTriggers.length > 0) {
30597        for (let autoTrigger of activeAutoTriggers) {
30598            let triggerOpen = autoTrigger.action == 'popup-open';
30599            triggerPopup(autoTrigger.popupId, triggerOpen, autoTrigger.delay);
30600        }
30601    }
30602
30603    if (activeScrollTriggers.length > 0) {
30604        window.addEventListener('scroll', function() {
30605            for (let scrollTrigger of activeScrollTriggers) {
30606                let triggerOpen = scrollTrigger.action == 'popup-open';
30607
30608                if (scrollTrigger.triggeringHtmlElementTag) {
30609                    // trigger popup when the element is in view
30610                    let triggeringElement = document.querySelector('[data-reference-tags~="'+scrollTrigger.triggeringHtmlElementTag+'"]');
30611                    if (triggeringElement) {
30612                        let rect = triggeringElement.getBoundingClientRect();
30613                        let viewHeight = Math.max(document.documentElement.clientHeight, window.innerHeight);
30614                        if (rect.top >= 0 && rect.bottom <= viewHeight) {
30615                            triggerPopup(scrollTrigger.popupId, triggerOpen, scrollTrigger.delay);
30616                        }
30617                    }
30618                } else {
30619                    triggerPopup(scrollTrigger.popupId, triggerOpen, scrollTrigger.delay);
30620                }
30621
30622            }
30623        });
30624    }
30625
30626    document.documentElement.addEventListener("mouseleave", function(event){
30627        if(event.clientY <= 0 || event.clientX <= 0 || 
30628            (event.clientX >= window.innerWidth || event.clientY >= window.innerHeight)) {
30629                
30630            for (let pageLeaveTrigger of activePageLeaveTriggers) {
30631                let triggerOpen = pageLeaveTrigger.action == 'popup-open';
30632                triggerPopup(pageLeaveTrigger.popupId, triggerOpen, pageLeaveTrigger.delay);
30633            }
30634        }
30635    });
30636
30637    window.addEventListener('scroll', setPopupPositions);
30638    window.addEventListener('resize', setPopupPositions);
30639
30640    // additional event listener for resize end to fix position 
30641    // of popup on fast resizing with transition effects
30642    function onEndResize(){
30643        setTimeout(setPopupPositions, 400);
30644    }
30645    var endResize;
30646    window.onresize = function(){
30647      clearTimeout(endResize);
30648      endResize = setTimeout(onEndResize, 100);
30649    };
30650
30651    let closeButtons = document.querySelectorAll('.floatbox__close');
30652    for (let closeButton of closeButtons) {
30653        closeButton.addEventListener('click', function(e) {
30654            let popupWrapperElement = closeButton.closest('.floatbox__wrapper');
30655            let popupId = popupWrapperElement.getAttribute('data-id');
30656            popupWrapperElement.classList.remove('floatbox__wrapper--active');
30657            setPopupStatusCookie(popupId, 'closed');
30658        });
30659    }
30660
30661    document.addEventListener('click', function(e) {
30662        let buttonElement = e.target.closest('.floatbox__wrapper--active .sp-button');
30663        if (!buttonElement || buttonElement.closest('form')) {
30664            return;
30665        }
30666        let popupWrapperElement = buttonElement.closest('.floatbox__wrapper');
30667        let popupId = popupWrapperElement.getAttribute('data-id');
30668        popupWrapperElement.classList.remove('floatbox__wrapper--active');
30669        setPopupStatusCookie(popupId, 'closed');
30670    });
30671
30672    document.addEventListener('PopupToggled', function() {
30673        setPopupPositions();
30674        // additional repositioning + delay to ensure mobile url bars are taken into account
30675        setTimeout(() => {
30676            setPopupPositions();
30677        }, 300);
30678        setCloseTriggers();
30679    });
30680    
30681}
30682;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/StatusBar.vue?vue&type=template&id=beedf594
30683
30684
30685const StatusBarvue_type_template_id_beedf594_hoisted_1 = { id: "sp-status-bar" }
30686const StatusBarvue_type_template_id_beedf594_hoisted_2 = { class: "sp-status-bar__main-area" }
30687const StatusBarvue_type_template_id_beedf594_hoisted_3 = ["href"]
30688const StatusBarvue_type_template_id_beedf594_hoisted_4 = {
30689  key: 0,
30690  class: "sp-status-bar-admin-button__label"
30691}
30692const StatusBarvue_type_template_id_beedf594_hoisted_5 = {
30693  key: 1,
30694  class: "sp-status-bar-admin-button__label"
30695}
30696const StatusBarvue_type_template_id_beedf594_hoisted_6 = ["href"]
30697const StatusBarvue_type_template_id_beedf594_hoisted_7 = { class: "sp-status-bar-button__label" }
30698const StatusBarvue_type_template_id_beedf594_hoisted_8 = { class: "sp-status-bar-status" }
30699const StatusBarvue_type_template_id_beedf594_hoisted_9 = { class: "sp-status-bar-status__label" }
30700
30701function StatusBarvue_type_template_id_beedf594_render(_ctx, _cache, $props, $setup, $data, $options) {
30702  const _component_sp_lang = (0,vue_esm_bundler/* resolveComponent */.g2)("sp-lang")
30703
30704  return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", StatusBarvue_type_template_id_beedf594_hoisted_1, [
30705    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", StatusBarvue_type_template_id_beedf594_hoisted_2, [
30706      (0,vue_esm_bundler/* createElementVNode */.Lk)("a", {
30707        href: $options.adminLink,
30708        class: "sp-status-bar-admin-button sp-status-bar-admin-button--whitelabel"
30709      }, [
30710        _cache[2] || (_cache[2] = (0,vue_esm_bundler/* createElementVNode */.Lk)("i", { class: "shopandicon spi_speedometer sp-status-bar-admin-button__font-icon" }, null, -1 /* CACHED */)),
30711        ($options.isWhiteLabel)
30712          ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", StatusBarvue_type_template_id_beedf594_hoisted_4, [
30713              (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
30714                default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[0] || (_cache[0] = [
30715                  (0,vue_esm_bundler/* createTextVNode */.eW)("status_bar.to_dashboard", -1 /* CACHED */)
30716                ]))]),
30717                _: 1 /* STABLE */
30718              })
30719            ]))
30720          : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", StatusBarvue_type_template_id_beedf594_hoisted_5, [
30721              (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
30722                default: (0,vue_esm_bundler/* withCtx */.k6)(() => [...(_cache[1] || (_cache[1] = [
30723                  (0,vue_esm_bundler/* createTextVNode */.eW)("status_bar.to_
30723shopando_dashboard", -1 /* CACHED */)
30724                ]))]),
30725                _: 1 /* STABLE */
30726              })
30727            ]))
30728      ], 8 /* PROPS */, StatusBarvue_type_template_id_beedf594_hoisted_3),
30729      ($options.buttonConfig)
30730        ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("a", {
30731            key: 0,
30732            href: $options.resourceLink,
30733            class: "sp-status-bar-button sp-status-bar-button--main"
30734          }, [
30735            _cache[3] || (_cache[3] = (0,vue_esm_bundler/* createElementVNode */.Lk)("i", { class: "shopandicon spi_pencil" }, null, -1 /* CACHED */)),
30736            (0,vue_esm_bundler/* createElementVNode */.Lk)("span", StatusBarvue_type_template_id_beedf594_hoisted_7, [
30737              (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
30738                default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
30739                  (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)($options.buttonConfig.label), 1 /* TEXT */)
30740                ]),
30741                _: 1 /* STABLE */
30742              })
30743            ])
30744          ], 8 /* PROPS */, StatusBarvue_type_template_id_beedf594_hoisted_6))
30745        : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
30746      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", StatusBarvue_type_template_id_beedf594_hoisted_8, [
30747        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
30748          class: (0,vue_esm_bundler/* normalizeClass */.C4)('sp-status-bar-status__indicator sp-status-bar-status__indicator--' + $options.status)
30749        }, null, 2 /* CLASS */),
30750        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", StatusBarvue_type_template_id_beedf594_hoisted_9, [
30751          (0,vue_esm_bundler/* createVNode */.bF)(_component_sp_lang, null, {
30752            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
30753              (0,vue_esm_bundler/* createTextVNode */.eW)("status_bar.status_" + (0,vue_esm_bundler/* toDisplayString */.v_)($options.status), 1 /* TEXT */)
30754            ]),
30755            _: 1 /* STABLE */
30756          })
30757        ])
30758      ])
30759    ]),
30760    (0,vue_esm_bundler/* createCommentVNode */.Q3)(" <a :href=\"designEditorLink\" class=\"sp-status-bar-button\">\n            <i class=\"spi spi_color-palette\"></i> <span class=\"sp-status-bar-button__label\"><sp-lang>status_bar.edit_design</sp-lang></span>\n        </a> ")
30761  ]))
30762}
30763;// ./vue/components/StatusBar.vue?vue&type=template&id=beedf594
30764
30765;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/StatusBar.vue?vue&type=script&lang=js
30766
30767/* harmony default export */ const StatusBarvue_type_script_lang_js = ({
30768	name: 'empty',
30769	data: () => ({
30770        buttonConfigs: {
30771            'category': {
30772                label: 'status_bar.edit_category',
30773                link: '/categories/$$$'
30774            },
30775            'product': {
30776                label: 'status_bar.edit_product',
30777                link: '/products/$$$'
30778            },
30779            'manufacturer': {
30780                label: 'status_bar.edit_manufacturer',
30781                link: '/manufacturers/$$$'
30782            },
30783            'tag': {
30784                label: 'status_bar.edit_tag',
30785                link: '/tags/$$$'
30786            },
30787            'page': {
30788                label: 'status_bar.edit_page',
30789                link: '/pages/$$$'
30790            },
30791            'checkout': {
30792                label: 'status_bar.edit_checkout_settings',
30793                link: '/checkout'
30794            },
30795            'profile': {
30796                label: 'status_bar.edit_profile_settings',
30797                link: '/profile'
30798            }
30799        }
30800	}),
30801    computed: {
30802        baseLink() {
30803            if (window.location.href.includes('local:9901')) return 'http://app.smarda.local:8080/#';
30804            return 'https://smarda.app/#';
30805        },
30806        status() {
30807            let online = SP_CONSTANTS.SHOP.ONLINE;
30808
30809            if (SP_CONSTANTS.RESOURCE && SP_CONSTANTS.RESOURCE.VISIBLE == '0') online = false;
30810
30811            let noindex = SP_CONSTANTS.SHOP.NO_INDEX;
30812            if (!online) return 'offline';
30813            if (noindex) return 'noindex';
30814            return 'online';
30815        },
30816        buttonConfig() {
30817            let config = this.buttonConfigs[SP_CONSTANTS.RESOURCE.TYPE];
30818            if (!config) return false;
30819            return config;
30820        },
30821        designEditorLink() {
30822            let path = window.location.pathname;
30823            return this.baseLink + '/design?page='+path;
30824        },
30825        adminLink() {
30826            return this.baseLink + '/';
30827        },
30828        resourceLink() {
30829            return this.baseLink + this.buttonConfig.link.replace('$$$', SP_CONSTANTS.RESOURCE.ID || '');
30830        },
30831        isWhiteLabel() {
30832            return SP_CONSTANTS.WL == '1' ? true : false;
30833        }
30834    },
30835    mounted() {
30836        // import the font
30837        const link = document.createElement('link');
30838        link.href = 'https://fonts.googleapis.com/css2?family=Montserrat:wght@400&display=swap';
30839        link.rel = 'stylesheet';
30840        document.head.appendChild(link);
30841
30842        document.body.style.marginBottom = '50px';
30843    }
30844});
30845
30846;// ./vue/components/StatusBar.vue?vue&type=script&lang=js
30847 
30848// EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/StatusBar.vue?vue&type=style&index=0&id=beedf594&lang=css
30849var StatusBarvue_type_style_index_0_id_beedf594_lang_css = __webpack_require__(603);
30850;// ./node_modules/style-loader/dist/cjs.js!./node_modules/css-loader/dist/cjs.js!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/StatusBar.vue?vue&type=style&index=0&id=beedf594&lang=css
30851
30852      
30853      
30854      
30855      
30856      
30857      
30858      
30859      
30860      
30861
30862var StatusBarvue_type_style_index_0_id_beedf594_lang_css_options = {};
30863
30864StatusBarvue_type_style_index_0_id_beedf594_lang_css_options.styleTagTransform = (styleTagTransform_default());
30865StatusBarvue_type_style_index_0_id_beedf594_lang_css_options.setAttributes = (setAttributesWithoutAttributes_default());
30866StatusBarvue_type_style_index_0_id_beedf594_lang_css_options.insert = insertBySelector_default().bind(null, "head");
30867StatusBarvue_type_style_index_0_id_beedf594_lang_css_options.domAPI = (styleDomAPI_default());
30868StatusBarvue_type_style_index_0_id_beedf594_lang_css_options.insertStyleElement = (insertStyleElement_default());
30869
30870var StatusBarvue_type_style_index_0_id_beedf594_lang_css_update = injectStylesIntoStyleTag_default()(StatusBarvue_type_style_index_0_id_beedf594_lang_css/* default */.A, StatusBarvue_type_style_index_0_id_beedf594_lang_css_options);
30871
30872
30873
30874
30875       /* harmony default export */ const components_StatusBarvue_type_style_index_0_id_beedf594_lang_css = (StatusBarvue_type_style_index_0_id_beedf594_lang_css/* default */.A && StatusBarvue_type_style_index_0_id_beedf594_lang_css/* default */.A.locals ? StatusBarvue_type_style_index_0_id_beedf594_lang_css/* default */.A.locals : undefined);
30876
30877;// ./vue/components/StatusBar.vue?vue&type=style&index=0&id=beedf594&lang=css
30878
30879;// ./vue/components/StatusBar.vue
30880
30881
30882
30883
30884;
30885
30886
30887const StatusBar_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(StatusBarvue_type_script_lang_js, [['render',StatusBarvue_type_template_id_beedf594_render]])
30888
30889/* harmony default export */ const StatusBar = (StatusBar_exports_);
30890;// ./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[1]!./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Chatbot.vue?vue&type=template&id=7babacea
30891
30892
30893const Chatbotvue_type_template_id_7babacea_hoisted_1 = { key: 0 }
30894const Chatbotvue_type_template_id_7babacea_hoisted_2 = ["aria-label", "aria-expanded"]
30895const Chatbotvue_type_template_id_7babacea_hoisted_3 = {
30896  key: 0,
30897  class: "chatbot__toggler-icon gs_chatbot__toggler-icon"
30898}
30899const Chatbotvue_type_template_id_7babacea_hoisted_4 = {
30900  key: 1,
30901  class: "chatbot__toggler-icon gs_chatbot__toggler-icon"
30902}
30903const Chatbotvue_type_template_id_7babacea_hoisted_5 = {
30904  class: "access-hide",
30905  "aria-live": "assertive"
30906}
30907const Chatbotvue_type_template_id_7babacea_hoisted_6 = ["aria-label"]
30908const Chatbotvue_type_template_id_7babacea_hoisted_7 = {
30909  class: "chatbot__header gs_chatbot__header",
30910  ref: "header"
30911}
30912const Chatbotvue_type_template_id_7babacea_hoisted_8 = { class: "gs_chatbot__name" }
30913const Chatbotvue_type_template_id_7babacea_hoisted_9 = { class: "chatbot__content-container" }
30914const Chatbotvue_type_template_id_7babacea_hoisted_10 = {
30915  class: "chatbot__chatbox gs_chatbot__chatbox",
30916  ref: "chatbox"
30917}
30918const Chatbotvue_type_template_id_7babacea_hoisted_11 = {
30919  tabindex: "0",
30920  class: "chatbot__chat chatbot__chat--incoming"
30921}
30922const Chatbotvue_type_template_id_7babacea_hoisted_12 = { class: "gs_chatbot__icon chatbot__chatbot-icon" }
30923const Chatbotvue_type_template_id_7babacea_hoisted_13 = ["innerHTML"]
30924const Chatbotvue_type_template_id_7babacea_hoisted_14 = {
30925  key: 0,
30926  class: "gs_chatbot__icon chatbot__chatbot-icon"
30927}
30928const Chatbotvue_type_template_id_7babacea_hoisted_15 = ["innerHTML"]
30929const Chatbotvue_type_template_id_7babacea_hoisted_16 = {
30930  key: 2,
30931  class: "gs_chatbot__chatbubble-outgoing"
30932}
30933const Chatbotvue_type_template_id_7babacea_hoisted_17 = { class: "gs_chatbot__disclaimer" }
30934const Chatbotvue_type_template_id_7babacea_hoisted_18 = ["aria-label", "placeholder"]
30935const Chatbotvue_type_template_id_7babacea_hoisted_19 = ["aria-label"]
30936
30937function Chatbotvue_type_template_id_7babacea_render(_ctx, _cache, $props, $setup, $data, $options) {
30938  return ($options.isChatbotActive)
30939    ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", Chatbotvue_type_template_id_7babacea_hoisted_1, [
30940        (0,vue_esm_bundler/* createElementVNode */.Lk)("button", {
30941          "aria-label": $options.getLabel('accessibility.open_chatbot'),
30942          class: (0,vue_esm_bundler/* normalizeClass */.C4)(["chatbot__toggler gs_chatbot__toggler", { 'chatbot__toggler--rotated': $data.chatbotOpen }]),
30943          onClick: _cache[0] || (_cache[0] = $event => ($options.toggleChatbot())),
30944          "aria-expanded": $data.chatbotOpen ? true : false,
30945          id: "chatbot"
30946        }, [
30947          (0,vue_esm_bundler/* createElementVNode */.Lk)("span", {
30948            class: (0,vue_esm_bundler/* normalizeClass */.C4)(["chatbot__toggler-icon-wrapper", { 'chatbot__toggler-icon-wrapper--rotated': $data.chatbotOpen }])
30949          }, [
30950            (!$data.chatbotOpen)
30951              ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", Chatbotvue_type_template_id_7babacea_hoisted_3, [
30952                  (0,vue_esm_bundler/* createElementVNode */.Lk)("i", {
30953                    class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon '+ $options.SP_CONSTANTS.THEME.TOGGLER_OPEN_ICON)
30954                  }, null, 2 /* CLASS */)
30955                ]))
30956              : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", Chatbotvue_type_template_id_7babacea_hoisted_4, [
30957                  (0,vue_esm_bundler/* createElementVNode */.Lk)("i", {
30958                    class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon '+ $options.SP_CONSTANTS.THEME.TOGGLER_CLOSE_ICON)
30959                  }, null, 2 /* CLASS */)
30960                ]))
30961          ], 2 /* CLASS */)
30962        ], 10 /* CLASS, PROPS */, Chatbotvue_type_template_id_7babacea_hoisted_2),
30963        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", Chatbotvue_type_template_id_7babacea_hoisted_5, " Chatbot sagt, " + (0,vue_esm_bundler/* toDisplayString */.v_)($data.latestMessage), 1 /* TEXT */),
30964        (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
30965          class: (0,vue_esm_bundler/* normalizeClass */.C4)({'chatbot__outer-wrapper': $options.isMobile})
30966        }, [
30967          (0,vue_esm_bundler/* createVNode */.bF)(vue_esm_bundler/* Transition */.eB, { name: "chatbot" }, {
30968            default: (0,vue_esm_bundler/* withCtx */.k6)(() => [
30969              ($data.chatbotOpen)
30970                ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
30971                    key: 0,
30972                    class: "chatbot gs_chatbot__container",
30973                    "aria-modal": "true",
30974                    "aria-label": $options.getLabel('accessibility.chatbot')
30975                  }, [
30976                    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", Chatbotvue_type_template_id_7babacea_hoisted_7, [
30977                      (0,vue_esm_bundler/* createElementVNode */.Lk)("h2", Chatbotvue_type_template_id_7babacea_hoisted_8, (0,vue_esm_bundler/* toDisplayString */.v_)($options.getLabel('chatbot.name')), 1 /* TEXT */),
30978                      (0,vue_esm_bundler/* createElementVNode */.Lk)("i", {
30979                        class: (0,vue_esm_bundler/* normalizeClass */.C4)(["gs_chatbot__mobile-close chatbot__mobile-close", 'shopandicon '+ $options.SP_CONSTANTS.THEME.CLOSE_ICON]),
30980                        onClick: _cache[1] || (_cache[1] = $event => ($options.toggleChatbot()))
30981                      }, null, 2 /* CLASS */)
30982                    ], 512 /* NEED_PATCH */),
30983                    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", Chatbotvue_type_template_id_7babacea_hoisted_9, [
30984                      (0,vue_esm_bundler/* createElementVNode */.Lk)("ul", Chatbotvue_type_template_id_7babacea_hoisted_10, [
30985                        (0,vue_esm_bundler/* createElementVNode */.Lk)("li", Chatbotvue_type_template_id_7babacea_hoisted_11, [
30986                          (0,vue_esm_bundler/* createElementVNode */.Lk)("span", Chatbotvue_type_template_id_7babacea_hoisted_12, [
30987                            (0,vue_esm_bundler/* createElementVNode */.Lk)("i", {
30988                              class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon '+ $options.SP_CONSTANTS.THEME.CHATBOT_ICON)
30989                            }, null, 2 /* CLASS */)
30990                          ]),
30991                          (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
30992                            class: "gs_chatbot__chatbubble-incoming",
30993                            innerHTML: $options.greeting || $options.getLabel('chatbot.default_greeting')
30994                          }, null, 8 /* PROPS */, Chatbotvue_type_template_id_7babacea_hoisted_13)
30995                        ]),
30996                        ((0,vue_esm_bundler/* openBlock */.uX)(true), (0,vue_esm_bundler/* createElementBlock */.CE)(vue_esm_bundler/* Fragment */.FK, null, (0,vue_esm_bundler/* renderList */.pI)($data.chatHistory, (message) => {
30997                          return ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("li", {
30998                            tabindex: "0",
30999                            class: (0,vue_esm_bundler/* normalizeClass */.C4)(["chatbot__chat", 'chatbot__chat--' + (message.role === 'user' ? 'outgoing' : 'incoming')])
31000                          }, [
31001                            (message.role === 'assistant')
31002                              ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("span", Chatbotvue_type_template_id_7babacea_hoisted_14, [
31003                                  (0,vue_esm_bundler/* createElementVNode */.Lk)("i", {
31004                                    class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon '+ $options.SP_CONSTANTS.THEME.CHATBOT_ICON)
31005                                  }, null, 2 /* CLASS */)
31006                                ]))
31007                              : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true),
31008                            (message.role === 'assistant')
31009                              ? ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", {
31010                                  key: 1,
31011                                  class: (0,vue_esm_bundler/* normalizeClass */.C4)(message.content === $options.getLabel('chatbot.error_message') ? 'gs_chatbot__chatbubble-error' : 'gs_chatbot__chatbubble-incoming'),
31012                                  ref_for: true,
31013                                  ref: $options.setLastMessage
31014                                }, [
31015                                  _cache[8] || (_cache[8] = (0,vue_esm_bundler/* createElementVNode */.Lk)("span", { class: "access-hide" }, "Chatbot sagt, ", -1 /* CACHED */)),
31016                                  (0,vue_esm_bundler/* createElementVNode */.Lk)("span", {
31017                                    innerHTML: $options.formatBotResponse(message.content)
31018                                  }, null, 8 /* PROPS */, Chatbotvue_type_template_id_7babacea_hoisted_15)
31019                                ], 2 /* CLASS */))
31020                              : ((0,vue_esm_bundler/* openBlock */.uX)(), (0,vue_esm_bundler/* createElementBlock */.CE)("div", Chatbotvue_type_template_id_7babacea_hoisted_16, [
31021                                  _cache[9] || (_cache[9] = (0,vue_esm_bundler/* createElementVNode */.Lk)("span", { class: "access-hide" }, "User sagt, ", -1 /* CACHED */)),
31022                                  (0,vue_esm_bundler/* createTextVNode */.eW)((0,vue_esm_bundler/* toDisplayString */.v_)(message.content), 1 /* TEXT */)
31023                                ]))
31024                          ], 2 /* CLASS */))
31025                        }), 256 /* UNKEYED_FRAGMENT */))
31026                      ], 512 /* NEED_PATCH */),
31027                      (0,vue_esm_bundler/* createElementVNode */.Lk)("div", Chatbotvue_type_template_id_7babacea_hoisted_17, (0,vue_esm_bundler/* toDisplayString */.v_)($options.getLabel('chatbot.disclaimer')), 1 /* TEXT */)
31028                    ]),
31029                    (0,vue_esm_bundler/* createElementVNode */.Lk)("div", {
31030                      class: (0,vue_esm_bundler/* normalizeClass */.C4)(["chatbot__chat-input gs_chatbot__chat-input", $data.focus ? 'gs_chatbot__chat-input-focused' : ''])
31031                    }, [
31032                      (0,vue_esm_bundler/* withDirectives */.bo)((0,vue_esm_bundler/* createElementVNode */.Lk)("textarea", {
31033                        "aria-label": $options.getLabel('chatbot.placeholder_input_message'),
31034                        class: "chatbot__textarea gs_chatbot__input-textarea",
31035                        "onUpdate:modelValue": _cache[2] || (_cache[2] = $event => (($data.userInput) = $event)),
31036                        placeholder: $options.getLabel('chatbot.placeholder_input_message'),
31037                        spellcheck: "false",
31038                        required: "",
31039                        onFocus: _cache[3] || (_cache[3] = $event => ($data.focus = true)),
31040                        onBlur: _cache[4] || (_cache[4] = $event => ($data.focus = false)),
31041                        onInput: _cache[5] || (_cache[5] = $event => ($options.resizeTextarea())),
31042                        onKeydown: _cache[6] || (_cache[6] = (0,vue_esm_bundler/* withKeys */.jR)((...args) => ($options.handleEnter && $options.handleEnter(...args)), ["enter"])),
31043                        ref: "chatInput"
31044                      }, null, 40 /* PROPS, NEED_HYDRATION */, Chatbotvue_type_template_id_7babacea_hoisted_18), [
31045                        [vue_esm_bundler/* vModelText */.Jo, $data.userInput]
31046                      ]),
31047                      (0,vue_esm_bundler/* createElementVNode */.Lk)("button", {
31048                        "aria-label": $options.getLabel('accessibility.send_message'),
31049                        class: "chatbot__send-button gs_chatbot__send-button",
31050                        onClick: _cache[7] || (_cache[7] = $event => ($options.handleInput()))
31051                      }, [
31052                        (0,vue_esm_bundler/* createElementVNode */.Lk)("i", {
31053                          class: (0,vue_esm_bundler/* normalizeClass */.C4)('shopandicon '+ $options.SP_CONSTANTS.THEME.SEND_BUTTON_ICON)
31054                        }, null, 2 /* CLASS */)
31055                      ], 8 /* PROPS */, Chatbotvue_type_template_id_7babacea_hoisted_19)
31056                    ], 2 /* CLASS */)
31057                  ], 8 /* PROPS */, Chatbotvue_type_template_id_7babacea_hoisted_6))
31058                : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
31059            ]),
31060            _: 1 /* STABLE */
31061          })
31062        ], 2 /* CLASS */)
31063      ]))
31064    : (0,vue_esm_bundler/* createCommentVNode */.Q3)("v-if", true)
31065}
31066;// ./vue/components/Chatbot.vue?vue&type=template&id=7babacea
31067
31068;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/components/Chatbot.vue?vue&type=script&lang=js
31069
31070/* harmony default export */ 
31070const Chatbotvue_type_script_lang_js = ({
31071  name: 'Chatbot',
31072  data() {
31073    return {
31074      userInput: '',      
31075      chatHistory: [],
31076      chatbotOpen: false,
31077      lastBotMessage: null,
31078      latestMessage: '',
31079      focus: false
31080    };
31081  },
31082  computed: {
31083    greeting() {
31084      return SP_CONSTANTS.SHOP.CHATBOT_GREETING;
31085    },
31086    isChatbotActive(){
31087      return SP_CONSTANTS.SHOP.IS_CHATBOT_ACTIVE && SP_CONSTANTS.SHOP.HAS_CHATBOT_FEATURE;
31088    },
31089    endpointUrl(){
31090      return `${SP_CONSTANTS.SHOP.API_PATH}/shops/${SP_CONSTANTS.SHOP.ID}/chatbotRequests`;
31091    },
31092    streamEndpointUrl(){
31093      return `${SP_CONSTANTS.SHOP.API_PATH}/shops/${SP_CONSTANTS.SHOP.ID}/chatbotRequests/stream`;
31094    },
31095    isMobile(){
31096      return window.innerWidth <= 575;
31097    },
31098    SP_CONSTANTS() {
31099			return SP_CONSTANTS;
31100		}
31101  },
31102  methods: {
31103    toggleChatbot() {    
31104      this.chatbotOpen = !this.chatbotOpen;
31105
31106      if(this.chatbotOpen){
31107        this.$nextTick(() => {
31108          this.scrollChatToBottom();
31109
31110          if(this.chatHistory.length > 0){
31111            this.$refs.chatInput.focus();
31112          }
31113        });
31114      }
31115    },
31116    resizeTextarea() {
31117      const textarea = this.$refs.chatInput;
31118      textarea.style.height = textarea.scrollHeight + 'px';
31119      if(!this.userInput) textarea.style.height = '';
31120    },
31121    handleEnter(e) {
31122      if (!e.shiftKey && window.innerWidth > 800) {
31123        e.preventDefault();
31124        this.handleInput();
31125      }
31126    },
31127    handleInput() {
31128      const message = this.userInput.trim();
31129      if (!message) return;
31130
31131      this.chatHistory.push({ role: 'user', content: message });
31132      this.userInput = '';
31133      this.resizeTextarea();
31134
31135      this.chatHistory.push({ role: 'assistant', content: this.getLabel('chatbot.thinking') });
31136      this.addMessageToChatbot();
31137
31138      this.$nextTick(() => {
31139        this.scrollChatToBottom();
31140      });
31141    },
31142    setLastMessage(element){
31143      this.lastBotMessage = element;
31144    },
31145    scrollChatToBottom() {
31146      const chatbox = this.$refs.chatbox;
31147      const headerHeight = this.$refs.header.offsetHeight;
31148
31149      if(this.lastBotMessage && this.lastBotMessage.offsetHeight > 450){
31150        chatbox.scrollTop = this.lastBotMessage.offsetTop - headerHeight - 10;
31151      } else {
31152        chatbox.scrollTo(0, chatbox.scrollHeight);
31153      }
31154    },
31155    addMessageToChatbot() {
31156      const assistantIndex = this.chatHistory.length - 1;
31157
31158      this.sendToServerStream(this.chatHistory, assistantIndex)
31159        .catch((err) => {
31160          console.error('Chatbot error:', err);
31161          const errorMessage = this.getLabel('chatbot.error_message');
31162          this.chatHistory[assistantIndex].content = errorMessage;
31163          this.latestMessage = errorMessage;
31164
31165          this.$nextTick(() => {
31166            this.scrollChatToBottom();
31167          });
31168        });
31169    },
31170    formatBotResponse(md) {
31171
31172      // HTML safety
31173      md = md
31174      .replace(/</g, '&lt;')
31175      .replace(/>/g, '&gt;');
31176
31177      // Convert markdown links [text](url) → <a href="url">text</a>
31178      md = md.replace(/\[([^\]]+)\]\(([^)]+)\)/g, '<a href="$2">$1</a>');
31179
31180      // Convert headings
31181      md = md.replace(/^# (.+)$/gm, '<strong>$1</strong>')
31182            .replace(/^## (.+)$/gm, '<strong>$1</strong>')
31183            .replace(/^### (.+)$/gm, '<strong>$1</strong>')
31184            .replace(/^#### (.+)$/gm, '<strong>$1</strong>')
31185            .replace(/^##### (.+)$/gm, '<strong>$1</strong>')
31186            .replace(/^###### (.+)$/gm, '<strong>$1</strong>');
31187
31188      // Convert bold and italic
31189      md = md.replace(/\*\*(.+?)\*\*/g, '<strong>$1</strong>')
31190            .replace(/\*(.+?)\*/g, '<em>$1</em>');
31191
31192      return md;
31193    },
31194    getLabel(name) {
31195        let [labelDomain, labelName] = name.toLowerCase().split('.');
31196        if (labels[labelDomain] && labels[labelDomain][labelName] && labels[labelDomain][labelName][SP_CONSTANTS.LOCALE]) {
31197            let labelValue = labels[labelDomain][labelName][SP_CONSTANTS.LOCALE];
31198            if (labelValue.indexOf('{{') >= 0 && this.variables) {
31199                for (let variable in this.variables) {
31200                    labelValue = labelValue.replace('{{'+variable+'}}', this.variables[variable]);
31201                }
31202            }
31203            return labelValue;
31204        } else if (labels[labelDomain] && labels[labelDomain][labelName] === undefined) {
31205            return labels[labelDomain]['error_occurred'][SP_CONSTANTS.LOCALE];
31206        } else {
31207            return this.labelString || this.name;
31208        }
31209    },
31210    async sendToServerStream(history, assistantIndex) {
31211      const messagesWithoutPlaceholder = history.filter((_, i) => i !== assistantIndex)
31212        .filter(m => m.content !== '');
31213      this.chatHistory[assistantIndex].content = '';
31214
31215      const response = await fetch(this.streamEndpointUrl, {
31216        method: "POST",
31217        headers: { "Content-Type": "application/json" },
31218        body: JSON.stringify({ messages: messagesWithoutPlaceholder })
31219      });
31220
31221      if (!response.ok) {
31222        throw new Error(`Server error ${response.status}`);
31223      }
31224
31225      const reader = response.body.getReader();
31226      const decoder = new TextDecoder();
31227      let buffer = '';
31228      let lastScrollTime = 0;
31229
31230      while (true) {
31231        const { done, value } = await reader.read();
31232        if (done) break;
31233
31234        buffer += decoder.decode(value, { stream: true });
31235        const lines = buffer.split('\n');
31236        buffer = lines.pop();
31237
31238        for (const line of lines) {
31239          const trimmed = line.trim();
31240          if (!trimmed || !trimmed.startsWith('data: ')) continue;
31241
31242          const data = trimmed.slice(6);
31243
31244          if (data === '[DONE]') {
31245            this.latestMessage = this.chatHistory[assistantIndex].content;
31246            this.$nextTick(() => { this.scrollChatToBottom(); });
31247            return;
31248          }
31249
31250          try {
31251            const parsed = JSON.parse(data);
31252            if (parsed.error) {
31253              throw new Error(parsed.message || 'Stream error');
31254            }
31255            if (parsed.token !== undefined) {
31256              this.chatHistory[assistantIndex].content += parsed.token;
31257
31258              const now = Date.now();
31259              if (now - lastScrollTime > 100) {
31260                lastScrollTime = now;
31261                this.$nextTick(() => { this.scrollChatToBottom(); });
31262              }
31263            }
31264          } catch (e) {
31265            if (e.message === 'Stream error') throw e;
31266          }
31267        }
31268      }
31269
31270      this.latestMessage = this.chatHistory[assistantIndex].content;
31271      this.$nextTick(() => { this.scrollChatToBottom(); });
31272    }
31273  },
31274  mounted() {
31275    window.addEventListener('keyup', e => {
31276      if(e.key === 'Escape'){
31277        this.chatbotOpen = false;
31278      }
31279    });
31280  }
31281});
31282
31283;// ./vue/components/Chatbot.vue?vue&type=script&lang=js
31284 
31285;// ./vue/components/Chatbot.vue
31286
31287
31288
31289
31290;
31291const Chatbot_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(Chatbotvue_type_script_lang_js, [['render',Chatbotvue_type_template_id_7babacea_render]])
31292
31293/* harmony default export */ const Chatbot = (Chatbot_exports_);
31294;// ./node_modules/vue-loader/dist/index.js??ruleSet[1].rules[4].use[0]!./vue/App.vue?vue&type=script&lang=js
31295
31296
31297
31298
31299
31300
31301
31302
31303
31304
31305
31306
31307/* harmony default export */ const Appvue_type_script_lang_js = ({
31308	name: 'App',
31309	components: {
31310		'cart-popup': CartPopup,
31311		'wishlist-popup': WishlistPopup,
31312		'cookie-consent': CookieConsent,
31313		'status-bar': StatusBar,
31314		'chatbot': Chatbot
31315	},
31316	computed: {
31317		showConsent() {
31318			// alert(SP_CONSTANTS.SHOP.SHOW_CC);
31319			return SP_CONSTANTS.SHOP.SHOW_CC;
31320		},
31321		SP_CONSTANTS() {
31322			return SP_CONSTANTS;
31323		}
31324	}, 
31325  	data() {
31326		return {
31327			userInteracted: false,
31328			isPreview: false
31329		}
31330	},
31331	watch: {
31332		// checkout cart items
31333		'$store.state.checkout.cartItems': function() {
31334			let cartItemsQuantity = 0;
31335			if (Array.isArray(this.$store.state.checkout.cartItems)) {
31336				for (let cartItem of this.$store.state.checkout.cartItems) {
31337					cartItemsQuantity += cartItem.quantity;
31338				}
31339			}
31340
31341			if (cartItemsQuantity > 0) {
31342				document.querySelectorAll('.header-toolbox__cart-counter').forEach(el => {
31343					el.classList.remove('access-hide');
31344					el.innerHTML = cartItemsQuantity;
31345				});
31346			} else {
31347				document.querySelectorAll('.header-toolbox__cart-counter').forEach(el => {
31348					el.classList.add('access-hide');
31349					el.innerHTML = 0;
31350				});
31351			}
31352			(0,SecureCookie/* SecureCookie */.o)('sp_cart_items_amount', cartItemsQuantity);
31353		},
31354	},
31355	methods: {
31356		isLoggedIn() {
31357			return ((0,SecureCookie/* SecureCookie */.o)('sp_customer_id') && (0,SecureCookie/* SecureCookie */.o)('sp_access_token')) ? true : false;
31358		},
31359		loadCart() {
31360			if (SP_CONSTANTS.SHOP.WEBSITE_MODE === '1') return;
31361			this.$store.dispatch('checkout/loadOrCreateNew');
31362		},
31363		loadSliders() {
31364			let self = this;
31365
31366			document.querySelectorAll('.product-collection--slider .product-collection__products').forEach(element => {
31367				let prevArrow = element.parentElement.parentElement.querySelector('.product-collection__arrow-prev');
31368				let nextArrow = element.parentElement.parentElement.querySelector('.product-collection__arrow-next');
31369				let numberOfColumns = JSON.parse(element.parentElement.parentElement.parentElement.getAttribute('data-number-of-columns'));
31370
31371				jQuery(element).slick({
31372					slidesToShow: numberOfColumns.xl,
31373					prevArrow: jQuery(prevArrow),
31374					nextArrow: jQuery(nextArrow),
31375					responsive: [
31376						{ breakpoint: 1199, settings: { slidesToShow: numberOfColumns.lg } },
31377						{ breakpoint: 991, settings: { slidesToShow: numberOfColumns.md } },
31378						{ breakpoint: 767, settings: { slidesToShow: numberOfColumns.sm } },
31379						{ breakpoint: 577, settings: { slidesToShow: numberOfColumns.xs } }
31380					]
31381				});
31382			});
31383
31384			document.querySelectorAll('.category-collection--slider .category-collection__categories').forEach(element => {
31385				let prevArrow = element.parentElement.parentElement.querySelector('.category-collection__arrow-prev');
31386				let nextArrow = element.parentElement.parentElement.querySelector('.category-collection__arrow-next');
31387				let numberOfColumns = JSON.parse(element.parentElement.parentElement.getAttribute('data-number-of-columns'));
31388
31389				jQuery(element).slick({
31390					slidesToShow: numberOfColumns.xl,
31391					prevArrow: jQuery(prevArrow),
31392					nextArrow: jQuery(nextArrow),
31393					responsive: [
31394						{ breakpoint: 1199, settings: { slidesToShow: numberOfColumns.lg } },
31395						{ breakpoint: 991, settings: { slidesToShow: numberOfColumns.md } },
31396						{ breakpoint: 767, settings: { slidesToShow: numberOfColumns.sm } },
31397						{ breakpoint: 577, settings: { slidesToShow: numberOfColumns.xs } }
31398					]
31399				});
31400			});
31401
31402			const setSliderDotClasses = (slider, sliderDotClass) => {
31403				// remove the active class from all dots
31404				let classes = sliderDotClass.split(' ');
31405				let cleanedClasses = [];
31406				for (let className of classes) {
31407					if (!className.includes('dot--active')) {
31408						cleanedClasses.push(className);
31409					}
31410				}
31411				sliderDotClass = cleanedClasses.join(' ');
31412
31413				let sliderDotClassActive = sliderDotClass.replaceAll('dot', 'dot--active');
31414				let sliderEl = slider[0];
31415				if (!sliderEl) return;
31416				sliderEl.querySelectorAll('.sp-slider__dots button').forEach(btn => {
31417					sliderDotClass.split(' ').filter(c => c).forEach(c => btn.classList.remove(c));
31418					sliderDotClassActive.split(' ').filter(c => c).forEach(c => btn.classList.remove(c));
31419				});
31420				sliderEl.querySelectorAll('.sp-slider__dots .slick-active button').forEach(btn => {
31421					sliderDotClassActive.split(' ').filter(c => c).forEach(c => btn.classList.add(c));
31422				});
31423				sliderEl.querySelectorAll('.sp-slider__dots li:not(.pause-list-item) button').forEach(btn => {
31424					sliderDotClass.split(' ').filter(c => c).forEach(c => btn.classList.add(c));
31425				});
31426			};
31427
31428			let initializeCarousel = function(element) {
31429				let prevArrow = element.parentElement.parentElement.querySelector('.content-container__slider-arrow-prev');
31430				let nextArrow = element.parentElement.parentElement.querySelector('.content-container__slider-arrow-next');
31431
31432				let sliderEl = element.parentElement.parentElement;
31433				let slideSpeed = sliderEl.getAttribute('data-slide-speed') || 5000;
31434				let animationDuration = sliderEl.getAttribute('data-animation-duration') || 300;
31435				let fade = Boolean(sliderEl.getAttribute('data-fade')) || false;
31436				let easing = sliderEl.getAttribute('data-easing') || 'ease';
31437				let slidesToShow = sliderEl.getAttribute('data-slides-to-show') || 1;
31438				let autoplay = Boolean(Number(sliderEl.getAttribute('data-autoplay'))) || false;
31439				let hasDots = Boolean(Number(sliderEl.getAttribute('data-has-dots')));
31440
31441				let pauseClass = sliderEl.getAttribute('data-pause-class') || 'sp-slider__pause';
31442				let sliderId = sliderEl.getAttribute('data-id');
31443
31444				const numberOfColumnLogic = {
31445					1: { xl: 1, lg: 1, md: 1, sm: 1, xs: 1 },
31446					2: { xl: 2, lg: 2, md: 2, sm: 2, xs: 1 },
31447					3: { xl: 3, lg: 3, md: 2, sm: 2, xs: 1 },
31448					4: { xl: 4, lg: 4, md: 2, sm: 2, xs: 2 },
31449					5: { xl: 5, lg: 5, md: 4, sm: 3, xs: 2 },
31450					6: { xl: 6, lg: 6, md: 5, sm: 4, xs: 3 },
31451					7: { xl: 7, lg: 7, md: 5, sm: 4, xs: 3 },
31452					8: { xl: 8, lg: 8, md: 6, sm: 6, xs: 4 },
31453					9: { xl: 9, lg: 9, md: 8, sm: 6, xs: 4 },
31454					10: { xl: 10, lg: 10, md: 8, sm: 5, xs: 5 }
31455				};
31456
31457				let numberOfColumns = numberOfColumnLogic[slidesToShow];
31458
31459				let slider = jQuery(element).slick({
31460					slidesToShow: numberOfColumns.xl,
31461					prevArrow: jQuery(prevArrow),
31462					nextArrow: jQuery(nextArrow),
31463					autoscroll: true,
31464					autoplay: autoplay,
31465					pauseOnHover: false,
31466					cssEase: easing,
31467					dots: hasDots,
31468					dotsClass: 'sp-slider__dots gs_content-container-carousel__dots',
31469					autoplaySpeed: slideSpeed,
31470					speed: animationDuration,
31471					fade: fade,
31472					responsive: [
31473						{ breakpoint: 1199, settings: { slidesToShow: numberOfColumns.lg } },
31474						{ breakpoint: 991, settings: { slidesToShow: numberOfColumns.md } },
31475						{ breakpoint: 767, settings: { slidesToShow: numberOfColumns.sm } },
31476						{ breakpoint: 577, settings: { slidesToShow: numberOfColumns.xs } }
31477					]
31478				});
31479
31480				let sliderDotClass = sliderEl.getAttribute('data-dot-class') || '';
31481
31482				setTimeout(() => {
31483					// 100 ms timeout to make sure the dots are rendered.
31484					// The only onload function for the slider is .on('init') but it is also too early
31485					setSliderDotClasses(slider, sliderDotClass);
31486				}, 100);
31487
31488				slider.on('afterChange', function() {
31489					setSliderDotClasses(slider, sliderDotClass);
31490				});
31491
31492				document.querySelectorAll('.sp-slider__dots button').forEach(btn => btn.classList.add('sp-slider__dot'));
31493				slider.on('reInit', function(slick) {
31494					// add pause button to slider
31495					setTimeout(_ => {
31496						let sliderElInner = slider[0];
31497						if (!sliderElInner) return;
31498						if (sliderElInner.querySelectorAll('.sp-slider__dots').length <= 0) {
31499							sliderElInner.insertAdjacentHTML('beforeend', '<ul class="sp-slider__dots"></ul>');
31500						}
31501						let dots = sliderElInner.querySelector('.sp-slider__dots');
31502						if (dots) {
31503							dots.insertAdjacentHTML('afterbegin',
31504								'<li role="presentation" class="pause-list-item"><button class="'+pauseClass+'" title="Pause" aria-label="Pause" aria-pressed="false" onclick="stopSlider(\''+sliderId+'\')"><i class="shopandicon ' + SP_CONSTANTS.THEME.SLIDER_PAUSE_ICON + '"></i></button></li>'
31505							);
31506						}
31507					}, 100);
31508				});
31509			};
31510
31511			document.querySelectorAll('.content-container__slider .content-container__slides').forEach(initializeCarousel);
31512
31513			document.addEventListener('content-section-refresh', function(e) {
31514				let sectionMatchcode = e.detail.sectionMatchcode;
31515				document.querySelectorAll('[data-section-matchcode="'+sectionMatchcode+'"] .content-container__slider .content-container__slides').forEach(initializeCarousel);
31516			});
31517
31518			document.querySelectorAll('.sp-slider-wrapper').forEach(wrapper => {
31519				let prevArrow = wrapper.querySelector('.sp-slide__arrow-prev');
31520				let nextArrow = wrapper.querySelector('.sp-slide__arrow-next');
31521
31522				let slideSpeed = wrapper.getAttribute('data-slide-speed') || 5000;
31523				let animationDuration = wrapper.getAttribute('data-animation-duration') || 300;
31524				let fade = Boolean(wrapper.getAttribute('data-fade')) || false;
31525				let easing = wrapper.getAttribute('data-easing') || 'ease';
31526
31527				let pauseClass = wrapper.getAttribute('data-pause-class') || 'sp-slider__pause';
31528				let hasPause = Boolean(Number(wrapper.getAttribute('data-has-pause'))) || false;
31529				let sliderId = wrapper.getAttribute('data-id');
31530
31531				const slider = jQuery(wrapper).find('.sp-slider');
31532
31533				slider.slick({
31534					slidesToShow: 1,
31535					autoscroll: true,
31536					autoplay: false,
31537					pauseOnHover: false,
31538					cssEase: easing,
31539					dots: Boolean(Number(wrapper.getAttribute('data-has-dots'))), // str "0"/"1" to nr to bool
31540					dotsClass: 'sp-slider__dots',
31541					autoplaySpeed: slideSpeed,
31542					speed: animationDuration,
31543					prevArrow: jQuery(prevArrow),
31544					nextArrow: jQuery(nextArrow),
31545					fade: fade
31546				});
31547
31548				if (hasPause) {
31549					slider.on('reInit', function(slick) {
31550						// add pause button to slider
31551						setTimeout(_ => {
31552							let sliderElInner = slider[0];
31553							if (!sliderElInner) return;
31554							if (sliderElInner.querySelectorAll('.sp-slider__dots').length <= 0) {
31555								sliderElInner.insertAdjacentHTML('beforeend', '<ul class="sp-slider__dots"></ul>');
31556							}
31557							let dots = sliderElInner.querySelector('.sp-slider__dots');
31558							if (dots) {
31559								dots.insertAdjacentHTML('afterbegin',
31560									'<li role="presentation" class="pause-list-item"><button class="'+pauseClass+'" title="Pause" aria-label="Pause" aria-pressed="false" onclick="stopSlider(\''+sliderId+'\')"><i class="shopandicon ' + SP_CONSTANTS.THEME.SLIDER_PAUSE_ICON + '"></i></button></li>'
31561								);
31562							}
31563						}, 100);
31564					});
31565				}
31566
31567				let sliderDotClass = wrapper.getAttribute('data-dot-class') || '';
31568
31569				setTimeout(() => {
31570					// 100 ms timeout to make sure the dots are rendered.
31571					// The only onload function for the slider is .on('init') but it is also too early
31572					setSliderDotClasses(slider, sliderDotClass);
31573				}, 100);
31574
31575				slider.on('afterChange', function() {
31576					setSliderDotClasses(slider, sliderDotClass);
31577				});
31578
31579				document.querySelectorAll('.sp-slider__dots button').forEach(btn => btn.classList.add('sp-slider__dot'));
31580				setSliderDotClasses(slider, sliderDotClass);
31581			});
31582		}
31583	},
31584	async mounted() {
31585		if ((0,SecureCookie/* SecureCookie */.o)('previewToken') && !window.location.search.includes('themeEditor')) {
31586			this.isPreview = true;
31587		}
31588
31589		frontend_trigger();
31590
31591		let self = this;
31592		let scrollPos = window.scrollY;
31593
31594		// add special class for rounded borders on all elements that are not completely full width
31595		const addSpecialNonFullWidthClass = function() {
31596			let sectionContainers = document.querySelectorAll('[class*="gs_content-section"] > [class*="container"]');
31597			sectionContainers.forEach((container) => {
31598				const containerRect = container.getBoundingClientRect();
31599				const isFullWidth = containerRect.left <= 0 && containerRect.right >= window.innerWidth;
31600	
31601				if (!isFullWidth) {
31602					container.classList.add("not-completely-full-width"); // Add special class if not touching sides
31603				} else {
31604					container.classList.remove("not-completely-full-width"); // Remove special class if touching sides
31605				}
31606			});
31607		};
31608		addSpecialNonFullWidthClass();
31609		window.addEventListener('resize', addSpecialNonFullWidthClass);
31610		
31611
31612		document.addEventListener('click', function(e) {
31613			self.userInteracted = true;
31614		});
31615		
31616		document.addEventListener('keydown', function(e) {
31617			self.userInteracted = true;
31618		});
31619
31620		document.addEventListener('mousemove', () => {
31621			this.userInteracted = true;
31622		});
31623
31624		document.addEventListener('scroll', () => {
31625			this.userInteracted = true;
31626
31627			// if scrollPos changes from 0 to a value or vice-versa, toggle sticky logo class
31628			if (scrollPos === 0 && window.scrollY > 0) {
31629				document.querySelectorAll('.header-logo--has-sticky').forEach(el => el.classList.add('header-logo--sticky-visible'));
31630			} else if (scrollPos > 0 && window.scrollY === 0) {
31631				document.querySelectorAll('.header-logo--has-sticky').forEach(el => el.classList.remove('header-logo--sticky-visible'));
31632			}
31633
31634			scrollPos = window.scrollY;
31635		});
31636
31637		var motionCount = 0;
31638		window.addEventListener('devicemotion', () => {
31639			if (motionCount > 2) {
31640				this.userInteracted = true;
31641			}
31642			motionCount++;
31643		});
31644
31645		let toggleMenuFunction = function(closeOnly) {
31646			if (closeOnly) {
31647				document.querySelectorAll('.mobile-menu').forEach(el => el.classList.remove('mobile-menu--active'));
31648				document.querySelectorAll('.mobile-menu__overlay').forEach(el => el.classList.remove('mobile-menu__overlay--active'));
31649			} else {
31650				document.querySelectorAll('.mobile-menu').forEach(el => el.classList.toggle('mobile-menu--active'));
31651				document.querySelectorAll('.mobile-menu__overlay').forEach(el => el.classList.toggle('mobile-menu__overlay--active'));
31652			}
31653			// if inactive give tabindex -1
31654
31655			let mobileMenu = document.querySelector('.mobile-menu');
31656			let isActive = mobileMenu && mobileMenu.classList.contains('mobile-menu--active');
31657			let containers = document.querySelectorAll('.mobile-menu, .mobile-menu__overlay');
31658
31659			if (isActive) {
31660				containers.forEach(el => el.setAttribute('aria-hidden', 'false'));
31661				containers.forEach(container => {
31662					container.querySelectorAll('a,button').forEach(el => el.setAttribute('tabindex', '0'));
31663				});
31664				document.querySelectorAll('.mobile-menu__overlay button').forEach(el => el.setAttribute('aria-hidden', 'false'));
31665			} else {
31666				containers.forEach(el => el.setAttribute('aria-hidden', 'true'));
31667				containers.forEach(container => {
31668					container.querySelectorAll('a,button').forEach(el => el.setAttribute('tabindex', '-1'));
31669				});
31670				document.querySelectorAll('.mobile-menu__overlay button').forEach(el => el.setAttribute('aria-hidden', 'true'));
31671			}
31672		};
31673
31674		document.querySelectorAll('.mobile-button,.mobile-menu__close,.mobile-menu__overlay').forEach(el => {
31675			el.addEventListener('click', function(e) {
31676				if (e.currentTarget.closest('.header--menu-button-left')) {
31677					// mobile button is on the left side and we clicked the open button
31678					// for accessibility move focus to the close button as otherwise we need to tab through the whole header
31679					document.querySelector('.mobile-menu__close').focus();
31680				}
31681
31682				let isSmartphone = window.matchMedia("(max-width: 767px)").matches;
31683				let isTablet = window.matchMedia("(min-width: 768px) and (max-width: 1199px)").matches;
31684				let isDesktop = window.matchMedia("(min-width: 1200px)").matches;
31685				let isCustomMenu = (
31686					SP_CONSTANTS.THEME.MENU_BUTTON_XL_POPUP_ID && isDesktop ||
31687					SP_CONSTANTS.THEME.MENU_BUTTON_MD_POPUP_ID && isTablet ||
31688					SP_CONSTANTS.THEME.MENU_BUTTON_XS_POPUP_ID && isSmartphone
31689				);
31690
31691				if (isCustomMenu) {
31692					if (isDesktop) {
31693						togglePopup(SP_CONSTANTS.THEME.MENU_BUTTON_XL_POPUP_ID)
31694					} else if (isTablet) {
31695						togglePopup(SP_CONSTANTS.THEME.MENU_BUTTON_MD_POPUP_ID)
31696					} else {
31697						togglePopup(SP_CONSTANTS.THEME.MENU_BUTTON_XS_POPUP_ID)
31698					}
31699				} else {
31700					toggleMenuFunction();
31701				}
31702			});
31703		});
31704
31705		document.querySelectorAll('.mobile-menu__close').forEach(el => {
31706			el.addEventListener('keydown', function(e) {
31707				if (e.key === 'Enter') {
31708					toggleMenuFunction();
31709				}
31710			});
31711		});
31712
31713		// delegated click on links inside .mobile-menu
31714		document.querySelectorAll('.mobile-menu').forEach(menu => {
31715			menu.addEventListener('click', function(e) {
31716				let link = e.target.closest('a');
31717				if (!link || !menu.contains(link)) return;
31718				let href = link.getAttribute('href');
31719				if (!href) {
31720					return;
31721				}
31722				let isHashOnly = href.indexOf('#') === 0;
31723				let isSamePageHash = href.indexOf('#') > 0 && href.split('#')[0] === window.location.pathname;
31724				if (isHashOnly || isSamePageHash) {
31725					toggleMenuFunction(true);
31726				}
31727			});
31728		});
31729
31730		document.querySelectorAll('.header-toolbox__search a').forEach(el => {
31731			el.addEventListener('click', function() {
31732				document.querySelectorAll('.search-header').forEach(s => s.classList.toggle('search-header--active'));
31733				let isActive = document.querySelector('.search-header')?.classList.contains('search-header--active');
31734				document.querySelectorAll('.header-toolbox__search a').forEach(a => a.setAttribute('aria-expanded', String(!!isActive)));
31735				if (isActive) {
31736					setTimeout(function() {
31737						document.querySelector('.header-search__input')?.focus();
31738					}, 50);
31739				}
31740			});
31741		});
31742
31743		document.addEventListener('click', function(e) {
31744			let searchHeader = document.querySelector('.search-header');
31745			if (!searchHeader || !searchHeader.classList.contains('search-header--active')) return;
31746			if (e.target.closest('.search-header') || e.target.closest('.header-toolbox__search')) return;
31747			document.querySelectorAll('.search-header').forEach(s => s.classList.remove('search-header--active'));
31748			document.querySelectorAll('.header-toolbox__search a').forEach(a => a.setAttribute('aria-expanded', 'false'));
31749		});
31750
31751		document.querySelectorAll('.header-search__icon').forEach(el => {
31752			el.addEventListener('click', function() {
31753				// if something is in the search input field, then submit else focus
31754				let input = document.querySelector('.header-search__input');
31755				if (input && input.value.length > 0) {
31756					document.querySelector('.header-search__form')?.requestSubmit();
31757				} else {
31758					input?.focus();
31759				}
31760			});
31761		});
31762
31763		if (document.querySelectorAll('#search-header').length === 0 || window.innerWidth < 768) {
31764			document.querySelectorAll('a[href="#search-header"]').forEach(el => {
31765				el.addEventListener('click', function() {
31766					document.querySelectorAll('.search-header').forEach(s => s.classList.add('search-header--active'));
31767					document.querySelectorAll('.header-toolbox__search a').forEach(a => a.setAttribute('aria-expanded', 'true'));
31768					setTimeout(function() {
31769						document.querySelector('.header-search__input')?.focus();
31770					}, 50);
31771				});
31772			});
31773		}
31774
31775		// replace the search icon with a loading icon
31776		document.querySelectorAll('.header-search__form').forEach(form => {
31777			form.addEventListener('submit', function(e) {
31778				let icon = form.parentElement?.querySelector('.header-search__icon');
31779				if (!icon) return;
31780				// remove all classes starting with spi_ (search icon can be user determined, default would be spi_search)
31781				[...icon.classList].forEach(c => {
31782					if (c.startsWith('spi_')) icon.classList.remove(c);
31783				});
31784				icon.classList.add(SP_CONSTANTS.THEME.LOADING_ICON);
31785				icon.classList.add('header-search__icon--loading');
31786			});
31787		});
31788
31789		// category navigation
31790		let activeLink = document.querySelector('.category-navigation__sublinks .category-navigation__active');
31791		if (activeLink && activeLink.parentElement) {
31792			activeLink.parentElement.style.display = 'block';
31793		}
31794
31795		document.querySelectorAll('.navigations--side').forEach(nav => {
31796			let isEmpty = !nav.innerHTML.trim();
31797			if (!isEmpty) {
31798				nav.insertAdjacentHTML('afterbegin',
31799					'<button class="gs_button__default__text gs_button__category-navigation__text sp-button"><i class="shopandicon ' + SP_CONSTANTS.THEME.CATEGORY_NAVIGATION_ICON + ' gs_button__default__icon gs_button__category-navigation__icon"></i> '+labels['catalog']['navigation'][SP_CONSTANTS.LOCALE]+'</button>'
31800				);
31801			}
31802		});
31803
31804		document.querySelectorAll('.gs_button__category-navigation__text').forEach(el => {
31805			el.addEventListener('click', function() {
31806				document.querySelectorAll('.category-navigation__container').forEach(c => c.classList.toggle('category-navigation--visible'));
31807			});
31808		});
31809
31810		// FIXME
31811		if (document.body.classList.contains('profischutz')) {
31812			document.querySelectorAll('.category-navigation__sublinks').forEach(el => el.style.display = '');
31813		}
31814
31815
31816		document.querySelectorAll('.product-collection__add-to-wishlist').forEach(el => {
31817			el.addEventListener('click', async function(e) {
31818				e.preventDefault();
31819				let id = e.currentTarget.getAttribute('data-id');
31820				await self.$store.dispatch('customer/load');
31821				self.$store.dispatch('customer/addToWishlist', {productId: id});
31822				self.$store.state.app.isWishlistPopupOpen = true;
31823				setTimeout(() => {
31824					document.querySelector('.wishlist-popup')?.focus();
31825				}, 100);
31826			});
31827		});
31828
31829
31830		// FIXME load cart: Replace with minimal call
31831
31832		// if (!cookie('sp_cart_items_amount')) {
31833		// 	await this.$store.dispatch('checkout/load');
31834		// }
31835
31836		if (self.$store.state.checkout.cartItems) {
31837			let cartItemsQuantity = (0,SecureCookie/* SecureCookie */.o)('sp_cart_items_amount');
31838
31839			if (cartItemsQuantity > 0) {
31840				document.querySelectorAll('.header-toolbox__cart-counter').forEach(el => {
31841					el.classList.remove('access-hide');
31842					el.innerHTML = cartItemsQuantity;
31843				});
31844			} else {
31845				document.querySelectorAll('.header-toolbox__cart-counter').forEach(el => {
31846					el.classList.add('access-hide');
31847					el.innerHTML = 0;
31848				});
31849			}
31850		}
31851
31852
31853		const onDomReady = function() {
31854			let originalHeights = [];
31855			document.querySelectorAll('header .header-menu__sub-menu').forEach(submenu => {
31856				let inner = submenu.querySelector('.header-menu__sub-menu-inner');
31857				originalHeights.push(inner ? getComputedStyle(inner).maxHeight : '');
31858				calculateSubmenu(submenu);
31859			});
31860			// reset to original height on resize
31861			window.addEventListener('resize', function() {
31862				document.querySelectorAll('header .header-menu__sub-menu').forEach((submenu, index) => {
31863					let inner = submenu.querySelector('.header-menu__sub-menu-inner');
31864					if (inner) inner.style.maxHeight = originalHeights[index];
31865					calculateSubmenu(submenu);
31866				});
31867			});
31868
31869
31870			function calculateSubmenu(submenu) {
31871				let menuItem = submenu.parentElement;
31872				submenu.style.display = 'block';
31873				submenu.style.pointerEvents = 'none';
31874
31875				let menuWidth = submenu.offsetWidth;
31876				let menuItemWidth = menuItem.offsetWidth;
31877				let dropdownRect = submenu.getBoundingClientRect();
31878				let maximumXPosition = dropdownRect.left + window.scrollX + menuWidth;
31879				let inner = submenu.querySelector('.header-menu__sub-menu-inner');
31880				let menuItemLast = inner ? inner.lastElementChild : null;
31881				let menuItemSpillsOver = false;
31882				if (menuItemLast) {
31883					let menuItemLastPosition = menuItemLast.offsetLeft - parseFloat(getComputedStyle(menuItemLast).marginLeft) + menuItemLast.offsetWidth;
31884					menuItemSpillsOver = menuItemLastPosition-5 > maximumXPosition;
31885				}
31886
31887				// full width menus tend to calculate to "spilling over" because of rounding errors, so we add a small threshold
31888				const SPILLOVER_THRESHOLD = 2;
31889
31890				if (menuItemSpillsOver) {
31891					// does overflow the menu on the side, this only happens with full-width menus
31892					let height = 100;
31893					const maxHeight = 3000;
31894					submenu.style.transform = 'translateX(0)';
31895					setDropdownHeight(submenu, height, maxHeight);
31896				} else if (submenu.offsetLeft - parseFloat(getComputedStyle(submenu).marginLeft) + menuWidth > document.body.clientWidth + SPILLOVER_THRESHOLD) {
31897					submenu.style.transform = 'translateX(calc(-100% + '+menuItemWidth+'px))';
31898				} else {
31899					submenu.style.transform = 'translateX(0)';
31900				}
31901
31902				// if the menuItem is in grid set the left position accordingly
31903				if (menuItem.classList.contains('header-menu__item--mode-in-grid')) {
31904					let screenWidth = document.body.clientWidth;
31905					let left = (screenWidth-1110)/2;
31906					submenu.style.left = left+'px';
31907					submenu.style.transform = 'translateX(0)';
31908				}
31909
31910				submenu.style.display = '';
31911				submenu.style.pointerEvents = '';
31912			}
31913
31914			// determine the height of the dropdown:
31915			// try 100px height and see if it fits
31916			// if a menu item spills over the right edge of the menu increase by 100px
31917			// stop the loop if no menu item does not spill over the right edge of the menu or if the height is greater than 3000px
31918			async function setDropdownHeight(dropdown, height, maxHeight) {
31919				dropdown.style.display = 'block';
31920				dropdown.style.pointerEvents = 'none';
31921				let inner = dropdown.querySelector('.header-menu__sub-menu-inner');
31922				if (inner) inner.style.maxHeight = height+'px';
31923
31924				let maximumXPosition = window.scrollX + dropdown.offsetWidth;
31925
31926				dropdown.style.display = '';
31927				dropdown.style.pointerEvents = '';
31928
31929				// wait for css to be applied, 10ms would be enough but 100 to be sure
31930				setTimeout(function () {
31931					dropdown.style.display = 'block';
31932					let menuItemLast = inner ? inner.lastElementChild : null;
31933					if (menuItemLast) {
31934						let menuItemLastPosition = menuItemLast.offsetLeft - parseFloat(getComputedStyle(menuItemLast).marginLeft) + menuItemLast.offsetWidth;
31935						let menuItemSpillsOver = menuItemLastPosition-5 > maximumXPosition; // subtract 5 px for slight browser calculation issues
31936						height += 100;
31937						if (menuItemSpillsOver && height < maxHeight) setDropdownHeight(dropdown, height, maxHeight);
31938					}
31939					dropdown.style.display = '';
31940				}, 100);
31941			}
31942
31943			
31944
31945
31946			document.querySelectorAll('.form-element__form-element--newsletter').forEach(form => {
31947				form.addEventListener('submit', async function(e) {
31948					e.preventDefault();
31949					let values = {};
31950					form.querySelectorAll('input').forEach(input => {
31951						values[input.name] = input.value;
31952					});
31953
31954
31955					// instead of a store we use a service as the form is built with jquery
31956					let data = null;
31957					try {
31958						data = await misc_NewsletterSubscriptionService.send(values);
31959					} catch (err) {
31960						data = null;
31961					}
31962					// No parsable answer (network error, HTML error page) is a
31963					// failure too; without this the handler threw and the
31964					// visitor saw nothing happen.
31965					if (!data || typeof data !== 'object') {
31966						data = {error: true, code: 'ERROR_OCCURRED'};
31967					}
31968
31969
31970					let gdprCheckbox = form.querySelector('input[name="acceptsGdpr"]');
31971					if (!(gdprCheckbox && gdprCheckbox.checked)) {
31972						data.error = true;
31973						data.code = 'ACCEPTS_GDPR_IS_NOT_SET';
31974					}
31975
31976					let elementId = form.getAttribute('data-id');
31977
31978					if (form.querySelector('input[data-mod="h"]')?.value !== '' ||
31979						form.querySelector('input[data-mod="h2"]')?.value !== elementId ||
31980						form.querySelector('input[data-mod="h3"]')?.value !== '') {
31981						data.error = true;
31982						data.code = 'HP_ERROR';
31983					}
31984
31985					if (!data.error) {
31986						form.querySelectorAll('.form-element__input-row').forEach(el => el.style.display = 'none');
31987						form.querySelectorAll('.form-element__button-wrapper').forEach(el => el.style.display = 'none');
31988						let outer = form.parentElement?.parentElement;
31989						if (outer) {
31990							outer.querySelectorAll('.form-element__intro-text').forEach(el => el.style.display = 'none');
31991							outer.querySelectorAll('.form-element__success-text').forEach(el => el.style.display = '');
31992						}
31993					} else if (data.error) {
31994						if (data.code != null) {
31995							let errorMessage = misc_LabelService.getLabel('api_error.newsletter_subscription_'+String(data.code).toLowerCase());
31996
31997							let outer = form.parentElement?.parentElement;
31998							if (outer) {
31999								outer.querySelectorAll('.form-element__error-message').forEach(el => {
32000									el.style.display = '';
32001									el.innerHTML = errorMessage;
32002								});
32003							}
32004						}
32005					}
32006				});
32007			});
32008
32009
32010			// Has Submenu
32011			document.querySelectorAll('.header-menu--levels .header-menu__item-link--has-submenu').forEach(element => {
32012				element.addEventListener('click', function(e) {
32013					e.preventDefault();
32014					let menuItem = e.currentTarget.closest('.header-menu__item');
32015					let submenu = menuItem ? menuItem.querySelector('.header-menu__sub-menu') : null;
32016
32017					// fix the title bar padding (go full width and disregard parent padding)
32018					let mobileMenu = document.querySelector('.mobile-menu');
32019					if (mobileMenu) {
32020						let cs = getComputedStyle(mobileMenu);
32021						let paddingLeft = parseInt(cs.paddingLeft);
32022						let paddingTop = parseInt(cs.paddingTop);
32023						document.querySelectorAll('.header-menu__title-bar').forEach(el => {
32024							el.style.marginLeft = (-paddingLeft) + 'px';
32025							el.style.marginTop = (-paddingTop) + 'px';
32026							el.style.width = 'calc(100% + ' + (paddingLeft * 2) + 'px)';
32027						});
32028					}
32029
32030					// 1. toggle close button
32031					document.querySelectorAll('.mobile-menu > .mobile-menu__close').forEach(el => el.classList.toggle('header-menu__item--hidden'));
32032					// 2. toggle the submenu
32033					if (submenu) submenu.classList.toggle('header-menu__sub-menu
32033--visible');
32034					// 3. toggle the main menu item link
32035					document.querySelectorAll('.header-menu__item-link').forEach(el => el.classList.toggle('header-menu__item--hidden'));
32036					// 4. toggle the main menu item <li>
32037					document.querySelectorAll('.header-menu__item-link').forEach(el => {
32038						if (el.parentElement) el.parentElement.classList.toggle('header-menu__item--hidden');
32039					});
32040					// 5. make sure that the current menu item <li> stays visible
32041					if (submenu && submenu.parentElement) submenu.parentElement.classList.remove('header-menu__item--hidden');
32042				});
32043			});
32044
32045			// Has Sub Submenu
32046			document.querySelectorAll('.header-menu--levels .header-menu__item-link--has-sub-submenu').forEach(element => {
32047				element.addEventListener('click', function(e) {
32048					e.preventDefault();
32049					let subItem = e.currentTarget.closest('.header-menu__sub-item');
32050					let submenu = subItem ? subItem.querySelector('.header-menu__sub-sub-menu') : null;
32051					// 1. toggle the submenu
32052					if (submenu) submenu.classList.toggle('header-menu__sub-menu--visible');
32053					// 2. toggle the main menu item link
32054					document.querySelectorAll('.header-menu__sub-item-link').forEach(el => el.classList.toggle('header-menu__item--hidden'));
32055					// 3. toggle the main menu item <li>
32056					document.querySelectorAll('.header-menu__sub-item-link').forEach(el => {
32057						if (el.parentElement) el.parentElement.classList.toggle('header-menu__item--hidden');
32058					});
32059					// 4. make sure that the current menu item <li> stays visible
32060					if (submenu && submenu.parentElement) submenu.parentElement.classList.remove('header-menu__item--hidden');
32061					// 5. toggle the visibility of the parent menu item title
32062					// 6. toggle the visibility of the parent title bar
32063					if (submenu) {
32064						let parentSubMenu = submenu.closest('.header-menu__sub-menu');
32065						if (parentSubMenu) {
32066							parentSubMenu.querySelectorAll('.header-menu__item-title--main').forEach(el => el.classList.toggle('header-menu__item--hidden'));
32067							parentSubMenu.querySelectorAll('.header-menu__title-bar--main').forEach(el => el.classList.toggle('header-menu__item--hidden'));
32068						}
32069					}
32070				});
32071			});
32072
32073			// accessibility open submenu
32074			document.querySelectorAll('header .header-menu__item-link').forEach(element => {
32075				const menuItem = element.parentElement?.classList.contains('header-menu__item') ? element.parentElement : null;
32076				element.addEventListener('keydown', function(e) {
32077					if (e.key !== 'Enter') return;
32078					if (!menuItem) return;
32079					let isMenuOpen = menuItem.classList.contains('header-menu__item--focus');
32080					let hasSubmenu = menuItem.querySelectorAll('.header-menu__sub-menu').length > 0;
32081					if (!isMenuOpen && hasSubmenu) {
32082						e.preventDefault();
32083						menuItem.classList.add('header-menu__item--focus');
32084						element.setAttribute('aria-expanded', 'true');
32085					}
32086				});
32087				element.addEventListener('mouseenter', function() {
32088					if (!menuItem) return;
32089					let hasSubmenu = menuItem.querySelectorAll('.header-menu__sub-menu').length > 0;
32090					if (hasSubmenu) {
32091						element.setAttribute('aria-expanded', 'true');
32092					}
32093				});
32094				element.addEventListener('mouseleave', function() {
32095					if (!menuItem) return;
32096					let hasSubmenu = menuItem.querySelectorAll('.header-menu__sub-menu').length > 0;
32097					let isMenuOpen = menuItem.classList.contains('header-menu__item--focus');
32098					if (!isMenuOpen && hasSubmenu) {
32099						element.setAttribute('aria-expanded', 'false');
32100					}
32101				});
32102				// on focus change to different main menu item close all other submenus
32103				element.addEventListener('focus', function() {
32104					document.querySelectorAll('.header-menu__item--focus').forEach(el => el.classList.remove('header-menu__item--focus'));
32105					document.querySelectorAll('.header-menu__item-link').forEach(el => el.setAttribute('aria-expanded', 'false'));
32106				});
32107			});
32108
32109			// add external link notice to external links
32110			if (!location.origin) location.origin = location.protocol + "//" + location.host;
32111			document.querySelectorAll('a').forEach(link => {
32112				let href = link.getAttribute('href');
32113				let className = link.getAttribute('class') || '';
32114				if (href && !className.includes('featherlight-link')) {
32115					if ((href.indexOf('http://') >= 0 || href.indexOf('https://') >= 0) && href.indexOf(location.origin) < 0) {
32116						// is external link
32117						link.insertAdjacentHTML('beforeend', '<span class="access-hide"> (Externer Link)</span>');
32118					}
32119				}
32120			});
32121
32122			document.addEventListener('keyup', function(e) {
32123				if (e.key === 'Escape') {
32124					document.querySelectorAll('.header-menu__item--focus').forEach(el => el.classList.remove('header-menu__item--focus'));
32125					document.querySelectorAll('.header-menu__item-link').forEach(el => el.setAttribute('aria-expanded', 'false'));
32126					toggleMenuFunction(true);
32127					self.$store.state.app.isWishlistPopupOpen = false;
32128					self.$store.state.checkout.isCartPopupOpen = false;
32129					let searchHeader = document.querySelector('.search-header');
32130					if (searchHeader && searchHeader.classList.contains('search-header--active')) {
32131						document.querySelectorAll('.search-header').forEach(s => s.classList.remove('search-header--active'));
32132						document.querySelectorAll('.header-toolbox__search a').forEach(a => a.setAttribute('aria-expanded', 'false'));
32133						document.querySelector('.header-toolbox__search a')?.focus();
32134					}
32135				}
32136			});
32137
32138
32139
32140			document.querySelectorAll('.video-element__transcription-link').forEach(videoTranscriptionLink => {
32141				videoTranscriptionLink.addEventListener('click', function(e) {
32142					e.preventDefault();
32143					let parent = videoTranscriptionLink.parentElement;
32144					if (parent) {
32145						parent.querySelectorAll('.video-element__transcription-text').forEach(el => el.classList.toggle('video-element__transcription-text--invisible'));
32146					}
32147					videoTranscriptionLink.classList.toggle('video-element__transcription-link--invisible');
32148				});
32149			});
32150
32151
32152			// calculate the header lines heights and set the top position of the header to the height of the header lines before
32153
32154			const recalculateHeaderLines = () => {
32155				let headerLines = document.querySelectorAll('header > div, .search-header');
32156				let headerHeight = 0;
32157				let windowWidth = window.innerWidth;
32158
32159				headerLines.forEach(line => {
32160					line.style.top = headerHeight + 'px';
32161					if (
32162						(windowWidth >= 1200 && line.classList.contains('sticky')) ||
32163						(windowWidth < 1200 && line.classList.contains('sticky-mobile'))
32164					) {
32165						headerHeight += line.offsetHeight;
32166					}
32167				});
32168			};
32169
32170			recalculateHeaderLines();
32171			window.addEventListener('resize', function() {
32172				// 400ms timeout to make sure the transition is finished, so the header height is accurate
32173				setTimeout(recalculateHeaderLines, 400);
32174			});
32175
32176
32177			// if is logged in show the account label
32178			if (self.isLoggedIn()) {
32179				// set the account label to "Konto"
32180				document.querySelectorAll('.toolbox-item__text--account').forEach(el => el.textContent = labels['toolbox']['account'][SP_CONSTANTS.LOCALE]);
32181			}
32182
32183		};
32184		// faithfully replicate jQuery(document).ready: never run synchronously
32185		if (document.readyState === 'loading') {
32186			document.addEventListener('DOMContentLoaded', onDomReady);
32187		} else {
32188			setTimeout(onDomReady);
32189		}
32190
32191
32192		document.querySelectorAll('.gs_input__fieldset').forEach(fieldset => {
32193			fieldset.addEventListener('click', function() {
32194				if (fieldset.querySelectorAll('.input--type-number').length <= 0) {
32195					fieldset.querySelector('input')?.focus();
32196				}
32197			});
32198		});
32199
32200		// search add focus class
32201		document.querySelectorAll('.header-search__input').forEach(input => {
32202			input.addEventListener('focus', function() {
32203				document.querySelectorAll('.header-search').forEach(el => {
32204					el.classList.add('gs_search__container-focus');
32205					el.classList.add('gs_search__container--focus');
32206				});
32207			});
32208			input.addEventListener('blur', function() {
32209				document.querySelectorAll('.header-search').forEach(el => {
32210					el.classList.remove('gs_search__container-focus');
32211					el.classList.remove('gs_search__container--focus');
32212				});
32213			});
32214		});
32215
32216
32217		await new Promise(resolve => {
32218			let interval = setInterval(() => {
32219				if (self.userInteracted) {
32220
32221					clearInterval(interval);
32222					resolve();
32223				}
32224			}, 100);
32225		});
32226
32227		this.loadSliders();
32228		this.loadCart();
32229
32230		document.querySelectorAll('.sp-slider-wrapper').forEach(wrapper => {
32231			const slider = jQuery(wrapper).find('.sp-slider');
32232			slider.slick('slickSetOption', 'autoplay', true, true);
32233		});
32234
32235		new page_collection();
32236		// pageCollection.init();
32237
32238		const contentElements = document.querySelectorAll('[data-scroll-trigger-xs],[data-scroll-trigger-sm],[data-scroll-trigger-md],[data-scroll-trigger-lg],[data-scroll-trigger-xl]');
32239
32240		const observer = new IntersectionObserver(entries => {
32241			entries.forEach(entry => {
32242			if (entry.isIntersecting) {
32243				entry.target.classList.add('scroll-triggered--shown');
32244				// entry.target.classList.remove('scroll-triggered--hidden');
32245				observer.unobserve(entry.target);
32246			}
32247			});
32248		});
32249		
32250		contentElements.forEach(element => {
32251			observer.observe(element);
32252		});
32253
32254		// .shopando-copy
32255
32256		const getElementBackgroundColor = function(element) {
32257			while (element) {
32258				const bgColor = window.getComputedStyle(element).backgroundColor;
32259				if (bgColor && bgColor !== "transparent" && bgColor !== "rgba(0, 0, 0, 0)") {
32260					return bgColor; // Found a valid background color
32261				}
32262				element = element.parentElement; // Move up the DOM tree
32263			}
32264			return "white"; // Default in case no background color is found
32265		}
32266
32267		const getContrastColor = function(bgColor) {
32268			// Convert color to RGB
32269			let r, g, b, a;
32270			if (bgColor.startsWith("rgba")) {
32271				[r, g, b, a] = bgColor.match(/\d+/g).map(Number);
32272				r = Math.round(r * a + 255 * (1 - a));
32273				g = Math.round(g * a + 255 * (1 - a));
32274				b = Math.round(b * a + 255 * (1 - a));
32275			} else if (bgColor.startsWith("rgb")) {
32276				[r, g, b] = bgColor.match(/\d+/g).map(Number);
32277			} else {
32278				// Convert HEX to RGB
32279				const hex = bgColor.replace("#", "");
32280				if (hex.length === 3) {
32281					[r, g, b] = hex.split("").map(c => parseInt(c + c, 16));
32282				} else {
32283					[r, g, b] = [hex.substring(0,2), hex.substring(2,4), hex.substring(4,6)].map(c => parseInt(c, 16));
32284				}
32285			}
32286
32287			// Calculate brightness
32288			const brightness = (r * 299 + g * 587 + b * 114) / 1000;
32289
32290			// Return black for light backgrounds and white for dark backgrounds
32291			return brightness > 128 ? "#333" : "#ddd";
32292		}
32293
32294		const updateLinkContrast = function(link) {
32295			if (!link) return;
32296			const bgColor = getElementBackgroundColor(link);
32297			const contrastColor = getContrastColor(bgColor);
32298			link.style.color = contrastColor;
32299		}
32300
32301		let shopandoCopy = document.querySelector('.shopando-copy a');
32302		updateLinkContrast(shopandoCopy);
32303
32304	}
32305});
32306
32307;// ./vue/App.vue?vue&type=script&lang=js
32308 
32309;// ./vue/App.vue
32310
32311
32312
32313
32314;
32315const App_exports_ = /*#__PURE__*/(0,exportHelper/* default */.A)(Appvue_type_script_lang_js, [['render',Appvue_type_template_id_331b2732_render]])
32316
32317/* harmony default export */ const App = (App_exports_);
32318;// ./vue/misc/SimpleRouter.js
32319
32320
32321
32322/* harmony default export */ const SimpleRouter = ((config, components) => {
32323  for (let element in config) {
32324    let entry = config[element];
32325
32326    if (!document.querySelector(element)) continue;
32327
32328    let component = typeof entry === 'function' ? (0,vue_esm_bundler/* defineAsyncComponent */.$V)(entry) : entry;
32329
32330    const app = (0,vue_esm_bundler/* createApp */.Ef)({
32331      render: () => (0,vue_esm_bundler.h)(component)
32332    });
32333
32334    for (let componentName in components) {
32335      app.component(componentName, components[componentName]);
32336    }
32337
32338    app.use(store);
32339    app.mount(element);
32340  }
32341});
32342;// ./vue/main.js
32343
32344
32345
32346
32347
32348
32349
32350
32351__webpack_require__(1143);
32352
32353
32354
32355
32356
32357
32358
32359
32360
32361
32362
32363
32364(async () => {
32365
32366	const app = (0,vue_esm_bundler/* createApp */.Ef)({})
32367
32368	window.labels = [];
32369	for (let label of SP_CONSTANTS.LABELS) {
32370		let [labelDomain, labelName] = label.name.split('.');
32371
32372		if (!window.labels[labelDomain]) window.labels[labelDomain] = [];
32373		if (!window.labels[labelDomain][labelName]) window.labels[labelDomain][labelName] = [];
32374		
32375		window.labels[labelDomain][labelName][SP_CONSTANTS.LOCALE] = label.text;
32376	}
32377
32378
32379	// Register Global Components
32380	for (let componentName in components) {
32381		app.component(componentName, components[componentName]);
32382	}
32383
32384	app.use(store);
32385
32386	SimpleRouter({
32387		'#app': App,
32388		'#filter': () => __webpack_require__.e(/* import() */ 92).then(__webpack_require__.bind(__webpack_require__, 7092)),
32389		'#find-as-you-type': () => __webpack_require__.e(/* import() */ 608).then(__webpack_require__.bind(__webpack_require__, 2608)),
32390		'#find-as-you-type-toggle': () => __webpack_require__.e(/* import() */ 608).then(__webpack_require__.bind(__webpack_require__, 2608))
32391	}, components);
32392
32393	// The checkout used to be created here as well. That raced the store: App.vue dispatches
32394	// checkout/loadOrCreateNew on every page, which creates one too when the cookie is missing,
32395	// and both wrote the cookie only in their response callback — so both saw "no cookie" and
32396	// posted. Measured in production: 687 duplicate creates a day, 684 of them provably from
32397	// these two senders (differing request sizes within one page load
32397), and 48 of those pairs
32398	// deadlocked in InnoDB and reached the customer as a 500.
32399	//
32400	// The store path is the one to keep: it also sends the timezone, Accept-Language and the
32401	// customer's access token, none of which the create here did.
32402
32403	let routes = {
32404		'#product': () => Promise.all(/* import() */[__webpack_require__.e(84), __webpack_require__.e(326)]).then(__webpack_require__.bind(__webpack_require__, 2326)),
32405		'#checkout': () => __webpack_require__.e(/* import() */ 56).then(__webpack_require__.bind(__webpack_require__, 1056)),
32406		'#profile': () => Promise.all(/* import() */[__webpack_require__.e(46), __webpack_require__.e(865)]).then(__webpack_require__.bind(__webpack_require__, 6865)),
32407		'#wishlist': () => __webpack_require__.e(/* import() */ 596).then(__webpack_require__.bind(__webpack_require__, 5596)),
32408		'#order': () => Promise.all(/* import() */[__webpack_require__.e(46), __webpack_require__.e(903)]).then(__webpack_require__.bind(__webpack_require__, 2903)),
32409		'#order-withdrawal': () => __webpack_require__.e(/* import() */ 322).then(__webpack_require__.bind(__webpack_require__, 5322)),
32410		'#product-review': () => __webpack_require__.e(/* import() */ 215).then(__webpack_require__.bind(__webpack_require__, 9215)),
32411		'#product-review-list': () => __webpack_require__.e(/* import() */ 84).then(__webpack_require__.bind(__webpack_require__, 8084)),
32412		'#product-review-summary': () => __webpack_require__.e(/* import() */ 549).then(__webpack_require__.bind(__webpack_require__, 9549))
32413	};
32414
32415	let forms = document.querySelectorAll('.sp-form');
32416	for (let form of forms) {
32417		let formId = form.getAttribute('id');
32418		let routeSelector = '#' + formId;
32419		routes[routeSelector] = () => __webpack_require__.e(/* import() */ 214).then(__webpack_require__.bind(__webpack_require__, 7214));
32420	}
32421
32422	SimpleRouter(routes, components);
32423
32424})();
32425
32426window.downloadAs = async function(url, name) {
32427	try {
32428		const response = await fetch(url, {
32429		headers: {
32430			"Content-Type": "application/octet-stream"
32431		}
32432		});
32433
32434		if (!response.ok) {
32435		throw new Error(`Network response was not ok: ${response.status}`);
32436		}
32437
32438		const blob = await response.blob();
32439
32440		const a = document.createElement("a");
32441		const urlObject = window.URL.createObjectURL(blob);
32442		a.href = urlObject;
32443		if (name) {
32444			a.download = name;
32445		} else {
32446			a.download = '';
32447		}
32448		a.click();
32449
32450		window.URL.revokeObjectURL(urlObject);
32451	} catch (err) {
32452		console.error("error", err);
32453	}
32454}
32455
32456window.openCookieOptIn = function() {
32457	var cookieOpen = new Event('CookieOptInOpen'); 
32458	document.dispatchEvent(cookieOpen);
32459}
32460
32461window.triggerCart = function() {
32462	var cartOpen = new Event('CartPopupOpen'); 
32463	document.dispatchEvent(cartOpen);
32464}
32465
32466const ACCORDION_ACTIVE_CLASS = 'gs_content-container-accordion__accordion-header--active';
32467const ACCORDION_HEADER_SELECTOR = '.gs_content-container-accordion__accordion-header';
32468
32469function syncAccordionHeader(btn) {
32470	let isOpen = btn.getAttribute('aria-expanded') === 'true';
32471	btn.classList.toggle('active', isOpen);
32472	btn.classList.toggle(ACCORDION_ACTIVE_CLASS, isOpen);
32473}
32474
32475function observeAccordionHeader(btn) {
32476	let body = document.querySelector(btn.getAttribute('data-target'));
32477	if (body) {
32478		let isOpen = body.classList.contains('show');
32479		btn.classList.toggle('active', isOpen);
32480		btn.classList.toggle(ACCORDION_ACTIVE_CLASS, isOpen);
32481	}
32482	new MutationObserver(() => syncAccordionHeader(btn))
32483		.observe(btn, { attributes: true, attributeFilter: ['aria-expanded'] });
32484}
32485
32486function initContentAccordions() {
32487	document.querySelectorAll(ACCORDION_HEADER_SELECTOR).forEach(observeAccordionHeader);
32488}
32489
32490if (document.readyState === 'loading') {
32491	document.addEventListener('DOMContentLoaded', initContentAccordions);
32492} else {
32493	initContentAccordions();
32494}
32495
32496document.addEventListener('form-refresh', function(e) {
32497
32498	let detail = e.detail;
32499	let formId = detail.formId;
32500	let data = {}
32501	data['#'+formId] = () => __webpack_require__.e(/* import() */ 214).then(__webpack_require__.bind(__webpack_require__, 7214));
32502	SimpleRouter(data, components);
32503});
32504
32505window.getCountryCode = function() {
32506	let timezone = Intl.DateTimeFormat().resolvedOptions().timeZone;
32507	// european + us, canada
32508	const countryCodesByTimezone = {
32509		'Europe/Vienna': 'AT',
32510		'Europe/Brussels': 'BE',
32511		'Europe/Zurich': 'CH',
32512		'Europe/Berlin': 'DE',
32513		'Europe/Copenhagen': 'DK',
32514		'Europe/Madrid': 'ES',
32515		'Europe/Paris': 'FR',
32516		'Europe/London': 'GB',
32517		'Europe/Dublin': 'IE',
32518		'Europe/Rome': 'IT',
32519		'Europe/Amsterdam': 'NL',
32520		'Europe/Oslo': 'NO',
32521		'Europe/Stockholm': 'SE',
32522		'Europe/Helsinki': 'FI',
32523		'Europe/Athens': 'GR',
32524		'Europe/Budapest': 'HU',
32525		'Europe/Warsaw': 'PL',
32526		'Europe/Prague': 'CZ',
32527		'Europe/Bucharest': 'RO',
32528		'Europe/Sofia': 'BG',
32529		'Europe/Tallinn': 'EE',
32530		'Europe/Vilnius': 'LT',
32531		'Europe/Riga': 'LV',
32532		'Europe/Bratislava': 'SK',
32533		'Europe/Lisbon': 'PT',
32534		'Europe/Luxembourg': 'LU',
32535		'Europe/Malta': 'MT',
32536		'Europe/Nicosia': 'CY',
32537		'Europe/Reykjavik': 'IS',
32538		'Europe/Zagreb': 'HR',
32539		'Europe/Skopje': 'MK',
32540		'Europe/Kiev': 'UA',
32541		'Europe/Sarajevo': 'BA',
32542		'Europe/Minsk': 'BY',
32543		'Europe/Chisinau': 'MD',
32544		'Europe/Tirane': 'AL',
32545		'Europe/Andorra': 'AD',
32546		'Europe/Vaduz': 'LI',
32547		'Europe/Monaco': 'MC',
32548		'Europe/San_Marino': 'SM',
32549		'Atlantic/Reykjavik': 'IS',
32550		'Atlantic/Azores': 'PT',
32551		'Atlantic/Canary': 'ES',
32552		'America/New_York': 'US',
32553		'America/Detroit': 'US',
32554		'America/Kentucky/Louisville': 'US',
32555		'America/Kentucky/Monticello': 'US',
32556		'America/Indiana/Indianapolis': 'US',
32557		'America/Indiana/Vincennes': 'US',
32558		'America/Indiana/Winamac': 'US',
32559		'America/Indiana/Marengo': 'US',
32560		'America/Indiana/Petersburg': 'US',
32561		'America/Indiana/Vevay': 'US',
32562		'America/Chicago': 'US',
32563		'America/Indiana/Tell_City': 'US',
32564		'America/Indiana/Knox': 'US',
32565		'America/Menominee': 'US',
32566		'America/North_Dakota/Center': 'US',
32567		'America/North_Dakota/New_Salem': 'US',
32568		'America/North_Dakota/Beulah': 'US',
32569		'America/Denver': 'US',
32570		'America/Boise': 'US',
32571		'America/Phoenix': 'US',
32572		'America/Los_Angeles': 'US',
32573		'America/Anchorage': 'US',
32574		'America/Juneau': 'US',
32575		'America/Sitka': 'US',
32576		'America/Metlakatla': 'US',
32577		'America/Yakutat': 'US',
32578		'America/Nome': 'US',
32579		'America/Adak': 'US',
32580		'Pacific/Honolulu': 'US',
32581		'America/St_Johns': 'CA',
32582		'America/Halifax': 'CA',
32583		'America/Glace_Bay': 'CA',
32584		'America/Moncton': 'CA',
32585		'America/Goose_Bay': 'CA',
32586		'America/Blanc-Sablon': 'CA',
32587		'America/Toronto': 'CA',
32588		'America/Nipigon': 'CA',
32589		'America/Thunder_Bay': 'CA',
32590		'America/Iqaluit': 'CA',
32591		'America/Pangnirtung': 'CA',
32592		'America/Atikokan': 'CA',
32593		'America/Winnipeg': 'CA',
32594		'America/Rainy_River': 'CA',
32595		'America/Resolute': 'CA',
32596		'America/Rankin_Inlet': 'CA',
32597		'America/Regina': 'CA',
32598		'America/Swift_Current': 'CA',
32599		'America/Edmonton': 'CA',
32600		'America/Cambridge_Bay': 'CA',
32601		'America/Yellowknife': 'CA',
32602		'America/Inuvik': 'CA',
32603		'America/Creston': 'CA',
32604		'America/Dawson_Creek': 'CA',
32605		'America/Fort_Nelson': 'CA',
32606		'America/Vancouver': 'CA',
32607		'America/Whitehorse': 'CA'
32608	};
32609
32610	let countryCode = countryCodesByTimezone[timezone];
32611
32612	if (!countryCode) {
32613		countryCode = null;
32614	}
32615
32616	return countryCode;
32617};
32618
32619
32620function setSliderPauseButton(id, ariaPressed, iconKey, onclickFn) {
32621	document.querySelectorAll('[data-id="'+id+'"] .sp-slider .sp-slider__pause').forEach(el => {
32622		el.setAttribute('aria-pressed', ariaPressed);
32623		el.setAttribute('onclick', onclickFn);
32624		el.innerHTML = '<i class="shopandicon ' + SP_CONSTANTS.THEME[iconKey] + '"></i>';
32625	});
32626}
32627
32628window.stopSlider = id => {
32629	jQuery('[data-id="'+id+'"] .sp-slider').slick('slickPause');
32630	setSliderPauseButton(id, 'true', 'SLIDER_PLAY_ICON', 'startSlider(\''+id+'\')');
32631};
32632
32633window.startSlider = id => {
32634	jQuery('[data-id="'+id+'"] .sp-slider').slick('slickPlay');
32635	setSliderPauseButton(id, 'false', 'SLIDER_PAUSE_ICON', 'stopSlider(\''+id+'\')');
32636};
32637
32638window.togglePopup = id => {
32639	document.querySelectorAll('.floatbox__wrapper[data-id="'+id+'"]').forEach(el => el.classList.toggle('floatbox__wrapper--active'));
32640	document.dispatchEvent(new Event('PopupToggled'));
32641}
32642
32643window.hideAllPopups = id => {
32644	document.querySelectorAll('.floatbox__wrapper').forEach(el => el.classList.remove('floatbox__wrapper--active'));
32645	document.dispatchEvent(new Event('PopupToggled'));
32646}
32647
32648window.showPopup = id => {
32649	document.querySelectorAll('.floatbox__wrapper[data-id="'+id+'"]').forEach(el => el.classList.add('floatbox__wrapper--active'));
32650	document.dispatchEvent(new Event('PopupToggled'));
32651}
32652
32653window.toggleHighContrast = () => {
32654	document.body.classList.toggle('high-contrast-mode');
32655	document.querySelectorAll('.contrast-switch i').forEach(el => {
32656		el.classList.toggle('spi_switch-off');
32657		el.classList.toggle('spi_switch-on');
32658	});
32659	document.querySelectorAll('.contrast-switch').forEach(el => el.classList.toggle('gs_global__contrast-switch--active'));
32660
32661	const contrastSwitch = document.querySelector('.contrast-switch');
32662	const newPressed = contrastSwitch?.getAttribute('aria-pressed') === 'true' ? 'false' : 'true';
32663	document.querySelectorAll('.contrast-switch').forEach(el => el.setAttribute('aria-pressed', newPressed));
32664
32665	localStorage.setItem('high-contrast-mode', newPressed);
32666}
32667
32668if (document.querySelector('.contrast-switch')?.getAttribute('aria-pressed') === 'true') {
32669	document.body.classList.toggle('high-contrast-mode');
32670}
32671
32672// read local storage and set high contrast mode accordingly
32673if (localStorage.getItem('high-contrast-mode') == 'true') {
32674	document.body.classList.add('high-contrast-mode');
32675	document.querySelectorAll('.contrast-switch i').forEach(el => {
32676		el.classList.add('spi_switch-on');
32677		el.classList.remove('spi_switch-off');
32678	});
32679	document.querySelectorAll('.contrast-switch').forEach(el => {
32680		el.classList.add('gs_global__contrast-switch--active');
32681		el.setAttribute('aria-pressed', 'true');
32682	});
32683} else if (localStorage.getItem('high-contrast-mode') == 'false') {
32684	document.body.classList.remove('high-contrast-mode');
32685	document.querySelectorAll('.contrast-switch i').forEach(el => {
32686		el.classList.remove('spi_switch-on');
32687		el.classList.add('spi_switch-off');
32688	});
32689	document.querySelectorAll('.contrast-switch').forEach(el => {
32690		el.classList.remove('gs_global__contrast-switch--active');
32691		el.setAttribute('aria-pressed', 'false');
32692	});
32693}
32694
32695var latestStyleUpdate = 0;
32696
32697window.addEventListener('message', async function(event) {
32698
32699	if (event.data.type == 'credentials') {
32700
32701		let hasOnlineTokenInput = document.querySelector('input#onlineToken');
32702		if (!hasOnlineTokenInput) return;
32703		
32704		// create fake form with hidden fields to submit the credentials, target is same
32705		let form = document.createElement('form');
32706		form.setAttribute('method', 'POST');
32707		
32708		// add inputs
32709		let input = document.createElement('input');
32710		input.setAttribute('type', 'hidden');
32711		input.setAttribute('name', 'previewToken');
32712		input.setAttribute('value', event.data.credentials.previewToken);
32713		form.appendChild(input);
32714
32715		input = document.createElement('input');
32716		input.setAttribute('type', 'hidden');
32717		input.setAttribute('name', 'onlineToken');
32718		input.setAttribute('value', event.data.credentials.onlineToken);
32719		form.appendChild(input);
32720
32721		document.body.appendChild(form);
32722		form.submit();
32723		form.remove();
32724		
32725
32726	} else if (event.data.type === 'hotReload') {
32727		
32728		let styleSetPojo = event.data.data;
32729
32730		// styleSetPojo is the JSON string the style editor sends via postMessage, and
32731		// StyleSetUpdaterController json_decodes it — declare it as such so the WAF
32732		// inspects real fields instead of the whole body as one argument name.
32733		const fetchConfig = {
32734			method: 'POST',
32735			headers: {
32736				'Content-type': 'application/json'
32737			}
32738		};
32739		fetchConfig.body = styleSetPojo;
32740
32741		let isLocal = false;
32742		if (SP_CONSTANTS.HOST.indexOf('smarda.local') > -1) {
32743			isLocal = true;
32744		}
32745
32746		let protocol = 'https://';
32747		if (isLocal) {
32748			protocol = 'http://';
32749		}
32750
32751		await window.fetch(protocol + SP_CONSTANTS.HOST + '/style-sets/generate', fetchConfig)
32752			.then(async (response) => {
32753				return response.text();
32754			})
32755			.then((message) => {
32756
32757				// guard that an older style that happens to 
32758				// be loaded after a newer one doesn't overwrite the newer one
32759				if (event.data.time < latestStyleUpdate) {
32760					return;
32761				} else {
32762					latestStyleUpdate = event.data.time;
32763				}
32764
32765				let styleParts = JSON.parse(message);
32766				if (styleParts) {
32767					let fullCss = '';
32768					for (let css of Object.values(styleParts)) {
32769						fullCss += css;
32770					}
32771					document.getElementById('custom-styles').innerHTML = fullCss;
32772				}
32773			});
32774
32775		// send message back to parent
32776		window.parent.postMessage({type: 'hotReload', data: 'done', time: event.data.time, action: event.data.action}, '*');
32777			
32778		FrontendInterfaceUtils.editorReplaceHover();
32779	}
32780});
32781})();
32782
32783/******/ })()
32784;

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.